1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
//! Pipeline Management and Shader Compilation
//!
//! This module manages shader compilation and render pipeline state:
//!
//! - [`PipelineCache`]: Two-level pipeline cache (L1 fast lookup + L2 canonical cache)
//! - [`PipelineKey`]: Unique identifier for pipeline configurations
//! - Vertex layout generation
//! - Shader template compilation with macro preprocessing
//!
//! # Caching Strategy
//!
//! The pipeline cache uses a two-level strategy:
//!
//! - **L1 Cache**: Fast hash-based lookup for common pipeline configurations
//! - **L2 Cache**: Canonical storage indexed by full pipeline descriptor
//!
//! This approach minimizes shader recompilation while supporting dynamic
//! shader macro combinations from materials.
//!
//! # Shader System
//!
//! Shaders use a template system with Jinja2-style macros:
//!
//! ```wgsl
//! {% if HAS_NORMAL_MAP %}
//! let normal = sample_normal_map(...);
//! {% endif %}
//! ```
//!
//! Materials declare their required macros via `shader_defines()`, which
//! are passed to the shader compiler.
pub use ;
pub use ;
pub use ;
pub use ShaderCompilationOptions;
pub use ;