00001 /* 00002 * Camera.h 00003 * Copyright (C) FIRSTNAME LASTNAME YEAR <EMAIL> 00004 * 00005 * Camera.h is free software: you can redistribute it and/or modify it 00006 * under the terms of the GNU General Public License as published by the 00007 * Free Software Foundation, either version 3 of the License, or 00008 * (at your option) any later version. 00009 * 00010 * Camera.h is distributed in the hope that it will be useful, but 00011 * WITHOUT ANY WARRANTY; without even the implied warranty of 00012 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. 00013 * See the GNU General Public License for more details. 00014 * 00015 * You should have received a copy of the GNU General Public License along 00016 * with this program. If not, see <http://www.gnu.org/licenses/>. 00017 */ 00018 00019 #ifndef Camera_H 00020 #define Camera_H 00021 00022 #include "uvsim/sensing/Sensor.h" 00023 #include <opencv/highgui.h> 00024 00025 00026 namespace uvsim 00027 { 00028 00034 class Camera : public uvsim::Sensor 00035 { 00036 public: 00040 Camera(int device); 00041 00045 virtual ~Camera(); 00046 00050 virtual void update(); 00051 00052 // Public Members 00053 IplImage * m_frame; 00054 00055 private: 00056 00057 // Private Members 00058 CvCapture * m_capture; 00059 }; 00060 00061 } 00062 00063 #endif 00064 00065 // vim:ts=4:sw=4