lib/smalruby/color.rb
# Round rgb color 0 to 255
#
# @param [Integer] value RGB color
# @return [Integer] rounded RGB color
Round rgb color 0 to 255
Round rgb color 0 to 255
def round_rgb_color(value)
      if value > 255
        255
      elsif value < 0
        0
      else
        value
      end
    end
def round_rgb_color ( value ) if value > 255 255 elsif value < 0 0 else value end end
Round rgb color 0 to 255
Round rgb color 0 to 255
rounded RGB color
rounded RGB color
Integer
value
<not_specific>
<not_specific>
value RGB color
value RGB color