mirror of
https://github.com/hyperion-project/hyperion.ng.git
synced 2023-10-10 13:36:59 +02:00
Disable the blackborder detector for effects
Former-commit-id: 2d4660f48c17977aabff52b7cbbc8d832b216f00
This commit is contained in:
parent
8d75a57f18
commit
d5597d55a7
@ -37,6 +37,9 @@ public:
|
||||
///
|
||||
void setSize(const unsigned width, const unsigned height);
|
||||
|
||||
/// Enable or disable the black border detector
|
||||
void enableBalckBorderDetector(bool enable);
|
||||
|
||||
///
|
||||
/// Processes the image to a list of led colors. This will update the size of the buffer-image
|
||||
/// if required and call the image-to-leds mapping to determine the mean color per led.
|
||||
@ -142,7 +145,7 @@ private:
|
||||
const LedString _ledString;
|
||||
|
||||
/// Flag the enables(true)/disabled(false) blackborder detector
|
||||
const bool _enableBlackBorderRemoval;
|
||||
bool _enableBlackBorderRemoval;
|
||||
|
||||
/// The processor for black border detection
|
||||
hyperion::BlackBorderProcessor * _borderProcessor;
|
||||
|
@ -64,6 +64,9 @@ Effect::Effect(PyThreadState * mainThreadState, int priority, int timeout, const
|
||||
{
|
||||
_colors.resize(_imageProcessor->getLedCount(), ColorRgb::BLACK);
|
||||
|
||||
// disable the black border detector for effects
|
||||
_imageProcessor->enableBalckBorderDetector(false);
|
||||
|
||||
// connect the finished signal
|
||||
connect(this, SIGNAL(finished()), this, SLOT(effectFinished()));
|
||||
}
|
||||
|
@ -43,6 +43,11 @@ void ImageProcessor::setSize(const unsigned width, const unsigned height)
|
||||
_imageToLeds = new ImageToLedsMap(width, height, 0, 0, _ledString.leds());
|
||||
}
|
||||
|
||||
void ImageProcessor::enableBalckBorderDetector(bool enable)
|
||||
{
|
||||
_enableBlackBorderRemoval = enable;
|
||||
}
|
||||
|
||||
bool ImageProcessor::getScanParameters(size_t led, double &hscanBegin, double &hscanEnd, double &vscanBegin, double &vscanEnd) const
|
||||
{
|
||||
if (led < _ledString.leds().size())
|
||||
|
Loading…
Reference in New Issue
Block a user