main lfr loop back to camera

This commit is contained in:
Tim Zeuner 2022-11-16 11:09:35 +01:00
parent 9dfc3dc883
commit e41f6b47d9

View File

@ -22,10 +22,9 @@ void LFR::loop()
namedWindow("Display window");
while(iAmLooping)
{
Mat image = input.readFile("C:\\Line-Following-Robot\\Test_data");
Mat processedImage = image;
processing.processImage(processedImage, this->thresholdBinary, this->gaussKernelSize);
std::vector<Vec4i> lines = processing.calculateLineSegments(processedImage);
Mat image = input.readWebcam();
processing.processImage(image, this->thresholdBinary, this->gaussKernelSize);
std::vector<Vec4i> lines = processing.calculateLineSegments(image);
for( size_t i = 0; i < lines.size(); i++ )
{
line( image, Point(lines[i][0], lines[i][1]),