General tidy up

This commit is contained in:
Murat
2020-08-08 00:21:19 +02:00
parent 13205a9d11
commit dd2d5e4b40
62 changed files with 117 additions and 296 deletions

View File

@@ -13,7 +13,7 @@ BlackBorderDetector::BlackBorderDetector(double threshold)
// empty
}
uint8_t BlackBorderDetector::calculateThreshold(double threshold)
uint8_t BlackBorderDetector::calculateThreshold(double threshold) const
{
int rgbThreshold = int(std::ceil(threshold * 255));
if (rgbThreshold < 0)

View File

@@ -56,8 +56,7 @@ void BlackBorderProcessor::handleSettingsUpdate(const settings::type& type, cons
{
_oldThreshold = newThreshold;
if(_detector != nullptr)
delete _detector;
delete _detector;
_detector = new BlackBorderDetector(newThreshold);
}