Bug 885879 - Make sure cue times are not rounded r=rillian
authorRick Eyre <rick.eyre@hotmail.com>
Wed, 19 Jun 2013 14:35:04 -0400
changeset 147577 386301e2ee28dbdfc9ccc7645cc4235aef4d812d
parent 147576 3e3e6bbe62bb1c62cd8e93b6e09da895cd6599ed
child 147578 e0715ae1e4b49739d74d60d91f5b80991788d99f
push id2697
push userbbajaj@mozilla.com
push dateMon, 05 Aug 2013 18:49:53 +0000
treeherdermozilla-beta@dfec938c7b63 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersrillian
bugs885879, 833386
milestone24.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 885879 - Make sure cue times are not rounded r=rillian Tests for this will be landing in bug 833386 Part 2.
content/media/VideoUtils.h
--- a/content/media/VideoUtils.h
+++ b/content/media/VideoUtils.h
@@ -159,17 +159,17 @@ CheckedInt64 UsecsToFrames(int64_t aUsec
 
 // Number of microseconds per second. 1e6.
 static const int64_t USECS_PER_S = 1000000;
 
 // Number of microseconds per millisecond.
 static const int64_t USECS_PER_MS = 1000;
 
 // Converts seconds to milliseconds.
-#define MS_TO_SECONDS(s) ((s) / PR_MSEC_PER_SEC)
+#define MS_TO_SECONDS(s) ((double)(s) / (PR_MSEC_PER_SEC))
 
 // The maximum height and width of the video. Used for
 // sanitizing the memory allocation of the RGB buffer.
 // The maximum resolution we anticipate encountering in the
 // wild is 2160p - 3840x2160 pixels.
 static const int32_t MAX_VIDEO_WIDTH = 4000;
 static const int32_t MAX_VIDEO_HEIGHT = 3000;