Documentation ¶
Index ¶
- Constants
- type BoneTransform
- type BspRegion
- type Fragment
- type LegacyMesh
- type LegacyPolygon
- type LegacyRenderGroup
- type LegacyVertexPiece
- type LegacyVertexTex
- type LightInstance
- type LightSource
- type LightSourceInstance
- type LightSourceReference
- type Material
- type MaterialList
- type Mesh
- type MeshReference
- type ObjectInstance
- type ParticleCloud
- type ParticleSprite
- type ParticleSpriteReference
- type Polygon
- type SkeletonReference
- type Track
- type TrackReference
- type VertexColor
- type VertexColorReference
Constants ¶
View Source
const ( // Used for boundaries that are not rendered. TextInfoReference can be null or have reference. MaterialTypeBoundary = 0x0 // Standard diffuse shader MaterialTypeDiffuse = 0x01 // Diffuse variant MaterialTypeDiffuse2 = 0x02 // Transparent with 0.5 blend strength MaterialTypeTransparent50 = 0x05 // Transparent with 0.25 blend strength MaterialTypeTransparent25 = 0x09 // Transparent with 0.75 blend strength MaterialTypeTransparent75 = 0x0A // Non solid surfaces that shouldn't really be masked MaterialTypeTransparentMaskedPassable = 0x07 MaterialTypeTransparentAdditiveUnlit = 0x0B MaterialTypeTransparentMasked = 0x13 MaterialTypeDiffuse3 = 0x14 MaterialTypeDiffuse4 = 0x15 MaterialTypeTransparentAdditive = 0x17 MaterialTypeDiffuse5 = 0x19 MaterialTypeInvisibleUnknown = 0x53 MaterialTypeDiffuse6 = 0x553 MaterialTypeCompleteUnknown = 0x1A // TODO: Analyze this MaterialTypeDiffuse7 = 0x12 MaterialTypeDiffuse8 = 0x31 MaterialTypeInvisibleUnknown2 = 0x4B MaterialTypeDiffuseSkydome = 0x0D // Need to confirm MaterialTypeTransparentSkydome = 0x0F // Need to confirm MaterialTypeTransparentAdditiveUnlitSkydome = 0x10 MaterialTypeInvisibleUnknown3 = 0x03 )
View Source
const ( ShaderTypeDiffuse = 0 ShaderTypeTransparent25 = 1 ShaderTypeTransparent50 = 2 ShaderTypeTransparent75 = 3 ShaderTypeTransparentAdditive = 4 ShaderTypeTransparentAdditiveUnlit = 5 ShaderTypeTransparentMasked = 6 ShaderTypeDiffuseSkydome = 7 ShaderTypeTransparentSkydome = 8 ShaderTypeTransparentAdditiveUnlitSkydome = 9 ShaderTypeInvisible = 10 ShaderTypeBoundary = 11 )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type BoneTransform ¶
type BoneTransform struct { Translation math32.Vector3 Rotation math32.Quaternion Scale float32 ModelMatrix math32.Matrix4 }
BoneTransform coordinate data
type BspRegion ¶
type BspRegion struct { HasPolygons bool Reference uint32 RegionType uint32 // contains filtered or unexported fields }
BspRegion information
func LoadBspRegion ¶
func LoadBspRegion(r io.ReadSeeker) (*BspRegion, error)
func (*BspRegion) FragmentType ¶
type Fragment ¶
type Fragment interface { // FragmentType identifies the fragment type FragmentType() string }
Fragment is what every fragment object type adheres to
type LegacyMesh ¶
type LegacyMesh struct { HashIndex uint32 Flags uint32 VertexCount uint32 TexCoordCount uint32 NormalCount uint32 ColorCount uint32 PolygonCount uint32 Size6 int16 Fragment1Maybe int16 VertexPieceCount uint32 MaterialReference uint32 Fragment3 uint32 CenterPosition math32.Vector3 Params2 uint32 Something2 uint32 Something3 uint32 // contains filtered or unexported fields }
LegacyMesh information
func LoadLegacyMesh ¶
func LoadLegacyMesh(r io.ReadSeeker) (*LegacyMesh, error)
func (*LegacyMesh) FragmentType ¶
func (l *LegacyMesh) FragmentType() string
type LegacyPolygon ¶
type LegacyRenderGroup ¶
type LegacyVertexPiece ¶
type LegacyVertexTex ¶
type LightInstance ¶
type LightInstance struct { Reference uint32 Position math32.Vector3 Radius float32 // contains filtered or unexported fields }
LightInstance information
func LoadLightInstance ¶
func LoadLightInstance(r io.ReadSeeker) (*LightInstance, error)
func (*LightInstance) FragmentType ¶
func (l *LightInstance) FragmentType() string
type LightSource ¶
type LightSource struct { // IsPlacedLightSource if used in the light.wld and is not if used in the main zone file IsPlacedLightSource bool // IsColoredLight returns true and impacts fragment size IsColoredLight bool // Color of the light, if applicable Color color.RGBA //Attenuation (?) - guess from Windcatcher. Not sure what it is. Attentuation uint32 // contains filtered or unexported fields }
LightSource information
func LoadLightSource ¶
func LoadLightSource(r io.ReadSeeker) (*LightSource, error)
func (*LightSource) FragmentType ¶
func (l *LightSource) FragmentType() string
type LightSourceInstance ¶
type LightSourceInstance struct { HashIndex uint32 Flags uint32 Reference uint32 Position math32.Vector3 Radius float32 }
LightSourceInstance information
func LoadLightSourceInstance ¶
func LoadLightSourceInstance(r io.ReadSeeker) (*LightSourceInstance, error)
func (*LightSourceInstance) FragmentType ¶
func (l *LightSourceInstance) FragmentType() string
type LightSourceReference ¶
type LightSourceReference struct { Reference uint32 // contains filtered or unexported fields }
LightSourceReference information
func LoadLightSourceReference ¶
func LoadLightSourceReference(r io.ReadSeeker) (*LightSourceReference, error)
func (*LightSourceReference) FragmentType ¶
func (l *LightSourceReference) FragmentType() string
type Material ¶
type Material struct { //BitmapInfoReference // ShaderType is the way to render the material ShaderType int // MaterialType is also part of rendering material MaterialType int // IsHandled is used when an alternative character skin is needed IsHandled bool // contains filtered or unexported fields }
Material information
func LoadMaterial ¶
func LoadMaterial(r io.ReadSeeker) (*Material, error)
func (*Material) FragmentType ¶
type MaterialList ¶
type MaterialList struct { MaterialReferences []uint32 // contains filtered or unexported fields }
MaterialList information
func LoadMaterialList ¶
func LoadMaterialList(r io.ReadSeeker) (*MaterialList, error)
func (*MaterialList) FragmentType ¶
func (m *MaterialList) FragmentType() string
type Mesh ¶
type Mesh struct { MaterialReference uint32 AnimationReference uint32 Center math32.Vector3 MaxDistance float32 MinPosition math32.Vector3 MaxPosition math32.Vector3 Verticies []math32.Vector3 TextureUVCoordinates []math32.Vector2 Normals []math32.Vector3 Colors []color.RGBA Indices []*Polygon // contains filtered or unexported fields }
Mesh information
func (*Mesh) FragmentType ¶
type MeshReference ¶
type MeshReference struct { Reference uint32 Name string Position math32.Vector3 Rotation math32.Vector3 Scale math32.Vector3 // contains filtered or unexported fields }
MeshReference information
func LoadMeshReference ¶
func LoadMeshReference(r io.ReadSeeker) (*MeshReference, error)
func (*MeshReference) FragmentType ¶
func (v *MeshReference) FragmentType() string
type ObjectInstance ¶
type ObjectInstance struct { Name string Position math32.Vector3 Rotation math32.Vector3 Scale math32.Vector3 // contains filtered or unexported fields }
ObjectInstance information
func LoadObjectInstance ¶
func LoadObjectInstance(r io.ReadSeeker) (*ObjectInstance, error)
func (*ObjectInstance) FragmentType ¶
func (v *ObjectInstance) FragmentType() string
type ParticleCloud ¶
type ParticleCloud struct {
// contains filtered or unexported fields
}
ParticleCloud information
func LoadParticleCloud ¶
func LoadParticleCloud(r io.ReadSeeker) (*ParticleCloud, error)
func (*ParticleCloud) FragmentType ¶
func (v *ParticleCloud) FragmentType() string
type ParticleSprite ¶
type ParticleSprite struct { Reference uint32 // contains filtered or unexported fields }
ParticleSprite information
func LoadParticleSprite ¶
func LoadParticleSprite(r io.ReadSeeker) (*ParticleSprite, error)
func (*ParticleSprite) FragmentType ¶
func (v *ParticleSprite) FragmentType() string
type ParticleSpriteReference ¶
type ParticleSpriteReference struct { Reference uint32 // contains filtered or unexported fields }
ParticleSpriteReference information
func LoadParticleSpriteReference ¶
func LoadParticleSpriteReference(r io.ReadSeeker) (*ParticleSpriteReference, error)
func (*ParticleSpriteReference) FragmentType ¶
func (v *ParticleSpriteReference) FragmentType() string
type SkeletonReference ¶
type SkeletonReference struct { Reference uint32 FrameMs uint32 // contains filtered or unexported fields }
SkeletonReference information
func LoadSkeletonReference ¶
func LoadSkeletonReference(r io.ReadSeeker) (*SkeletonReference, error)
func (*SkeletonReference) FragmentType ¶
func (v *SkeletonReference) FragmentType() string
type Track ¶
type Track struct { Frames []*BoneTransform // contains filtered or unexported fields }
Track information
func (*Track) FragmentType ¶
type TrackReference ¶
type TrackReference struct { Reference uint32 FrameMs uint32 // contains filtered or unexported fields }
TrackReference information
func LoadTrackReference ¶
func LoadTrackReference(r io.ReadSeeker) (*TrackReference, error)
func (*TrackReference) FragmentType ¶
func (v *TrackReference) FragmentType() string
type VertexColor ¶
type VertexColor struct { // Colors of the vertex, if applicable Colors []color.RGBA // contains filtered or unexported fields }
VertexColor information
func LoadVertexColor ¶
func LoadVertexColor(r io.ReadSeeker) (*VertexColor, error)
func (*VertexColor) FragmentType ¶
func (v *VertexColor) FragmentType() string
type VertexColorReference ¶
type VertexColorReference struct { VertexColor *VertexColor Reference uint32 // contains filtered or unexported fields }
VertexColorReference, Referenced by an ObjectInstance fragment.
func LoadVertexColorReference ¶
func LoadVertexColorReference(r io.ReadSeeker) (*VertexColorReference, error)
func (*VertexColorReference) FragmentType ¶
func (v *VertexColorReference) FragmentType() string
Source Files ¶
- bspregion.go
- fragment.go
- legacymesh.go
- lightinstance.go
- lightsource.go
- lightsourceinstance.go
- lightsourcereference.go
- material.go
- materiallist.go
- materialtype.go
- mesh.go
- meshreference.go
- objectinstance.go
- particlecloud.go
- particlesprite.go
- particlespritereference.go
- polygon.go
- shadertype.go
- skeletonreference.go
- track.go
- trackreference.go
- vertexcolor.go
- vertexcolorreference.go
Click to show internal directories.
Click to hide internal directories.