Created
May 3, 2015 20:21
-
-
Save gekkehenkie11/562e51c5f0fddf833338 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| public final void a(aa aa1) | |
| { | |
| int i1; | |
| android.hardware.Camera.Parameters parameters; | |
| Object obj; | |
| try | |
| { | |
| j = Camera.open(o); | |
| } | |
| // Misplaced declaration of an exception variable | |
| catch(aa aa1) | |
| { | |
| com.facebook.debug.a.a.a(a, "Camera open failed", aa1); | |
| throw new z(aa1.getMessage()); | |
| } | |
| c.a(); | |
| parameters = j.getParameters(); | |
| if(a("continuous-picture", j.getParameters().getSupportedFocusModes())) | |
| parameters.setFocusMode("continuous-picture"); | |
| obj = h.a(o); | |
| if(android.os.Build.VERSION.SDK_INT < 11) | |
| { | |
| com.facebook.debug.a.a.a(a, "Finding preview size smaller than and proportional to %d x %d", Integer.valueOf(((CamcorderProfile) (obj)).videoFrameWidth), Integer.valueOf(((CamcorderProfile) (obj)).videoFrameHeight)); | |
| k = s.a(parameters.getSupportedPreviewSizes(), ((CamcorderProfile) (obj)).videoFrameWidth, ((CamcorderProfile) (obj)).videoFrameHeight, v.b); | |
| } | |
| if(android.os.Build.VERSION.SDK_INT >= 11 || k == null) | |
| { | |
| com.facebook.debug.a.a.a(a, "Finding preview size proportional to %d x %d", Integer.valueOf(((CamcorderProfile) (obj)).videoFrameWidth), Integer.valueOf(((CamcorderProfile) (obj)).videoFrameHeight)); | |
| k = s.a(parameters.getSupportedPreviewSizes(), ((CamcorderProfile) (obj)).videoFrameWidth, ((CamcorderProfile) (obj)).videoFrameHeight, v.a); | |
| } | |
| com.facebook.debug.a.a.a(a, "Setting camera preview size %d x %d", Integer.valueOf(k.width), Integer.valueOf(k.height)); | |
| parameters.setPreviewSize(k.width, k.height); | |
| obj = s.a(parameters.getSupportedPictureSizes(), k.width, k.height); | |
| com.facebook.debug.a.a.a(a, "Setting camera picture size %d x %d", Integer.valueOf(((android.hardware.Camera.Size) (obj)).width), Integer.valueOf(((android.hardware.Camera.Size) (obj)).height)); | |
| parameters.setPictureSize(((android.hardware.Camera.Size) (obj)).width, ((android.hardware.Camera.Size) (obj)).height); | |
| j.setParameters(parameters); | |
| if(j != null && android.os.Build.VERSION.SDK_INT >= 14) | |
| { | |
| i = g.a(j, Boolean.valueOf(k())); | |
| i.a(parameters.getPreviewSize().width, parameters.getPreviewSize().height); | |
| } | |
| i1 = a(c.a()); | |
| j.setDisplayOrientation(i1); | |
| if(i != null) | |
| i.a(i1); | |
| try | |
| { | |
| aa1.a(j); | |
| } | |
| // Misplaced declaration of an exception variable | |
| catch(aa aa1) | |
| { | |
| com.facebook.debug.a.a.a(a, "Setting camera preview failed", aa1); | |
| d.a("QuickCamPopup", "error setting the camera to the preview texture. Maybe because the phone isn't ics or above, maybe camera is already in use"); | |
| throw new z(aa1.getMessage()); | |
| } | |
| try | |
| { | |
| j.startPreview(); | |
| return; | |
| } | |
| // Misplaced declaration of an exception variable | |
| catch(aa aa1) | |
| { | |
| com.facebook.debug.a.a.a(a, "Camera start preview failed", aa1); | |
| } | |
| b.execute(new x(this)); | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment