summaryrefslogtreecommitdiffstats
path: root/services/camera
Commit message (Collapse)AuthorAgeFilesLines
* camera: fix frame deletion logic in mInFlightMapRuchit Sharma2014-11-251-2/+6
| | | | | | | | | | | For per-frame error notifications, camera3.h requirements state that all the buffer handles for a failed frame capture must be returned via process_capture_result() call(s). Hence, Camera3Device needs to ensure that the frame entry is not deleted from mInFlightMap until all buffers for that frame have been returned by HAL. Bug: 17757940 Change-Id: I2579ca7980d2fd67d53abc530e2706538f7d3d3a
* Camera2: Fix CameraParameters parse segfault.Ruben Brunk2014-11-201-0/+1
| | | | | Bug: 18331142 Change-Id: I41feec93f753f97b3e6bf963deb4a42b73406421
* Merge "Camera2Client: remove recording stream if necessary" into lmp-mr1-devYin-Chia Yeh2014-11-193-7/+56
|\
| * Camera2Client: remove recording stream if necessaryYin-Chia Yeh2014-11-183-7/+56
| | | | | | | | | | Bug: 17495165 Change-Id: I11b763fde8f9448f4bddec3fe6c81581e7699edb
* | Merge "CameraService: normalize face rectangles properly" into lmp-mr1-devChien-Yu Chen2014-11-173-73/+90
|\ \ | |/ |/|
| * CameraService: normalize face rectangles properlyChien-Yu Chen2014-11-133-73/+90
| | | | | | | | | | | | | | | | | | Use android.scaler.cropRegion reported in the capture result to normalize face rectangles instead of using the one in current capture request. Bug: 11460393 Change-Id: Id21834bf6ae1f7cc106b4dffb98f9f249a75034b
* | Merge "Camera2Device: fix camera metadata leaks" into lmp-mr1-devChien-Yu Chen2014-11-122-15/+5
|\ \ | |/ |/|
| * Camera2Device: fix camera metadata leaksChien-Yu Chen2014-11-102-15/+5
| | | | | | | | | | | | bug 11132653 Change-Id: I5445b020c3aeaac9a556c023568adac635834356
* | Merge "Add a BufferItem parameter to onFrameAvailable" into lmp-mr1-devDan Stoza2014-11-0712-13/+13
|\ \
| * | Add a BufferItem parameter to onFrameAvailableDan Stoza2014-11-0412-13/+13
| |/ | | | | | | | | | | | | | | Passes the BufferItem for the queued buffer to the onFrameAvailable callback so the consumer can track the BufferQueue's contents. Bug: 18111837 Change-Id: If9d07229c9b586c668e5f99074e9b63b0468feb0
* | CameraService: API1: fix picture FOVChien-Yu Chen2014-10-281-0/+14
|/ | | | | | | | | Fix the wrong assumption that active array size equals to pixel array size. bug 17918247 Change-Id: Ic308f281fb677332a74e95abb473c5b13063eeca
* CameraService: Disconnect: Release mutex while waiting for joins.Eino-Ville Talvala2014-10-221-6/+14
| | | | | | | | | | | | | | | The threads shutting down may have callpaths that require taking the binder interface mutex, so waiting to join them with that mutex held can lead to deadlocks. A specific instance is StreamingProcessor calling dataCallbackTimestamp, which can immediately lead to a Camera2Client::releaseRecordingFrame call, which requires the binder interface mutex. If this call happens right when shutdown is occurring, and Camera2Client::disconnect is holding the mutex, deadlock ensues. Bug: 17997578 Change-Id: I71253cd5542b5920ad205976d315110ca0043d94
* Camera2Client: avoid two consecutive sets of configure_streams callsZhijun He2014-10-141-0/+4
| | | | | | | | | | | | When mediaRecorder starts without an active preview stream, Camera2Client starts preview then immediately start recording, which could cause the second configure_streams to call into HAL before any preview request is sent. This could cause HAL to run into bad state. This change work around this issue by making sure the first preview request is submitted to the HAL before start recording. Bug: 17915062 Change-Id: I94ae64ee76487603695a469240da601ddcb29a66
* CameraService: API1: Reallocate JPEG ashmem heap if size changesEino-Ville Talvala2014-09-291-1/+14
| | | | | Bug: 17682603 Change-Id: I7cba3365d00c33cf4267b1b59a94bd7d0bba08df
* Camera2Client: Revert HALv2 device behavior back to MR2Eino-Ville Talvala2014-09-282-47/+69
| | | | | | | | | | | | | | - Do not idle device before video snapshot stream configuration, to avoid deadlock during waiting. - Do not tear down ZSL stream - Don't refresh ZSL stream after deletion was requested. The v2 HAL implementations really don't like the ZSL stream being touched ever. Bug: 17634430 Bug: 17628507 Change-Id: I36b44a395e697be9802c4bd917a82b77c8d04be2
* CameraService: API1: Fix flash modeEino-Ville Talvala2014-09-271-1/+1
| | | | | | | | Sometimes it's useful to ensure variables are initialized in all code paths. Bug: 17680416 Change-Id: I9bed8a3bcb94417384bf0551fe1c0eee6cc49577
* Camera1 shim: If there's no flash, the keys need to be null.Eino-Ville Talvala2014-09-251-10/+13
| | | | | | | | | | | | | | | | Previously, we set FLASH_MODE_OFF for FLASH_MODE when a flash unit isn't available. However, per the API documentation, the key has to be null instead. - Make sure that the flash mode and supported flash mode keys are null if there's no flash unit on start - Don't set flash mode in later setParameters calls if there is no flash unit - Map NULL value for flash mode key to FLASH_MODE_OFF for internal consistency. Bug: 17660716 Change-Id: I3033682f0b882b8c2004114e2afef31662caebda
* camera: add traces for KPI measurementRuchit Sharma2014-09-252-2/+16
| | | | | Bug: 17658101 Change-Id: I1d8035c4a8fba7b88a87f205ce57c13d812e9df5
* Camera2Client: log an error when autoFocus is called in wrong stateZhijun He2014-09-231-0/+2
| | | | | Bug: 17555612 Change-Id: Ife33da712fbc8dc44d81e1e869fc75fb21026204
* Merge "API1: ZSL buffers should be skipped for manual AF mode" into lmp-devZhijun He2014-09-201-0/+5
|\
| * API1: ZSL buffers should be skipped for manual AF modeZhijun He2014-09-191-0/+5
| | | | | | | | | | | | | | | | | | ZSL counts on good auto focus (CAF). It is really tricky to enable ZSL for manual focus mode. as it is bascically a locked focus mode, you can not tell if the focus is good or not by reading the afstate. Bug: 17577928 Change-Id: I68ff7d143e7d56f942bb00a8da6a9faea57b52a0
* | CameraService: Add client name/pid to device open/close logging.Eino-Ville Talvala2014-09-182-2/+10
|/ | | | | Bug: 15672812 Change-Id: I1162c6d9d0a1eea1dd32949a04c295b4941d2602
* CameraService: Fix dump methods for two clientsEino-Ville Talvala2014-09-182-7/+19
| | | | | | | | Actually write dump text into the provided FD, and add a bit more dump data into CameraDeviceClient. Bug: 17570762 Change-Id: I37b1db85188855d4e89c8050c4b13f0d22e07e0c
* Merge "Camera2: handle one more videosnapshot failure" into lmp-devYin-Chia Yeh2014-09-151-13/+7
|\
| * Camera2: handle one more videosnapshot failureYin-Chia Yeh2014-09-151-13/+7
| | | | | | | | | | | | | | | | Handle one more corner case. Also remove redundant re-try path. Bug: 17484683 Change-Id: I0b3e1223f4f28022e7ec6abe028ca3c2623829de
* | Merge "Camera3Device: Treat failure to idle as an error" into lmp-devEino-Ville Talvala2014-09-151-0/+4
|\ \ | |/ |/|
| * Camera3Device: Treat failure to idle as an errorEino-Ville Talvala2014-09-141-0/+4
| | | | | | | | | | Bug: 16899526 Change-Id: Ia995aac6360c9c41ed654af5a7052480f23903d8
* | Merge "Camera1: Validate scene mode override AF mode" into lmp-devEino-Ville Talvala2014-09-141-0/+14
|\ \ | |/
| * Camera1: Validate scene mode override AF modeEino-Ville Talvala2014-09-131-0/+14
| | | | | | | | | | | | | | | | | | Don't allow uncalibrated cameras to list a fixed focus mode for variable-focus cameras, since uncalibrated cameras cannot do INFINITY focus. Bug: 17492043 Change-Id: I5835efd6f21be0ebb74a9b7ea3ef5b2e7cf63e7a
* | Camera3: Update ZSL post-processing tagsZhijun He2014-09-144-0/+58
| | | | | | | | | | | | | | | | | | Update ZSL processing tags according the still capture template Also cache the request template to avoid extra cost of querying into HAL every time. Bug: 17463102 Change-Id: I2eeffefb0a4131c99a85dd3e4484cc6f0f025efa
* | Merge "Camera: Allow larger preview resolutions in API1 for >= HALv2 ↵Eino-Ville Talvala2014-09-132-4/+29
|\ \ | |/ | | | | devices" into lmp-dev
| * Camera: Allow larger preview resolutions in API1 for >= HALv2 devicesEino-Ville Talvala2014-09-132-4/+29
| | | | | | | | | | | | | | | | | | | | | | | | Limit preview resolutions to a max of 1920x1920 instead of 1920x1080p, so that any aspect ratio with a 1920 as the larger dimension can be used. Also improve the initial preview/video size selection logic, to ensure that the selected size is both a valid preview and video size, and not too large. Bug: 17458832 Change-Id: Iea006fadb5fbf0f03d23c3c5babb5b3611469688
* | Merge "Camera2: fix 4K recording" into lmp-devZhijun He2014-09-134-18/+111
|\ \
| * | Camera2: fix 4K recordingYin-Chia Yeh2014-09-134-18/+111
| |/ | | | | | | | | Bug: 17484683 Change-Id: I09bb12698057555329286c777102b9b310452fb3
* | Merge "camera: add latest parameters to dumpsys for api1 cameras" into lmp-devIgor Murashkin2014-09-122-0/+14
|\ \ | |/ |/|
| * camera: add latest parameters to dumpsys for api1 camerasIgor Murashkin2014-09-112-0/+14
| | | | | | | | | | Bug: 17290106 Change-Id: I08ac1659d0367613c37669d5bf6e6bf7b2b63bc2
* | Merge "Camera2: improve ZSL candidate selection logic" into lmp-devYin-Chia Yeh2014-09-123-2/+38
|\ \
| * | Camera2: improve ZSL candidate selection logicYin-Chia Yeh2014-09-113-2/+38
| |/ | | | | | | | | | | | | | | | | 1. Clear ZSL queue when focus mode is changed and autoFocus is cancelled. 2. Do not check focus state is focus mode is fixed. Bug: 17185356 Change-Id: I2cb10fb457b080f0db950c894e56995f638e147b
* | Merge "camera2: skip capture result after clearZslQueue" into lmp-devYin-Chia Yeh2014-09-126-9/+41
|\ \ | |/ |/|
| * camera2: skip capture result after clearZslQueueYin-Chia Yeh2014-09-116-9/+41
| | | | | | | | | | | | | | | | After ZSL queue is cleared, don't add capture result to ZSL queue if its corresponding buffer has been cleared. Bug: 17185356 Change-Id: Iddac39ab09b2560e2ce9390895927217c1736d5a
* | Merge "camera2: Fix video snapshot for HAL 2.* devices." into lmp-devRuben Brunk2014-09-106-2/+53
|\ \ | |/ |/|
| * camera2: Fix video snapshot for HAL 2.* devices.Ruben Brunk2014-09-096-2/+53
| | | | | | | | | | | | | | | | | | | | | | Bug: 15408128 - Lazily destroy ZSL stream when ZslProcessor is updated, or when the camera client is disconnected, allowing HAL 2.* devices that rely on the ZSL stream to capture video snapshots to function correctly. Change-Id: Ia5cf14c62acda4d9c640440dc5b8e0796dc0b3fa
* | Merge "Camera2: reconfigure video snapshot size if needed" into lmp-devYin-Chia Yeh2014-09-085-4/+93
|\ \
| * | Camera2: reconfigure video snapshot size if neededYin-Chia Yeh2014-09-085-4/+93
| | | | | | | | | | | | | | | | | | | | | | | | When recording fails to start due to stream configuration failed, try configure stream again by setting jpeg stream to video size. Bug: 16162133 Change-Id: Ib20271e787ae07719ce419f0b15c7f86434f7ebb
* | | Merge "Camera API1: fix AE state check in precapture state" into lmp-devZhijun He2014-09-051-5/+12
|\ \ \ | |_|/ |/| |
| * | Camera API1: fix AE state check in precapture stateZhijun He2014-09-031-5/+12
| |/ | | | | | | | | | | | | It is legal to transit to CONVERGED or FLASH_REQUIRED after a AE precapture trigger. Bug: 17365185 Change-Id: Id041eff5eac564c32d09b547a0139d24807336f4
* | Merge "camera1: Ensure MemoryHeap buffers are mmapped before copying." into ↵Ruben Brunk2014-09-021-1/+14
|\ \ | |/ |/| | | lmp-dev
| * camera1: Ensure MemoryHeap buffers are mmapped before copying.Ruben Brunk2014-08-291-1/+14
| | | | | | | | | | Bug: 16986293 Change-Id: Icb68254d7ed1812fa9e60342749a2746d6fcfb17
* | Merge "CameraService: Create a dummy stream when 0 streams are requested." ↵Eino-Ville Talvala2014-08-285-1/+286
|\ \ | | | | | | | | | into lmp-dev
| * | CameraService: Create a dummy stream when 0 streams are requested.Eino-Ville Talvala2014-08-285-1/+286
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | A workaround for a camera device HAL v3.2 or older specification hole - it's not acceptable to configure_streams with 0 output streams. However, we allow for this at the public API level, to allow an application to release all output streams. So in this case, create a dummy stream that doesn't actually do anything as a placeholder. Bug: 17220694 Change-Id: Ib25242ffc2c9f2b2f619fd5fe6d652266579da85