parser

package
v0.0.0-...-6765b72 Latest Latest
Warning

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

Go to latest
Published: Jul 4, 2020 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AddCamera

func AddCamera(scene *Scene, v map[string]interface{})

func AddLight

func AddLight(scene *Scene, v map[string]interface{})

func AddMaterial

func AddMaterial(scene *Scene, v map[string]interface{})

func AddPlane

func AddPlane(scene *Scene, v map[string]interface{})

func AddSphere

func AddSphere(scene *Scene, v map[string]interface{})

func AddTransform

func AddTransform(scene *Scene, v map[string]interface{})

Types

type DefinedTransform

type DefinedTransform struct {
	// contains filtered or unexported fields
}

type Scene

type Scene struct {
	Lights     []mat.Light
	World      *mat.World
	Camera     *mat.Camera
	Materials  map[string]mat.Material
	Transforms map[string][]mat.Mat4x4
}

func NewScene

func NewScene() *Scene

func ParseYAML

func ParseYAML(file string) *Scene

ParseYAML is a WiP parser for loading scenes given a custom YAML format. The format is similar to, but not compatible with the yaml files the book sometimes uses.

Jump to

Keyboard shortcuts

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