question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

blur after moveTo(newX, newY);

See original GitHub issue

I use GYROSCOPE sensor to swipe & scroll pdfview,

bellow my pdfview init ` pdfView = (PDFView)activity.findViewById(resource_layout); pdfView.setLayerType(View.LAYER_TYPE_HARDWARE,null); pdfView.setDrawingCacheEnabled(true); pdfView.enableRenderDuringScale(false); pdfView.useBestQuality(true);

    InputStream inStream = activity.getResources().openRawResource(resource_raw);


    pdfView.fromStream(inStream)
            .defaultPage(0)
            .onPageChange(this)
            .enableDoubletap(false)
            .enableAnnotationRendering(true)
            .onLoad(this)
            .onPageScroll(this)
            .scrollHandle(new DefaultScrollHandle(activity))
            .load();

`

on loadcomplete I set zoom to 3

@Override public void loadComplete(int nbPages) { pdfView.zoomTo(3); }

when pdfview zoom to 3, it works well,

but when I scroll with sensor ` @Override public void onSensorChanged(SensorEvent event) { float valuey = event.values[0]; float valuex = event.values[1]; valuey = valuey * 50; valuex = valuex * 50;

    smoothedX       = smooth(valuex, smoothedX);
    valuex          = smoothedX;
    smoothedY       = smooth(valuey, smoothedY);
    valuey          = smoothedY;

    float baseX = pdfView.getCurrentXOffset();
    float baseY = pdfView.getCurrentYOffset();
    if(abs(valuex)>3 || abs(valuey)>3){
        baseY += valuey;
        baseX -= valuex;
        pdfView.moveTo(baseX, baseY);
    }
}`

pdf move to point x & y correctly , but display is blur photo_2017-05-22_13-12-32

please help…

Issue Analytics

  • State:open
  • Created 6 years ago
  • Comments:13 (5 by maintainers)

github_iconTop GitHub Comments

2reactions
barteksccommented, Jun 6, 2017

You may try using pdfView.loadPages() after .moveTo()

1reaction
YuriyBereguliakcommented, Jun 26, 2018

I just using .loadPages() method after moveTo or zoomTo. And after that all this small grids releases.

Read more comments on GitHub >

github_iconTop Results From Across the Web

How to use Motion Blur for Beginners - After Effects Tutorial
Join Nebula for $3 a month to get access to exclusive content from over 150 creators you already love! http://nebula.tv/moboxIn this After ......
Read more >
Element: blur event - Web APIs | MDN
The blur event fires when an element has lost focus. The event does not bubble, but the related focusout event that follows does...
Read more >
How can tell I which element i clicked on to trigger a blur event ...
I have a blur() event handler that fires a function, I want the function not to fire when the blur is triggered by...
Read more >
How to Disable Home Screen Wallpaper Blur in iOS 16
1. Long-press on the lock screen to enter the customization mode and click on the plus (+) button to add new wallpaper.
Read more >
Javascript Window Blur() and Window Focus() Method
Javascript Window Blur() method is used to remove focus from the current window. i.e, It sends the new open Window to the background....
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found