summaryrefslogtreecommitdiffstats
path: root/services/camera
Commit message (Collapse)AuthorAgeFilesLines
* Merge tag 'android-6.0.1_r17' into HEADJessica Wagantall2016-03-0710-6/+37
|\ | | | | | | | | Android 6.0.1 release 17 Ticket: CYNGNOS-1854
| * Camera: Disallow dumping clients directlyEino-Ville Talvala2016-01-2210-6/+37
| | | | | | | | | | | | | | | | Camera service dumps should only be initiated through ICameraService::dump. Bug: 26265403 Change-Id: If3ca4718ed74bf33ad8a416192689203029e2803
* | cameraservice: Change the error mapping for ERROR_CAMERA_DEVICE.Sai Kumar Sanagavarapu2016-01-081-2/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | In case of API1-HAL3, if HAL reports CAMERA3_MSG_ERROR_DEVICE, it is getting mapped to CAMERA_ERROR_UNKNOWN in the service layer. But this particular error code is not handled properly even in applications like GoogleCamera (Android default camera app). For example if camera deamon gets killed when GoogleCamera is previewing, since its not handling the error properly, preview freeze is seen for long time followed by mediaserver crash if any user interaction happens meanwhile. Ideally, app should close gracefully based on the error received. So, map CAMERA3_MSG_ERROR_DEVICE to CAMERA_ERROR_SERVER_DIED, so that app and mediaserver gets closed gracefully. Change-Id: Idad9d23262e28e85b020b5bacdaad7c77fe16372
* | Merge tag 'android-6.0.1_r3' of ↵Steve Kondik2015-12-074-14/+17
|\ \ | |/ | | | | | | | | | | | | https://android.googlesource.com/platform/frameworks/av into cm-13.0 Android 6.0.1 release 3 Change-Id: I2f2a1fe1b58c828e8341556996211562d6e195ab
| * DO NOT MERGE: libcameraservice: Fix nullptr crash when no client.Tom Keel2015-10-211-2/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | This change prevents a crash in the camera service when the camera HAL notifies the service about the absence of a removable camera and there happens to be no client connected to the service. It checks that the pointer returned from clientToDisconnect.get() is non-null before trying to dereference it (as is done in existing code immediately below this change). Bug: 25165323 Change-Id: I8055654bac980542e63ea7f52bf897eaafbc09bc Signed-off-by: Tom Keel <thomas.keel@intel.com>
| * libcameraservice: Fix ALOG prints in FlashLight.Ranjith Kagathi Ananda2015-10-161-4/+8
| | | | | | | | | | | | | | | | | | Add missing __FUNCTION__ arguments into log statements. Ack by: Dilip Gopalakrishna Bug: 25023187 Change-Id: I0256bad626d490fb9360a73c104afaad7a012a97
| * Camera: frameworks: Add NULL check for callbackRanjith Kagathi Ananda2015-10-161-1/+5
| | | | | | | | | | | | | | | | | | --Added NULL check for mRemoteCallback Ack by: Susmitha Gummalla Bug: 25023187 Change-Id: Ib88a128a52e81b8ec1052e3222b6d8b9e494afcc
| * Merge "Camera: setup vendor tags before get_camera_info" into mnc-dr-devYin-Chia Yeh2015-10-151-6/+7
| |\
| | * Camera: setup vendor tags before get_camera_infoYin-Chia Yeh2015-10-141-6/+7
| | | | | | | | | | | | | | | | | | | | | So HAL can use vendor tags on first get_camera_info call. Bug: 24913201 Change-Id: I73f17de87e3712a27f9cee366995df27a740f5cb
| * | Merge "Camera: Add video recording stop sound" into mnc-dr-devChien-Yu Chen2015-10-144-8/+10
| |\ \
| | * | Camera: Add video recording stop soundChien-Yu Chen2015-10-144-8/+10
| | |/ | | | | | | | | | | | | | | | | | | Add video recording stop sound to match MediaActionSound. Bug: 24745252 Change-Id: I84b69757c7e0a98abfaafcce5f41dd45fd41cf74
| * | DO NOT MERGE: Fix setTorchMode support for the old HAL versionOleksiy Avramchenko2015-10-141-0/+1
| |/ | | | | | | | | | | | | | | | | | | CameraHardwareInterfaceFlashControl class calls disconnectCameraDevice when torch is disabled. This closes connection to the camera module, but mDevice instance is kept and variable is non-NULL which will prevent connection next time torch is going to be enabled. Bug: 24909924 Change-Id: Icb1ffb07f05256afd92821f0f4908cda5332c05b
* | Fix setTorchMode support for the old HAL versionOleksiy Avramchenko2015-11-171-0/+1
| | | | | | | | | | | | | | | | | | CameraHardwareInterfaceFlashControl class calls disconnectCameraDevice when torch is disabled. This closes connection to the camera module, but mDevice instance is kept and variable is non-NULL which will prevent connection next time torch is going to be enabled. Change-Id: Icb1ffb07f05256afd92821f0f4908cda5332c05b
* | Merge branch 'LA.BF64.1.2.2_rb4.7' of ↵Steve Kondik2015-11-161-4/+8
|\ \ | | | | | | | | | | | | | | | git://codeaurora.org/platform/frameworks/av into cm-13.0 Change-Id: Ia41df61c3ccfeb809572b63a4b1a8ca6bd85dfb2
| * \ Merge "Camera: frameworks: Add NULL check for callback"Linux Build Service Account2015-11-041-1/+5
| |\ \
| | * | Camera: frameworks: Add NULL check for callbackSusmitha Gummalla2015-10-301-1/+5
| | | | | | | | | | | | | | | | | | | | | | | | --Added NULL check for mRemoteCallback Change-Id: Ib88a128a52e81b8ec1052e3222b6d8b9e494afcc
| * | | Merge "DO NOT MERGE: CameraService: Link to client binder death at end of ↵Linux Build Service Account2015-11-022-8/+11
| |\ \ \ | | |/ / | |/| | | | | | connect"
| | * | DO NOT MERGE: CameraService: Link to client binder death at end of connectEino-Ville Talvala2015-10-292-8/+11
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | If, within a binder Looper thread, a Binder object death notifier is registered, and then a nested Binder transaction is begun, that transaction may process a death notification callback for the just-registered object, if it was dead at the time of registration. This can lead to an unexpected nested call into the service, and cause deadlock. To avoid this, move the death notifier registration to the end of handling the connect transaction. Also remove one extra bit of disconnect logging. Bug: 23525545 Change-Id: If01cbaf42704f55134118afefc9a8f7bdb014e09
| * | | libcameraservice: Fix ALOG prints in FlashLight.Dilip Gopalakrishna2015-10-251-4/+8
| |/ / | | | | | | | | | | | | | | | Add missing __FUNCTION__ arguments into log statements. Change-Id: I0256bad626d490fb9360a73c104afaad7a012a97
* | | libcameraservice: Fix nullptr crash when no client.Tom Keel2015-11-071-2/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This change prevents a crash in the camera service when the camera HAL notifies the service about the absence of a removable camera and there happens to be no client connected to the service. It checks that the pointer returned from clientToDisconnect.get() is non-null before trying to dereference it (as is done in existing code immediately below this change). Change-Id: I8055654bac980542e63ea7f52bf897eaafbc09bc Signed-off-by: Tom Keel <thomas.keel@intel.com>
* | | Merge tag 'android-6.0.0_r26' into cm-13.0Ricardo Cerqueira2015-11-0524-266/+725
|\ \ \ | | |/ | |/| | | | | | | | | | Android 6.0.0 release 26 Change-Id: I8a57007bf6efcd8b95c3cebf5e0444345bdd4cda
| * | Camera3Device: Change HFR request thread priority to 1Chien-Yu Chen2015-10-011-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | Based on periods of the request thread and audio threads with SCHED_FIFO policy, 1 is a more reasonable priority for HFR request thread. Bug: 24427480 Change-Id: I91f0066a0e114fc83abcc6a604ecbaa72c6a34e8
| * | Camera3Device: Bookkeeping reprocess shutters separatelyChien-Yu Chen2015-09-302-12/+27
| | | | | | | | | | | | | | | | | | | | | | | | Bookkeeping reprocess shutters separately so regular and reprocess shutters together don't need to come in order. Bug: 24497512 Change-Id: I4aaf22045131e9e2e26bf163f7df9ff4c5cd6259
| * | CameraService: Use SCHED_FIFO for request queue thread in HFREino-Ville Talvala2015-09-263-1/+19
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | - Move SchedulingPolicyService from audioservice to mediautils - When starting up a high speed stream config, set request queue thread to SCHED_FIFO using SchedulingPolicyService Bug: 24227252 Change-Id: I224b59142bd111caf563779f55cddd62385b9bac
| * | Merge "Camera: API1 shim: select better default FPS range" into mnc-dr-devYin-Chia Yeh2015-09-151-2/+2
| |\ \
| | * | Camera: API1 shim: select better default FPS rangeYin-Chia Yeh2015-09-111-2/+2
| | | | | | | | | | | | | | | | | | | | Bug: 23992350 Change-Id: Ie86b24d9e5ea753c6dfc2e5526d371b339be96a1
| * | | Merge "Camera3Device: Signal buffer returned after it failed" into mnc-dr-devChien-Yu Chen2015-09-121-1/+4
| |\ \ \
| | * | | Camera3Device: Signal buffer returned after it failedChien-Yu Chen2015-09-111-1/+4
| | |/ / | | | | | | | | | | | | | | | | | | | | | | | | | | | | Signal buffer returned even after it failed so the thread waiting for it can wake up sooner. Bug: 23981045 Change-Id: Iccbcc7ece2e0f6204da9c54f2bdd96ff6843a8f5
| * | | Reduce DUMP permission denial output to one line.dcashman2015-09-111-1/+1
| |/ / | | | | | | | | | | | | Bug: 23940813 Change-Id: I0060dbaff5cd0c3d028ac5cd7aba7da3f0371150
| * | CameraService: Add more systracing, fix module init orderEino-Ville Talvala2015-09-092-14/+84
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Improve debugging of performance of concurrent calls to the service. - Add ATRACE calls to camera service entry points - Add ATRACE calls for camera HAL module calls - Ensure that camera module init method is called before all others Bug: 23718257 Bug: 23933447 Change-Id: I2a025866ab39eda3962877120cab13a063c7727e
| * | Merge "CameraService: Link to client binder death at end of connect" into ↵Eino-Ville Talvala2015-09-052-8/+11
| |\ \ | | | | | | | | | | | | mnc-dr-dev
| | * | CameraService: Link to client binder death at end of connectEino-Ville Talvala2015-09-042-8/+11
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | If, within a binder Looper thread, a Binder object death notifier is registered, and then a nested Binder transaction is begun, that transaction may process a death notification callback for the just-registered object, if it was dead at the time of registration. This can lead to an unexpected nested call into the service, and cause deadlock. To avoid this, move the death notifier registration to the end of handling the connect transaction. Also remove one extra bit of disconnect logging. Bug: 23525545 Change-Id: If01cbaf42704f55134118afefc9a8f7bdb014e09
| * | | Merge "Camera3Device: Clean up next request batch variable" into mnc-dr-devChien-Yu Chen2015-09-052-52/+41
| |\ \ \ | | |/ / | |/| |
| | * | Camera3Device: Clean up next request batch variableChien-Yu Chen2015-09-042-52/+41
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Make the Vector of next requests a RequestThread member variable to avoid memory allocation in every threadloop. Bug: 23360060 Change-Id: I4f33e5c49f0f4deb1f9f45bada0909da748849e4
| * | | Merge "Camera3Device: Support batch requests" into mnc-dr-devChien-Yu Chen2015-09-048-199/+387
| |\ \ \ | | |/ /
| | * | Camera3Device: Support batch requestsChien-Yu Chen2015-09-038-199/+387
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Refactor request threadLoop to three parts: waiting for next batch of requests, preparing HAL requests and output buffers for next batch of requests, and submitting the batch of requests to HAL. Set the batch size to the size of the request list if it's a video recording request in a high speed video configuration. Add a flush lock so that HAL's flush() won't be called while submitting a batch of requests. Bug: 23360060 Change-Id: Icd395b1f955a9b336eec6fa5aff6b17741ce08c7
| * | | CameraService: Treat TOP_SLEEPING same as TOP for priority.Eino-Ville Talvala2015-09-032-0/+7
| |/ / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When arbitrating between camera clients, treat processes in the TOP_SLEEPING state with the same high priority as processes in the TOP state. This resolves race conditions during lock screen handoffs between clients such as face unlock (a bound foreground process) and a secure camera app (the topmost activity, but transitioning from TOP_SLEEPING to TOP asynchronously from the activity lifecycle callbacks). Bug: 23731720 Change-Id: I92c3f8f561c7725627826c0ba3dc926e99af746c
| * | am fe751bea: Camera: Fix flashlight deadlockChien-Yu Chen2015-09-022-3/+5
| |\ \ | | | | | | | | | | | | | | | | * commit 'fe751bea0d3eedd6e817aebf4e457425b82e7117': Camera: Fix flashlight deadlock
| | * | Camera: Fix flashlight deadlockChien-Yu Chen2015-09-012-3/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Use a dedicated mutex for torch UID map so it won't cause a deadlock after flashlight app gets killed while the torch is on. Bug: 23722318 Change-Id: I228377aa0412052d56b6b948361d9abaecbbc686
| * | | Camera3Device: Don't hold mutex during HAL device close.Eino-Ville Talvala2015-08-281-6/+14
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The HAL device shutdown will likely need to wait on various events and queues to drain, and holding the mutex will prevent, for example, error notifications from being processed. This can lead to deadlocks. Bug: 23501571 Change-Id: I873ac23ef30545adf533e7839445448573ab5048
| * | | CameraService: Notify camera service proxy of device statusEino-Ville Talvala2015-08-218-6/+74
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Send the camera proxy service in system server updates to camera device state: opened/closed/active/idle. Bug: 23393557 Change-Id: Id7c70f134821efa34af8f6e7b4caa4c2ab128ebc
| * | | Merge "Add experimental camera session prepare API." into mnc-dr-devRuben Brunk2015-08-1710-13/+103
| |\ \ \ | | |/ / | |/| |
| | * | Add experimental camera session prepare API.Ruben Brunk2015-08-1410-13/+103
| | | | | | | | | | | | | | | | | | | | Bug: 18949148 Change-Id: I8f73e68ea2e3acc60d98954106f364d13f439a82
* | | | cameraservice: Resolve message vs start/stop preview racesRicardo Cerqueira2015-10-301-1/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Move the mutex in start/stopPreview to include the metadata message management. Fast start/stop sequences could (and would) eventually cause the messages to be enabled/disabled out of sequence (or while the camera wasn't ready for it) This is a port of I367bc45729ce2e858fea972f35e881a755c6021a from cm-11 Change-Id: I9a065f951f628d1c550acbac18493b9ad3853d03
* | | | camera: add ability for a device to specify MAX_CAMERASDan Pasanen2015-10-302-0/+8
| | | | | | | | | | | | | | | | Change-Id: I3db99ea4eff63aab3448efe7b2eb51366c658c03
* | | | Camera: Added null check for memory referenceSuman Mukherjee2015-10-301-0/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Null memory reference in releaseRecordingFrame will cause crash in cfuzz tool. Added Null check for memory reference Change-Id: Id15fc55cc89b6039a36c1c3c7e4b55c0ae5aa296
* | | | Camera: Support obtaining camera memory from MemoryHeapIonEthan Chen2015-10-302-0/+25
| | | | | | | | | | | | | | | | | | | | | | | | * Exynos 5 devices want the ION file descriptor from MemoryHeapIon Change-Id: I9e445cf24c15713f713181667e7b7caa1a96592e
* | | | camera: Allow hardware/camera.h header to be overriddenEthan Chen2015-10-302-2/+2
| | | | | | | | | | | | | | | | Change-Id: I715ba261de0b01e61cbfe7cacd567a9f511fb8cb
* | | | Camera: frameworks: Add NULL check for callbackSusmitha Gummalla2015-10-291-1/+5
| |_|/ |/| | | | | | | | | | | | | | --Added NULL check for mRemoteCallback Change-Id: Ib88a128a52e81b8ec1052e3222b6d8b9e494afcc
* | | Camera: Add extensions to CameraClientShuzhen Wang2015-10-062-2/+34
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This change includes the following gerrits: # This is a combination of 4 commits. # The first commit's message is: Camera: Enable Histogram feature. Link the histogram enable/disable commands from application to the HAL layer. Change-Id: I510c4e1798285ed1315bfb0d234fa76090659ba2 # This is the 2nd commit message: Camera: Add support for ZSL burst mode. Added ability to set number of snapshots in burst mode. Change-Id: Ie0e7c8c0117b7adc985cfc92df79747ee6a5ea51 # This is the 3rd commit message: CameraService: Adds support for longshot mode - This change introduces additional functionality inside CameraClient for supporting continuous compressed data callbacks. This is needed for 'Burst/Long shot' mode where we could have indefinite number of callbacks after capture is triggered. (cherrypicked from commit e4f502aa7cbe8875e8a1589024cdcf227c228a2b) Change-Id: Ia18ca9bdda7736c679db557e510870115089537a # This is the 4th commit message: CameraClient: Enables meta data notifications. Adds the needed functionality for enabling/disabling metadata messages depending on the camera client commands. Change-Id: I39d632b4742e83df5db5f86b12742aefc2480dfc Cherrypicked from 25bd97f5ec30e7942c3b1fdc96115da6028736f0 Change-Id: Ie930d20c962593e40a0767f9cf7d4385df8e2561