model

package
v0.0.0-...-b05aa3b Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 3, 2019 License: MIT Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Group

type Group struct {
	Name     string
	Material string
	SzPos    int       // number components of position per vertex
	SzNorm   int       // number components of nromal per vertex
	SzTC     int       // number components of texcoord per vertex
	Verts    []float32 // interlacing position, texcoord, normal
	Smooth   int       // smoothing group
	Indices  []uint16
}

func (Group) IndexMode

func (g Group) IndexMode() bool

func (Group) NumVerts

func (g Group) NumVerts() uint32

func (Group) VertSize

func (g Group) VertSize() uint32

func (Group) VertStride

func (g Group) VertStride() uint32

type Model

type Model struct {
	Name    string
	MtlLibs []string
	Groups  []*Group
}

func (*Model) AppendStaticMesh

func (m *Model) AppendStaticMesh(vertices [][8]float32, indices []uint16, mat calc.Mat4) *Model

func (Model) String

func (m Model) String() string

Directories

Path Synopsis
Package obj provide interface to load OBJ format 3D models
Package obj provide interface to load OBJ format 3D models

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL