Just like grDevices::convertColor, but with HSV as an option.
col2col(
pixel_matrix,
from = c("sRGB", "Lab", "Luv", "HSV"),
to = c("sRGB", "Lab", "Luv", "HSV"),
ref_white = "D65"
)
A pixel matrix in the specified to
color space.
A matrix of pixel colors, rows are pixels and columns are channels.
Color space to convert from.
Color space to convert to.
Reference white.
As my mother used to say: good enough for government work.