summaryrefslogtreecommitdiff
path: root/graphics/libvideogfx/patches/patch-ag
blob: 7a3f72ef6a413e9ead4b428932ff9d82c5ce0ffe (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
$NetBSD: patch-ag,v 1.1 2006/01/15 20:34:13 joerg Exp $

--- libvideogfx/graphics/datatypes/primitives.hh.orig	2006-01-15 20:26:10.000000000 +0000
+++ libvideogfx/graphics/datatypes/primitives.hh
@@ -35,6 +35,8 @@
 #ifndef LIBVIDEOGFX_GRAPHICS_DATATYPES_PRIMITIVES_HH
 #define LIBVIDEOGFX_GRAPHICS_DATATYPES_PRIMITIVES_HH
 
+#include <cmath>
+
 namespace videogfx {
 
   template <class T> struct Point2D
@@ -52,7 +54,7 @@ namespace videogfx {
 
     T x,y;
 
-    T Length() const { return (T)sqrt((double)(x*x+y*y)); }
+    T Length() const { return (T)std::sqrt((double)(x*x+y*y)); }
   };
 
   template <class T> struct Rect2D