39 #ifndef vpDisplayOpenCV_h
40 #define vpDisplayOpenCV_h
42 #include <visp3/core/vpConfig.h>
43 #if defined(VISP_HAVE_OPENCV)
45 #include <visp3/core/vpDisplay.h>
46 #include <visp3/core/vpImage.h>
47 #include <visp3/core/vpImageConvert.h>
49 #if VISP_HAVE_OPENCV_VERSION >= 0x020101
50 # include <opencv2/core/core.hpp>
51 # include <opencv2/highgui/highgui.hpp>
143 #if (VISP_HAVE_OPENCV_VERSION < 0x020408)
144 IplImage* background;
156 static std::vector<std::string> m_listTitles;
157 static unsigned int m_nbWindows ;
210 const char *title=NULL) ;
212 const char *title=NULL) ;
217 int winx=-1,
int winy=-1,
218 const char *title=NULL) ;
220 int winx=-1,
int winy=-1,
221 const char *title=NULL) ;
223 void init(
unsigned int width,
unsigned int height,
224 int winx=-1,
int winy=-1 ,
225 const char *title=NULL) ;
229 void setFont(
const char *font );
240 unsigned int w=4,
unsigned int h=2,
241 unsigned int thickness=1) ;
249 unsigned int thickness=1);
251 const vpColor &color,
unsigned int thickness=1) ;
254 const vpColor &color,
unsigned int thickness=1) ;
265 const vpColor &color,
unsigned int thickness=1) ;
269 unsigned int width,
unsigned int height,
270 const vpColor &color,
bool fill =
false,
271 unsigned int thickness=1) ;
274 const vpColor &color,
bool fill =
false,
275 unsigned int thickness=1) ;
277 const vpColor &color,
bool fill =
false,
278 unsigned int thickness=1) ;
287 bool blocking=
true) ;
290 bool blocking=
true) ;
300 static void on_mouse(
int event,
int x,
int y,
int flags,
void* param );
virtual void displayCircle(const vpImagePoint ¢er, unsigned int radius, const vpColor &color, bool fill=false, unsigned int thickness=1)=0
virtual void displayImage(const vpImage< unsigned char > &I)=0
virtual void init(vpImage< unsigned char > &I, int x=-1, int y=-1, const char *title=NULL)=0
Class that defines generic functionnalities for display.
virtual void displayArrow(const vpImagePoint &ip1, const vpImagePoint &ip2, const vpColor &color=vpColor::white, unsigned int w=4, unsigned int h=2, unsigned int thickness=1)=0
unsigned int getWidth() const
Class to define colors available for display functionnalities.
virtual void clearDisplay(const vpColor &color=vpColor::white)=0
virtual bool getClickUp(vpImagePoint &ip, vpMouseButton::vpMouseButtonType &button, bool blocking=true)=0
virtual bool getPointerMotionEvent(vpImagePoint &ip)=0
static const vpColor green
virtual void flushDisplay()=0
unsigned int getHeight() const
virtual bool getPointerPosition(vpImagePoint &ip)=0
virtual bool getKeyboardEvent(bool blocking=true)=0
virtual void setWindowPosition(int winx, int winy)=0
The vpDisplayOpenCV allows to display image using the opencv library.
virtual void displayCross(const vpImagePoint &ip, unsigned int size, const vpColor &color, unsigned int thickness=1)=0
virtual void displayImageROI(const vpImage< unsigned char > &I, const vpImagePoint &iP, const unsigned int width, const unsigned int height)=0
virtual void setTitle(const char *title)=0
virtual void setFont(const char *font)=0
virtual void displayRectangle(const vpImagePoint &topLeft, unsigned int width, unsigned int height, const vpColor &color, bool fill=false, unsigned int thickness=1)=0
static void getImage(const vpImage< unsigned char > &Is, vpImage< vpRGBa > &Id)
virtual void displayDotLine(const vpImagePoint &ip1, const vpImagePoint &ip2, const vpColor &color, unsigned int thickness=1)=0
virtual void closeDisplay()=0
virtual void displayCharString(const vpImagePoint &ip, const char *text, const vpColor &color=vpColor::green)=0
Defines a rectangle in the plane.
virtual bool getClick(bool blocking=true)=0
Class that defines a 2D point in an image. This class is useful for image processing and stores only ...
virtual void displayLine(const vpImagePoint &ip1, const vpImagePoint &ip2, const vpColor &color, unsigned int thickness=1)=0
virtual void flushDisplayROI(const vpImagePoint &iP, const unsigned int width, const unsigned int height)=0
static const vpColor white
virtual void displayPoint(const vpImagePoint &ip, const vpColor &color)=0