monitor

package
v0.0.0-...-29fc142 Latest Latest
Warning

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

Go to latest
Published: Apr 3, 2023 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

View Source
const (
	SidePixel    = 16
	WidthScreen  = SidePixel * 64
	HeightScreen = SidePixel * 32
)

Variables

This section is empty.

Functions

This section is empty.

Types

type FrameBuffer

type FrameBuffer [64 * 32]byte

func (*FrameBuffer) CheckOverlap

func (f *FrameBuffer) CheckOverlap(x, y int) bool

CheckOverlap checks if the given x, y are outside the bounds of the array

func (*FrameBuffer) Get

func (f *FrameBuffer) Get(x, y int) *byte

Get returns the cell of the FrameBuffer corresponded to the (x,y) coordinate of the 64x32 display

type Monitor

type Monitor interface {
	ToDraw(buffer FrameBuffer)
}

func NewMonitor

func NewMonitor(window *pixelgl.Window) Monitor

Jump to

Keyboard shortcuts

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