CameraView
CameraView copied to clipboard
Can the camera be prepared in other thread to avoid UI glitches while opening?
Currently whenever camera open/close is called the UI stucks. Can we prepare camera preview in some other thread to atleast reduce jerks specially when camera is in ViewPager fragment similar to instagram.
Version used
2.7.2
This issue has been automatically marked as stale because it has not had activity in the last 20 days. It will be closed if no further activity occurs within the next seven days. Thank you for your contributions.
@usmanrana-ilsa do you have solve this problem?
In my case I was doing some other operations too during swipe on page. Holding them unless camera fragment is resumed improved the performance. Otherwise camera is preparing in main thread and that would cause some glitch. Almost similar behavior is observed in Instagram camera as well.
im using view pager with 3 fragments. when page is swiped, i'm not doing any operation. but its still show some glitch (showing overlay gray, before camera preview is loaded). do you experience it? @usmanrana07
yes, CameraView isn't resuming from last paused preview, but shows shuttering effect while resume again
How to solve the problem of slow focus when opening?
open or resume camera preview when the page is done swiping and that can help you.