Color.pm: fixed typo

git-svn-id: https://svn.fhem.de/fhem/trunk/fhem@20813 2b470e98-0d58-463d-a4d8-8e2adae1ed80
This commit is contained in:
justme-1968 2019-12-22 18:42:10 +00:00
parent 7737ba27eb
commit 027b313e71

View File

@ -130,7 +130,7 @@ rgb2hsv($$$) {
my( $r, $g, $b ) = @_;
my( $h, $s, $v );
main::Log3 undef, 1, "Color::rgb2hsv value our of range [$r,$g,$b]. should be in 0..1." if( $r > 1 || $g > 1 || $b > 1 );
main::Log3 undef, 1, "Color::rgb2hsv value out of range [$r,$g,$b]. should be in 0..1." if( $r > 1 || $g > 1 || $b > 1 );
$r /= 255.0 if( $r > 1 );
$g /= 255.0 if( $g > 1 );
$b /= 255.0 if( $b > 1 );
@ -164,7 +164,7 @@ sub
hsv2rgb($$$) {
my ( $h, $s, $v ) = @_;
main::Log3 undef, 1, "Color::hsv2rgb value our of range [$h,$s,$v]. should be in 0..1." if( $h > 1 || $s > 1 || $v > 1 );
main::Log3 undef, 1, "Color::hsv2rgb value out of range [$h,$s,$v]. should be in 0..1." if( $h > 1 || $s > 1 || $v > 1 );
$h /= 356.0 if( $h > 1 );
$s /= 100.0 if( $s > 1 );
$v /= 100.0 if( $v > 1 );