bitmap

package
v2.0.30 Latest Latest
Warning

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

Go to latest
Published: Apr 27, 2020 License: BSD-2-Clause Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Bitmap

type Bitmap interface {
	// dispmanx properties
	DXSize() rpi.DXSize
	DXRect() rpi.DXRect
	DXHandle() rpi.DXResource

	// Return image type
	Type() gopi.SurfaceFlags

	// Return bounds
	Origin() gopi.Point
	Size() gopi.Size

	// Return the bitmap as bytes
	// with bytes per row
	Bytes() ([]byte, uint32)

	// ClearToColor clears the screen to a single color
	ClearToColor(color.Color)

	// Paint a pixel
	Pixel(color.Color, gopi.Point)

	// PaintCircle paints an outlined circle with origin and radius
	CircleOutline(color.Color, gopi.Point, float32)

	// PaintLine paints a line
	Line(color.Color, gopi.Point, gopi.Point)

	// Paint a rune with a particular font face
	Rune(color.Color, gopi.Point, rune, gopi.FontFace, gopi.FontSize)

	// Retain and release
	Retain()
	Release() bool

	// Return points in the rectangle
	Centre() gopi.Point
	NorthWest() gopi.Point
	SouthWest() gopi.Point
	NorthEast() gopi.Point
	SouthEast() gopi.Point

	// Implements image.Image and draw.Image
	draw.Image

	// Implements gopi.Unit
	gopi.Unit
}

type Color

type Color struct {
	Data []byte
	Mode gopi.SurfaceFlags
}

func (Color) RGBA

func (c Color) RGBA() (r, g, b, a uint32)

func (Color) String

func (c Color) String() string

type ColorModel

type ColorModel struct {
	Mode gopi.SurfaceFlags
}

func (ColorModel) Convert

func (m ColorModel) Convert(c color.Color) color.Color

type Config

type Config struct {
	Size gopi.Size
	Mode gopi.SurfaceFlags
}

type RetainCount

type RetainCount struct {
	sync.RWMutex
	// contains filtered or unexported fields
}

func (*RetainCount) Dec

func (this *RetainCount) Dec() bool

func (*RetainCount) Inc

func (this *RetainCount) Inc() uint

func (*RetainCount) String

func (this *RetainCount) String() string

Jump to

Keyboard shortcuts

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