subtract_colors Function

public elemental function subtract_colors(c1, c2) result(c)

Arguments

Type IntentOptional Attributes Name
type(rgb_color), intent(in) :: c1
type(rgb_color), intent(in) :: c2

Return Value type(rgb_color)


Called by

proc~~subtract_colors~~CalledByGraph proc~subtract_colors subtract_colors interface~operator(-) operator(-) interface~operator(-)->proc~subtract_colors

Source Code

  elemental function subtract_colors(c1,c2) result(c)
    type(rgb_color),intent(in) :: c1,c2
    type(rgb_color)            :: c
    c%r = c1%r - c2%r
    c%g = c1%g - c2%g
    c%b = c1%b - c2%b
  end function subtract_colors