Documentation
¶
Index ¶
- Constants
- func CopyMeshSlice(source []MeshTypes.Mesh) []MeshTypes.Mesh
- func CopySlice[Source DeepCopy[Destination], Destination any](source []Source) []Destination
- func CreateGeometryReferencePointers[T GeometryReferenceCreation](refPointers *ReferencePointers, source *[]T, parentPrefix string)
- func CreateReferencePointers[T ReferenceCreation](refPointers *ReferencePointers, source *[]T)
- func CreateReferencePointersMap[T ReferenceCreation](refPointers *ReferencePointers, source *map[string]T)
- func GenerateMeshes[T MeshTaskCreator](objects []T, parentMeshConfig ParentMeshConfig)
- func GetBoolPtr(value bool) *bool
- func ReadMeshes[T MeshReader](src []T, fileMap map[string]*zip.File) error
- func ResolveReferences[T ReferenceResolver](refPointers *ReferencePointers, source *[]T)
- func ResolveReferencesMap[T ReferenceResolver](refPointers *ReferencePointers, source *map[string]T)
- type Address
- type Addresses
- type Alignment
- type AuxData
- type ChildList
- type Class
- type ColorCIE
- type Connection
- type CustomCommand
- type DMXAddress
- type Data
- type DeepCopy
- type Fixture
- type FixtureModel
- type FocusPoint
- type FocusPointModel
- type GDTF
- type GeneralSceneDescription
- func (a *GeneralSceneDescription) CreateReferencePointer(refPointers *ReferencePointers)
- func (a *GeneralSceneDescription) GenerateMeshes()
- func (a *GeneralSceneDescription) GetStageModel(config ModelConfig) StageModel
- func (a *GeneralSceneDescription) ResolveReference(refPointers *ReferencePointers)
- type Geometries
- type Geometry3D
- type GeometryReferenceCreation
- type GlobalModelConfig
- type Gobo
- type GroupObject
- type IPv4
- type IPv6
- type Layer
- type MVRParserConfig
- type Mapping
- type MappingDefinition
- type Matrix
- type MeshReader
- type MeshTaskCreator
- type ModelConfig
- type ModelNodeConfig
- type Network
- type NodeModel
- type NodeReference
- type Overwrite
- type ParentMeshConfig
- type Position
- type Projection
- type Projector
- type ProjectorModel
- type Protocol
- type ReferenceCreation
- type ReferencePointers
- type ReferenceResolver
- type Scene
- type SceneObject
- type SceneObjectModel
- type Source
- type StageModel
- type Support
- type SupportModel
- type SymDef
- type Symbol
- type Truss
- type TrussModel
- type UserData
- type Vector
- type VideoScreen
- type VideoScreenModel
Constants ¶
View Source
const ( IgnoreMeshes = 0 // ignore meshes entirely (leave nil) ReadMeshesIntoModels = 1 // generate individual model part meshes BuildFixtureModels = 2 // assemble single mesh with correct rotations per fixture type BuildStageModel = 3 // assemble )
Variables ¶
This section is empty.
Functions ¶
func CreateGeometryReferencePointers ¶
func CreateGeometryReferencePointers[T GeometryReferenceCreation](refPointers *ReferencePointers, source *[]T, parentPrefix string)
func CreateReferencePointers ¶
func CreateReferencePointers[T ReferenceCreation](refPointers *ReferencePointers, source *[]T)
func CreateReferencePointersMap ¶
func CreateReferencePointersMap[T ReferenceCreation](refPointers *ReferencePointers, source *map[string]T)
func GenerateMeshes ¶ added in v0.1.0
func GenerateMeshes[T MeshTaskCreator](objects []T, parentMeshConfig ParentMeshConfig)
func GetBoolPtr ¶ added in v0.1.0
func ReadMeshes ¶
func ReadMeshes[T MeshReader](src []T, fileMap map[string]*zip.File) error
func ResolveReferences ¶
func ResolveReferences[T ReferenceResolver](refPointers *ReferencePointers, source *[]T)
func ResolveReferencesMap ¶
func ResolveReferencesMap[T ReferenceResolver](refPointers *ReferencePointers, source *map[string]T)
Types ¶
type Address ¶
type Address struct {
Break int
Value DMXAddress
}
type AuxData ¶
type AuxData struct {
SymDefs []*SymDef
Positions []*Position
MappingDefinitions []*MappingDefinition
Classes []*Class
}
auxiliary data for the scene node
func (*AuxData) CreateReferencePointer ¶
func (a *AuxData) CreateReferencePointer(refPointers *ReferencePointers)
type ChildList ¶
type ChildList struct {
SceneObjects []*SceneObject
GroupObjects []*GroupObject
FocusPoints []*FocusPoint
Fixtures []*Fixture
Supports []*Support
Trusses []*Truss
VideoScreens []*VideoScreen
Projectors []*Projector
}
func (*ChildList) CreateReferencePointer ¶
func (c *ChildList) CreateReferencePointer(refPointers *ReferencePointers)
func (*ChildList) GenerateMesh ¶ added in v0.1.0
func (a *ChildList) GenerateMesh(parentMeshConfig ParentMeshConfig)
func (*ChildList) ResolveReference ¶
func (c *ChildList) ResolveReference(refPointers *ReferencePointers)
type Class ¶
logical grouping across different layers
func (*Class) CreateReferencePointer ¶
func (a *Class) CreateReferencePointer(refPointers *ReferencePointers)
type Connection ¶
type Connection struct {
Own string // Node Link to the Geometry with DIN SPEC 15800 Type Wiring Object . Starting point is the Geometry Collect of the linked GDTF.
Other string // Node Link to the Geometry with DIN SPEC 15800 Type Wiring Object . Starting point is the Geometry Collect of the linked GDTF of the object defined in toObject.
ToObject NodeReference[any] // UUID of an other object in the scene.
}
type CustomCommand ¶
type DMXAddress ¶
NOTE: values are 0 indexed
func GetDMXAddress ¶
func GetDMXAddress(value string) (*DMXAddress, error)
type Fixture ¶
type Fixture struct {
UUID string
Name string
Multipatch *string
Matrix MeshTypes.Matrix
Class NodeReference[Class]
GDTFSpec NodeReference[GDTF]
GDTFMode string
Focus NodeReference[FocusPoint]
CastShadow bool
DMXInvertPan bool
DMXInvertTilt bool
Position NodeReference[Position]
Function *string
FixtureID string
FixtureIDNumeric int
UnitNumber int
ChildPosition string // Node link to the geometry. Starting point is the Geometry Collect of the linked parent GDTF of this object.
Addresses *Addresses
Protocols []*Protocol
Alignments []*Alignment
CustomCommands []*CustomCommand
Overwrites []*Overwrite
Connections []*Connection
Color *ColorCIE
CustomId int
CustomIdType int
Mappings []*Mapping
Gobo *Gobo
Model FixtureModel
ChildList
}
func (*Fixture) CreateReferencePointer ¶
func (a *Fixture) CreateReferencePointer(refPointers *ReferencePointers)
func (*Fixture) GenerateMesh ¶ added in v0.1.0
func (obj *Fixture) GenerateMesh(parentMeshConfig ParentMeshConfig)
func (*Fixture) ResolveReference ¶
func (a *Fixture) ResolveReference(refPointers *ReferencePointers)
type FixtureModel ¶ added in v0.1.0
type FixtureModel struct {
Fixture *Fixture
TransformationMatrix MeshTypes.Matrix
MeshModel []GDTFTypes.MeshModel
Geometries []MeshTypes.Mesh
}
func (FixtureModel) Copy ¶ added in v0.1.0
func (obj FixtureModel) Copy() FixtureModel
type FocusPoint ¶
type FocusPoint struct {
UUID string
Name string
Matrix MeshTypes.Matrix
Class NodeReference[Class]
Model FocusPointModel
Geometries *Geometries
}
func (*FocusPoint) CreateReferencePointer ¶
func (a *FocusPoint) CreateReferencePointer(refPointers *ReferencePointers)
func (*FocusPoint) GenerateMesh ¶ added in v0.1.0
func (obj *FocusPoint) GenerateMesh(parentMeshConfig ParentMeshConfig)
func (*FocusPoint) ResolveReference ¶
func (a *FocusPoint) ResolveReference(refPointers *ReferencePointers)
type FocusPointModel ¶ added in v0.1.0
type FocusPointModel struct {
FocusPoint *FocusPoint
TransformationMatrix MeshTypes.Matrix
Geometries []MeshTypes.Mesh
}
func (FocusPointModel) Copy ¶ added in v0.1.0
func (obj FocusPointModel) Copy() FocusPointModel
type GeneralSceneDescription ¶
type GeneralSceneDescription struct {
VersionMajor int
VersionMinor int
Provider string
ProviderVersion string
UserData *UserData
Scene *Scene
}
func (*GeneralSceneDescription) CreateReferencePointer ¶
func (a *GeneralSceneDescription) CreateReferencePointer(refPointers *ReferencePointers)
func (*GeneralSceneDescription) GenerateMeshes ¶ added in v0.1.0
func (a *GeneralSceneDescription) GenerateMeshes()
func (*GeneralSceneDescription) GetStageModel ¶ added in v0.2.0
func (a *GeneralSceneDescription) GetStageModel(config ModelConfig) StageModel
func (*GeneralSceneDescription) ResolveReference ¶
func (a *GeneralSceneDescription) ResolveReference(refPointers *ReferencePointers)
type Geometries ¶
type Geometries struct {
Geometry3D []*Geometry3D
Symbol []*Symbol
}
func (*Geometries) GenerateMeshes ¶ added in v0.1.0
func (obj *Geometries) GenerateMeshes(parentMeshConfig ParentMeshConfig) []MeshTypes.Mesh
func (*Geometries) ResolveReference ¶
func (a *Geometries) ResolveReference(refPointers *ReferencePointers)
type Geometry3D ¶
type GeometryReferenceCreation ¶
type GeometryReferenceCreation interface {
CreateGeometryReferencePointer(refPointers *ReferencePointers, parentPrefix string)
}
type GlobalModelConfig ¶
type GlobalModelConfig struct {
RenderOnlyAddressedFixture bool
}
type GroupObject ¶
type GroupObject struct {
UUID string
Name string
Matrix MeshTypes.Matrix
Class NodeReference[Class]
ChildList
}
func (*GroupObject) CreateReferencePointer ¶
func (a *GroupObject) CreateReferencePointer(refPointers *ReferencePointers)
func (*GroupObject) GenerateMesh ¶ added in v0.1.0
func (obj *GroupObject) GenerateMesh(parentMeshConfig ParentMeshConfig)
func (*GroupObject) ResolveReference ¶
func (a *GroupObject) ResolveReference(refPointers *ReferencePointers)
type Layer ¶
spatial representation of a geometric container
func (*Layer) CreateReferencePointer ¶
func (a *Layer) CreateReferencePointer(refPointers *ReferencePointers)
func (*Layer) ResolveReference ¶
func (a *Layer) ResolveReference(refPointers *ReferencePointers)
type MVRParserConfig ¶
type Mapping ¶
type Mapping struct {
LinkedDef NodeReference[MappingDefinition]
Ux int
Uy int
Ox int
Oy int
Rz float32
}
func (*Mapping) ResolveReference ¶
func (a *Mapping) ResolveReference(refPointers *ReferencePointers)
type MappingDefinition ¶
type MappingDefinition struct {
UUID string
Name string
SizeX int
SizeY int
Source Source
ScaleHandeling *string // ScaleKeepRatio or ScaleIgnoreRatio or KeepSizeCenter
}
input source for fixture color mapping applications
func (*MappingDefinition) CreateReferencePointer ¶
func (a *MappingDefinition) CreateReferencePointer(refPointers *ReferencePointers)
type MeshTaskCreator ¶
type MeshTaskCreator interface {
GenerateMesh(parentMeshConfig ParentMeshConfig)
}
type ModelConfig ¶
type ModelConfig struct {
Global GlobalModelConfig
Individual map[string]ModelNodeConfig // configure by Node (fixture, ...) UUID (also applies to children)
}
type ModelNodeConfig ¶
type NodeModel ¶ added in v0.2.0
type NodeModel interface {
// contains filtered or unexported methods
}
type NodeReference ¶
type Overwrite ¶
type Overwrite struct {
Universal string // Node Link to the Wheel, Emitter or Filter. Starting point is the the collect of the Universal GDTF.
Target string // Node Link to the Wheel, Emitter or Filter. Starting point is the the collect of the linked GDTF of the fixture. When no target is given, it will be like a static gobo or filter that you attach in front of all beams
}
This node defines an overwrite with the Universal.gdtt GDTF template inside the MVR to overwrite Wheel Slots, Emitters and Filters for the fixture
type ParentMeshConfig ¶
type Position ¶
logical grouping of lighting devices and trusses
func (*Position) CreateReferencePointer ¶
func (a *Position) CreateReferencePointer(refPointers *ReferencePointers)
type Projection ¶
type Projector ¶
type Projector struct {
UUID string
Name string
Multipatch string
Matrix MeshTypes.Matrix
Class NodeReference[Class]
Geometries *Geometries
Projections []*Projection
Function *string
GDTFSpec NodeReference[GDTF]
GDTFMode string
CastShadow bool
Addresses *Addresses
Alignments []*Alignment
CustomCommands []*CustomCommand
Overwrites []*Overwrite
Connections []*Connection
FixtureID string
FixtureIDNumeric int
UnitNumber int
CustomId int
CustomIdType int
Model ProjectorModel
ChildList
}
func (*Projector) CreateReferencePointer ¶
func (a *Projector) CreateReferencePointer(refPointers *ReferencePointers)
func (*Projector) GenerateMesh ¶ added in v0.1.0
func (obj *Projector) GenerateMesh(parentMeshConfig ParentMeshConfig)
func (*Projector) ResolveReference ¶
func (a *Projector) ResolveReference(refPointers *ReferencePointers)
type ProjectorModel ¶ added in v0.1.0
type ProjectorModel struct {
Projector *Projector
TransformationMatrix MeshTypes.Matrix
MeshModel []GDTFTypes.MeshModel
Geometries []MeshTypes.Mesh
}
func (ProjectorModel) Copy ¶ added in v0.1.0
func (obj ProjectorModel) Copy() ProjectorModel
type Protocol ¶
type Protocol struct {
Geometry string // defaults to NetworkInOut_1
Name string // Custom Name of the protocol to identify the protocol. Needs to be unique for this instance of object.
Type string // Name of the protocol.
Version string // This is the protocol version if available.
Transmission string // Unicast, Multicast, Broadcast, Anycast
}
type ReferenceCreation ¶
type ReferenceCreation interface {
CreateReferencePointer(refPointers *ReferencePointers)
}
type ReferencePointers ¶
type ReferencePointers struct {
GDTFSpecs map[string]*GDTF // handled seperately
Classes map[string]*Class
Positions map[string]*Position
SymDefs map[string]*SymDef
MappingDefinitions map[string]*MappingDefinition
FoucsPoints map[string]*FocusPoint
Object map[string]*any
}
func CreateRefPointersMap ¶
func CreateRefPointersMap() *ReferencePointers
type ReferenceResolver ¶
type ReferenceResolver interface {
ResolveReference(refPointers *ReferencePointers)
}
type Scene ¶
func (*Scene) CreateReferencePointer ¶
func (a *Scene) CreateReferencePointer(refPointers *ReferencePointers)
func (*Scene) ResolveReference ¶
func (a *Scene) ResolveReference(refPointers *ReferencePointers)
type SceneObject ¶
type SceneObject struct {
UUID string
Name string
Multipatch string
Matrix MeshTypes.Matrix
Class NodeReference[Class]
Geometries *Geometries
GDTFSpec NodeReference[GDTF]
GDTFMode string
CastShadow bool
Addresses *Addresses
Alignments []*Alignment
CustomCommands []*CustomCommand
Overwrites []*Overwrite
Connections []*Connection
FixtureID string
FixtureIDNumeric int
UnitNumber int
CustomId int
CustomIdType int
Model SceneObjectModel
ChildList
}
func (*SceneObject) CreateReferencePointer ¶
func (a *SceneObject) CreateReferencePointer(refPointers *ReferencePointers)
func (*SceneObject) GenerateMesh ¶ added in v0.1.0
func (obj *SceneObject) GenerateMesh(parentMeshConfig ParentMeshConfig)
func (*SceneObject) ResolveReference ¶
func (a *SceneObject) ResolveReference(refPointers *ReferencePointers)
type SceneObjectModel ¶ added in v0.1.0
type SceneObjectModel struct {
SceneObject *SceneObject
TransformationMatrix MeshTypes.Matrix
MeshModel []GDTFTypes.MeshModel
Geometries []MeshTypes.Mesh
}
func (SceneObjectModel) Copy ¶ added in v0.1.0
func (obj SceneObjectModel) Copy() SceneObjectModel
type StageModel ¶ added in v0.1.0
type StageModel struct {
SceneObjectModels []SceneObjectModel
FocusPointModels []FocusPointModel
FixtureModels []FixtureModel
SupportModels []SupportModel
TrussModels []TrussModel
VideoScreenModels []VideoScreenModel
ProjectorModels []ProjectorModel
}
func (*StageModel) Copy ¶ added in v0.1.0
func (obj *StageModel) Copy() StageModel
type Support ¶
type Support struct {
UUID string
Name string
Multipatch string
Matrix MeshTypes.Matrix
Class NodeReference[Class]
Position NodeReference[Position]
Geometries *Geometries
Function *string
ChainLength float32
GDTFSpec NodeReference[GDTF]
GDTFMode string
CastShadow bool
Addresses *Addresses
Alignments []*Alignment
CustomCommands []*CustomCommand
Overwrites []*Overwrite
Connections []*Connection
FixtureID string
FixtureIDNumeric int
UnitNumber int
CustomId int
CustomIdType int
Model SupportModel
ChildList
}
func (*Support) CreateReferencePointer ¶
func (a *Support) CreateReferencePointer(refPointers *ReferencePointers)
func (*Support) GenerateMesh ¶ added in v0.1.0
func (obj *Support) GenerateMesh(parentMeshConfig ParentMeshConfig)
func (*Support) ResolveReference ¶
func (a *Support) ResolveReference(refPointers *ReferencePointers)
type SupportModel ¶ added in v0.1.0
type SupportModel struct {
Support *Support
TransformationMatrix MeshTypes.Matrix
MeshModel []GDTFTypes.MeshModel
Geometries []MeshTypes.Mesh
}
func (SupportModel) Copy ¶ added in v0.1.0
func (obj SupportModel) Copy() SupportModel
type SymDef ¶
type SymDef struct {
UUID string
Name string
Geometries *Geometries
}
contains the graphics so the scene can refer to this, thus optimizing repetition of the geometry
func (*SymDef) CreateReferencePointer ¶
func (a *SymDef) CreateReferencePointer(refPointers *ReferencePointers)
func (*SymDef) ResolveReference ¶
func (a *SymDef) ResolveReference(refPointers *ReferencePointers)
type Symbol ¶
type Symbol struct {
UUID string
SymDef NodeReference[SymDef]
Matrix MeshTypes.Matrix
}
func (*Symbol) GenerateMeshes ¶ added in v0.1.0
func (a *Symbol) GenerateMeshes(parentMeshConfig ParentMeshConfig) []MeshTypes.Mesh
func (*Symbol) ResolveReference ¶
func (a *Symbol) ResolveReference(refPointers *ReferencePointers)
type Truss ¶
type Truss struct {
UUID string
Name string
Multipatch string
Matrix MeshTypes.Matrix
Class NodeReference[Class]
Position NodeReference[Position]
Geometries *Geometries
Function *string
GDTFSpec NodeReference[GDTF]
GDTFMode string
CastShadow bool
Addresses *Addresses
Alignments []*Alignment
CustomCommands []*CustomCommand
Overwrites []*Overwrite
Connections []*Connection
ChildPosition *string // Node link to the geometry. Starting point is the Geometry Collect of the linked parent GDTF of this object.
FixtureID string
FixtureIDNumeric int // v1.6 only, MA exports 1.5
UnitNumber int
CustomId int
CustomIdType int
Model TrussModel
ChildList
}
func (*Truss) CreateReferencePointer ¶
func (a *Truss) CreateReferencePointer(refPointers *ReferencePointers)
func (*Truss) GenerateMesh ¶ added in v0.1.0
func (obj *Truss) GenerateMesh(parentMeshConfig ParentMeshConfig)
func (*Truss) ResolveReference ¶
func (a *Truss) ResolveReference(refPointers *ReferencePointers)
type TrussModel ¶ added in v0.1.0
type TrussModel struct {
Truss *Truss
TransformationMatrix MeshTypes.Matrix
MeshModel []GDTFTypes.MeshModel
Geometries []MeshTypes.Mesh
}
func (TrussModel) Copy ¶ added in v0.1.0
func (obj TrussModel) Copy() TrussModel
type VideoScreen ¶
type VideoScreen struct {
UUID string
Name string
Multipatch string
Matrix MeshTypes.Matrix
Class NodeReference[Class]
Geometries *Geometries
Sources []*Source
Function *string
GDTFSpec NodeReference[GDTF]
GDTFMode string
CastShadow bool
Addresses *Addresses
Alignments []*Alignment
CustomCommands []*CustomCommand
Overwrites []*Overwrite
Connections []*Connection
FixtureID string
FixtureIDNumeric int
UnitNumber int
CustomId int
CustomIdType int
Model VideoScreenModel
ChildList
}
func (*VideoScreen) CreateReferencePointer ¶
func (a *VideoScreen) CreateReferencePointer(refPointers *ReferencePointers)
func (*VideoScreen) GenerateMesh ¶ added in v0.1.0
func (obj *VideoScreen) GenerateMesh(parentMeshConfig ParentMeshConfig)
func (*VideoScreen) ResolveReference ¶
func (a *VideoScreen) ResolveReference(refPointers *ReferencePointers)
type VideoScreenModel ¶ added in v0.1.0
type VideoScreenModel struct {
VideoScreen *VideoScreen
TransformationMatrix MeshTypes.Matrix
MeshModel []GDTFTypes.MeshModel
Geometries []MeshTypes.Mesh
}
func (VideoScreenModel) Copy ¶ added in v0.1.0
func (obj VideoScreenModel) Copy() VideoScreenModel
Click to show internal directories.
Click to hide internal directories.