entity

package
v0.0.0-...-6af930d Latest Latest
Warning

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

Go to latest
Published: Apr 1, 2021 License: MIT Imports: 18 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewImage

func NewImage(r io.Reader) *graphic.Mesh

NewImage returns a new mesh containing the specified image which can be read by the io.Reader interface (currently supported are PNG and JPG)

func NewImageFromRex

func NewImageFromRex(block rexfile.Image) *graphic.Mesh

NewImage returns a new mesh for the given REX image datablock

Types

type RexMesh

type RexMesh struct {
	*graphic.Mesh
	// contains filtered or unexported fields
}

func NewRexMesh

func NewRexMesh(data rexfile.Mesh) *RexMesh

func (*RexMesh) OfferMaterial

func (m *RexMesh) OfferMaterial(material rexfile.Material)

OfferMaterial is used by the caller to propagate a material. If the materialID is matching, the material is replaced

func (*RexMesh) OfferTexture

func (m *RexMesh) OfferTexture(img rexfile.Image)

OfferTexture is used by the caller to propagate a texture for the material. If the ID is matching, the texture is applied

type TerrainMesh

type TerrainMesh struct {
	*graphic.Mesh
	// contains filtered or unexported fields
}

func NewTerrainMesh

func NewTerrainMesh(width, height float32, nrWidthSegments, nrHeightSegments int) *TerrainMesh

func (*TerrainMesh) ApplyNoiseMap

func (t *TerrainMesh) ApplyNoiseMap()

Jump to

Keyboard shortcuts

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