Documentation ¶
Index ¶
- type FrameBuffer
- func (f *FrameBuffer) Circle(centerx, centery, radius, color int)
- func (f *FrameBuffer) Clear()
- func (f *FrameBuffer) DisplayImage(imageWidth, imageHeight int, image []byte)
- func (f *FrameBuffer) Fill(color uint8)
- func (f *FrameBuffer) FillRect(x, y, width, height int, color uint8)
- func (f *FrameBuffer) HLine(x, y, width int, color byte)
- func (f *FrameBuffer) Line(x0, y0, x1, y1, color int)
- func (f *FrameBuffer) Pixel(x, y int, color ...int) byte
- func (f *FrameBuffer) Rect(x, y, width, height int, color byte, fill bool)
- func (f *FrameBuffer) Scroll(dx, dy int)
- func (f *FrameBuffer) SetRotation(val int) error
- func (f *FrameBuffer) VLine(x, y, height int, color byte)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type FrameBuffer ¶
type FrameBuffer struct { Buf *[]byte Width int Height int Stride int Rotation int // Can only be one of (0, 1, 2, 3) }
Type FrameBuffer implements a framebuffer using the MHMSBFormat
func (*FrameBuffer) Circle ¶
func (f *FrameBuffer) Circle(centerx, centery, radius, color int)
func (*FrameBuffer) Clear ¶
func (f *FrameBuffer) Clear()
func (*FrameBuffer) DisplayImage ¶
func (f *FrameBuffer) DisplayImage(imageWidth, imageHeight int, image []byte)
Rough implementation just for B/W
func (*FrameBuffer) Fill ¶
func (f *FrameBuffer) Fill(color uint8)
func (*FrameBuffer) FillRect ¶
func (f *FrameBuffer) FillRect(x, y, width, height int, color uint8)
func (*FrameBuffer) HLine ¶
func (f *FrameBuffer) HLine(x, y, width int, color byte)
func (*FrameBuffer) Line ¶
func (f *FrameBuffer) Line(x0, y0, x1, y1, color int)
func (*FrameBuffer) Pixel ¶
func (f *FrameBuffer) Pixel(x, y int, color ...int) byte
Func Pixel will get the value of a pixel if you don't pass a color if you pass a color, Pixel will set the pixel to the provided color
func (*FrameBuffer) Rect ¶
func (f *FrameBuffer) Rect(x, y, width, height int, color byte, fill bool)
func (*FrameBuffer) Scroll ¶
func (f *FrameBuffer) Scroll(dx, dy int)
Func Scroll shifts the framebuffer in x and y direction
func (*FrameBuffer) SetRotation ¶
func (f *FrameBuffer) SetRotation(val int) error
Func SetRotation sets the rotation of the framebuffer
func (*FrameBuffer) VLine ¶
func (f *FrameBuffer) VLine(x, y, height int, color byte)
Click to show internal directories.
Click to hide internal directories.