Documentation
¶
Index ¶
- func Clear(red, green, blue, alpha float32)
- func ClearRect(width, height int, red, green, blue float32)
- func DrawCanvasRect(canvas *Canvas, left, top, width, height int, alphas []float32)
- func DrawColorRect(left, top, width, height int, leftTopColor []float32, rightTopColor []float32, ...)
- func DrawStringRect(fontTexture *StringTexture, left, top int, rgbFg []float32, rgbBg []float32, ...)
- func DrawTextureRect(texture *Texture, left, top, width, height int, alphas []float32)
- func DrawTextureRectUpsideDown(texture *Texture, left, top, width, height int, alphas []float32)
- func Init()
- func LoadTrueTypeFromFile(fontFilename string) *truetype.Font
- func PopOrtho()
- func PopView()
- func PopViewport()
- func PushOrtho(width, height int)
- func PushView(width, height int)
- func PushViewport(width, height int)
- func Uninit()
- type Canvas
- type ColorRect
- type FrameBuffer
- type G4Font
- type StringTexture
- type Texture
- type TextureRect
- func (r *TextureRect) Draw(texture *Texture, left, top, width, height int, ...)
- func (r *TextureRect) DrawString(texture *Texture, left, top, width, height int, rgbFg []float32, ...)
- func (r *TextureRect) DrawUpsideDown(texture *Texture, left, top, width, height int, ...)
- func (r *TextureRect) Free()
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func DrawCanvasRect ¶
func DrawColorRect ¶
func DrawStringRect ¶
func DrawStringRect(fontTexture *StringTexture, left, top int, rgbFg []float32, rgbBg []float32, alpha float32)
func DrawTextureRect ¶
func LoadTrueTypeFromFile ¶
func PopViewport ¶
func PopViewport()
func PushViewport ¶
func PushViewport(width, height int)
Types ¶
type Canvas ¶
type Canvas struct { Framebuffer *FrameBuffer Width, Height int }
type ColorRect ¶
type ColorRect struct {
// contains filtered or unexported fields
}
func NewColorRect ¶
func NewColorRect() *ColorRect
type FrameBuffer ¶
func NewFrameBuffer ¶
func NewFrameBuffer(width, height int) *FrameBuffer
func (*FrameBuffer) Begin ¶
func (f *FrameBuffer) Begin()
func (*FrameBuffer) End ¶
func (f *FrameBuffer) End()
func (*FrameBuffer) Free ¶
func (f *FrameBuffer) Free()
type StringTexture ¶
func NewStringTexture ¶
func NewStringTexture(str string, aceFont *G4Font) *StringTexture
func (*StringTexture) Free ¶
func (s *StringTexture) Free()
type Texture ¶
type Texture struct { TextureId uint32 Width, Height int // contains filtered or unexported fields }
func NewTexture ¶
func NewTexture() *Texture
func (*Texture) Deactivate ¶
func (t *Texture) Deactivate()
func (*Texture) LoadBytes_RGBA ¶
type TextureRect ¶
type TextureRect struct {
// contains filtered or unexported fields
}
func NewTextureRect ¶
func NewTextureRect(vertexShaderFilename, fragmentShaderFilename string) *TextureRect
func (*TextureRect) Draw ¶
func (r *TextureRect) Draw(texture *Texture, left, top, width, height int, leftTopRightBottomAlphas []float32, projection *float32)
func (*TextureRect) DrawString ¶
func (*TextureRect) DrawUpsideDown ¶
func (r *TextureRect) DrawUpsideDown(texture *Texture, left, top, width, height int, leftTopRightBottomAlphas []float32, projection *float32)
func (*TextureRect) Free ¶
func (r *TextureRect) Free()
Source Files
¶
Click to show internal directories.
Click to hide internal directories.