Bug 1100210 - Mark MPEG2 Layer 1,2,3 audio as MP3. r=k17e, a=sledru
authorJean-Yves Avenard <jyavenard@mozilla.com>
Tue, 17 Mar 2015 16:42:47 +1100
changeset 258312 a72d76b284ea
parent 258311 a1d7b2cdd950
child 258313 d59b572e546f
push id4643
push userryanvm@gmail.com
push date2015-04-07 14:24 +0000
treeherdermozilla-beta@0c29ab096b90 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersk17e, sledru
bugs1100210
milestone38.0
Bug 1100210 - Mark MPEG2 Layer 1,2,3 audio as MP3. r=k17e, a=sledru Extract data from ESDS atom's objectTypeIndication
media/libstagefright/frameworks/av/media/libstagefright/MPEG4Extractor.cpp
--- a/media/libstagefright/frameworks/av/media/libstagefright/MPEG4Extractor.cpp
+++ b/media/libstagefright/frameworks/av/media/libstagefright/MPEG4Extractor.cpp
@@ -2441,17 +2441,17 @@ status_t MPEG4Extractor::updateAudioTrac
     }
 
     if (objectTypeIndication == 0xe1) {
         // This isn't MPEG4 audio at all, it's QCELP 14k...
         mLastTrack->meta->setCString(kKeyMIMEType, MEDIA_MIMETYPE_AUDIO_QCELP);
         return OK;
     }
 
-    if (objectTypeIndication  == 0x6b) {
+    if (objectTypeIndication  == 0x6b || objectTypeIndication  == 0x69) {
         // The media subtype is MP3 audio
         mLastTrack->meta->setCString(kKeyMIMEType, MEDIA_MIMETYPE_AUDIO_MPEG);
     }
 
     const uint8_t *csd;
     size_t csd_size;
     if (esds.getCodecSpecificInfo(
                 (const void **)&csd, &csd_size) != OK) {