A helper library for defining wgsl shaders, typically for use with the
rust wgsl library.
util/- utility code that does not depend on internally defined structures.shared- RheSharedtype helps defer choice betweenRcandArc.
model/- crate-public static-lifetime models of declared structuresapi/- public definitions with nice lifetime annotationsproject.rs- top-level project encapsulationshader.rs- top-level shader encapsulationentry_point.rs- top-level entrypoint encapsulationdata_type/- type-mappings from rust types to classes of wgsl typesbuilder/- procedural builder API for constructing shadershandle/- lifetime-annotated model handles for use within builders.
printer- the code to generate pretty wgsl text from a model.
The general expectation is that things in model/ share their underlying
contents and are cloneable, and have static lifetime.
Likewise, the top-level Project and Shader and EntryPoint types are
static-lifetime values that share their underlying data and can be cloned.
The types in api/builder/ however, use lifetimes to constrain the mixing
of declarations and enforce scope-compliance.