|
direcs
2012-09-30
|
This class gets a live picture from a Kinect camera. This class uses the QThread techniques and then some OpenCV stuff on the live picture; we will see... More...
#include <camThread.h>
Public Slots | |
| void | enableFaceDetection (int state) |
| void | setThreshold (int threshold) |
Signals | |
| void | camImageComplete (QImage *image) |
| void | camImageDepthComplete (QImage *image) |
| void | camImageOpenCVComplete (QImage *image) |
| void | disableCamera () |
| void | disableFaceDetection () |
| void | faceDetected (int faces, int faceX, int faceY, int faceRadius, int lastFaceX, int lastFaceY) |
| void | message (QString text) |
Public Member Functions | |
| CamThread () | |
| bool | init () |
| bool | isConnected (void) |
| virtual void | run () |
| void | setCascadePath (QString haarClassifierCascade) |
| void | stop () |
| ~CamThread () | |
Private Attributes | |
| bool | cameraIsOn |
| char * | data |
| char * | dataDepth |
| freenect_context * | f_ctx |
| freenect_device * | f_dev |
| bool | faceDetectionIsEnabled |
| bool | faceDetectionWasActive |
| Mat | gray |
| QString | haarClassifierCascadeFilename |
| bool | initDone |
| std::vector< uint16_t > | m_gamma |
| int | mThreshold |
| QImage | qimage |
| QImage | qimageDepth |
| QImage | qimageOpenCV |
| volatile bool | stopped |
| unsigned int | timestamp |
Static Private Attributes | |
| static const unsigned long | THREADSLEEPTIME = 50 |
This class gets a live picture from a Kinect camera. This class uses the QThread techniques and then some OpenCV stuff on the live picture; we will see...
Definition at line 56 of file camThread.h.
| CamThread::CamThread | ( | ) |
Definition at line 24 of file camThread.cpp.
| CamThread::~CamThread | ( | ) |
Definition at line 38 of file camThread.cpp.
|
signal |
| *image | is a pointer to the camera image |

|
signal |
| *image | is a pointer to the camera image |

|
signal |
| *image | is a pointer to the camera image |

|
signal |
Disables camera controls in the GUI
|
signal |
Disables checkBoxes in the GUI

|
slot |
Enables or disables the face detection. When activated, a circle for each face is drawn on the camera live image.
| state | has to be Qt::Checked to enable the detection. All other states disable. |
Definition at line 175 of file camThread.cpp.
|
signal |
This signal is emmited when a face was detected in the camera image
| faces | is the total number of faces detected |
| faceX | is the X coordinate to the middle of a detected face (0, if none) |
| faceY | is the Y coordinate to the middle of a detected face (0, if none) |
| faceRadius | is the radius (0, if none) |
| lastFaceX | is the X coordinate of the latest face detected |
| lastFaceY | is the Y coordinate of the latest face detected |
| bool CamThread::init | ( | ) |
Definition at line 203 of file camThread.cpp.


| bool CamThread::isConnected | ( | void | ) |
Definition at line 169 of file camThread.cpp.
|
signal |
Emits a info or error message to a slot. This slot can be used to display a text on a splash screen, log file, to print it to a console...
| text | is the message to be emitted |

|
virtual |
| void CamThread::setCascadePath | ( | QString | haarClassifierCascade | ) |
Sets the path and filename to the haar classifier cascade.
| haarClassifierCascade | is the whole filename |
Definition at line 189 of file camThread.cpp.

|
slot |
Set threshold for OpenCV algorithm.
| threshold |
Definition at line 246 of file camThread.cpp.

| void CamThread::stop | ( | ) |
|
private |
Definition at line 171 of file camThread.h.
|
private |
Definition at line 153 of file camThread.h.
|
private |
Definition at line 154 of file camThread.h.
|
private |
Definition at line 150 of file camThread.h.
|
private |
Definition at line 151 of file camThread.h.
|
private |
Definition at line 172 of file camThread.h.
|
private |
Definition at line 173 of file camThread.h.
|
private |
Definition at line 160 of file camThread.h.
|
private |
Definition at line 174 of file camThread.h.
|
private |
Definition at line 170 of file camThread.h.
|
private |
Definition at line 164 of file camThread.h.
|
private |
Definition at line 162 of file camThread.h.
|
private |
Definition at line 157 of file camThread.h.
|
private |
Definition at line 158 of file camThread.h.
|
private |
Definition at line 159 of file camThread.h.
|
private |
Definition at line 175 of file camThread.h.
|
staticprivate |
Definition at line 179 of file camThread.h.
|
private |
Definition at line 155 of file camThread.h.