|
From: Tapio V. <aa...@us...> - 2010-05-22 17:04:43
|
Module: performous
Branch: master
Commit: e108090f38deabfecc1ba9deef67d55f1ac43585
Author: Tapio Vierros <tap...@gm...>
Date: Sat May 22 20:04:07 2010 +0300
Move OpenCV includes to webcam.cc
---
game/webcam.cc | 5 +++++
game/webcam.hh | 9 ++-------
2 files changed, 7 insertions(+), 7 deletions(-)
diff --git a/game/webcam.cc b/game/webcam.cc
index c4487c5..0dd11e1 100644
--- a/game/webcam.cc
+++ b/game/webcam.cc
@@ -3,6 +3,11 @@
#include "webcam.hh"
#include "xtime.hh"
+#ifdef USE_OPENCV
+#include <cv.h>
+#include <highgui.h>
+#endif
+
Webcam::Webcam(int cam_id):
m_thread(), m_capture(NULL), m_frameAvailable(false), m_running(false), m_quit(false)
{
diff --git a/game/webcam.hh b/game/webcam.hh
index 5754f3d..ae7cd09 100644
--- a/game/webcam.hh
+++ b/game/webcam.hh
@@ -1,12 +1,5 @@
#pragma once
-#ifdef USE_OPENCV
-#include <cv.h>
-#include <highgui.h>
-#else
-typedef void CvCapture;
-#endif
-
#include <boost/scoped_ptr.hpp>
#include <boost/thread/mutex.hpp>
#include <boost/thread/thread.hpp>
@@ -14,6 +7,8 @@ typedef void CvCapture;
#include "surface.hh"
+class CvCapture;
+
struct CamFrame {
int width;
int height;
|