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

Commit 01a15c24 authored by Surajit Podder's avatar Surajit Podder Committed by Linux Build Service Account
Browse files

video: Add key to indicate thumbnail mode

Add key "thumbnail-mode" in metadata to
signal thumbnail decoding.

Squash the below change as well:

Stagefright: video: Default thumbnail generation to hardware decoder
Change-Id: I045ab87cb6877f3318f38c50f06d32e19595d83b

Change-Id: I9d78f026989c48f62c403cbb88dc24c5f74771a4
parent ef67203e
Loading
Loading
Loading
Loading
+3 −1
Original line number Diff line number Diff line
@@ -158,6 +158,8 @@ static VideoFrame *extractVideoFrame(
    // TODO: Use Flexible color instead
    videoFormat->setInt32("color-format", OMX_COLOR_FormatYUV420Planar);

    videoFormat->setInt32("thumbnail-mode", 1);

    status_t err;
    sp<ALooper> looper = new ALooper;
    looper->start();
@@ -498,7 +500,7 @@ VideoFrame *StagefrightMetadataRetriever::getFrameAtTime(
    MediaCodecList::findMatchingCodecs(
            mime,
            false, /* encoder */
            MediaCodecList::kPreferSoftwareCodecs,
            0 /* MediaCodecList::kPreferSoftwareCodecs */,
            &matchingCodecs);

    for (size_t i = 0; i < matchingCodecs.size(); ++i) {