mirror of
https://github.com/kerberos-io/openalpr-base.git
synced 2025-10-06 07:06:54 +08:00
Added a pause_on_frame debug variable (useful for debugging video)
This commit is contained in:
@@ -46,6 +46,7 @@ color_filter = 0
|
|||||||
ocr = 0
|
ocr = 0
|
||||||
postprocess = 0
|
postprocess = 0
|
||||||
show_images = 0
|
show_images = 0
|
||||||
|
pause_on_frame = 0
|
||||||
|
|
||||||
;;; Country Specific variables ;;;;
|
;;; Country Specific variables ;;;;
|
||||||
|
|
||||||
|
@@ -136,10 +136,14 @@ std::vector<AlprResult> AlprImpl::recognize(cv::Mat img)
|
|||||||
|
|
||||||
|
|
||||||
displayImage(config, "Main Image", img);
|
displayImage(config, "Main Image", img);
|
||||||
// Pause indefinitely until they press a key
|
|
||||||
cv::waitKey(1);
|
cv::waitKey(1);
|
||||||
//while ((char) cv::waitKey(50) == -1)
|
|
||||||
// {}
|
if (config->debugPauseOnFrame)
|
||||||
|
{
|
||||||
|
// Pause indefinitely until they press a key
|
||||||
|
while ((char) cv::waitKey(50) == -1)
|
||||||
|
{}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@@ -135,6 +135,7 @@ void Config::loadValues(string country)
|
|||||||
debugOcr = getBoolean("debug", "ocr", false);
|
debugOcr = getBoolean("debug", "ocr", false);
|
||||||
debugPostProcess = getBoolean("debug", "postprocess", false);
|
debugPostProcess = getBoolean("debug", "postprocess", false);
|
||||||
debugShowImages = getBoolean("debug", "show_images", false);
|
debugShowImages = getBoolean("debug", "show_images", false);
|
||||||
|
debugPauseOnFrame = getBoolean("debug", "pause_on_frame", false);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@@ -104,6 +104,7 @@ class Config
|
|||||||
bool debugOcr;
|
bool debugOcr;
|
||||||
bool debugPostProcess;
|
bool debugPostProcess;
|
||||||
bool debugShowImages;
|
bool debugShowImages;
|
||||||
|
bool debugPauseOnFrame;
|
||||||
|
|
||||||
void debugOff();
|
void debugOff();
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user