Bug 1147744: Part1. Round down display size. r=k17e
authorJean-Yves Avenard <jyavenard@mozilla.com>
Wed, 08 Apr 2015 14:26:35 +1000
changeset 238093 d540c29d5c2f574d68ba813774cf0e3f38141c40
parent 238092 4699b65bf6e53386ffa04009d9ebb7fc7c9ee9b2
child 238094 801b4019fb00e17d660949300caff87fa8da753a
push id58114
push userjyavenard@mozilla.com
push dateWed, 08 Apr 2015 04:27:32 +0000
treeherdermozilla-inbound@801b4019fb00 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersk17e
bugs1147744
milestone40.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 1147744: Part1. Round down display size. r=k17e
media/libstagefright/binding/H264.cpp
--- a/media/libstagefright/binding/H264.cpp
+++ b/media/libstagefright/binding/H264.cpp
@@ -4,17 +4,16 @@
 
 #include "mozilla/ArrayUtils.h"
 #include "mozilla/PodOperations.h"
 #include "mp4_demuxer/AnnexB.h"
 #include "mp4_demuxer/ByteReader.h"
 #include "mp4_demuxer/ByteWriter.h"
 #include "mp4_demuxer/H264.h"
 #include <media/stagefright/foundation/ABitReader.h>
-#include <cmath>
 
 using namespace mozilla;
 
 namespace mp4_demuxer
 {
 
 class BitReader
 {
@@ -127,17 +126,17 @@ H264::DecodeNALUnit(const ByteBuffer* aN
   return rbsp.forget();
 }
 
 static int32_t
 ConditionDimension(float aValue)
 {
   // This will exclude NaNs and too-big values.
   if (aValue > 1.0 && aValue <= INT32_MAX)
-    return int32_t(round(aValue));
+    return int32_t(aValue);
   return 0;
 }
 
 /* static */ bool
 H264::DecodeSPS(const ByteBuffer* aSPS, SPSData& aDest)
 {
   MOZ_ASSERT(aSPS);
   BitReader br(*aSPS);