Documentation
¶
Index ¶
- Constants
- func CopyFile(src string, dst string) error
- func Exists(path string) bool
- func IsDir(path string) bool
- func MakeDir(dir string) error
- func WriteFile(path string, data []byte) error
- type ArGLTF
- type ArGLTFBuffer
- type ArGLTFInput
- type ArGLTFMesh
- type ArGLTFTexture
- type ArWGSL
- type ArWGSLShader
- type Archive
- type Basil
- func (p *Basil) AddFile(path string, data []byte)
- func (p *Basil) AddScript(src []byte)
- func (p *Basil) BaseDir() string
- func (p *Basil) Build() error
- func (p *Basil) Clean() error
- func (p *Basil) ConfigJson() string
- func (p *Basil) DistDir() string
- func (p *Basil) Minify() bool
- func (p *Basil) Read() error
- func (p *Basil) SetDir(path string) error
- type Config
- type File
- type Source
Constants ¶
View Source
const ( HasPosition int = 1 << iota HasNormal HasTangent HasTexcoord0 HasBlendWeight0 HasWeightIndices0 HasTexture0 HasTexture1 HasTexture2 HasDoubleSided HasAlphaBlend )
Variables ¶
This section is empty.
Functions ¶
Types ¶
type ArGLTF ¶
type ArGLTF struct {
Buffer []*ArGLTFBuffer `json:"buffer,omitempty"`
Texture []*ArGLTFTexture `json:"texture,omitempty"`
Input []*ArGLTFInput `json:"input,omitempty"`
Mesh map[string]*ArGLTFMesh `json:"mesh,omitempty"`
}
type ArGLTFBuffer ¶
type ArGLTFBuffer struct {
Embed int `json:"embed,omitempty"`
}
type ArGLTFInput ¶
type ArGLTFInput struct {
Count int `json:"count"`
Hint int `json:"hint"`
// Input
VertexBuffer0 []int `json:"vb0,omitempty"` // [buffer, offset, size], slot: 0, shaderLocation: 0, format: float32x3 (position)
VertexBuffer1 []int `json:"vb1,omitempty"` // [buffer, offset, size], slot: 1, shaderLocation: 1, format: float32x3 (normal)
VertexBuffer2 []int `json:"vb2,omitempty"` // [buffer, offset, size], slot: 2, shaderLocation: 2
VertexBuffer3 []int `json:"vb3,omitempty"` // [buffer, offset, size], slot: 3, shaderLocation: 3
VertexBuffer4 []int `json:"vb4,omitempty"` // [buffer, offset, size], slot: 4, shaderLocation: 4
VertexBuffer5 []int `json:"vb5,omitempty"` // [buffer, offset, size], slot: 5, shaderLocation: 5
IndexBuffer []int `json:"ib,omitempty"` // [buffer, offset, size], format: uint16
// Uniform
Factor0 []float64 `json:"factor0,omitempty"` // [Color.r, Color.g, Color.b, Color.a]
Factor1 []float64 `json:"factor1,omitempty"` // [Occlusion, Metallic, Roughness, unused]
Factor2 []float64 `json:"factor2,omitempty"` // [Emissive.r, Emissive.g, Emissive.b, unused]
Texture0 int `json:"texture0,omitempty"` // BaseColorTexture
Texture1 int `json:"texture1,omitempty"` // ParameterTexture(OcclusionMetallicRoughness)
Texture2 int `json:"texture2,omitempty"` // NormalTexture
}
type ArGLTFMesh ¶
type ArGLTFMesh struct {
Input []int `json:"input"`
}
type ArGLTFTexture ¶
type ArGLTFTexture struct {
Embed int `json:"embed,omitempty"`
}
type ArWGSL ¶
type ArWGSL struct {
Shader []*ArWGSLShader `json:"shader,omitempty"`
}
type ArWGSLShader ¶
type ArWGSLShader struct {
Embed int `json:"embed,omitempty"`
}
type Basil ¶
type Basil struct {
// contains filtered or unexported fields
}
func (*Basil) ConfigJson ¶
type Config ¶
Click to show internal directories.
Click to hide internal directories.