Ensure none of the HAL structs change size over time.
Issues might arise when making changes without taking the different
pointer sizes for specific architectures into account.
Change-Id: I63f00004a23f09b2f46df01e7c69296766a5d03f
Remove the requirement of HAL_PIXEL_FORMAT_IMPLEMENTATION_DEFINED and make and
fix some minor issues.
Bug: 10388724
Change-Id: I18f0ea60f87902d6c2bbaca53957a91953866c40
The original version of this HAL used a field in keymaster_module to
represent the module's version number, but a later revision of the HAL
interface added a distinguisher between HAL module and device versions.
This is needed to support upgrade code in keystore.
(cherry picked from commit c124b23f94)
Bug: 10600582
Change-Id: Ia2b0cbeca5c507600228c39ec7a8402f819f8804
The original version of this HAL used a field in keymaster_module to
represent the module's version number, but a later revision of the HAL
interface added a distinguisher between HAL module and device versions.
This is needed to support upgrade code in keystore.
Bug: 10600582
Change-Id: Ied34cf382e2b7725e648faada00df2dee993e6c5
Add a test to test multiple stream configuration: one preview stream, one small
size YUV burst capture stream, and one large size YUV burst capture stream.
Also cleanup the code.
Bug 10325342
Change-Id: I676484cc0034055caa8f2a8788100ed34b4cefbb
Both surfaceflinger and HWC implementations have been defining these
themselves, making future changes more difficult. Better to define
them centrally, where they can be updated easily.
Change-Id: I793158b858c84b2470b05f9ea77cc5a0c7e247f1
By default, this test runs through a range of application-set
exposure, frame duration, and sensitivity values, and verifies
that the duration of capture, and in some cases the brightness,
match what's expected.
Optionally, it can use environment variables to specify the
burst parameters, and to enable dumping the captured YUV images
to flash for later debugging.
Change-Id: I647d360344ef3684e99c86c369e96ac82e62fc96
Add cnativewindow which provides a minimal bridge between EGL and hwcomposer or fbhal.
Add test-arrows, a trivial GLES2 test program to exercise this.
Change-Id: I60ece4378def6b6eda55437c215fc46a180ad7a3
- Requests were missing control type (capture vs reprocess)
- Not waiting for streams to be drained before disconnecting (sporadic fails)
Change-Id: Iab218b89a663db6dc26d791a390d0e11667f6889
Producer would wait for buffers to be released so it could dequeue into them.
Since the test never acquired/released buffers, it would run out, and then
the HAL would deadlock when trying to shutdown since the producing thread
would never finish.
Change-Id: I4222feeec7a3ffab4c243e12b7d9bd56364ad983
This fixes a segfault in the HAL where it was trying to write to a locked buffer
that disappeared from underneath it.
Any users of CameraModuleFixture should now call SetUp/TearDown explicitly.
Other classes remain unchanged until we need a custom TearDown order for them.
Change-Id: I9aa8c2d86492a76f2c01c1ad4cbe0cf91e5c7916
The C++ class names don't match what the classes do, so rename
ISurfaceTexture to IGraphicBufferProducer, and SurfaceTexture to
GLConsumer.
Bug 7736700
Change-Id: I7fc8474c1d0d95658609b69cdb0af412d69a42c4
Use CAMERA2_TEST_FORKING_DISABLED=1 environment variable to override this
behavior (e.g. when wanting to attach gdb to the test app).
Change-Id: Ib639885bdb827fc2415c878cbcb1b2d84dff687b
Align camera2's management of platform-opaque formats with rest of
framework. Instead of using CAMERA2_PIXEL_FORMAT_OPAQUE, use
HAL_PIXEL_FORMAT_IMPLEMENTATION_DEFINED as the format for both the
camera HAL and for gralloc, and depend on the gralloc usage flags to
let the gralloc module select the appropriate real format for specific
stream endpoints.
Add a new gralloc usage for ZSL mode, where the camera service will
hold a streaming circular buffer of opaque full-resolution images
during camera preview. Since this is an opaque format that needs to be
optimized for 30fps operation, need gralloc to be aware of this use
case.
Bug: 6243944
Change-Id: If7f2516649381ce9bcffe4e319b63cbc068f643f
Disallow modification to static characteristics structure, and clarify
ownership and lifetime of the structure.
Also update test code accordingly.
Bug: 6243944
Change-Id: I6921d6889937212867efb99aa3881ab3ffc4f6f9
Needs a third change that's not yet done with review.
This reverts commit c9ec8a656b59912f496880d3a63c0decd490f09d
Change-Id: Ic3e465e1308cbf107a250ec17b73a59a35e52f9f
Disallow modification to static characteristics structure, and clarify
ownership and lifetime of the structure.
Also update test code accordingly.
Bug: 6243944
Change-Id: Ib8de5e9d6580187b21a5ae9a28a3d24f1d083f7b
Check the key values of successful attempts.
For imported keys, the key values should match the
input values when they're returned.
For generated keys, the modulus size should be correct and the public
exponent should be correct.
Bug: 6736252
Bug: http://code.google.com/p/android/issues/detail?id=34212
Change-Id: I37ed97d36ebfbe4301b43426129928bcb53c39f8
This change updates uses of ANativeWindow to use the new ANW functions that
accept and return Sync HAL fence file descriptors.
Change-Id: I8ea699ba0a9b5c4b4316f9428cbd565976899991
- Clean up const/struct usage in HAL
- Add user pointer to notify callback
- Revamp allocate_stream, now it picks its own ID.
- Much simpler stream interface
- Merged request/reprocess input queues
- Frame queue interface no longer a mirror of request queue
- Added triggers/notifications
- Added default request creation
- Lots of comments
Unit tests added:
- Lots of utility code to speed up test writing
- Basic open/close
- Capturing 1 raw buffer (request input, frame output, buffer output)
- Capturing a burst of 10 raw buffers
Bug: 6243944
Change-Id: I490bd5df81079a44c43d87b02c9a7f7ca251f531
- Add missing method in stream_ops (set_buffers_geometry)
- Remove extra method in stream_ops (set_swap_interval)
- Document metadata queue protocol
- Change metadata queue methods to be set/get through function calls
only, instead of a struct member in the HAL device ops.
- Change vendor extension tag query methods to be retrieved by a get
call, instead of a struct member in the HAL device ops.
- Add basic gtest unit test skeleton, which currently just returns
static info from all camera devices.
Change-Id: I94117097b0243023ad60638070cc7f0cefec18e6
In order to aid keymasters erase their memory efficiently, introduce new
delete_all API to tell keymasters to forget everything. This will be
triggered when keystore itself is told to reset.
Change-Id: I730375f1f32cd1ea0bf1fa38d5b1bec2f81ba492
This adds unit tests for implementors of the keymaster API. It can be
compiled and run as a stand-alone executable.
Change-Id: Id5bb8f4533b744c254b52e07df66a8d158dfda0d