diff --git a/app/Makefile b/app/Makefile index 9ec5ee327e611d3656e0ef75dbb084e0b6b6a392..cd2d75d8a17a31a2bcee1f728915e003addd762d 100644 --- a/app/Makefile +++ b/app/Makefile @@ -1,14 +1,16 @@ LIBPATH=../../build SUBDIR=SandboxSetup +.PHONY: genMakefile genExe + all: -$(MAKE) genMakefile -$(MAKE) genExe -genMakefile: +genMakefile: $(SUBDIR)/$(SUBDIR).pro $(shell cd $(SUBDIR) && qmake *.pro) -genExe: +genExe: $(SUBDIR)/Makefile $(shell cd $(SUBDIR) && export LD_LIBRARY_PATH=$(pwd)/$(LIBPATH) && make) clean: diff --git a/app/SandboxSetup/SandboxSetup.pro b/app/SandboxSetup/SandboxSetup.pro index 7e0806f06026c0433c4a4824259fbf41d41475ed..a699d0a5139338ac38f90bd0b949d1f6af196dbf 100644 --- a/app/SandboxSetup/SandboxSetup.pro +++ b/app/SandboxSetup/SandboxSetup.pro @@ -69,4 +69,4 @@ INCLUDEPATH += ../../inc LIBS += -L"../../build" -lsandbox -lrealsense2 -lyaml-cpp LIBS += $(shell pkg-config --libs --cflags opencv) -#CONFIG += -fsanitize=address -fsanitize=leak -fsanitize=undefined +#QMAKE_CXXFLAGS += -fsanitize=address -fsanitize=leak -fsanitize=undefined diff --git a/app/SandboxSetup/beamerlocationgui.cpp b/app/SandboxSetup/beamerlocationgui.cpp index 378e6cc933e8017d5a17ddbe1bbb8fa3bdc1aea2..51592d686cd30bcad43de3d0919d3ed0291d672d 100644 --- a/app/SandboxSetup/beamerlocationgui.cpp +++ b/app/SandboxSetup/beamerlocationgui.cpp @@ -96,15 +96,15 @@ void BeamerLocationGui::routineFrame(){ rgb = camera->getColorFrame(); // Look for the circle target - double minDist = rgb.cols / (double)profil->getMinDistance(); - double minRadius = (profil->getMinRadius()>0) ? rgb.cols/(double)profil->getMinRadius() : 0; - double maxRadius = (profil->getMaxRadius()>0) ? rgb.cols/(double)profil->getMaxRadius() : 0; + double minDist = rgb.cols*(double)profil->getMinDistance()/100; + double minRadius = (profil->getMinRadius()>0) ? rgb.cols*(double)profil->getMinRadius()/100 : 0; + double maxRadius = (profil->getMaxRadius()>0) ? rgb.cols*(double)profil->getMaxRadius()/100 : 0; circle = beamer->findCircles( rgb, profil->getContrast(), profil->getBrightness(), minDist, - profil->getCannyEdgeThreshold(), - profil->getHoughAccThreshold(), + (int)profil->getCannyEdgeThreshold(), + (int)profil->getHoughAccThreshold(), minRadius, maxRadius ); diff --git a/app/SandboxSetup/camerafocus.cpp b/app/SandboxSetup/camerafocus.cpp index 724416228a7b08e18ee9d95d8f1bfc518f1244a3..c5e45a3ea47b5b132f4ef98a85d5ccb69338d6f5 100644 --- a/app/SandboxSetup/camerafocus.cpp +++ b/app/SandboxSetup/camerafocus.cpp @@ -20,11 +20,9 @@ CameraFocus::CameraFocus(SandboxSetup *sandbox, MonitorGui *_mg, QWidget *parent setup = sandbox; mg = _mg; myThread = new RefreshFrame(this); - //connect(myThread, &RefreshFrame::finished, myThread, &QObject::deleteLater); blackScreen = new QtFullScreen(mg->getResolution(), true, this); - setup->loadFrameProcessProfil(); - initCameraParams(); + frameTimer = new QTimer(this); connect(frameTimer, &QTimer::timeout, this, &CameraFocus::startCapture); } @@ -41,13 +39,11 @@ CameraFocus::~CameraFocus() void CameraFocus::showEvent(QShowEvent *event){ - setup->getCamera()->capture(); - cv::Mat rgb = setup->getCamera()->getColorFrame(); - // we assume the matrixe for the accumulators has a ratio of 1 with the captured frame - ui->sbxAccThreshold->setMaximum( rgb.cols*rgb.rows ); - QWidget::showEvent(event); - cv::Mat black = cv::Mat(1, 1, CV_8UC3, cv::Scalar(0, 0, 0)); + initCameraParams(); + cv::Mat black = cv::Mat(setup->getBeamer()->getHeight(), setup->getBeamer()->getWidth(), CV_8UC3, cv::Scalar(0, 0, 0)); + cv::line(black, cv::Point(black.cols/2, 0), cv::Point(black.cols/2, black.rows-1), cv::Scalar(255, 0, 0), 4); + cv::line(black, cv::Point(0, black.rows/2), cv::Point(black.cols-1, black.rows/2), cv::Scalar(255, 0, 0), 4); blackScreen->editGeometry(mg->getResolution()); blackScreen->imShow(black); frameTimer->start(100); @@ -87,15 +83,15 @@ void CameraFocus::refreshFrame(){ if(profil->getCannyEdgeThreshold() > 0 && profil->getHoughAccThreshold() > 0){ - double minDist = rgb.cols / (double)profil->getMinDistance(); - double minRadius = (profil->getMinRadius()>0) ? rgb.cols/(double)profil->getMinRadius() : 0; - double maxRadius = (profil->getMaxRadius()>0) ? rgb.cols/(double)profil->getMaxRadius() : 0; + double minDist = rgb.cols*(double)profil->getMinDistance()/100; + double minRadius = (profil->getMinRadius()>0) ? rgb.cols*(double)profil->getMinRadius()/100 : 0; + double maxRadius = (profil->getMaxRadius()>0) ? rgb.cols*(double)profil->getMaxRadius()/100 : 0; crc = setup->getBeamer()->findCircles( rgb, profil->getContrast(), profil->getBrightness(), minDist, - profil->getCannyEdgeThreshold(), - profil->getHoughAccThreshold(), + (int)profil->getCannyEdgeThreshold(), + (int)profil->getHoughAccThreshold(), minRadius, maxRadius ); } @@ -133,24 +129,33 @@ void CameraFocus::initCameraParams(){ void CameraFocus::loadProfil(FrameProcessProfil *profilLoaded, FrameProcessProfil *profilSaved){ + // save profil profilSaved->setContrast(profilLoaded->getContrast()); profilSaved->setBrightness(profilLoaded->getBrightness()); profilSaved->setMinDistance(profilLoaded->getMinDistance()); profilSaved->setCannyEdgeThreshold(profilLoaded->getCannyEdgeThreshold()); profilSaved->setHoughAccThreshold(profilLoaded->getHoughAccThreshold()); + bool isUnrestricted = profilLoaded->getContrast() > 5.00 || + profilLoaded->getBrightness() < -1275 || + profilLoaded->getHoughAccThreshold() > 300; + + ui->ckbxAdvanced->setChecked(isUnrestricted); + switchMode(!isUnrestricted); - ui->sbxContrast->setValue(profilLoaded->getContrast()); - ui->sbxBrightness->setValue(profilLoaded->getBrightness()); - ui->sbxMinDistance->setValue(profilLoaded->getMinDistance()); - ui->sbxCannyThreshold->setValue(profilLoaded->getCannyEdgeThreshold()); - ui->sbxAccThreshold->setValue(profilLoaded->getHoughAccThreshold()); + // set values + ui->sbxContrast->setValue((double)profilLoaded->getContrast()); + ui->sbxBrightness->setValue((int)profilLoaded->getBrightness()); + ui->sbxMinDistance->setValue((int)profilLoaded->getMinDistance()); + ui->sbxCannyThreshold->setValue((int)profilLoaded->getCannyEdgeThreshold()); + ui->sbxAccThreshold->setValue((int)profilLoaded->getHoughAccThreshold()); + // check for the known target's size if(profilLoaded->getMinRadius() > 0 && profilLoaded->getMaxRadius() > 0){ - profilSaved->setMinRadius(profilLoaded->getMinRadius()); - profilSaved->setMaxRadius(profilLoaded->getMaxRadius()); - ui->sbxMinRadius->setValue(profilLoaded->getMinRadius()); - ui->sbxMaxRadius->setValue(profilLoaded->getMaxRadius()); + profilSaved->setMinRadius((int)profilLoaded->getMinRadius()); + profilSaved->setMaxRadius((int)profilLoaded->getMaxRadius()); + ui->sbxMinRadius->setValue((int)profilLoaded->getMinRadius()); + ui->sbxMaxRadius->setValue((int)profilLoaded->getMaxRadius()); ui->ckbxTargetSize->setChecked(true); ui->ckbxTargetSize->clicked(true); }else{ @@ -265,3 +270,38 @@ void CameraFocus::on_ckbxTargetSize_clicked(bool checked) setup->getBeamer()->getProfil()->setMinRadius(min); setup->getBeamer()->getProfil()->setMaxRadius(max); } + + +void CameraFocus::switchMode(bool isRestricted){ + + if(isRestricted){ + ui->sldContrast->setMaximum(500); + ui->sbxContrast->setMaximum(5.00); + + ui->sldBrightness->setMinimum(-1275); + ui->sbxBrightness->setMinimum(-1275); + + ui->sldAccThreshold->setMaximum(300); + ui->sbxAccThreshold->setMaximum(300); + + }else{ + // we assume the matrixe for the accumulators has a ratio of 1 with the captured frame + setup->getCamera()->capture(); + cv::Mat rgb = setup->getCamera()->getColorFrame(); + int maxHough = rgb.cols*rgb.rows; + + ui->sldContrast->setMaximum(25500); + ui->sbxContrast->setMaximum(255.00); + + ui->sldBrightness->setMinimum(-65025); + ui->sbxBrightness->setMinimum(-65025); + + ui->sldAccThreshold->setMaximum(maxHough); + ui->sbxAccThreshold->setMaximum(maxHough); + } +} + +void CameraFocus::on_ckbxAdvanced_clicked(bool checked) +{ + switchMode(!checked); +} diff --git a/app/SandboxSetup/camerafocus.h b/app/SandboxSetup/camerafocus.h index 2df9e48ca3e7c239f416936be9d24917fca8edb5..d756c7f30dd06d53922a983b614df2732561936b 100644 --- a/app/SandboxSetup/camerafocus.h +++ b/app/SandboxSetup/camerafocus.h @@ -60,6 +60,8 @@ private slots: void on_ckbxTargetSize_clicked(bool checked); + void on_ckbxAdvanced_clicked(bool checked); + protected: void showEvent(QShowEvent *event); void closeEvent(QCloseEvent *event); @@ -87,6 +89,7 @@ private: void startCapture(); void loadProfil(FrameProcessProfil *profilLoaded, FrameProcessProfil *profilSaved); void initCameraParams(); + void switchMode(bool isRestricted); }; diff --git a/app/SandboxSetup/camerafocus.ui b/app/SandboxSetup/camerafocus.ui index f95635618b8c9639b1ff699c254a9a4684d6b5d1..319f8f520c7f2a7e1ce698d5051bf8b43c9b3551 100644 --- a/app/SandboxSetup/camerafocus.ui +++ b/app/SandboxSetup/camerafocus.ui @@ -39,7 +39,7 @@ <property name="geometry"> <rect> <x>680</x> - <y>280</y> + <y>270</y> <width>89</width> <height>25</height> </rect> @@ -100,29 +100,29 @@ <property name="geometry"> <rect> <x>60</x> - <y>320</y> + <y>310</y> <width>671</width> - <height>301</height> + <height>311</height> </rect> </property> <layout class="QGridLayout" name="glytParams"> - <item row="2" column="1"> + <item row="3" column="1"> <widget class="QSlider" name="sldMinDistance"> <property name="minimum"> <number>1</number> </property> <property name="maximum"> - <number>20</number> + <number>100</number> </property> <property name="value"> - <number>8</number> + <number>15</number> </property> <property name="orientation"> <enum>Qt::Horizontal</enum> </property> </widget> </item> - <item row="1" column="2"> + <item row="2" column="2"> <widget class="QSpinBox" name="sbxBrightness"> <property name="minimum"> <number>-65025</number> @@ -135,14 +135,14 @@ </property> </widget> </item> - <item row="4" column="0"> + <item row="5" column="0"> <widget class="QLabel" name="label_5"> <property name="text"> <string>Hough accumulator threshold</string> </property> </widget> </item> - <item row="6" column="2"> + <item row="7" column="2"> <widget class="QSpinBox" name="sbxMinRadius"> <property name="enabled"> <bool>false</bool> @@ -151,21 +151,21 @@ <number>1</number> </property> <property name="maximum"> - <number>20</number> + <number>100</number> </property> <property name="value"> <number>10</number> </property> </widget> </item> - <item row="1" column="0"> + <item row="2" column="0"> <widget class="QLabel" name="label_2"> <property name="text"> <string>Brightness</string> </property> </widget> </item> - <item row="7" column="2"> + <item row="8" column="2"> <widget class="QSpinBox" name="sbxMaxRadius"> <property name="enabled"> <bool>false</bool> @@ -174,38 +174,38 @@ <number>1</number> </property> <property name="maximum"> - <number>20</number> + <number>100</number> </property> <property name="value"> - <number>2</number> + <number>50</number> </property> </widget> </item> - <item row="3" column="0"> + <item row="4" column="0"> <widget class="QLabel" name="label_4"> <property name="text"> <string>Upper Canny threshold</string> </property> </widget> </item> - <item row="6" column="0"> + <item row="7" column="0"> <widget class="QLabel" name="lblMinRadius"> <property name="enabled"> <bool>false</bool> </property> <property name="text"> - <string>Minimum circle radius (divisor from the camera's width)</string> + <string>Minimum circle radius (% of the camera's width)</string> </property> </widget> </item> - <item row="0" column="0"> + <item row="1" column="0"> <widget class="QLabel" name="label"> <property name="text"> <string>Contrast</string> </property> </widget> </item> - <item row="6" column="1"> + <item row="7" column="1"> <widget class="QSlider" name="sldMinRadius"> <property name="enabled"> <bool>false</bool> @@ -214,7 +214,7 @@ <number>1</number> </property> <property name="maximum"> - <number>20</number> + <number>100</number> </property> <property name="value"> <number>10</number> @@ -224,10 +224,10 @@ </property> </widget> </item> - <item row="2" column="0"> + <item row="3" column="0"> <widget class="QLabel" name="label_3"> <property name="text"> - <string>Minimum distance between circles's center (divisor from the camera's width)</string> + <string>Minimum distance between circles's center (% of the camera's width)</string> </property> <property name="textFormat"> <enum>Qt::AutoText</enum> @@ -237,7 +237,7 @@ </property> </widget> </item> - <item row="3" column="2"> + <item row="4" column="2"> <widget class="QSpinBox" name="sbxCannyThreshold"> <property name="maximum"> <number>255</number> @@ -247,13 +247,13 @@ </property> </widget> </item> - <item row="0" column="1"> + <item row="1" column="1"> <widget class="QSlider" name="sldContrast"> <property name="minimum"> <number>0</number> </property> <property name="maximum"> - <number>300</number> + <number>500</number> </property> <property name="value"> <number>100</number> @@ -263,30 +263,30 @@ </property> </widget> </item> - <item row="2" column="2"> + <item row="3" column="2"> <widget class="QSpinBox" name="sbxMinDistance"> <property name="minimum"> <number>1</number> </property> <property name="maximum"> - <number>20</number> + <number>100</number> </property> <property name="value"> - <number>8</number> + <number>15</number> </property> </widget> </item> - <item row="7" column="0"> + <item row="8" column="0"> <widget class="QLabel" name="lblMaxRadius"> <property name="enabled"> <bool>false</bool> </property> <property name="text"> - <string>Maximum circle radius (divisor from the camera's width)</string> + <string>Maximum circle radius (% of the camera's width)</string> </property> </widget> </item> - <item row="0" column="2"> + <item row="1" column="2"> <widget class="QDoubleSpinBox" name="sbxContrast"> <property name="minimum"> <double>0.010000000000000</double> @@ -302,7 +302,7 @@ </property> </widget> </item> - <item row="3" column="1"> + <item row="4" column="1"> <widget class="QSlider" name="sldCannyThreshold"> <property name="maximum"> <number>255</number> @@ -315,7 +315,7 @@ </property> </widget> </item> - <item row="4" column="2"> + <item row="5" column="2"> <widget class="QSpinBox" name="sbxAccThreshold"> <property name="maximum"> <number>300</number> @@ -325,7 +325,7 @@ </property> </widget> </item> - <item row="4" column="1"> + <item row="5" column="1"> <widget class="QSlider" name="sldAccThreshold"> <property name="maximum"> <number>300</number> @@ -341,10 +341,10 @@ </property> </widget> </item> - <item row="1" column="1"> + <item row="2" column="1"> <widget class="QSlider" name="sldBrightness"> <property name="minimum"> - <number>-765</number> + <number>-1275</number> </property> <property name="maximum"> <number>255</number> @@ -354,7 +354,7 @@ </property> </widget> </item> - <item row="7" column="1"> + <item row="8" column="1"> <widget class="QSlider" name="sldMaxRadius"> <property name="enabled"> <bool>false</bool> @@ -363,23 +363,30 @@ <number>1</number> </property> <property name="maximum"> - <number>20</number> + <number>100</number> </property> <property name="value"> - <number>2</number> + <number>50</number> </property> <property name="orientation"> <enum>Qt::Horizontal</enum> </property> </widget> </item> - <item row="5" column="0"> + <item row="6" column="0"> <widget class="QCheckBox" name="ckbxTargetSize"> <property name="text"> <string>Target's size known</string> </property> </widget> </item> + <item row="0" column="0"> + <widget class="QCheckBox" name="ckbxAdvanced"> + <property name="text"> + <string>Unrestricted</string> + </property> + </widget> + </item> </layout> </widget> </widget> diff --git a/app/SandboxSetup/croppingmask.ui b/app/SandboxSetup/croppingmask.ui index 030968bb000f4f6b7258cde5a1b828b4d2079135..2f4ec8e1ce233ee9dd1b8e644f7e8b540551aad5 100644 --- a/app/SandboxSetup/croppingmask.ui +++ b/app/SandboxSetup/croppingmask.ui @@ -63,7 +63,7 @@ <x>40</x> <y>370</y> <width>561</width> - <height>91</height> + <height>101</height> </rect> </property> <property name="readOnly"> @@ -74,7 +74,7 @@ <html><head><meta name="qrichtext" content="1" /><style type="text/css"> p, li { white-space: pre-wrap; } </style></head><body style=" font-family:'Ubuntu'; font-size:11pt; font-weight:400; font-style:normal;"> -<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;">At this point, the beamer and the blue screen should be set correctly. So now we want to determine the edges of the blue screen. To do that, be sure to have a flat surface to have a clean blue rectangle projected. (ie. you can use a cardboard as support). Then drag the corners to match the bluescreen's edges.</p></body></html></string> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;">At this point, the beamer and the blue screen should be set correctly. So now we want to determine the edges of the blue screen. To do that, be sure to have a flat surface to have a clean blue rectangle projected. (ie. you can use a cardboard as support). Then drag the corners of the green rectangle to match the bluescreen's corners.</p></body></html></string> </property> </widget> </widget> diff --git a/inc/beamer.h b/inc/beamer.h index 203743adcad8cfb24336dd2466164ebd9df2c6aa..08d9f6fec7e3a9ee26a43236ce7d6e8940237193 100644 --- a/inc/beamer.h +++ b/inc/beamer.h @@ -6,18 +6,17 @@ class FrameProcessProfil{ private: - double contrast; // [0, 255] - int brightness; // [-255, 255] - // radius of the circle based on the width of the frame, where : - // radius = frame.width / ratioRadius - uint minDistance; // [1, n] + // Profil to process on gray scaled images + double contrast; // ]0, 255] + int brightness; // [-2^16, 255] + uint minDistance; // [1, 100] % of the frame's width uint cannyEdgeThreshold; // [0, 255] the strongest the contrast in the image is, the higher this param should be - uint houghAccThreshold; // [0, n] should be set way lower than upperMin if cicles have weak contrasts at their edges - uint minRadius; - uint maxRadius; + uint houghAccThreshold; // [0, n] where n = width*height of the frame + uint minRadius; // [1, 100] % of the frame's width + uint maxRadius; // [1, 100] % of the frame's width public: - FrameProcessProfil(double c=1.0, int b=0, int d=8, uint cannyThreshold=100, uint accThreshold=50, uint minR=10, uint maxR=2){ + FrameProcessProfil(double c=1.0, int b=0, int d=15, uint cannyThreshold=100, uint accThreshold=50, uint minR=10, uint maxR=50){ contrast = c; brightness = b; minDistance = d; @@ -41,11 +40,20 @@ class FrameProcessProfil{ uint getMaxRadius(){ return maxRadius; }; void setMaxRadius(uint max){ maxRadius = max; }; + void print(){ + std::cout << contrast << std::endl; + std::cout << brightness << std::endl; + std::cout << minDistance << std::endl; + std::cout << cannyEdgeThreshold << std::endl; + std::cout << houghAccThreshold << std::endl; + std::cout << minRadius << std::endl; + std::cout << maxRadius << std::endl; + } + }; class Beamer{ private: - const char *BEAMER_POSITION_FILE = "./beamer.dat"; cv::Point3f beamerPosition; cv::Size resolution = cv::Size(256,144); FrameProcessProfil profil = FrameProcessProfil(); diff --git a/src/components/beamer.cpp b/src/components/beamer.cpp index 03716aa38f474bd68b78bb72dff2f5174ccafb52..055151d03c841b1d561a6e6ef46ce3d63663ded2 100644 --- a/src/components/beamer.cpp +++ b/src/components/beamer.cpp @@ -246,8 +246,6 @@ std::vector<cv::Point3i> Beamer::findCircles(cv::Mat &rgb, double contrast, int // min_radius : Min radius of the circles drew on the accumulator // max_radius : Max radius of the circles drew on the accumulator cv::HoughCircles(src_gray, circles, CV_HOUGH_GRADIENT, 1, centersMinDist, (double)cannyEdgeThreshold, (double)houghAccThreshold, minRadius, maxRadius); - - //doit tester si le cercle est bon (rayon); std::vector<cv::Point3i> result; if (!circles.empty()) diff --git a/src/components/camera.cpp b/src/components/camera.cpp index 8ba7e983219c93ab2a74d02fd843660bf1d61cdc..e38276b7c46fcbb291807a294e0a51ccfc7af5d8 100644 --- a/src/components/camera.cpp +++ b/src/components/camera.cpp @@ -14,14 +14,20 @@ Camera::Camera() { void Camera::start(){ + // check for a device availible + if(!cfg.can_resolve(pipe)){ + std::cout << "Error: No device found" << std::endl; + exit(0); + } + std::remove("./camera.logs"); rs2::log_to_file(RS2_LOG_SEVERITY_DEBUG, "./camera.logs"); - //rs2::log_to_console(RS2_LOG_SEVERITY_DEBUG);//RS2_LOG_SEVERITY_ERROR); + spatFilter.set_option(RS2_OPTION_HOLES_FILL, 5); - //cfg.enable_device_from_file("../input/flux/flux5.bag"); profile = pipe.start(cfg); auto sensor = profile.get_device().first<rs2::depth_sensor>(); + // TODO: At the moment the SDK does not offer a closed enum for D400 visual presets // We do this to reduce the number of black pixels // The hardware can perform hole-filling much better and much more power efficient then our software diff --git a/src/tools/sandboxConfig.cpp b/src/tools/sandboxConfig.cpp index 1d85fe5d19e71c98fe2b0af57a2b5127385ea461..bfa736caef0a34541f9119f2e4210926c1a1bb22 100644 --- a/src/tools/sandboxConfig.cpp +++ b/src/tools/sandboxConfig.cpp @@ -301,14 +301,6 @@ int SandboxConfig::loadFrameProcessProfil(char *path, FrameProcessProfil *profil profil->setMinRadius(config[PROCESSPROFIL]["minRadius"].as<uint>()); profil->setMaxRadius(config[PROCESSPROFIL]["maxRadius"].as<uint>()); -/* - std::cout << config[PROCESSPROFIL]["contrast"].as<double>(); - std::cout << config[PROCESSPROFIL]["brightness"].as<int>(); - std::cout << config[PROCESSPROFIL]["radiusRatio"].as<uint>(); - std::cout << config[PROCESSPROFIL]["contrast"].as<double>(); - std::cout << config[PROCESSPROFIL]["contrast"].as<double>(); -*/ - return 0; }