Palette is a palette of colors. Convert returns the palette color closest to c in Euclidean R,G,B space. Index returns the index of the palette color closest to c in Euclidean
R,G,B,A space.
Palette : Model
func image.NewPaletted(r image.Rectangle, p Palette) *image.Paletted
RGBA represents a traditional 32-bit alpha-premultiplied color, having 8
bits for each of red, green, blue and alpha.
An alpha-premultiplied color component C has been scaled by alpha (A), so
has valid values 0 <= C <= A.Auint8Buint8Guint8Ruint8( RGBA) RGBA() (r, g, b, a uint32)
RGBA : Color
func image.(*RGBA).RGBAAt(x, y int) RGBA
func image.(*RGBA).SetRGBA(x, y int, c RGBA)
YCbCr represents a fully opaque 24-bit Y'CbCr color, having 8 bits each for
one luma and two chroma components.
JPEG, VP8, the MPEG family and other codecs use this color model. Such
codecs often use the terms YUV and Y'CbCr interchangeably, but strictly
speaking, the term YUV applies only to analog video signals, and Y' (luma)
is Y (luminance) after applying gamma correction.
Conversion between RGB and Y'CbCr is lossy and there are multiple, slightly
different formulae for converting between the two. This package follows
the JFIF specification at https://www.w3.org/Graphics/JPEG/jfif3.pdf.Cbuint8Cruint8Yuint8( YCbCr) RGBA() (uint32, uint32, uint32, uint32)
YCbCr : Color
func image.(*YCbCr).YCbCrAt(x, y int) YCbCr
sqDiff returns the squared-difference of x and y, shifted by 2 so that
adding four of those won't overflow a uint32.
x and y are both assumed to be in the range [0, 0xffff].
Package-Level Variables (total 15, all are exported)
Models for the standard color types.
Models for the standard color types.
Standard colors.
CMYKModel is the Model for CMYK colors.
Models for the standard color types.
Models for the standard color types.
Models for the standard color types.
Models for the standard color types.
NYCbCrAModel is the Model for non-alpha-premultiplied Y'CbCr-with-alpha
colors.
Standard colors.
Models for the standard color types.
Models for the standard color types.
Standard colors.
Standard colors.
YCbCrModel is the Model for Y'CbCr colors.
The pages are generated with Goldsv0.6.7. (GOOS=linux GOARCH=amd64)
Golds is a Go 101 project developed by Tapir Liu.
PR and bug reports are welcome and can be submitted to the issue list.
Please follow @Go100and1 (reachable from the left QR code) to get the latest news of Golds.