buffered

package
v2.0.0-...-ff95b93 Latest Latest
Warning

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

Go to latest
Published: Jul 31, 2022 License: Apache-2.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func BeginFrame

func BeginFrame(graphicsDriver graphicsdriver.Graphics) error

func EndFrame

func EndFrame(graphicsDriver graphicsdriver.Graphics) error

Types

type Image

type Image struct {
	// contains filtered or unexported fields
}

func NewImage

func NewImage(width, height int, imageType atlas.ImageType) *Image

func (*Image) At

func (img *Image) At(graphicsDriver graphicsdriver.Graphics, x, y int) (r, g, b, a byte, err error)

func (*Image) DrawTriangles

func (i *Image) DrawTriangles(srcs [graphics.ShaderImageCount]*Image, vertices []float32, indices []uint16, colorm affine.ColorM, mode graphicsdriver.CompositeMode, filter graphicsdriver.Filter, address graphicsdriver.Address, dstRegion, srcRegion graphicsdriver.Region, subimageOffsets [graphics.ShaderImageCount - 1][2]float32, shader *Shader, uniforms [][]float32, evenOdd bool)

DrawTriangles draws the src image with the given vertices.

Copying vertices and indices is the caller's responsibility.

func (*Image) DumpScreenshot

func (i *Image) DumpScreenshot(graphicsDriver graphicsdriver.Graphics, name string, blackbg bool) error

func (*Image) MarkDisposed

func (i *Image) MarkDisposed()

func (*Image) ReplacePixels

func (i *Image) ReplacePixels(pix []byte, x, y, width, height int)

ReplacePixels replaces the pixels at the specified region.

type Shader

type Shader struct {
	// contains filtered or unexported fields
}

func NewShader

func NewShader(ir *shaderir.Program) *Shader

func (*Shader) MarkDisposed

func (s *Shader) MarkDisposed()

Jump to

Keyboard shortcuts

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