pub fn color_space<T>(
input: &Array<T>,
tospace: ColorSpace,
fromspace: ColorSpace
) -> Array<T> where
T: HasAfEnum + RealNumber,
Color space conversion
Following are the supported conversions
RGB (Red, Green, Blue) is the most common format used in computer imaging. RGB stores individual values for red, green and blue, and hence the 3 values per pixel. A combination of these three values produces the gamut of unique colors.
HSV (Hue, Saturation, Value), also known as HSB (hue, saturation, brightness), is often used by artists because it is more natural to think about a color in terms of hue and saturation than in terms of additive or subtractive color components (as in RGB). HSV is a transformation of RGB colorspace; its components and colorimetry are relative to the RGB colorspace from which it was derived. Like RGB, HSV also uses 3 values per pixel.
GRAY is a single channel color space where pixel value ranges from 0 to 1. Zero represents black, one represent white and any value between zero & one is a gray value
input
is the input imagetospace
is the target color space. Takes values of ColorSpacefromspace
is the source image color space. Takes values of ColorSpaceAn Array with input image values in target color space
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4