Documentation ¶
Overview ¶
Package glutil implements OpenGL utility functions.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Image ¶
Image bridges between an *image.RGBA and an OpenGL texture.
The contents of the *image.RGBA can be uploaded as a texture and drawn as a 2D quad.
The number of active Images must fit in the system's OpenGL texture limit. The typical use of an Image is as a texture atlas.
func (*Image) Draw ¶
func (img *Image) Draw(sz size.Event, topLeft, topRight, bottomLeft geom.Point, srcBounds image.Rectangle)
Draw draws the srcBounds part of the image onto a parallelogram, defined by three of its corners, in the current GL framebuffer.
Click to show internal directories.
Click to hide internal directories.