Skip to content

Commit 6256866

Browse files
committed
Skip OkhsvTransform if it is the identity function
1 parent 6b5bc18 commit 6256866

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

libsrc/hyperion/MultiColorAdjustment.cpp

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -114,7 +114,10 @@ void MultiColorAdjustment::applyAdjustment(std::vector<ColorRgb>& ledColors)
114114
uint8_t oblue = color.blue;
115115
uint8_t B_RGB = 0, B_CMY = 0, B_W = 0;
116116

117-
adjustment->_okhsvTransform.transform(ored, ogreen, oblue);
117+
if (!adjustment->_okhsvTransform.isIdentity())
118+
{
119+
adjustment->_okhsvTransform.transform(ored, ogreen, oblue);
120+
}
118121
adjustment->_rgbTransform.transform(ored,ogreen,oblue);
119122
adjustment->_rgbTransform.getBrightnessComponents(B_RGB, B_CMY, B_W);
120123

0 commit comments

Comments
 (0)