avyos.dev/pkg/graphics/backend/framebuffer
package framebuffer
Package Overview
No package-level documentation is provided.
| Export Group | Count |
|---|---|
| Constants | 0 |
| Variables | 0 |
| Functions | 0 |
| Types | 1 |
Types
Backend
type Backend struct {
// contains filtered or unexported fields
}Backend represents the Linux framebuffer backend.
Functions
func New() *BackendNew creates a new framebuffer backend.
Methods
func (b *Backend) Buffer() *graphics.BufferBuffer returns the back buffer for drawing.
func (b *Backend) Close() errorClose closes the framebuffer device and restores text mode.
func (b *Backend) Flush() errorFlush copies the entire back buffer to the screen.
func (b *Backend) FlushRect(r graphics.Rect) errorFlushRect copies only the given rectangle from the back buffer to the screen.
func (b *Backend) FlushRects(rects []graphics.Rect) errorFlushRects copies multiple rectangles from the back buffer to the screen.
func (b *Backend) HasSystemCursor() boolHasSystemCursor returns false since the framebuffer has no system cursor.
func (b *Backend) Info() stringInfo returns information about the framebuffer.
func (b *Backend) Open() errorOpen opens the framebuffer device.
func (b *Backend) OpenDevice(device string) errorOpenDevice opens a specific framebuffer device.
func (b *Backend) PixelFormat() graphics.PixelFormatPixelFormat returns the detected pixel format.
func (b *Backend) Size() (width, height int)Size returns the screen dimensions.
func (b *Backend) Start()Start is a no-op for the framebuffer backend.