1 #include "opencv2/imgproc/imgproc.hpp" 2 #include "opencv2/imgproc/types_c.h" 3 #include "opencv2/highgui/highgui_c.h" 4 #include <opencv2/opencv.hpp> 95 void col2origCol(
int hsv[3],
int bgr[3], cv::Mat src);
103 void printText(cv::Mat src, std::string text);
void makeContours(FrameGen *m, InterHand *hg)
create contours for the hand from the incoming frame to get the hand location and detect the hand ...
Definition: handDetect.cpp:211
int findBiggestContour(std::vector< std::vector< cv::Point >> contours)
get the biggest contours and remove the cotours that do not represent hands
Definition: handDetect.cpp:189
handDetect()
constructor
Definition: handDetect.cpp:23
int getMedian(std::vector< int > val)
calculate the median value of the color averaging results
Definition: handDetect.cpp:77
void normalizeColors(FrameGen *myImage)
get the color boundries and normalize them to 0-255
Definition: handDetect.cpp:145
void waitForPalmCover(FrameGen *m)
specify the location of the calibration squares on the incoming frame and draw them ...
Definition: handDetect.cpp:48
Class to handle intermediate processing of the hand detection such as hand bounding rectangle and con...
Definition: InterHand.hpp:14
Class to detect the hand from a video stream using thresholding and contours.
Definition: handDetect.h:27
void initTrackbars()
create trackbars to be able to manually adjust the threshold if needed. To use the trackbars...
Definition: handDetect.cpp:128
void produceBinaries(FrameGen *m)
getting the lower and upper boundries of the hand color. the function calculate these boundries based...
Definition: handDetect.cpp:171
void col2origCol(int hsv[3], int bgr[3], cv::Mat src)
convert the frame color to the original color from two input color spaces
Definition: handDetect.cpp:32
std::vector< My_ROI > roi
Definition: handDetect.cpp:19
void getAvgColor(FrameGen *m, My_ROI roi, int avg[3])
aquire the average hand skin color from the calibration squares
Definition: handDetect.cpp:89
Class for video capturing from camera module. It takes the frames from the camera and passes it to ot...
Definition: FrameGen.hpp:14
cv::Mat crop(FrameGen *m, InterHand *hg)
crop the detected hand area of each frame and store it in Mat object to be fed to the inference model...
Definition: handDetect.cpp:200
void average(FrameGen *m)
calculate the final average color of the hand in hue lightness saturation space based on average skin...
Definition: handDetect.cpp:108
Class for drawing region of interest. The functions and variables of this class are used to draw regi...
Definition: roi.hpp:15
void init(FrameGen *m)
Function to take the initial video stream and specify the area of calibrartion squares.
Definition: handDetect.cpp:27
void printText(cv::Mat src, std::string text)
function to print text on the frame when needed
Definition: handDetect.cpp:43