You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I use a BottomNavigationView to navigate between my camera fragment and another one.
On the start of my app the camera preview is loaded correctly.
If I navigate to my second fragment and back again, CameraX is successfully bound to the lifecycle, but the TextureView is black.
I can resolve this by adding Thread.sleep(330) before CameraX.bindToLifecycle() but this is a bad solution, because it adds some delay before showing the preview.
What can I do to solve this problem without this delay?
The text was updated successfully, but these errors were encountered:
ghost
changed the title
Black TextureSurface after navigation
Black TextureView after navigation
Jul 12, 2019
I think, its happen when u rebind camera to lifecycle.
I have black screen os some devices (ex. Alcatel 5059D) when trying to switch between front and back cameras.
I have error in logcat: E/Camera: CameraDevice.onError(): 1 with error: ERROR_MAX_CAMERAS_IN_USE
I think this issue should be at least partially alleviated with alpha04. Please reopen if it still reproduces, and provide specific device and code to reproduce this issue consistently.
I use a
BottomNavigationView
to navigate between my camera fragment and another one.On the start of my app the camera preview is loaded correctly.
If I navigate to my second fragment and back again,
CameraX
is successfully bound to the lifecycle, but theTextureView
is black.I can resolve this by adding
Thread.sleep(330)
beforeCameraX.bindToLifecycle()
but this is a bad solution, because it adds some delay before showing the preview.What can I do to solve this problem without this delay?
The text was updated successfully, but these errors were encountered: