Documentation ¶
Index ¶
- Constants
- Variables
- type Geometry
- type Instance
- func (i *Instance) Color() mgl32.Vec4
- func (i *Instance) GetModel() mgl32.Mat4
- func (i *Instance) InsertAfter(inst *Instance)
- func (i *Instance) MarkChanged()
- func (i *Instance) Next() *Instance
- func (i *Instance) Remove()
- func (i *Instance) SetColor(r, g, b, a float32)
- func (i *Instance) SetPosition(p mgl32.Vec3)
- func (i *Instance) SetRotation(r float32)
- func (i *Instance) SetScale(s mgl32.Vec3)
- type InstanceList
- type Instances
- type Point
- type Renderer
- type UniformBufferSheet
- type UniformSprite
Constants ¶
View Source
const FRAGMENT = `` /* 353-byte string literal not displayed */
View Source
const VERTEX = `` /* 691-byte string literal not displayed */
Variables ¶
View Source
var Square = []Point{ Point{ Position: mgl32.Vec3{-0.5, -0.5, 0}, Texture: mgl32.Vec2{0, 0}, Frame: 0, }, Point{ Position: mgl32.Vec3{0.5, 0.5, 0}, Texture: mgl32.Vec2{1, 1}, Frame: 0, }, Point{ Position: mgl32.Vec3{-0.5, 0.5, 0}, Texture: mgl32.Vec2{0, 1}, Frame: 0, }, Point{ Position: mgl32.Vec3{-0.5, -0.5, 0}, Texture: mgl32.Vec2{0, 0}, Frame: 0, }, Point{ Position: mgl32.Vec3{0.5, -0.5, 0}, Texture: mgl32.Vec2{1, 0}, Frame: 0, }, Point{ Position: mgl32.Vec3{0.5, 0.5, 0}, Texture: mgl32.Vec2{1, 1}, Frame: 0, }, }
Functions ¶
This section is empty.
Types ¶
type Instance ¶
type Instance struct { Frame int Key string // TODO: move to an interface{} data pointer. // contains filtered or unexported fields }
func (*Instance) InsertAfter ¶
func (*Instance) MarkChanged ¶
func (i *Instance) MarkChanged()
func (*Instance) SetPosition ¶
func (*Instance) SetRotation ¶
type InstanceList ¶
type InstanceList struct {
// contains filtered or unexported fields
}
func NewInstanceList ¶
func NewInstanceList() (l *InstanceList)
func (*InstanceList) Head ¶
func (l *InstanceList) Head() *Instance
func (*InstanceList) NewInstance ¶
func (l *InstanceList) NewInstance() (inst *Instance)
func (*InstanceList) Prepend ¶
func (l *InstanceList) Prepend(inst *Instance)
type Renderer ¶
type Renderer struct {
// contains filtered or unexported fields
}
func NewRenderer ¶
type UniformBufferSheet ¶
type UniformSprite ¶
type UniformSprite [4]float32
func NewUniformSprite ¶
func NewUniformSprite(texW, texH, texX, texY float32) UniformSprite
Click to show internal directories.
Click to hide internal directories.