Camera tracking integration
authorSergey Sharybin <sergey.vfx@gmail.com>
Mon, 26 Sep 2011 20:03:07 +0000 (20:03 +0000)
committerSergey Sharybin <sergey.vfx@gmail.com>
Mon, 26 Sep 2011 20:03:07 +0000 (20:03 +0000)
===========================

Attempt to fix MinGW compilaiton.

extern/libmv/libmv/numeric/numeric.h
extern/libmv/patches/mingw.patch [new file with mode: 0644]
extern/libmv/patches/series

index f39d126c0f25d75832ac0bc09993e03d5a48106c..21e0f067446a2ff7b454a0f0a19a156a3bc9b280 100644 (file)
@@ -40,7 +40,7 @@
   }
 #endif //_WIN32 || __APPLE__
 
-#if _WIN32
+#if (defined(WIN32) || defined(WIN64)) && !defined(__MINGW32__)
   inline long lround(double d) {
     return (long)(d>0 ? d+0.5 : ceil(d-0.5));
   }
diff --git a/extern/libmv/patches/mingw.patch b/extern/libmv/patches/mingw.patch
new file mode 100644 (file)
index 0000000..0b08a48
--- /dev/null
@@ -0,0 +1,13 @@
+diff --git a/src/libmv/numeric/numeric.h b/src/libmv/numeric/numeric.h
+index f39d126..21e0f06 100644
+--- a/src/libmv/numeric/numeric.h
++++ b/src/libmv/numeric/numeric.h
+@@ -40,7 +40,7 @@
+   }
+ #endif //_WIN32 || __APPLE__
+-#if _WIN32
++#if (defined(WIN32) || defined(WIN64)) && !defined(__MINGW32__)
+   inline long lround(double d) {
+     return (long)(d>0 ? d+0.5 : ceil(d-0.5));
+   }
index 8b0e74066344b5026aed035d4ac6209939c56af6..f8048e27718ab323923596c16127f7c55d7e1809 100644 (file)
@@ -6,3 +6,4 @@ config_mac.patch
 levenberg_marquardt.patch
 function_derivative.patch
 high_distortion_crash_fix.patch
+mingw.patch