Skip to content

Commit

Permalink
Camcorder: Send initial focus after starting preview
Browse files Browse the repository at this point in the history
Sending the event before preview was crashing qualcomm libcameras

Change-Id: Ib81270d07fcfbecb6042b7260ae9a7b7d5e6b44d
  • Loading branch information
rmcc committed Nov 14, 2011
1 parent d84a534 commit cb2e2f8
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/com/android/camera/VideoCamera.java
Original file line number Diff line number Diff line change
Expand Up @@ -756,7 +756,6 @@ private void startPreview() throws CameraHardwareException {
setCameraParameters();

CameraSettings.setContinuousAf(mParameters, false);
mCameraDevice.autoFocus(null);
// Enable higher framerate recording on some tegra 2 devices
CameraSettings.enableHighFrameRateFHD(mParameters);
CameraSettings.setVideoMode(mParameters, true);
Expand All @@ -769,6 +768,8 @@ private void startPreview() throws CameraHardwareException {
closeCamera();
throw new RuntimeException("startPreview failed", ex);
}

mCameraDevice.autoFocus(null);
}

private void closeCamera() {
Expand Down

14 comments on commit cb2e2f8

@JerryScript-duplicate
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This commit breaks the camera on the Optimus line of phones. Reverting it fixes the issue.

@rmcc
Copy link
Member Author

@rmcc rmcc commented on cb2e2f8 Nov 17, 2011

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You're going to have to be more specific. I'm maintainer for all 3 Optimus phones we support (2X, 3D, and Black), and it works fine on all 3.

@JerryScript-duplicate
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sorry, I'm referring to the inferiorhumanorgans-kang for the Optimus V, S, M, and C.

@koush
Copy link

@koush koush commented on cb2e2f8 Nov 17, 2011

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You may notice this is the CyanogenMod repository, and we don't support other people's builds/ports...

@mrg666
Copy link

@mrg666 mrg666 commented on cb2e2f8 Nov 17, 2011

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We fixed it ourselves and nobody asked your support. This is just a report that we thought could help CM since it has been working fine. This is all about open source development.

@JerryScript-duplicate
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@koush: Yes, we are quite aware of the lack of support for these phones, you've made us painfully aware tyvm.

@defer
Copy link
Member

@defer defer commented on cb2e2f8 Nov 17, 2011

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@JerryScript stop being patronizing. If the developers are interested in adding support for these devices they are welcome to contact us over at #cyanogenmod-dev.

This is a volunteer project, we don't exactly pick which ones we support and which ones we don't. What you can't ask us is to maintain support for something that isn't on our tree. Instead of complaining to us go complain to that inferior-whatever rom and ask him why he doesn't contribute his tree back.

@mrg666
Copy link

@mrg666 mrg666 commented on cb2e2f8 Nov 17, 2011

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Let me repeat, nobody asked any support. The comment was added, as I understand as a normal person, to everyone who use this repository for their project. Do you guys get this kind of arrogance when you deal with Google developers? BTW, it is inferiorhumanorgans, there is no "whatever".

@defer
Copy link
Member

@defer defer commented on cb2e2f8 Nov 17, 2011

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

How can you read arrogance over anything I said?

@mrg666
Copy link

@mrg666 mrg666 commented on cb2e2f8 Nov 17, 2011

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You're welcome. And, thanks for all your work.

@koush
Copy link

@koush koush commented on cb2e2f8 Nov 17, 2011

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Basically what @defer said. My comment wasn't arrogance, it was frustration. You're sending us bug reports on devices that you don't care to push upstream into CM.

@JerryScript-duplicate
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I apologize, I thought many projects used this repo, similar to how AOSP is used. I will maintain my bug reports seperately until such a time as IHO may seek inclusion. I guess all phones must worked 100% with CM source before any bug reports are filed.

@koush
Copy link

@koush koush commented on cb2e2f8 Nov 17, 2011

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Join #cyanogenmod-dev and talk to one of us about forking your device repos. We include devices, given that they mostly work.

@koush
Copy link

@koush koush commented on cb2e2f8 Nov 17, 2011

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

But to be honest, at this point, unless you have something very stable, and ready for our 7.2 release, we probably won't include it: we're all focusing on ICS now. 7.2 will be our final GB release.

Of course, if you are ICS ready, thats another story.

Please sign in to comment.