- trackeye_src.zip
- TrackEye_SourceCode
- trackeye_demo.zip
- TrackEye_Executable
- Avis
- Sample.avi
- cv.dll
- cvaux.dll
- cvcam.dll
- EyeDatabase
- eye0.jpg
- eye1.jpg
- eye10.jpg
- eye11.jpg
- eye12.jpg
- eye13.jpg
- eye14.jpg
- eye15.jpg
- eye16.jpg
- eye2.jpg
- eye3.jpg
- eye4.jpg
- eye5.jpg
- eye6.jpg
- eye7.jpg
- eye8.jpg
- eye9.jpg
- highgui.dll
- Readme.txt
- SampleEye.jpg
- SampleHUE.jpg
- Thumbs.db
- TrackEye_636.exe
|
#include "cv.h"
#include "highgui.h"
// Function prototypes
void extractHUE(IplImage* source, IplImage* dest);
void drawFaceBox(IplImage* img, CvBox2D faceBox);
void extractHUE(IplImage* source, IplImage* hue)
{
IplImage* HSV = cvCreateImage(cvGetSize(source), IPL_DEPTH_8U, 3);
// convert HSV color space
cvCvtColor(source, HSV, CV_RGB2HSV);
cvCvtPixToPlane(HSV, hue, NULL, NULL, NULL);
cvReleaseImage(&HSV);
}
void drawFaceBox(IplImage* img, CvBox2D faceBox, double color)
{
// top-left corner
CvPoint pt1;
pt1.x = (int)(faceBox.center.x - (faceBox.size.width/2.0));
pt1.y = (int)(faceBox.center.y - (faceBox.size.height/2.0));
// bottom-right corner
CvPoint pt2;
pt2.x = (int)(faceBox.center.x + (faceBox.size.width/2.0));
pt2.y = (int)(faceBox.center.y + (faceBox.size.height/2.0));
cvRectangle( img, pt1, pt2, color, 2 );
}
|
By viewing downloads associated with this article you agree to the Terms of Service and the article's licence.
If a file you wish to view isn't highlighted, and is a text file (not binary), please
let us know and we'll add colourisation support for it.
Zafer is an electronics engineer living in Ankara/Turkey and working for ASELSAN A.S./TMM.
He has been coding for about 12 years, and can't think a life without C/C++.
He likes
- MS Visual C++ 6.0 and MFC
- .NET C#
- All kinds of electronics stuff
- Machine Vision projects
Also he enjoys
- Listening to "The Cranberries" & "The Glorious Dolores"
- Travelling
E-mail : zafersavas@yahoo.com