Documentation ¶
Index ¶
- type Camera3D
- func (c *Camera3D) Front() mgl32.Vec3
- func (c *Camera3D) Move(magnitude mgl32.Vec3)
- func (c *Camera3D) Position() mgl32.Vec3
- func (c *Camera3D) Projection() mgl32.Mat4
- func (c *Camera3D) Right() mgl32.Vec3
- func (c *Camera3D) Rotate(pitch, yaw, roll float32)
- func (c *Camera3D) Update()
- func (c *Camera3D) View() mgl32.Mat4
- type Material
- type Mesh
- func (m *Mesh) Destroy()
- func (m *Mesh) Move(magnitude mgl32.Vec3)
- func (m *Mesh) Render(shader *Shader)
- func (m *Mesh) Rotate(angle mgl32.Vec3)
- func (m *Mesh) Scale(magnitude mgl32.Vec3)
- func (m *Mesh) SetPosition(position mgl32.Vec3)
- func (m *Mesh) SetRotation(rotation mgl32.Vec3)
- func (m *Mesh) SetScale(scale mgl32.Vec3)
- type Model
- type Primitive
- type Pyramid
- type Quad
- type Renderer3D
- type Shader
- func (s *Shader) Bind()
- func (s *Shader) Destroy()
- func (s *Shader) SetFloat(value float32, name string)
- func (s *Shader) SetInt(value int32, name string)
- func (s *Shader) SetMat3(value mgl32.Mat4, name string, transpose bool)
- func (s *Shader) SetMat4(value mgl32.Mat4, name string, transpose bool)
- func (s *Shader) SetVec2(value mgl32.Vec2, name string)
- func (s *Shader) SetVec3(value mgl32.Vec3, name string)
- func (s *Shader) SetVec4(value mgl32.Vec4, name string)
- func (s *Shader) Unbind()
- type Texture
- type Triangle
- type Vertex
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Camera3D ¶
type Camera3D struct {
// contains filtered or unexported fields
}
func (*Camera3D) Projection ¶
type Material ¶
type Material struct {
// contains filtered or unexported fields
}
func NewMaterial ¶
func (*Material) SendToShader ¶
type Mesh ¶
type Mesh struct {
// contains filtered or unexported fields
}
func NewMeshPrimitive ¶
func (*Mesh) SetPosition ¶
func (*Mesh) SetRotation ¶
type Pyramid ¶
type Pyramid struct {
// contains filtered or unexported fields
}
func NewPyramid ¶
func NewPyramid() *Pyramid
func (*Pyramid) GetIndexCount ¶
func (*Pyramid) GetIndices ¶
func (*Pyramid) GetTriangleCount ¶
func (*Pyramid) GetVertexCount ¶
func (*Pyramid) GetVertices ¶
type Quad ¶
type Quad struct {
// contains filtered or unexported fields
}
func (*Quad) GetIndexCount ¶
func (*Quad) GetIndices ¶
func (*Quad) GetTriangleCount ¶
func (*Quad) GetVertexCount ¶
func (*Quad) GetVertices ¶
type Renderer3D ¶
type Renderer3D struct {
// contains filtered or unexported fields
}
func MakeRenderer3D ¶
func MakeRenderer3D(title string, width, height int32, glMajor, glMinor int) (Renderer3D, error)
func (*Renderer3D) Destroy ¶
func (r *Renderer3D) Destroy()
func (*Renderer3D) GetContext ¶
func (r *Renderer3D) GetContext() sdl.GLContext
func (*Renderer3D) GetWindow ¶
func (r *Renderer3D) GetWindow() *sdl.Window
func (*Renderer3D) RenderBegin ¶
func (r *Renderer3D) RenderBegin()
func (*Renderer3D) RenderEnd ¶
func (r *Renderer3D) RenderEnd()
type Texture ¶
type Texture struct { UV1 mgl32.Vec2 // READ ONLY UV2 mgl32.Vec2 // READ ONLY // contains filtered or unexported fields }
func NewTexture ¶
type Triangle ¶
type Triangle struct {
// contains filtered or unexported fields
}
func NewTriangle ¶
func NewTriangle() *Triangle
func (*Triangle) GetIndexCount ¶
func (*Triangle) GetIndices ¶
func (*Triangle) GetTriangleCount ¶
func (*Triangle) GetVertexCount ¶
func (*Triangle) GetVertices ¶
Click to show internal directories.
Click to hide internal directories.