Documentation ¶
Index ¶
- Variables
- type BGR
- type BGRImage
- func (p BGRImage) At(x, y int) color.Color
- func (p *BGRImage) BGRAt(x, y int) BGR
- func (p BGRImage) Bounds() image.Rectangle
- func (p BGRImage) ColorModel() color.Model
- func (p *BGRImage) FillFromBGRImage(bgrImage *RGBImage) error
- func (p *BGRImage) FillFromGrayImage(grayImage *image.Gray) error
- func (p *BGRImage) FillFromNRGBAImage(nrgbaImage *image.NRGBA) error
- func (p *BGRImage) FillFromRGBAImage(rgbaImage *image.RGBA) error
- func (p *BGRImage) FillFromRGBImage(rgbImage *RGBImage) error
- func (p *BGRImage) FillFromYCBCRImage(ycImage *image.YCbCr) error
- func (p BGRImage) Mode() Mode
- func (p *BGRImage) PixOffset(x, y int) int
- func (p *BGRImage) Set(x, y int, c color.Color)
- func (p *BGRImage) SetBGR(x, y int, c BGR)
- func (p *BGRImage) SubImage(r image.Rectangle) Image
- type Image
- type Mode
- type RGB
- type RGBImage
- func (p RGBImage) At(x, y int) color.Color
- func (p RGBImage) Bounds() image.Rectangle
- func (p RGBImage) ColorModel() color.Model
- func (p *RGBImage) FillFromBGRImage(bgrImage *BGRImage) error
- func (p *RGBImage) FillFromGrayImage(grayImage *image.Gray) error
- func (p *RGBImage) FillFromNRGBAImage(nrgbaImage *image.NRGBA) error
- func (p *RGBImage) FillFromRGBAImage(rgbaImage *image.RGBA) error
- func (p *RGBImage) FillFromRGBImage(rgbImage *RGBImage) error
- func (p *RGBImage) FillFromYCBCRImage(ycImage *image.YCbCr) error
- func (p RGBImage) Mode() Mode
- func (p *RGBImage) PixOffset(x, y int) int
- func (p *RGBImage) RGBAt(x, y int) RGB
- func (p *RGBImage) Set(x, y int, c color.Color)
- func (p *RGBImage) SetRGB(x, y int, c RGB)
- func (p *RGBImage) SubImage(r image.Rectangle) Image
Constants ¶
This section is empty.
Variables ¶
View Source
var (
BGRModel color.Model = color.ModelFunc(bgrModel)
)
View Source
var (
RGBModel color.Model = color.ModelFunc(rgbModel)
)
Functions ¶
This section is empty.
Types ¶
type BGR ¶
type BGR struct {
B, G, R uint8
}
BGR represents a traditional 32-bit alpha-premultiplied color, having 8 bits for each of red, green, blue.
type BGRImage ¶
type BGRImage struct { // Pix holds the image's pixels, in R, G, B order. The pixel at // (x, y) starts at Pix[(y-Rect.Min.Y)*Stride + (x-Rect.Min.X)*3]. Pix []uint8 // Stride is the Pix stride (in bytes) between vertically adjacent pixels. Stride int // Rect is the image's bounds. Rect image.Rectangle }
BGRImage is an in-memory image whose At method returns RGB values.
func NewBGRImage ¶
NewBGRImage returns a new BGRImage image with the given bounds.
func (BGRImage) ColorModel ¶
func (*BGRImage) FillFromBGRImage ¶
func (*BGRImage) FillFromGrayImage ¶
func (*BGRImage) FillFromNRGBAImage ¶
func (*BGRImage) FillFromRGBAImage ¶
func (*BGRImage) FillFromRGBImage ¶
func (*BGRImage) FillFromYCBCRImage ¶
type RGB ¶
type RGB struct {
R, G, B uint8
}
RGB represents a traditional 32-bit alpha-premultiplied color, having 8 bits for each of red, green, blue.
type RGBImage ¶
type RGBImage struct { // Pix holds the image's pixels, in R, G, B order. The pixel at // (x, y) starts at Pix[(y-Rect.Min.Y)*Stride + (x-Rect.Min.X)*3]. Pix []uint8 // Stride is the Pix stride (in bytes) between vertically adjacent pixels. Stride int // Rect is the image's bounds. Rect image.Rectangle }
RGBImage is an in-memory image whose At method returns RGB values.
func NewRGBImage ¶
NewRGBImage returns a new RGBImage image with the given bounds.
func (RGBImage) ColorModel ¶
func (*RGBImage) FillFromBGRImage ¶
func (*RGBImage) FillFromGrayImage ¶
func (*RGBImage) FillFromNRGBAImage ¶
func (*RGBImage) FillFromRGBAImage ¶
func (*RGBImage) FillFromRGBImage ¶
func (*RGBImage) FillFromYCBCRImage ¶
Click to show internal directories.
Click to hide internal directories.