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

Commit d7d6df84 authored by Lajos Molnar's avatar Lajos Molnar
Browse files

stagefright: MP4Extractor: allow 10% overhead on default sample size

Bug: 64528824
Change-Id: Id19ec0d634d9337190d04abdbd97842b66502c01
parent e3c46b0a
Loading
Loading
Loading
Loading
+3 −0
Original line number Diff line number Diff line
@@ -1676,6 +1676,9 @@ status_t MPEG4Extractor::parseChunk(off64_t *offset, int depth) {
                    // ratio. Use compression ratio of 1.
                    max_size = width * height * 3 / 2;
                }
                // HACK: allow 10% overhead
                // TODO: read sample size from traf atom for fragmented MPEG4.
                max_size += max_size / 10;
                mLastTrack->meta->setInt32(kKeyMaxInputSize, max_size);
            }