Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var Stdout io.Writer = nil
Functions ¶
This section is empty.
Types ¶
type Files ¶
Files describe an in-memory file system that contains all files available to the transpiler.
type Options ¶
type Options struct {
// Files to present to the wesl transpiler
Files Files
// Constants to inject into the transpiler.
// Value must be either int, float32 or string
Constants map[string]any
// Conditions for @if etc
Conditions map[string]bool
// PackageName for the local sources (in addition to default "package::").
// Enables imports like `import mypkg::foo` alongside `import package::foo`.
// Should be a valid WGSL identifier (use underscores, not hyphens or slashes).
PackageName string
}
type Transpiler ¶
type Transpiler struct {
// contains filtered or unexported fields
}
func New ¶
func New() *Transpiler
Click to show internal directories.
Click to hide internal directories.