summaryrefslogtreecommitdiffstats
path: root/media/libstagefright/MPEG4Extractor.cpp
Commit message (Collapse)AuthorAgeFilesLines
* Expose sample duration in MPEG4Extractor.Robert Shih2014-04-251-2/+10
| | | | | Bug: 12782113 Change-Id: I75ee361243c5382d9288349c554deb7bed952782
* Advance read pointer before failingMarco Nelissen2014-02-241-22/+47
| | | | | | | to prevent infinite loops when processing a truncated chunk b/13130358 Change-Id: I24c46788ebc76c242da52a8f059b7577bbaebff4
* Expand support for fragmented mp4Marco Nelissen2014-02-191-12/+27
| | | | | | | | Don't require that there are no other boxes between mdat and moof boxes, or that moof immediately follows moov. Fix SAP parsing and seeking to exact start of segment. Change-Id: I668644c5c7866dd2512f3b7f745fba438ae6e627
* Fix crash when seeking fragmented mp4 filesMarco Nelissen2014-02-181-10/+17
| | | | | | | | Rewinding a fragmented mp4 file without a segment index (sidx) after playing it to the end would crash. b/13028840 Change-Id: I280e74364589f0acefd432a59f85a6594c009a21
* Even more warnings (now errors) fixed to unbreak the sdk-x86 build(s).Andreas Huber2014-02-121-1/+1
| | | | Change-Id: Ib4a5ab1a9e50fe9e7747a907f8b4a8c207099fdb
* warnings be gone.Andreas Huber2014-02-111-3/+6
| | | | Change-Id: Ie3bae3f037730e316d7fca12e7a3527973f752ef
* resolved conflicts for merge of 566be7c3 to masterNarayan Kamath2014-02-111-1/+1
|\ | | | | | | Change-Id: I7b1cc71057b2bd4f771e7bcf508a8c3abd6017ce
| * Make frameworks/av 64-bit compatibleKévin PETIT2014-02-111-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | Contains the necessary changes to make frameworks/av build and work on a 64-bit machine. Signed-off-by: Craig Barber <craig.barber@arm.com> Signed-off-by: Kévin PETIT <kevin.petit@arm.com> Signed-off-by: Ashok Bhat <ashok.bhat@arm.com> Signed-off-by: Marcus Oakland <marcus.oakland@arm.com> Change-Id: I725feaae50ed8eee25ca2c947cf15aee1f395c43
* | am 6146f60c: am 319c5640: am 07a017d3: Merge "Added support for ID3v2 meta ↵Marco Nelissen2014-01-171-1/+70
|\ \ | |/ | | | | | | | | | | data in 3gp files" * commit '6146f60c87a8a9c66036325c66dea826d2e98f6f': Added support for ID3v2 meta data in 3gp files
| * Added support for ID3v2 meta data in 3gp filesOscar Rydhé2014-01-161-1/+70
| | | | | | | | | | | | | | | | Added support for parsing ID3v2 meta data from the ID32 chunk in 3gp files. The priority will be 3gpp -> ID3v2 -> iTunes per field. Change-Id: I0282ecab58e3e5fa6bd738078d562c8bb8ce00ed
* | Support more channel configurations in MPEG4ExtractorJean-Michel Trivi2014-01-081-1/+158
|/ | | | | | | | | | Add support for streams having an audio specific configuration with the channel_configuration equal to zero. Add support for 6.1 and 7.1 channel configurations. Bug 9428126 Change-Id: Iaac2516139093579c52095d4f74ae4428f8e368a
* stagefright: do not offload LD-AAC decodingEric Laurent2013-12-211-0/+3
| | | | | | | | | | For now, do not offload LD and ELD AAC decoding because there is no way to know if it is supported by the audio DSP implementation. The longer term fix will be to have mapMimeToAudioFormat() use the audio object type in track metadata to refine the AAC format and the audio HAL list supported AAC profiles. Change-Id: Iaa88ecf3f4ae42ad48c1b42a9b007dd80eb88147
* stagefright: fix offloading HE-AAC sampling rate.Eric Laurent2013-12-191-17/+23
| | | | | | | | Fix HE AAC SBR sampling rate reading for explicit signaling. Bug: 11697128. Change-Id: Ifec0ab9d48d9293f6774ec1efd9da9445994cb7c
* Merge commit '2381f06f374ee0cb8bca0edf5388394432b00e6d' into HEADThe Android Open Source Project2013-12-051-6/+20
|\
| * am 24605338: Merge "Fix metadata access" into klp-devMarco Nelissen2013-11-151-3/+6
| |\ | | | | | | | | | | | | * commit '246053380a9f628405a29a055a3f1f4fba13ed5b': Fix metadata access
| | * Fix metadata accessMarco Nelissen2013-11-151-3/+6
| | | | | | | | | | | | | | | | | | | | | | | | Metadata string pointers become invalid after setting more metadata, so don't cache them. b/11692062 Change-Id: Iaf1afb24cf53f7fa36f49ce759355693494076e5
| * | am 92092b39: Merge "stagefright: limit default max-input-size for AVC" into ↵Lajos Molnar2013-11-131-7/+18
| |\ \ | | |/ | | | | | | | | | | | | | | | klp-dev * commit '92092b395d59e8943a461d344f617f1dc85375a3': stagefright: limit default max-input-size for AVC
| | * stagefright: limit default max-input-size for AVCLajos Molnar2013-11-131-7/+18
| | | | | | | | | | | | | | | | | | | | | | | | | | | AVC has a compression ratio of at least 2. Account for this, as some codecs refuse exorbitant max-input-size requests. Change-Id: Ib68b485879ba33a12a486f2ce18fe100be977699 Signed-off-by: Lajos Molnar <lajos@google.com> Bug: 11599364
* | | Fix SIGABRT when playing mp4 fileMarco Nelissen2013-11-251-0/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | If the track duration was shorter than the segment duration, the calculated encoder padding would be negative, resulting in a crash. b/11823061 https://code.google.com/p/android/issues/detail?id=62610 Change-Id: I3989ad88caea38d212b61355c15aec13382c6116
* | | Fixed data offset at parsing IPMP DescriptorsIchitaro Kohara2013-11-251-1/+2
|/ / | | | | | | | | | | | | | | MPEG4Extractor::parseDrmSINF() miscalculated data offset in parsing IPMP Descriptors. This commit makes it to take in 2 bytes which is the size of IPMPS_Type field. Change-Id: I42cbb6793af9d9b2f14dbfdd7a616096002793f9
* | am ff58698e: am f36ae7ca: Merge "Added support for 3GPP meta data atoms"Marco Nelissen2013-08-191-2/+129
|\ \ | |/ |/| | | | | * commit 'ff58698ec7e0f32bf9f3e1758173fe170e17270c': Added support for 3GPP meta data atoms
| * Added support for 3GPP meta data atomsOscar Rydhé2013-08-131-2/+129
| | | | | | | | | | | | | | 3GPP metadata is not supported, only iTunes Metadata Format is supported. Change-Id: I78b41c88788d5a43800c936e0ac0f98424515c62
| * Fix sample info parsingMarco Nelissen2013-04-181-58/+83
| | | | | | | | | | | | b/8626561 Change-Id: Ibd5168282eb33d1abdc423e15a0d9aeb5a1ad687
| * Add support for common encryptionMarco Nelissen2013-04-081-8/+356
| | | | | | | | | | | | b/7465749 Change-Id: I5403b74a5ae428ad28b382863a09daafc400b137
| * Parse SBR extension sample rateMarco Nelissen2013-03-141-9/+22
| | | | | | | | Change-Id: Ib6f6994228a279ee10b389515fba04516c7c42ba
| * Add support for fragmented mp4 to MPEG4ExtractorMarco Nelissen2013-02-151-29/+853
| | | | | | | | | | | | | | This makes FragmentedMP4Extractor obsolete. It will be removed in a separate change. Change-Id: Ida74c07ccf84983e20a1320ee24ffc7a5c083859
| * Merge "Memory leak solved in MPEG4Extractor::parseChunk for cover art"Andreas Huber2012-12-031-6/+3
| |\
| | * Memory leak solved in MPEG4Extractor::parseChunk for cover artJens Gulin2012-11-191-6/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | Repeated leaks detected in mediaserver context. Most chunks small but some bigger. Adding up it was not uncommon to see 200Mb footprint. libc memdebug allocation call stack showed the root cause in "covr" parsing - that explains why content often was empty but sometimes big. Change-Id: I0de6c1eeef174d2529973ff9c6a020ec3dd44c75
| * | Merge "Handle large AVCC chunks"Andreas Huber2012-11-201-6/+4
| |\ \
| | * | Handle large AVCC chunksJan Olof Svensson2012-11-191-6/+4
| | |/ | | | | | | | | | | | | | | | | | | | | | If enabling seq_scaling_matrix_present_flag = 1 the AVCC chunk can be larger than the original buffer size. Changed to using ABuffer instead. Change-Id: Idacc14b45ea2634c5e608919f3ce567f23363135
| * | Changed parsing of trkn and disk from 8 bits to 16 bitsAndreas Lillvik2012-11-191-5/+7
| |/ | | | | | | | | | | | | The MPEG4Extractor was parsing 8 bits instead of 16 bits when parsing 'trkn' and 'disk'. Also added support for 16 bytes size 'disk'. Change-Id: I22b4de2ac800881884d5759776cb380917522a87
| * Fix iTunSMPB parsing for AAC tracks encoded with NeroJohn Grossman2012-09-071-8/+19
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Make sure to clear out the mean/name/data state when parsing apple-style metadata from tracks every time we have a full set, not just when we find an iTunSMPB set. AAC tracks encoded from WAV by Nero tend to put in an additional apple style metadata tag (cdec) before the iTunSMPB tag. The sequence in the file goes something like mean : "com.apple.iTunes" name : "cdec" data : "ndaudio 1.5.4.0 / -2pass -br 320000" mean : "com.apple.iTunes" name : "iTunSMPB" data : " 00000000 00000A40 000000B8 <etc...>" If the internal state was not cleared after the first set, then when the second instance of "name" is encountered, an attempt is made to parse the previous data entry as an iTunSMPB tag when it is actually a cdec tag. Afterwards, mean, name and data are all cleared, and when the second data is encountered there is no current mean or name present, so the gapless metadata gets skipped. By clearing the metadata state every time we have a full set of mean/name/data, we make sure that we are always interpreting the data field as the proper type. Change-Id: I196e2e3f83e434f15d5ee55ae40a74a92d5a1845
| * Fragmented mp4 extractorMarco Nelissen2012-09-051-1/+2
| | | | | | | | | | | | | | Still experimental. Set property "media.stagefright.use-fragmp4" to true to enable. Change-Id: I210b9c5b5164b5c5eefc31309845ee881ac7db8e
* | Fail more gracefully on version mismatchMarco Nelissen2013-07-291-3/+3
| | | | | | | | | | | | b/9900647 Change-Id: I9ea508a2685ff8adc780edd5ecec30dd1a9b0997
* | Edit list uses timescale from movie headerMarco Nelissen2013-05-301-7/+10
| | | | | | | | | | | | not from track media header Change-Id: I24063183f44027b999782cc9006e9a1b56e87355
* | Don't crash if no timescale was givenMarco Nelissen2013-05-291-0/+2
| | | | | | | | | | | | b/9175577 Change-Id: Ie159a9c9b42e6c8d9366d0ef6a607234af569e36
* | Add support for MPEG editlist gapless infoMarco Nelissen2013-05-231-0/+61
| | | | | | | | Change-Id: I862d89c805d738db9bdf81a8f1c5b317ff968dff
* | Fix sample info parsingMarco Nelissen2013-04-181-58/+83
| | | | | | | | | | | | b/8626561 Change-Id: Ibd5168282eb33d1abdc423e15a0d9aeb5a1ad687
* | Add support for common encryptionMarco Nelissen2013-04-081-8/+356
| | | | | | | | | | | | b/7465749 Change-Id: I5403b74a5ae428ad28b382863a09daafc400b137
* | Parse SBR extension sample rateMarco Nelissen2013-03-141-9/+22
| | | | | | | | Change-Id: Ib6f6994228a279ee10b389515fba04516c7c42ba
* | Add support for fragmented mp4 to MPEG4ExtractorMarco Nelissen2013-02-151-29/+853
| | | | | | | | | | | | | | This makes FragmentedMP4Extractor obsolete. It will be removed in a separate change. Change-Id: Ida74c07ccf84983e20a1320ee24ffc7a5c083859
* | Merge "Memory leak solved in MPEG4Extractor::parseChunk for cover art"Andreas Huber2012-12-031-6/+3
|\ \
| * | Memory leak solved in MPEG4Extractor::parseChunk for cover artJens Gulin2012-11-191-6/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | Repeated leaks detected in mediaserver context. Most chunks small but some bigger. Adding up it was not uncommon to see 200Mb footprint. libc memdebug allocation call stack showed the root cause in "covr" parsing - that explains why content often was empty but sometimes big. Change-Id: I0de6c1eeef174d2529973ff9c6a020ec3dd44c75
* | | Merge "Handle large AVCC chunks"Andreas Huber2012-11-201-6/+4
|\ \ \
| * | | Handle large AVCC chunksJan Olof Svensson2012-11-191-6/+4
| |/ / | | | | | | | | | | | | | | | | | | | | | If enabling seq_scaling_matrix_present_flag = 1 the AVCC chunk can be larger than the original buffer size. Changed to using ABuffer instead. Change-Id: Idacc14b45ea2634c5e608919f3ce567f23363135
* | | Changed parsing of trkn and disk from 8 bits to 16 bitsAndreas Lillvik2012-11-191-5/+7
|/ / | | | | | | | | | | | | The MPEG4Extractor was parsing 8 bits instead of 16 bits when parsing 'trkn' and 'disk'. Also added support for 16 bytes size 'disk'. Change-Id: I22b4de2ac800881884d5759776cb380917522a87
* | Fix iTunSMPB parsing for AAC tracks encoded with NeroJohn Grossman2012-09-071-8/+19
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Make sure to clear out the mean/name/data state when parsing apple-style metadata from tracks every time we have a full set, not just when we find an iTunSMPB set. AAC tracks encoded from WAV by Nero tend to put in an additional apple style metadata tag (cdec) before the iTunSMPB tag. The sequence in the file goes something like mean : "com.apple.iTunes" name : "cdec" data : "ndaudio 1.5.4.0 / -2pass -br 320000" mean : "com.apple.iTunes" name : "iTunSMPB" data : " 00000000 00000A40 000000B8 <etc...>" If the internal state was not cleared after the first set, then when the second instance of "name" is encountered, an attempt is made to parse the previous data entry as an iTunSMPB tag when it is actually a cdec tag. Afterwards, mean, name and data are all cleared, and when the second data is encountered there is no current mean or name present, so the gapless metadata gets skipped. By clearing the metadata state every time we have a full set of mean/name/data, we make sure that we are always interpreting the data field as the proper type. Change-Id: I196e2e3f83e434f15d5ee55ae40a74a92d5a1845
* | Fragmented mp4 extractorMarco Nelissen2012-09-051-1/+2
|/ | | | | | | Still experimental. Set property "media.stagefright.use-fragmp4" to true to enable. Change-Id: I210b9c5b5164b5c5eefc31309845ee881ac7db8e
* Add Fraunhofer AAC encoder with AAC-ELD support.Dave Burke2012-04-251-12/+10
| | | | Change-Id: I6cd499d257d72f50a5b508bed97796a591a51506
* Fix the file mimetype reported by the mpeg4 extractor.Andreas Huber2012-03-231-1/+2
| | | | | Change-Id: I72474c17757dba5867f55b0e99e76e9e4e32ce7b related-to-bug: 6217289