#include <ImageWidget.h>
List of all members.
Public Member Functions |
| ImageWidget (QWidget *parent=0) |
void | setImage (QImage *image) |
void | setImage (IplImage *img) |
void | reset () |
void | addRectange (CvRect &rect) |
Protected Member Functions |
void | paintEvent (QPaintEvent *event) |
QImage | iplToQImage (IplImage *img, QImage *&dest) |
Protected Attributes |
QPen * | rectPen |
QImage * | image |
QList< QRect > | rects |
Detailed Description
Qt widget to display an OpenCV IplImage.
Constructor & Destructor Documentation
ImageWidget::ImageWidget |
( |
QWidget * |
parent = 0 ) |
|
Initializes the widget. A blank rectangle is drawn until an image is set.
- Parameters:
-
Member Function Documentation
void ImageWidget::addRectange |
( |
CvRect & |
rect ) |
|
Draws a rectangle on top of the image.
- Note:
- This method can be called multiple times in-between setImage() to draw multiple rectangles.
- Parameters:
-
rect | Rectangle coordinates and size |
QImage ImageWidget::iplToQImage |
( |
IplImage * |
img, |
|
|
QImage *& |
dest |
|
) |
| [protected] |
Converts an IplImage to a QImage
- Parameters:
-
img | Input image |
dest | Destination image |
- Returns:
- Returns
dest
void ImageWidget::paintEvent |
( |
QPaintEvent * |
event ) |
[protected] |
Redraws the widget.
- Note:
- Do not call this method directly!
void ImageWidget::reset |
( |
) |
|
Removes the current image. This will result in a blank rectangle - similar to the constructor.
void ImageWidget::setImage |
( |
QImage * |
image ) |
|
Sets the image that should be displayed.
- Note:
- Internally, the IplImage is converted to a QImage
- Parameters:
-
void ImageWidget::setImage |
( |
IplImage * |
img ) |
|
Sets the image that should be displayed.
- Parameters:
-
The documentation for this class was generated from the following files:
- NIST_VASIR_src_beta_v1.0/YooIRIS/ImageWidget.h
- NIST_VASIR_src_beta_v1.0/YooIRIS/ImageWidget.cpp