Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 9c886cd0 authored by Valerie Hau's avatar Valerie Hau Committed by Automerger Merge Worker
Browse files

Merge "Relax constraints on getting PlaneLayouts" into rvc-dev am: 28fcdf27

Change-Id: I7e082d6d1ade5eb8d1c0be6db36c5d74276fed5d
parents 7278d84d 28fcdf27
Loading
Loading
Loading
Loading
+9 −7
Original line number Diff line number Diff line
@@ -1865,13 +1865,15 @@ TEST_P(GraphicsMapperHidlTest, GetFromBufferDescriptorInfoChromaSiting) {
 */
TEST_P(GraphicsMapperHidlTest, GetFromBufferDescriptorInfoPlaneLayouts) {
    hidl_vec<uint8_t> vec;
    ASSERT_EQ(Error::NONE,
              mGralloc->getFromBufferDescriptorInfo(mDummyDescriptorInfo,
                                                    gralloc4::MetadataType_PlaneLayouts, &vec));

    const auto ret = mGralloc->getFromBufferDescriptorInfo(
            mDummyDescriptorInfo, gralloc4::MetadataType_PlaneLayouts, &vec);
    if (ret == Error::NONE) {
        std::vector<PlaneLayout> planeLayouts;
        ASSERT_EQ(NO_ERROR, gralloc4::decodePlaneLayouts(vec, &planeLayouts));
        ASSERT_NO_FATAL_FAILURE(verifyDummyDescriptorInfoPlaneLayouts(planeLayouts));
    } else {
        ASSERT_EQ(Error::UNSUPPORTED, ret);
    }
}

/**