Bug: 151896491
Test: local build
Exempt-From-Owner-Approval: This CL update suite name vts-core to vts as
the suite name is updated. This CL won't change test logic or behavior.
Change-Id: I562b4dc50765e953800a814a8fd84a01c1b9352b
Merged-In: I562b4dc50765e953800a814a8fd84a01c1b9352b
marissaw@ is leaving. jessehall@ is on a different team. Remove
them and add new owners.
Test: Compiles
Bug: 150462113
Change-Id: I922710de701d3923268591bcb48db3e12acb0500
(cherry picked from commit 88417a586b)
Updates Cb and Cr plane indexing. The existing code seems to use
chromaStep as a sub-sampling factor and seems to assume that the
underlying format is tri-planar.
Updates Cb and Cr value checking. The existing code would write
values into the Cb and Cr planes using a value derived from
even-x-value and odd-y-value full-image-coordinates (e.g. (0,1))
but then check against the values in the Cb and Cr planes using
a value derived from even-x-value and even-y-value coordinates
(e.g. (0,0)).
Updates y-plane sample increment check to confirm that it is
multiple of 8. I don't see any requirements stating this needs
to be 32 bits.
Bug: b/146515640
Test: VtsHalGraphicsMapperV4_0Target
Change-Id: Ia9e496ae43b2d1ac9ea8d57a4d4fc55f0be7b2b6
1) handles allocated through 'allocate' should be removed through
'freeBuffer'.
2) make use of intended buffer handle in GetTransportSizeBadBuffer.
Bug: 146444563
Test: build, boot, VtsHalGraphicsMapperV2_1TargetTest
Cherry pick to master from android10-tests-dev
Change-Id: I6c1a67fc36dbc653ec2ada6a335d685d21e82800
Merged-In: I6c1a67fc36dbc653ec2ada6a335d685d21e82800
Signed-off-by: Pierre Couillaud <pierre.couillaud@broadcom.com>
The existing test never assigns a handle to bufferHandle so
mGralloc->getReservedRegion() will always be called with
nullptr and will always return with BAD_BUFFER.
Bug: b/146515640
Test: VtsHalGraphicsMapperV4_0Target
Change-Id: I85dac94956c6b9db5b4a19faeb16fc947f7457e1
1) handles allocated through 'allocate' should be removed through
'freeBuffer'.
2) make use of intended buffer handle in GetTransportSizeBadBuffer.
Bug: 146444563
Test: build, boot, VtsHalGraphicsMapperV2_1TargetTest
Change-Id: I6c1a67fc36dbc653ec2ada6a335d685d21e82800
Signed-off-by: Pierre Couillaud <pierre.couillaud@broadcom.com>
SampleIncrementInBits is the delta between samples not components.
It should be 32 for RGBA_8888.
Test: VtsHalGraphicsMapperV4_0
Bug: 150461327
Change-Id: Idf283b93cd0243fa33eabac23185c513825d83ca
Sync fences can be invalid if the buffer is already ready. If the
fence is invalid, we do not need to wait.
Test: VtsHalGraphicsMapperV4_0
Bug: 150213134
Change-Id: I8326d5f8b358c466ee9a686fd299daed1d4b4aa8
std::optional defaults to containing std::nullopt_t. Using "->" or
"." on an std::optional object that does not contain a value is
undefined. Clang seems to ignore the whole line.
SetSmpte2086 and SetCta861_3 both incorrectly instantiate their
std::optional types. The std::optional types contain std::nullopt_t
when they are passed into encode. When mapper decodes the fields,
they are empty.
Update std::optionals to be instantiated correctly.
Bug: 149931805
Test: VtsHalGraphicsMapperV4_0
Change-Id: I046242f8261a5378228231b89b2eedec242667cb
The parameter order of a couple checks is wrong.
For example:
EXPECT_GT(val1, val2) is EXPECT_TRUE(val1 > val2)
so EXPECT_GT(0, X) can never be true.
Update the tests to be correct.
Test: VtsHalGraphicsMapperV4_0
Bug: 149739702
Change-Id: I21070a912b6014acc5feb63b6b19912b45fe8f5f
Usage cannot be change after allocation. Mapper must return
BAD_VALUE. SetConstantMetadata already tests this. Remove
the tests that attempted to set USAGE and expected it could
succeed.
Test: VtsHalGraphicsMapperV4_0
Bug: 149830560
Change-Id: I730dd3f3c0c48946c436e8fb60256365e0d9ab1e
VTS_10 testing item VtsHalGraphicsMapperV2_1Target fail due to
Gralloc0 HAL do not have return value : BAD_VALUE and BAD_BUFFER
so add Error::BAD_VALUE and Error::BAD_BUFFER as return value to
fix this VTS fail.
Bug: 146034198
Test: ran VtsHalGraphicsMapperV2_1Target 10 times and it all pass.
Change-Id: I792830ddf98cbf59de7d3a7b4dd4cf5f72269244
GTEST_SUCCEED() does not cause a GTEST to return. Insert a
return after every GTEST_SUCCEED().
Test: VtsHalGraphicsMapperV4_0
Bug: 149008032
Change-Id: I65637e7a0ac9a9ac8d69c9d8ccbb427543d82428
sampleIncrementInBits is per sample not per component. An RGBA sample
is 32 bits not 8.
Test: VtsHalGraphicsMapperV4_0
Bug: 149310539
Change-Id: If4bd5aac87cada7040f52ee40159a72fa72a97be
SetConstantMetadata was trying to set constant metadata
with bad values. SetBadMetadata was also trying to set
constant metadata with bad values. Update SetConstantMetadata
to set constant metadata with good values. Remove constant
metadata from the SetBadMetadata test.
Bug: 149004202
Test: VtsHalGraphicsMapperV4_0
Change-Id: I6816fca64c7ac89e457628e94bc06bc1b05c916f
Move crop out of PlaneLayout so it can be set and get independently
from PlaneLayout.
Bug: 141632767
Test: atest VtsHalGraphicsMapperV4_0
Change-Id: Ib685c0a065754e3e3bd697d3518b03b4c76d447e
In order to provide a more descriptive name, and to be consistent
with HIDL, the stable AIDL package names are switching from
vintf-*common format to the package format
(android.hardware.*common).
Bug: N/A
Test: all build time
Change-Id: Ie1d92a50dddf7e3e1bd473e2a957279c6dadb865
Existing Android framework code (and transitively, CTS test) require
that an accessRegion of (0,0,0,0) is treated the same as an
accessRegion covering the entire buffer, when calling lock() or
lockYCbCr().
Document this so that there is no confusion about this going forward,
since this requirement pre-dates the HIDL HALs.
Bug: 119440345
Test: Builds, passes CTS
Change-Id: I5ff86539ee28a72dd972255ad405db357e62536d
Add support for BT709 full range support with SMPTE 170M transfer function.
Minor: Remove deprecated dataspace support in aidl.
BUG: b/130737986
Test: build
Change-Id: I17b1f7d868e99396df9779bdd53d63bdcd2a06af
dumpDebugInfo could be called by anyone. A safer
approach is for processes to dump their own buffers
via IMapper's dumpBuffers.
Bug: 137966819
Test: Compiles
Change-Id: I4c8c7a6415babfb93034ee8674ba0f40cd8c1bb8
Use the gralloctypes helper function to determine if a
PlaneLayoutComponentType is a standard type. Also update the
lock RGBA_8888 function to ignore non-standard
PlaneLayoutComponentTypes.
Bug: 141632767
Test: VtsHalGraphicsMapperV4_0TargetTest
Change-Id: Ie3ea4a22b2c9ecf4b1d85932833978d2e23f77c1
When a buffer is locked (mapped to the CPU) by two or more clients,
there is no good way to manage a reader/writer relationship. There are
no requirements for how the writes should propagate to the readers.
Clients must unlock and relock to be sure writes are flushed.
They must unlock and relock to get the lastest copy of the buffer.
This patch adds explicit flush and reread commands to help readers
and writers synchronize without having to unmap and remap the
buffer.
Bug: 136316517
Test: TODO
Change-Id: I10d3de1b0e46c4f3b50dc34aea653701933638a9
This patch adds a reserved region of shared memory to every gralloc
native_handle_t. The reserved region of memory will allow future
versions of Android to add new buffer features without requiring
gralloc upgrades.
Bug: 145232031
Test: VtsHalGraphicsMapperV4_0TargetTest
Change-Id: I1bdfec0a6ef85097096035d3d38e5c9e7fcc32f2
Gralloc 4 removes lockYCbCr but clients will still expect similar
functionality to lockYCbCr. This test case ensure that gralloc
will still behave sufficiently similarly when locking
YCBCR_420_888.
Bug: 141631415
Test: VtsHalGraphicsMapperV4_0TargetTest
Change-Id: I60d2c220bab858eabe89a95b225d2816ab7289cc
Add functions to IMapper to dump a buffer and to dump all the
buffers in the current process. The dump includes
all gettable or settable metadata.
Bug: 141632317
Test: VtsHalGraphicsMapperV4_0TargetTest
Change-Id: Iaa54b899aef185867b3fd66025c0eb251a9a7bd1
Clean up code comments based on review comments in ag/9684750 and
ag/9684750.
Bug: 144551649
Test: Compiles
Change-Id: I96f5962d2c1b79352f85dcf9354689814310ecc0
IMapper 4.0 does support lockYCbCr functionality through lock and
BufferMetadata getters. However, we will wait to add the support in
one central gralloc library. For now just stub out the call so
there aren't any compiler errors.
Bug: 141631415
Test: Compiles
Change-Id: I9d2f70c87412f8ac2114db85eb6dc01539876e2b
Add function to get the metadata types supported by IMapper.
In future releases, we will add more standard types but upgrading
devices may not support those types. This function will allow the
framework to identify which metadata types the device supports.
Bug: 141632767
Test: VtsHalGraphicsMapperV4_0TargetTest
Change-Id: I760cf054d2b6f08a52ad70f4ae60a39a63500939