Commit Graph

5 Commits

Author SHA1 Message Date
Sergii Piatakov
6a4d4d59bc camera: fix -Wmissing-field-initializers compiler warnings
Test: add `USE_CAMERA_V4L2_HAL := true` to
      hardware/libhardware/modules/camera/3_4/Android.mk and build
      mmm hardware/libhardware/modules/camera/3_4
Change-Id: I2c17b1e40b29ac400e0a950a9cd96d7f9404ea32
Signed-off-by: Sergii Piatakov <sergii.piatakov@globallogic.com>
2018-08-10 14:39:32 +03:00
Dmitry Shmidt
de9c47bdb9 camera 3_4: Fix compilation errors
Compile Error:
hardware/libhardware/modules/camera/3_4/camera.cpp:502:9: error: non-constant-expression cannot be narrowed from type 'std::__1::vector<camera3_stream_buffer, std::__1::allocator<camera3_stream_buffer> >::size_type' (aka 'unsigned long') to 'uint32_t' (aka 'unsigned int') in initializer list [-Wc++11-narrowing]
        request->output_buffers.size(),
        ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Compile Error:
hardware/libhardware/modules/camera/3_4/v4l2_gralloc.cpp:168:15: error: use of undeclared identifier 'EINVAL'
      return -EINVAL;

Test: Add to device.mk
        USE_CAMERA_V4L2_HAL := true
        PRODUCT_PACKAGES += camera.v4l2
      mma

Change-Id: Ia6bbd6bac06540214d2c6167a8826f3f4c946e57
Merged-In: Ia6bbd6bac06540214d2c6167a8826f3f4c946e57
Signed-off-by: Dmitry Shmidt <dimitrysh@google.com>
2018-01-25 09:42:16 -08:00
Ari Hausman-Cohen
e31e1f33b4 Only provide templates for supported capabilities
Plugs in the StaticProperties class for ease of accessing the
static metadata.

Expands StaticProperties to handle checking template support.

Test: Unit tests pass, test app runs, fixes 2 failing CTS tests on rpi3
BUG: b/32951283
Change-Id: I3077a3507751c3072b88f7d91902bdaa5b53c30e
2016-11-21 17:17:33 -08:00
Ari Hausman-Cohen
ffb9b72e4e Add configs & validation to static properties
Static properties read and validate stream configurations,
stall durations, and reprocess formats.

Static properties can be used to validate a given
camera3_stream_configuration_t to check if the streams
all work together as defined by the metadata properties.

BUG: 31044638
TEST: unit tests pass
Change-Id: I2c8eecb680cd86fbe0340c07e4d73bd25429b4e9
2016-09-20 18:03:04 -07:00
Ari Hausman-Cohen
f45f8d4fa1 Add StaticProperties and MetadataReader
MetadataReader provides a clean wrapper around getting
and translating certain metadata values in a nice form.

StaticProperties will be used by Camera as the source of
truth for metadata properties, extracted directly from a reader,
rather than calling down into the device again.

BUG: 31044638
TEST: unit tests pass
Change-Id: I712a80f87e629a7288c678637de0eae0225acf96
2016-09-16 14:34:28 -07:00