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

Commit 8bf0fede authored by Lajos Molnar's avatar Lajos Molnar Committed by android-build-merger
Browse files

stagefright: read constrained AVC profiles

am: 738a3af8

Change-Id: Iadffd88789f48586ea141e56f6c5c895accc3e1d
parents 77ec4782 738a3af8
Loading
Loading
Loading
Loading
+5 −0
Original line number Diff line number Diff line
@@ -237,6 +237,11 @@ static void parseAvcProfileLevelFromAvcc(const uint8_t *ptr, size_t size, sp<AMe
    OMX_VIDEO_AVCPROFILETYPE codecProfile;
    OMX_VIDEO_AVCLEVELTYPE codecLevel;
    if (profiles.map(profile, &codecProfile)) {
        if (profile == 66 && (constraints & 0x40)) {
            codecProfile = (OMX_VIDEO_AVCPROFILETYPE)OMX_VIDEO_AVCProfileConstrainedBaseline;
        } else if (profile == 100 && (constraints & 0x0C) == 0x0C) {
            codecProfile = (OMX_VIDEO_AVCPROFILETYPE)OMX_VIDEO_AVCProfileConstrainedHigh;
        }
        format->setInt32("profile", codecProfile);
        if (levels.map(level, &codecLevel)) {
            // for 9 && 11 decide level based on profile and constraint_set3 flag