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

Commit 1622326c authored by Wonsik Kim's avatar Wonsik Kim
Browse files

codec2: add color formats for image component

Bug: 134461870
Test: atest CtsMediaTestCases:MediaCodecTest#testPrependHeadersToSyncFrames
Change-Id: I8233ec928e7c5700abc1bdd7f32e097892947949
parent 85b23e26
Loading
Loading
Loading
Loading
+2 −1
Original line number Diff line number Diff line
@@ -194,7 +194,8 @@ void addSupportedColorFormats(
    // TODO: get this from intf() as well, but how do we map them to
    // MediaCodec color formats?
    bool encoder = trait.kind == C2Component::KIND_ENCODER;
    if (mediaType.find("video") != std::string::npos) {
    if (mediaType.find("video") != std::string::npos
            || mediaType.find("image") != std::string::npos) {
        // vendor video codecs prefer opaque format
        if (trait.name.find("android") == std::string::npos) {
            caps->addColorFormat(COLOR_FormatSurface);