Documentation ¶
Overview ¶
Package graphicscommand represents a low layer for graphics using OpenGL.
Index ¶
- func Error() error
- func FlushCommands()
- func NeedsRestoring() bool
- func ResetGraphicsDriverState() error
- func SetGraphicsDriver(driver driver.Graphics)
- type Image
- func (i *Image) Dispose()
- func (i *Image) DrawTriangles(src *Image, vertices []float32, indices []uint16, clr *affine.ColorM, ...)
- func (i *Image) Dump(path string) error
- func (i *Image) InternalSize() (int, int)
- func (i *Image) IsInvalidated() bool
- func (i *Image) Pixels() []byte
- func (i *Image) ReplacePixels(p []byte, x, y, width, height int)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NeedsRestoring ¶ added in v1.10.0
func NeedsRestoring() bool
func ResetGraphicsDriverState ¶
func ResetGraphicsDriverState() error
ResetGraphicsDriverState resets or initializes the current graphics driver state.
func SetGraphicsDriver ¶ added in v1.10.0
Types ¶
type Image ¶
type Image struct {
// contains filtered or unexported fields
}
Image represents an image that is implemented with OpenGL.
func (*Image) DrawTriangles ¶ added in v1.10.0
func (*Image) Dump ¶ added in v1.10.0
Dump dumps the image to the specified path. In the path, '*' is replaced with the image's ID.
This is for testing usage.
func (*Image) InternalSize ¶ added in v1.10.0
func (*Image) IsInvalidated ¶
func (*Image) Pixels ¶
Pixels returns the image's pixels. Pixels might return nil when OpenGL error happens.
func (*Image) ReplacePixels ¶
Click to show internal directories.
Click to hide internal directories.