summaryrefslogtreecommitdiffstats
path: root/media/libstagefright/mpeg2ts
Commit message (Collapse)AuthorAgeFilesLines
* Merge remote-tracking branch 'remotes/android-6.0.1_r52' into HEADJessica Wagantall2016-07-071-0/+7
|\ | | | | | | | | | | Ticket: CYNGNOS-3020 Change-Id: I7e8d69c5f7041b66893ea643c4bc19c3b7bcdda5
| * Check section size when verifying CRCMarco Nelissen2016-05-271-0/+7
| | | | | | | | | | Bug: 28333006 Change-Id: Ief7a2da848face78f0edde21e2f2009316076679
* | Fix harmless unsigned overflow in recoverPTSChad Brubaker2016-03-221-1/+1
|/ | | | Change-Id: I89e3a827cf566421e8dd9b6a3c842e73a19c140f
* Merge "NuPlayer: pull more video buffers in advance in GenericSource" into ↵Chong Zhang2015-07-152-0/+18
|\ | | | | | | mnc-dev
| * NuPlayer: pull more video buffers in advance in GenericSourceChong Zhang2015-07-142-0/+18
| | | | | | | | | | | | | | | | pull 4 video buffers at a time, and start pulling when we're down to 1 buffers to avoid starving the decoder. bug: 22320866 Change-Id: I10914dc092f3830ecb6296e2d9ebf9064ff7a5dc
* | mpeg2ts: keep the size of the sync points at most 5mb per a trackJaesung Chung2015-07-091-2/+13
|/ | | | | Bug: 21901470 Change-Id: I1506d3c73a213ff29e3b0adb8b0a1e7571e583aa
* Merge "mpeg2ts: more error tolerance" into mnc-devWonsik Kim2015-06-111-5/+2
|\
| * mpeg2ts: more error toleranceWonsik Kim2015-06-111-5/+2
| | | | | | | | | | | | | | | | | | Be more tolerant with corrupt packet. Instead of reporting EOS, simply discard the damaged packet and continue. Bug: 21764375 Change-Id: Ibfd112db884732a082371c1abbd047077d1bf57e
* | Merge "stagefright: check the validity of the range of adaptation field" ↵Jaesung Chung2015-06-091-0/+5
|\ \ | |/ |/| | | into mnc-dev
| * stagefright: check the validity of the range of adaptation fieldJaesung Chung2015-05-151-0/+5
| | | | | | | | | | Bug: 20439174 Change-Id: I76a9a3cd1669164cee921191d27d4c669eeb9ae0
* | mpeg2ts: revise duration estimation logicWonsik Kim2015-05-291-10/+16
| | | | | | | | | | | | | | | | | | Estimate duration based on GOP duration and size to yield more accurate result. For a fully buffered stream, just use the buffered duration. Bug: 21391417 Change-Id: I116ae8f596007a0b9fca427a4875c10820ddfea2
* | mpeg2ts: fixing build breakage due to an unmatched argument typeJaesung Chung2015-05-221-1/+3
| | | | | | | | Change-Id: I30e5093d55c29fa62fe8c19095c006861c0ee5a0
* | Merge "mpeg2ts: Fix SIGEGV on ATSParser::Stream::flush()" into mnc-devJaesung Chung2015-05-221-1/+1
|\ \
| * | mpeg2ts: Fix SIGEGV on ATSParser::Stream::flush()Jaesung Chung2015-05-221-1/+1
| | | | | | | | | | | | | | | Bug: 21340130 Change-Id: I4c7eeaf1e35a93400adc87af4eea1902d89d2630
* | | Fixing build breakage due to removal of numPacketsParsedJaesung Chung2015-05-221-2/+1
|/ / | | | | | | Change-Id: Ia888b5865691a3b916aceff064a9b25b3118e2b0
* | Merge "mpeg2ts: MPEG2TSExtractor detects A/V streams until timed out" into ↵Jaesung Chung2015-05-221-3/+6
|\ \ | | | | | | | | | mnc-dev
| * | mpeg2ts: MPEG2TSExtractor detects A/V streams until timed outJaesung Chung2015-05-201-3/+6
| | | | | | | | | | | | | | | Bug: 20433028 Change-Id: I6145eae8d64ad9150477a8ac52545e68768c75eb
* | | Merge "Implement seek for MPEG2TSExtractor" into mnc-devWonsik Kim2015-05-223-73/+377
|\ \ \ | |/ / |/| |
| * | Implement seek for MPEG2TSExtractorWonsik Kim2015-05-203-73/+377
| |/ | | | | | | | | | | | | TODO: Use bandwidth-based estimation to seek forward long period. Bug: 20126845 Change-Id: I5e2f90784a9ce0dce348715dfcfc4f83ee196170
* | Merge "Change mime for HLS timed ID3 stream to application/x-id3v4" into mnc-devRobert Shih2015-05-151-1/+1
|\ \ | |/ |/|
| * Change mime for HLS timed ID3 stream to application/x-id3v4Robert Shih2015-05-141-1/+1
| | | | | | | | | | Bug: 21151892 Change-Id: I6a243b0edbbb445df0caf65f395f81926fd515f0
* | HLS: invoke signalEOS on ATSParser to flush out final samplesRobert Shih2015-05-112-0/+3
|/ | | | | | | Also clear EOS status when we reset ATSParser. Bug: 20959760 Change-Id: I730234acf3cdbee08affe0f28b7e8759e11059cb
* Merge "MPEG2PSExtractor: check number of bits left before skipping" into mnc-devRobert Shih2015-04-301-0/+4
|\
| * MPEG2PSExtractor: check number of bits left before skippingRobert Shih2015-04-291-0/+4
| | | | | | | | | | Bug: 18752034 Change-Id: Ie185ebac8324b4fd6dbb68d7cc53124dfe97cbc2
* | DO NOT MERGE: Prevent crash at erroneous MPEG2TS bitstreamJinsuk Kim2015-04-295-125/+320
|/ | | | | | | | | | | | | Used new RCHECK_ macros for drop-in replacements for CHECK_ to avoid crashing at bit errors encountered while parsing MPEG2 transport packets. Also removed CHECK_ macros in PSI table processing as errors would have been already filtered out by CRC check. Bug: 20274977 Change-Id: I5ca810df3c4295142610bbd1d586d7529bb9f303 (cherry picked from commit e84ab89a2cdae1d1828225f88d895882d716f90e)
* Copy sei offset/size during ABuffer/MediaBuffer conversionRobert Shih2015-04-231-0/+5
| | | | | Bug: 20537676 Change-Id: I0bd11527ccd022c39d94b7877df81de4da1b14a6
* AnotherPacketSource: make getBufferedDurationUs more discontinuity-awareRobert Shih2015-04-212-104/+100
| | | | | | | | | The new getBufferedDurationUs implementation obsoletes the purpose of getEstimatedDurationUs; remove getEstimatedDurationUs and its associated member variables. Finally replace calls to getEstimatedDurationUs with getBufferedDurationUs. Change-Id: I38f20df8e177ffbfe299b203d99076fc98dcd274
* stagefright: make more warnings errorsLajos Molnar2015-04-171-1/+1
| | | | Change-Id: I9b1ad60fbfb866dbf9c00843e06553c3eb25c113
* stagefright: warnings be gone, some are now errors, use clangLajos Molnar2015-04-171-0/+1
| | | | Change-Id: I81f438ae444f04c12ae27ae4ef6d073033de172c
* stagefright: initial timed id3 support in hlsRobert Shih2015-04-166-2/+57
| | | | Change-Id: I00a8a786b3f4b74742c34770edd94e937abe20a8
* am 6705a49f: am 541a9ac7: am 8cd4132a: am 3f22f5a2: Merge "Signal EOS at end ↵Marco Nelissen2015-04-164-1/+33
|\ | | | | | | | | | | | | of mpeg video to flush out final sample" * commit '6705a49f6481ad1728215a2a72472fe43c786cd0': Signal EOS at end of mpeg video to flush out final sample
| * Signal EOS at end of mpeg video to flush out final sampleMarco Nelissen2015-04-154-1/+33
| | | | | | | | Change-Id: I27196a4a4b7fe37da52d3ee99da8cb80294d36d0
* | Merge "mpeg2ts: Set SAMPLE_FLAG_SYNC for mpeg2ts stream"Jinsuk Kim2015-04-142-0/+34
|\ \
| * | mpeg2ts: Set SAMPLE_FLAG_SYNC for mpeg2ts streamTerry Heo2015-04-142-0/+34
| | | | | | | | | | | | | | | | | | | | | Added logic to find sync frame of mpeg2, mpeg4 and h264 Bug: 19940277 Change-Id: I4d95ae247f590b831bf11ff8c9c6fe45d21dab56
* | | Merge "HLS: allow down switch during prepare"Chong Zhang2015-04-101-8/+19
|\ \ \
| * | | HLS: allow down switch during prepareChong Zhang2015-04-091-8/+19
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | to avoid having to immediately down switch (and pause) after playback starts. do not count "discard" packet when estimating duration. bug: 19567254 Change-Id: I0cdd37a06ca800dd81a91cca5eb9b46a1eab7b20
* | | | am fdbafc07: am da589e3d: am fc33bb3f: am e686cc09: Merge "Don\'t fail read ↵Marco Nelissen2015-04-091-6/+11
|\ \ \ \ | |/ / / |/| | / | | |/ | |/| | | | | | | when "seeking" to current position" * commit 'fdbafc0728380645ee2194e2ccfe72b12c65fccf': Don't fail read when "seeking" to current position
| * | Merge "Don't fail read when "seeking" to current position"Marco Nelissen2015-04-091-6/+11
| |\ \
| | * | Don't fail read when "seeking" to current positionMarco Nelissen2015-04-031-6/+11
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Fixes thumbnails for MPEG2TS files. Bug: 19583374 Change-Id: I66e5ca014e2f32ba2566c6f511b6e8859d5a97dc
| * | | ESQueue:use 0x000001 instead of 0x00000001 as sync word in H264/MPEG_VIDEORobert Shih2015-04-031-2/+2
| |/ / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | H264/MPEG_VIDEO sync words can be either 0x000001 (3 bytes) or 0x00000001 (4 bytes); simply searching for 0x000001 in appendData suffices because: 1. 0x000001 is a suffix of 0x00000001, as such we would continue to identify all sync words that we used to identify originally. 2. the parsing logic downstream of appendData in dequeueAccessUnitMPEGVideo and dequeueAccessUnitH264 can both handle 0x000001. Bug: 19900317 Change-Id: Iac42aad74563d056a443b4396eacbae0f7a4738b
* | | HLS: traces in LiveSession and PlaylistFetcher for easier debuggingChong Zhang2015-04-081-2/+2
| |/ |/| | | | | | | bug: 19567254 Change-Id: I4305d37cb74279ccd435f99483231cd1dcf42fc9
* | Merge "ESQueue:use 0x000001 instead of 0x00000001 as sync word in ↵Robert Shih2015-04-031-2/+2
|\ \ | | | | | | | | | H264/MPEG_VIDEO"
| * | ESQueue:use 0x000001 instead of 0x00000001 as sync word in H264/MPEG_VIDEORobert Shih2015-04-011-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | H264/MPEG_VIDEO sync words can be either 0x000001 (3 bytes) or 0x00000001 (4 bytes); simply searching for 0x000001 in appendData suffices because: 1. 0x000001 is a suffix of 0x00000001, as such we would continue to identify all sync words that we used to identify originally. 2. the parsing logic downstream of appendData in dequeueAccessUnitMPEGVideo and dequeueAccessUnitH264 can both handle 0x000001. Bug: 19900317 Change-Id: Iac42aad74563d056a443b4396eacbae0f7a4738b
* | | Merge "HLS: misc bug fixes"Chong Zhang2015-04-034-44/+71
|\ \ \
| * | | HLS: misc bug fixesChong Zhang2015-04-024-44/+71
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | - fix no target-duration case - fix for audio-only <=> audio/video switching - disable audio-only variants if there is at least one variant with video - fix mpeg2ts PTS wraparound when bandwidth adapting - tweak up/down switch marks bug: 19567254 Change-Id: Ib46144203c56dfc96eccd6ddaa3867e8a4f2c6a9
* | | | Merge "Do CRC check for MPEG2TS PSI sections"Jinsuk Kim2015-03-311-1/+112
|\ \ \ \ | |/ / / |/| | |
| * | | Do CRC check for MPEG2TS PSI sectionsJinsuk Kim2015-03-311-1/+112
| |/ / | | | | | | | | | | | | | | | | | | | | | CRC checking helps the parser avoid getting wrong values from corrupted data in the stream transmitted over a noisy channel. Bug: 19821428 Change-Id: I7f589a66a781298c039124a4bd1c9453e77b1bf3
* | | HLS: faster switching and pause/resume on low bufferChong Zhang2015-03-272-6/+165
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | - when upswitching, discard excessive buffering on low bandwidth variant, switch to new variant earlier - when downswitching, report newly found IDR positions continuously, and switch as soon as new fetcher passes playback position. This allows us to skip time-consuming resumeUntil() of old fetcher most of the time - implement pause/resume on low buffering, and notify buffering percentage - buffering parameter tuning, separate pause/resume/ready buffer level and up/down switch buffer level, boost up fetcher buffering significantly bug: 19567254 Change-Id: I750dfcc6f861d78d16a71f501beb86d8129cb048
* | | HLS: allow pause/resume in the middle of a segmentChong Zhang2015-03-203-0/+23
|/ / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | - when down switching, decide whether to finish current segment based on bandwidth settings, abort current segment if needed. - when switching, pause new fetcher after the first 47K chunk, and go back to resume old fethcer to stop point immediately. - when old fetcher reaches stop point, swap packet sources and resume new fetcher. - mark switching as done as soon as old fecther reaches stop point. This allows us to resume bandwidth monitoring earlier, and do subsequent switches sooner. bug: 19567254 Change-Id: Iba4b5fb9b06541bb1e49592536648f5d4cbc69ab
* | HLS: some fixes for seek with discontinuity.Chong Zhang2015-03-171-4/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | - keep old fetcher when seeking, unless the URI is changing. - when restarting after a seek, check discontinuity seq, and queue format change if it's changed. - add a simple kill switch to abort when stop (or pause for seek). - when seeking, if searching for start time goes into 2nd segment, do not signal time discontinuity or reset first PTS. - use setFormat() to set format in AnotherPacketSource, otherwise video/audio flags are not updated and format are not cleared on discontinuities. - do not start queueing video access unit until first IDR after start bug: 19656539 Change-Id: I79108d26964f59ea00d2eeac8f5f9318747f8541