cairo, videofilter: use gst/math-compat.h header for rint
authorTim-Philipp Müller <tim.muller@collabora.co.uk>
Fri, 31 Dec 2010 02:16:54 +0000 (02:16 +0000)
committerTim-Philipp Müller <tim.muller@collabora.co.uk>
Fri, 31 Dec 2010 02:16:54 +0000 (02:16 +0000)
ext/cairo/gsttimeoverlay.c
gst/videofilter/gstvideobalance.c

index 18f18f8..b731c37 100644 (file)
 #include "config.h"
 #endif
 
+#include <gst/math-compat.h>
+
 #include <gsttimeoverlay.h>
 
 #include <string.h>
-#include <math.h>
 
 #include <cairo.h>
 
 #include <gst/video/video.h>
 
-#ifndef HAVE_RINT
-#define rint(x) ((double) floor((x)+(((x) < 0)? -0.5 : 0.5)))
-#endif
-
 static GstStaticPadTemplate gst_cairo_time_overlay_src_template =
 GST_STATIC_PAD_TEMPLATE ("src",
     GST_PAD_SRC,
index 136acae..968e259 100644 (file)
 #include "config.h"
 #endif
 
+#include <gst/math-compat.h>
+
 #include "gstvideobalance.h"
 #include <string.h>
-#include <math.h>
 
 #include <gst/controller/gstcontroller.h>
 #include <gst/interfaces/colorbalance.h>
 
-#ifndef HAVE_RINT
-#define rint(x) (floor((x)+0.5))
-#endif
-
 GST_DEBUG_CATEGORY_STATIC (videobalance_debug);
 #define GST_CAT_DEFAULT videobalance_debug