Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix for CameraView blacks outs and Aspect ratio iteration issue #1

Merged
merged 5 commits into from
Jun 14, 2017

Conversation

dsegna
Copy link
Owner

@dsegna dsegna commented Jun 14, 2017

Original pull request here: google#125

Fixed layout issues with the capture FAB in the demo (google#120)
getSupportedAspectRatio returns aspect ratios of preview sizes for which
picture sizes doesn't exist. This results in NullPointerException. So
getSuportedAspectRatio now depends on suported Picture Sizes
Resolves: google#88
TextureView/SurfaceView was added twice to CameraView. So when
requestLayout is called on CameraView blank surface comes up. Note that
CameraView parent is FrameLayout, so last added view comes in front.
In the solution, I have simply removed last added
TextureView/SurfaceView before adding new TextureView/SurfaceView inside
start function on CameraView. This makes sure that new Surface is
created for each start.

Resolves: google#111
It is not safe to traverse and remove from the same set. It will result
is `ConcurrentModificationException` or `NullpointerException` in case
of ArrayMap. So new `Set<AspectRatio>` was added to traverse the
ArrayMap.

Check commit: 6ceaf86
@dsegna dsegna merged commit 5205390 into dsegna:master Jun 14, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants