Bug 1043710 - Pass dts to VideoToolbox decoder. r=ajones
authorRalph Giles <giles@mozilla.com>
Wed, 27 Aug 2014 14:08:00 -0700
changeset 223704 feb4a53fd308b7a28ff372d7f8f378131fadcc65
parent 223703 632d5a8709cbd78fe679de85eb7776bd863ebbb2
child 223705 674723cd981a5af7878cb5f5ee45075f61b71057
push id3979
push userraliiev@mozilla.com
push dateMon, 13 Oct 2014 16:35:44 +0000
treeherdermozilla-beta@30f2cc610691 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersajones
bugs1043710
milestone34.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1043710 - Pass dts to VideoToolbox decoder. r=ajones
content/media/fmp4/apple/AppleVTDecoder.cpp
--- a/content/media/fmp4/apple/AppleVTDecoder.cpp
+++ b/content/media/fmp4/apple/AppleVTDecoder.cpp
@@ -332,18 +332,18 @@ AppleVTDecoder::OutputFrame(CVPixelBuffe
 static CMSampleTimingInfo
 TimingInfoFromSample(mp4_demuxer::MP4Sample* aSample)
 {
   CMSampleTimingInfo timestamp;
 
   timestamp.duration = CMTimeMake(aSample->duration, USECS_PER_S);
   timestamp.presentationTimeStamp =
     CMTimeMake(aSample->composition_timestamp, USECS_PER_S);
-  // No DTS value available from libstagefright.
-  timestamp.decodeTimeStamp = CMTimeMake(0, USECS_PER_S);
+  timestamp.decodeTimeStamp =
+    CMTimeMake(aSample->decode_timestamp, USECS_PER_S);
 
   return timestamp;
 }
 
 nsresult
 AppleVTDecoder::SubmitFrame(mp4_demuxer::MP4Sample* aSample)
 {
   // For some reason this gives me a double-free error with stagefright.