[EDIT] files accordingly to style guide

This commit is contained in:
Sem van der Hoeven
2021-06-18 10:31:00 +02:00
parent 344745d9cf
commit ce0a1f3da7
15 changed files with 51 additions and 37 deletions

View File

@@ -1,4 +1,4 @@
#include "BackgroundRemover.h"
#include "background_remover.h"
/*
Author: Pierfrancesco Soffritti https://github.com/PierfrancescoSoffritti

View File

@@ -1,4 +1,4 @@
#include "FingerCount.h"
#include "finger_count.h"
#include "opencv2/imgproc.hpp"
#include "opencv2/highgui.hpp"

View File

@@ -1,5 +1,5 @@
#include "HandDetectRegion.h"
#include "hand_detect_region.h"
#define TIME_DURATION 1.0f
namespace computervision
{
@@ -83,7 +83,14 @@ namespace computervision
std::string calibration_text = (!background_calibrated ? "calibrating background in " : (!skin_calibrated ? "calibrating skin in " : ""));
calibration_text += std::to_string(seconds_left);
if (!background_calibrated || !skin_calibrated)
{
cv::rectangle(camera_frame, cv::Rect(0, camera_frame.rows - 130, 600, 60), cv::Scalar(0, 0, 0), -1);
cv:putText(camera_frame, calibration_text, cv::Point(5, 400), cv::FONT_HERSHEY_COMPLEX, 1.0, cv::Scalar(255, 0, 255), 2);
}
if (background_calibrated && !skin_calibrated)
{
cv::putText(camera_frame, "put your hand in the left square", cv::Point(5, camera_frame.rows - 105), cv::FONT_HERSHEY_COMPLEX, 1.0, cv::Scalar(255, 0, 255), 2);
}
}

View File

@@ -6,9 +6,9 @@
#include "async/StaticCameraInstance.h"
#include "calibration/HandCalibrator.h"
#include "BackgroundRemover.h"
#include "SkinDetector.h"
#include "FingerCount.h"
#include "background_remover.h"
#include "skin_detector.h"
#include "finger_count.h"
namespace computervision
{
class HandDetectRegion

View File

@@ -4,10 +4,10 @@
#include <opencv2/video.hpp>
#include <GLFW/glfw3.h>
#include "ObjectDetection.h"
#include "BackgroundRemover.h"
#include "SkinDetector.h"
#include "FingerCount.h"
#include "object_detection.h"
#include "background_remover.h"
#include "skin_detector.h"
#include "finger_count.h"
#include "async/StaticCameraInstance.h"
#include "calibration/HandCalibrator.h"
@@ -116,8 +116,15 @@ namespace computervision
std::string calibration_text = (!background_calibrated ? "calibrating background in " : (!skin_calibrated ? "calibrating skin in " : ""));
calibration_text += std::to_string(seconds_left);
if (!background_calibrated || !skin_calibrated)
cv:putText(camera_frame, calibration_text, cv::Point(5, 400), cv::FONT_HERSHEY_COMPLEX, 1.0, cv::Scalar(255, 0, 255), 2);
{
cv::rectangle(camera_frame, cv::Rect(0, camera_frame.rows - 120, 500, 50), cv::Scalar(0, 0, 0), -1);
cv::putText(camera_frame, calibration_text, cv::Point(5, camera_frame.rows-80), cv::FONT_HERSHEY_COMPLEX, 1.0, cv::Scalar(255, 0, 255), 2);
}
if (background_calibrated && !skin_calibrated)
{
cv::putText(camera_frame, "put your hand in the square", cv::Point(5, camera_frame.rows - 100), cv::FONT_HERSHEY_COMPLEX, 1.0, cv::Scalar(255, 0, 255), 2);
}
imshow("camera", camera_frame);
/*imshow("output", frame_out);

View File

@@ -1,4 +1,4 @@
#include "SkinDetector.h"
#include "skin_detector.h"
#include <iostream>
/*