img

package
v0.0.0-...-55c0a6c Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 27, 2021 License: GPL-3.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

View Source
const ALPHABIT_SHIFT = 0
View Source
const ALPHA_BIT_MASK = 0x000000FF
View Source
const BLUE_BIT_MASK = 0x0000FF00
View Source
const BLUE_BIT_SHIFT = 010
View Source
const GREEN_BIT_MASK = 0x00FF0000
View Source
const GREEN_BIT_SHIFT = 020
View Source
const RED_BIT_MASK = 0xFF000000
View Source
const RED_BIT_SHIFT = 030

Variables

This section is empty.

Functions

func ColorToUint

func ColorToUint(color *color.RGBA) uint32

func UintToColor

func UintToColor(num uint32) *color.RGBA

Types

type RgbImage

type RgbImage struct {
	Raw    []uint32
	Bounds *image.Rectangle
	// contains filtered or unexported fields
}

func NewImage

func NewImage(width int, height int) (*RgbImage, error)

func (*RgbImage) Fill

func (img *RgbImage) Fill(color *color.RGBA)

func (*RgbImage) Paint

func (img *RgbImage) Paint() *image.RGBA

func (*RgbImage) SetNoice

func (img *RgbImage) SetNoice(col *color.RGBA, distribution float64) error

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL