@forgeax/engine-render 0.0.0-dev.8d955ade1c79
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +202 -0
- package/README.md +647 -0
- package/dist/.tsbuildinfo +1 -0
- package/dist/__tests__/authoring-path.unit.test.d.ts +2 -0
- package/dist/__tests__/authoring-path.unit.test.d.ts.map +1 -0
- package/dist/__tests__/backend-selection-rhi-capture.test-d.d.ts +2 -0
- package/dist/__tests__/backend-selection-rhi-capture.test-d.d.ts.map +1 -0
- package/dist/__tests__/callback-inference.test-d.d.ts +2 -0
- package/dist/__tests__/callback-inference.test-d.d.ts.map +1 -0
- package/dist/__tests__/cluster-binner.test.d.ts +2 -0
- package/dist/__tests__/cluster-binner.test.d.ts.map +1 -0
- package/dist/__tests__/cluster-grid-default-surface.unit.test.d.ts +2 -0
- package/dist/__tests__/cluster-grid-default-surface.unit.test.d.ts.map +1 -0
- package/dist/__tests__/construct-renderer-identity.unit.test.d.ts +2 -0
- package/dist/__tests__/construct-renderer-identity.unit.test.d.ts.map +1 -0
- package/dist/__tests__/device-scope-lifecycle.unit.test.d.ts +2 -0
- package/dist/__tests__/device-scope-lifecycle.unit.test.d.ts.map +1 -0
- package/dist/__tests__/device-scope-stale-matrix.unit.test.d.ts +2 -0
- package/dist/__tests__/device-scope-stale-matrix.unit.test.d.ts.map +1 -0
- package/dist/__tests__/direct-extract-consumer-contract.test-d.d.ts +2 -0
- package/dist/__tests__/direct-extract-consumer-contract.test-d.d.ts.map +1 -0
- package/dist/__tests__/direct-light-snapshot.unit.test.d.ts +2 -0
- package/dist/__tests__/direct-light-snapshot.unit.test.d.ts.map +1 -0
- package/dist/__tests__/factory-contract.integration.test.d.ts +2 -0
- package/dist/__tests__/factory-contract.integration.test.d.ts.map +1 -0
- package/dist/__tests__/fallback-row-stride-surface.unit.test.d.ts +2 -0
- package/dist/__tests__/fallback-row-stride-surface.unit.test.d.ts.map +1 -0
- package/dist/__tests__/frame-observation.contract.test.d.ts +2 -0
- package/dist/__tests__/frame-observation.contract.test.d.ts.map +1 -0
- package/dist/__tests__/fullscreen-feature-plan.unit.test.d.ts +2 -0
- package/dist/__tests__/fullscreen-feature-plan.unit.test.d.ts.map +1 -0
- package/dist/__tests__/glyph-text-layout-recovery.unit.test.d.ts +2 -0
- package/dist/__tests__/glyph-text-layout-recovery.unit.test.d.ts.map +1 -0
- package/dist/__tests__/gpu-driven-indirect-raster-evidence.d.ts +6 -0
- package/dist/__tests__/gpu-driven-indirect-raster-evidence.d.ts.map +1 -0
- package/dist/__tests__/gpu-driven-indirect-raster.browser.test.d.ts +2 -0
- package/dist/__tests__/gpu-driven-indirect-raster.browser.test.d.ts.map +1 -0
- package/dist/__tests__/gpu-driven-indirect-raster.dawn.test.d.ts +2 -0
- package/dist/__tests__/gpu-driven-indirect-raster.dawn.test.d.ts.map +1 -0
- package/dist/__tests__/gpu-driven-production.integration.test.d.ts +2 -0
- package/dist/__tests__/gpu-driven-production.integration.test.d.ts.map +1 -0
- package/dist/__tests__/gpu-driven-scaling.unit.test.d.ts +2 -0
- package/dist/__tests__/gpu-driven-scaling.unit.test.d.ts.map +1 -0
- package/dist/__tests__/gpu-driven-view-gpu-evidence.d.ts +18 -0
- package/dist/__tests__/gpu-driven-view-gpu-evidence.d.ts.map +1 -0
- package/dist/__tests__/gpu-driven-view-graph.integration.test.d.ts +2 -0
- package/dist/__tests__/gpu-driven-view-graph.integration.test.d.ts.map +1 -0
- package/dist/__tests__/gpu-driven-view-reference.d.ts +15 -0
- package/dist/__tests__/gpu-driven-view-reference.d.ts.map +1 -0
- package/dist/__tests__/gpu-driven-view.browser.test.d.ts +2 -0
- package/dist/__tests__/gpu-driven-view.browser.test.d.ts.map +1 -0
- package/dist/__tests__/gpu-driven-view.dawn.test.d.ts +2 -0
- package/dist/__tests__/gpu-driven-view.dawn.test.d.ts.map +1 -0
- package/dist/__tests__/gpu-driven-view.unit.test.d.ts +2 -0
- package/dist/__tests__/gpu-driven-view.unit.test.d.ts.map +1 -0
- package/dist/__tests__/gpu-resource-store-stride.unit.test.d.ts +2 -0
- package/dist/__tests__/gpu-resource-store-stride.unit.test.d.ts.map +1 -0
- package/dist/__tests__/gpu-scene-render-graph-gpu.d.ts +7 -0
- package/dist/__tests__/gpu-scene-render-graph-gpu.d.ts.map +1 -0
- package/dist/__tests__/gpu-scene-render-graph.browser.test.d.ts +2 -0
- package/dist/__tests__/gpu-scene-render-graph.browser.test.d.ts.map +1 -0
- package/dist/__tests__/gpu-scene-render-graph.dawn.test.d.ts +2 -0
- package/dist/__tests__/gpu-scene-render-graph.dawn.test.d.ts.map +1 -0
- package/dist/__tests__/gpu-scene-schema.unit.test.d.ts +2 -0
- package/dist/__tests__/gpu-scene-schema.unit.test.d.ts.map +1 -0
- package/dist/__tests__/gpu-scene.dawn.test.d.ts +2 -0
- package/dist/__tests__/gpu-scene.dawn.test.d.ts.map +1 -0
- package/dist/__tests__/gpu-scene.unit.test.d.ts +2 -0
- package/dist/__tests__/gpu-scene.unit.test.d.ts.map +1 -0
- package/dist/__tests__/ibl/face-uniforms.unit.test.d.ts +2 -0
- package/dist/__tests__/ibl/face-uniforms.unit.test.d.ts.map +1 -0
- package/dist/__tests__/infinite-grid-no-vertex-probe.unit.test.d.ts +2 -0
- package/dist/__tests__/infinite-grid-no-vertex-probe.unit.test.d.ts.map +1 -0
- package/dist/__tests__/injection-kind-owner.test-d.d.ts +2 -0
- package/dist/__tests__/injection-kind-owner.test-d.d.ts.map +1 -0
- package/dist/__tests__/ktx2-basis-gpu-consumer.dawn.test.d.ts +2 -0
- package/dist/__tests__/ktx2-basis-gpu-consumer.dawn.test.d.ts.map +1 -0
- package/dist/__tests__/light-buffer-layout.unit.test.d.ts +2 -0
- package/dist/__tests__/light-buffer-layout.unit.test.d.ts.map +1 -0
- package/dist/__tests__/material-contract-inventory.unit.test.d.ts +2 -0
- package/dist/__tests__/material-contract-inventory.unit.test.d.ts.map +1 -0
- package/dist/__tests__/material-cooked-projection.unit.test.d.ts +2 -0
- package/dist/__tests__/material-cooked-projection.unit.test.d.ts.map +1 -0
- package/dist/__tests__/material-snapshot-mutation.integration.test.d.ts +2 -0
- package/dist/__tests__/material-snapshot-mutation.integration.test.d.ts.map +1 -0
- package/dist/__tests__/material-static-dynamic-route.unit.test.d.ts +2 -0
- package/dist/__tests__/material-static-dynamic-route.unit.test.d.ts.map +1 -0
- package/dist/__tests__/material-stride-surface.unit.test.d.ts +2 -0
- package/dist/__tests__/material-stride-surface.unit.test.d.ts.map +1 -0
- package/dist/__tests__/mesh-buffer-usage-surface.unit.test.d.ts +2 -0
- package/dist/__tests__/mesh-buffer-usage-surface.unit.test.d.ts.map +1 -0
- package/dist/__tests__/mesh-material-bindings.unit.test.d.ts +2 -0
- package/dist/__tests__/mesh-material-bindings.unit.test.d.ts.map +1 -0
- package/dist/__tests__/mesh-stride-surface.unit.test.d.ts +2 -0
- package/dist/__tests__/mesh-stride-surface.unit.test.d.ts.map +1 -0
- package/dist/__tests__/morph-culling-reentry.dawn.test.d.ts +2 -0
- package/dist/__tests__/morph-culling-reentry.dawn.test.d.ts.map +1 -0
- package/dist/__tests__/morph-feature-gpu-work.integration.test.d.ts +2 -0
- package/dist/__tests__/morph-feature-gpu-work.integration.test.d.ts.map +1 -0
- package/dist/__tests__/morph-feature-plan.unit.test.d.ts +2 -0
- package/dist/__tests__/morph-feature-plan.unit.test.d.ts.map +1 -0
- package/dist/__tests__/morph-visual-evidence.integration.test.d.ts +2 -0
- package/dist/__tests__/morph-visual-evidence.integration.test.d.ts.map +1 -0
- package/dist/__tests__/nineslice-handle-surface.unit.test.d.ts +2 -0
- package/dist/__tests__/nineslice-handle-surface.unit.test.d.ts.map +1 -0
- package/dist/__tests__/post-process-error-policy-owner.unit.test.d.ts +2 -0
- package/dist/__tests__/post-process-error-policy-owner.unit.test.d.ts.map +1 -0
- package/dist/__tests__/prepared-buffer-kind-owner.test-d.d.ts +2 -0
- package/dist/__tests__/prepared-buffer-kind-owner.test-d.d.ts.map +1 -0
- package/dist/__tests__/prepared-graphics-capability.unit.test.d.ts +2 -0
- package/dist/__tests__/prepared-graphics-capability.unit.test.d.ts.map +1 -0
- package/dist/__tests__/prepared-graphics-generation.unit.test.d.ts +2 -0
- package/dist/__tests__/prepared-graphics-generation.unit.test.d.ts.map +1 -0
- package/dist/__tests__/prepared-graphics-lifecycle.unit.test.d.ts +2 -0
- package/dist/__tests__/prepared-graphics-lifecycle.unit.test.d.ts.map +1 -0
- package/dist/__tests__/prepared-graphics-pipeline-warmup.unit.test.d.ts +2 -0
- package/dist/__tests__/prepared-graphics-pipeline-warmup.unit.test.d.ts.map +1 -0
- package/dist/__tests__/prepared-graphics-resolver.unit.test.d.ts +2 -0
- package/dist/__tests__/prepared-graphics-resolver.unit.test.d.ts.map +1 -0
- package/dist/__tests__/prepared-graphics-snapshot.unit.test.d.ts +2 -0
- package/dist/__tests__/prepared-graphics-snapshot.unit.test.d.ts.map +1 -0
- package/dist/__tests__/prepared-graphics-store.unit.test.d.ts +2 -0
- package/dist/__tests__/prepared-graphics-store.unit.test.d.ts.map +1 -0
- package/dist/__tests__/prepared-graphics-validation.unit.test.d.ts +2 -0
- package/dist/__tests__/prepared-graphics-validation.unit.test.d.ts.map +1 -0
- package/dist/__tests__/profiler-default-off.test.d.ts +2 -0
- package/dist/__tests__/profiler-default-off.test.d.ts.map +1 -0
- package/dist/__tests__/profiler-phase-catalog.test.d.ts +2 -0
- package/dist/__tests__/profiler-phase-catalog.test.d.ts.map +1 -0
- package/dist/__tests__/profiler-phase-integration.test.d.ts +2 -0
- package/dist/__tests__/profiler-phase-integration.test.d.ts.map +1 -0
- package/dist/__tests__/profiler-phase-token.test.d.ts +2 -0
- package/dist/__tests__/profiler-phase-token.test.d.ts.map +1 -0
- package/dist/__tests__/public-surface.test-d.d.ts +2 -0
- package/dist/__tests__/public-surface.test-d.d.ts.map +1 -0
- package/dist/__tests__/recover-error-policy-owner.unit.test.d.ts +2 -0
- package/dist/__tests__/recover-error-policy-owner.unit.test.d.ts.map +1 -0
- package/dist/__tests__/render-error-code-owner.test-d.d.ts +2 -0
- package/dist/__tests__/render-error-code-owner.test-d.d.ts.map +1 -0
- package/dist/__tests__/render-error-detail-ssot.test-d.d.ts +2 -0
- package/dist/__tests__/render-error-detail-ssot.test-d.d.ts.map +1 -0
- package/dist/__tests__/render-error-exhaustive.test-d.d.ts +2 -0
- package/dist/__tests__/render-error-exhaustive.test-d.d.ts.map +1 -0
- package/dist/__tests__/render-feature-assembly.test-d.d.ts +2 -0
- package/dist/__tests__/render-feature-assembly.test-d.d.ts.map +1 -0
- package/dist/__tests__/render-feature-context.test-d.d.ts +2 -0
- package/dist/__tests__/render-feature-context.test-d.d.ts.map +1 -0
- package/dist/__tests__/render-feature-contract.test-d.d.ts +2 -0
- package/dist/__tests__/render-feature-contract.test-d.d.ts.map +1 -0
- package/dist/__tests__/render-feature-diagnostics.unit.test.d.ts +2 -0
- package/dist/__tests__/render-feature-diagnostics.unit.test.d.ts.map +1 -0
- package/dist/__tests__/render-feature-docs.unit.test.d.ts +2 -0
- package/dist/__tests__/render-feature-docs.unit.test.d.ts.map +1 -0
- package/dist/__tests__/render-feature-errors.unit.test.d.ts +2 -0
- package/dist/__tests__/render-feature-errors.unit.test.d.ts.map +1 -0
- package/dist/__tests__/render-feature-gpu-work.integration.test.d.ts +2 -0
- package/dist/__tests__/render-feature-gpu-work.integration.test.d.ts.map +1 -0
- package/dist/__tests__/render-feature-plan.test-d.d.ts +2 -0
- package/dist/__tests__/render-feature-plan.test-d.d.ts.map +1 -0
- package/dist/__tests__/render-feature-plan.unit.test.d.ts +2 -0
- package/dist/__tests__/render-feature-plan.unit.test.d.ts.map +1 -0
- package/dist/__tests__/render-feature-prepared-diagnostics.unit.test.d.ts +2 -0
- package/dist/__tests__/render-feature-prepared-diagnostics.unit.test.d.ts.map +1 -0
- package/dist/__tests__/render-feature-prepared-errors.test-d.d.ts +2 -0
- package/dist/__tests__/render-feature-prepared-errors.test-d.d.ts.map +1 -0
- package/dist/__tests__/render-feature-prepared-graphics-docs.unit.test.d.ts +2 -0
- package/dist/__tests__/render-feature-prepared-graphics-docs.unit.test.d.ts.map +1 -0
- package/dist/__tests__/render-feature-prepared-graphics-isolation.unit.test.d.ts +2 -0
- package/dist/__tests__/render-feature-prepared-graphics-isolation.unit.test.d.ts.map +1 -0
- package/dist/__tests__/render-feature-prepared-graphics-negative.test-d.d.ts +2 -0
- package/dist/__tests__/render-feature-prepared-graphics-negative.test-d.d.ts.map +1 -0
- package/dist/__tests__/render-feature-prepared-graphics.test-d.d.ts +2 -0
- package/dist/__tests__/render-feature-prepared-graphics.test-d.d.ts.map +1 -0
- package/dist/__tests__/render-feature-prepared-graphics.unit.test.d.ts +2 -0
- package/dist/__tests__/render-feature-prepared-graphics.unit.test.d.ts.map +1 -0
- package/dist/__tests__/render-feature-public-surface.test-d.d.ts +2 -0
- package/dist/__tests__/render-feature-public-surface.test-d.d.ts.map +1 -0
- package/dist/__tests__/render-feature-retry.unit.test.d.ts +2 -0
- package/dist/__tests__/render-feature-retry.unit.test.d.ts.map +1 -0
- package/dist/__tests__/render-feature-scheduling.unit.test.d.ts +2 -0
- package/dist/__tests__/render-feature-scheduling.unit.test.d.ts.map +1 -0
- package/dist/__tests__/render-feature-stage-failed-policy-owner.unit.test.d.ts +2 -0
- package/dist/__tests__/render-feature-stage-failed-policy-owner.unit.test.d.ts.map +1 -0
- package/dist/__tests__/render-feature-stage-fault-recovery.unit.test.d.ts +2 -0
- package/dist/__tests__/render-feature-stage-fault-recovery.unit.test.d.ts.map +1 -0
- package/dist/__tests__/render-feature-visibility-context.test-d.d.ts +2 -0
- package/dist/__tests__/render-feature-visibility-context.test-d.d.ts.map +1 -0
- package/dist/__tests__/render-feature-visibility-context.unit.test.d.ts +2 -0
- package/dist/__tests__/render-feature-visibility-context.unit.test.d.ts.map +1 -0
- package/dist/__tests__/render-feature-zero-work.unit.test.d.ts +2 -0
- package/dist/__tests__/render-feature-zero-work.unit.test.d.ts.map +1 -0
- package/dist/__tests__/render-graph-compute-raster-gpu.d.ts +7 -0
- package/dist/__tests__/render-graph-compute-raster-gpu.d.ts.map +1 -0
- package/dist/__tests__/render-graph-compute-raster.browser.test.d.ts +2 -0
- package/dist/__tests__/render-graph-compute-raster.browser.test.d.ts.map +1 -0
- package/dist/__tests__/render-graph-compute-raster.dawn.test.d.ts +2 -0
- package/dist/__tests__/render-graph-compute-raster.dawn.test.d.ts.map +1 -0
- package/dist/__tests__/render-graph-hzb-gpu.d.ts +7 -0
- package/dist/__tests__/render-graph-hzb-gpu.d.ts.map +1 -0
- package/dist/__tests__/render-graph-hzb.browser.test.d.ts +2 -0
- package/dist/__tests__/render-graph-hzb.browser.test.d.ts.map +1 -0
- package/dist/__tests__/render-graph-hzb.dawn.test.d.ts +2 -0
- package/dist/__tests__/render-graph-hzb.dawn.test.d.ts.map +1 -0
- package/dist/__tests__/render-graph-primitives.unit.test.d.ts +2 -0
- package/dist/__tests__/render-graph-primitives.unit.test.d.ts.map +1 -0
- package/dist/__tests__/render-graph-storage-indirect-gpu.d.ts +12 -0
- package/dist/__tests__/render-graph-storage-indirect-gpu.d.ts.map +1 -0
- package/dist/__tests__/render-graph-storage-indirect.browser.test.d.ts +2 -0
- package/dist/__tests__/render-graph-storage-indirect.browser.test.d.ts.map +1 -0
- package/dist/__tests__/render-graph-storage-indirect.dawn.test.d.ts +2 -0
- package/dist/__tests__/render-graph-storage-indirect.dawn.test.d.ts.map +1 -0
- package/dist/__tests__/render-scene-projection.unit.test.d.ts +2 -0
- package/dist/__tests__/render-scene-projection.unit.test.d.ts.map +1 -0
- package/dist/__tests__/renderer-factory-material-contract.unit.test.d.ts +2 -0
- package/dist/__tests__/renderer-factory-material-contract.unit.test.d.ts.map +1 -0
- package/dist/__tests__/renderer-lifecycle.integration.test.d.ts +2 -0
- package/dist/__tests__/renderer-lifecycle.integration.test.d.ts.map +1 -0
- package/dist/__tests__/rhi-backend-package-boundary.unit.test.d.ts +2 -0
- package/dist/__tests__/rhi-backend-package-boundary.unit.test.d.ts.map +1 -0
- package/dist/__tests__/scriptable-pack-consumer.test-d.d.ts +2 -0
- package/dist/__tests__/scriptable-pack-consumer.test-d.d.ts.map +1 -0
- package/dist/__tests__/shader-stage-surface.unit.test.d.ts +2 -0
- package/dist/__tests__/shader-stage-surface.unit.test.d.ts.map +1 -0
- package/dist/__tests__/ssao-config.unit.test.d.ts +2 -0
- package/dist/__tests__/ssao-config.unit.test.d.ts.map +1 -0
- package/dist/__tests__/ssao-kernel-surface.unit.test.d.ts +2 -0
- package/dist/__tests__/ssao-kernel-surface.unit.test.d.ts.map +1 -0
- package/dist/__tests__/standard-clustered-pipeline.unit.test.d.ts +2 -0
- package/dist/__tests__/standard-clustered-pipeline.unit.test.d.ts.map +1 -0
- package/dist/__tests__/standard-descriptors.test-d.d.ts +2 -0
- package/dist/__tests__/standard-descriptors.test-d.d.ts.map +1 -0
- package/dist/__tests__/standard-pipeline.dawn.test.d.ts +2 -0
- package/dist/__tests__/standard-pipeline.dawn.test.d.ts.map +1 -0
- package/dist/__tests__/standard-pipeline.integration.test.d.ts +2 -0
- package/dist/__tests__/standard-pipeline.integration.test.d.ts.map +1 -0
- package/dist/__tests__/standard-profile-oracle.unit.test.d.ts +2 -0
- package/dist/__tests__/standard-profile-oracle.unit.test.d.ts.map +1 -0
- package/dist/__tests__/surface-configuration.unit.test.d.ts +2 -0
- package/dist/__tests__/surface-configuration.unit.test.d.ts.map +1 -0
- package/dist/__tests__/texture-usage-surface.unit.test.d.ts +2 -0
- package/dist/__tests__/texture-usage-surface.unit.test.d.ts.map +1 -0
- package/dist/__tests__/typed-pipeline-topology.unit.test.d.ts +2 -0
- package/dist/__tests__/typed-pipeline-topology.unit.test.d.ts.map +1 -0
- package/dist/__tests__/urp-pipeline-targets.unit.test.d.ts +2 -0
- package/dist/__tests__/urp-pipeline-targets.unit.test.d.ts.map +1 -0
- package/dist/__tests__/urp-pipeline.unit.test.d.ts +2 -0
- package/dist/__tests__/urp-pipeline.unit.test.d.ts.map +1 -0
- package/dist/__tests__/vertex-color-pipeline.unit.test.d.ts +2 -0
- package/dist/__tests__/vertex-color-pipeline.unit.test.d.ts.map +1 -0
- package/dist/__tests__/vertex-layout-consumer.unit.test.d.ts +2 -0
- package/dist/__tests__/vertex-layout-consumer.unit.test.d.ts.map +1 -0
- package/dist/__tests__/visibility-diagnostics.integration.test.d.ts +2 -0
- package/dist/__tests__/visibility-diagnostics.integration.test.d.ts.map +1 -0
- package/dist/__tests__/visibility-extract.integration.test.d.ts +2 -0
- package/dist/__tests__/visibility-extract.integration.test.d.ts.map +1 -0
- package/dist/__tests__/visibility-extract.perf.test.d.ts +2 -0
- package/dist/__tests__/visibility-extract.perf.test.d.ts.map +1 -0
- package/dist/__tests__/visibility-feature-dedup.integration.test.d.ts +2 -0
- package/dist/__tests__/visibility-feature-dedup.integration.test.d.ts.map +1 -0
- package/dist/__tests__/visibility-hidden-report.unit.test.d.ts +2 -0
- package/dist/__tests__/visibility-hidden-report.unit.test.d.ts.map +1 -0
- package/dist/__tests__/visibility-instances.integration.test.d.ts +2 -0
- package/dist/__tests__/visibility-instances.integration.test.d.ts.map +1 -0
- package/dist/__tests__/visibility-multi-world.integration.test.d.ts +2 -0
- package/dist/__tests__/visibility-multi-world.integration.test.d.ts.map +1 -0
- package/dist/__tests__/visibility-producer-matrix.integration.test.d.ts +2 -0
- package/dist/__tests__/visibility-producer-matrix.integration.test.d.ts.map +1 -0
- package/dist/__tests__/visibility-producer-matrix.unit.test.d.ts +2 -0
- package/dist/__tests__/visibility-producer-matrix.unit.test.d.ts.map +1 -0
- package/dist/__tests__/visibility-public-surface.test-d.d.ts +2 -0
- package/dist/__tests__/visibility-public-surface.test-d.d.ts.map +1 -0
- package/dist/__tests__/visibility-resolver.unit.test.d.ts +2 -0
- package/dist/__tests__/visibility-resolver.unit.test.d.ts.map +1 -0
- package/dist/__tests__/visibility-resource-short-circuit.unit.test.d.ts +2 -0
- package/dist/__tests__/visibility-resource-short-circuit.unit.test.d.ts.map +1 -0
- package/dist/__tests__/visibility-snapshot-contract.unit.test.d.ts +2 -0
- package/dist/__tests__/visibility-snapshot-contract.unit.test.d.ts.map +1 -0
- package/dist/__tests__/vocabulary.unit.test.d.ts +2 -0
- package/dist/__tests__/vocabulary.unit.test.d.ts.map +1 -0
- package/dist/assembly/backend-contract.d.ts +37 -0
- package/dist/assembly/backend-contract.d.ts.map +1 -0
- package/dist/assembly/factory.d.ts +207 -0
- package/dist/assembly/factory.d.ts.map +1 -0
- package/dist/assembly/host-contract.d.ts +84 -0
- package/dist/assembly/host-contract.d.ts.map +1 -0
- package/dist/assembly/material/assembly.d.ts +21 -0
- package/dist/assembly/material/assembly.d.ts.map +1 -0
- package/dist/assembly/material/pipeline-projection.d.ts +30 -0
- package/dist/assembly/material/pipeline-projection.d.ts.map +1 -0
- package/dist/assets/asset-decoders.d.ts +5 -0
- package/dist/assets/asset-decoders.d.ts.map +1 -0
- package/dist/assets/render-asset-port.d.ts +17 -0
- package/dist/assets/render-asset-port.d.ts.map +1 -0
- package/dist/assets/resolve-render-asset.d.ts +6 -0
- package/dist/assets/resolve-render-asset.d.ts.map +1 -0
- package/dist/authoring.d.ts +12 -0
- package/dist/authoring.d.ts.map +1 -0
- package/dist/authoring.mjs +27 -0
- package/dist/authoring.mjs.map +1 -0
- package/dist/chunk-CQXZC5XI.mjs +182 -0
- package/dist/chunk-CQXZC5XI.mjs.map +1 -0
- package/dist/chunk-HCOGPHKS.mjs +93 -0
- package/dist/chunk-HCOGPHKS.mjs.map +1 -0
- package/dist/chunk-YEJIUW7D.mjs +1152 -0
- package/dist/chunk-YEJIUW7D.mjs.map +1 -0
- package/dist/cluster-binner.d.ts +152 -0
- package/dist/cluster-binner.d.ts.map +1 -0
- package/dist/components/__tests__/points-lines-admission.unit.test.d.ts +2 -0
- package/dist/components/__tests__/points-lines-admission.unit.test.d.ts.map +1 -0
- package/dist/components/__tests__/points-lines-schema.unit.test.d.ts +2 -0
- package/dist/components/__tests__/points-lines-schema.unit.test.d.ts.map +1 -0
- package/dist/components/__tests__/schema-contract.unit.test.d.ts +2 -0
- package/dist/components/__tests__/schema-contract.unit.test.d.ts.map +1 -0
- package/dist/components/__tests__/schema-parity.unit.test.d.ts +2 -0
- package/dist/components/__tests__/schema-parity.unit.test.d.ts.map +1 -0
- package/dist/components/__tests__/visibility-schema.unit.test.d.ts +2 -0
- package/dist/components/__tests__/visibility-schema.unit.test.d.ts.map +1 -0
- package/dist/components/camera.d.ts +311 -0
- package/dist/components/camera.d.ts.map +1 -0
- package/dist/components/directional-light.d.ts +76 -0
- package/dist/components/directional-light.d.ts.map +1 -0
- package/dist/components/glyph-text.d.ts +26 -0
- package/dist/components/glyph-text.d.ts.map +1 -0
- package/dist/components/index.d.ts +24 -0
- package/dist/components/index.d.ts.map +1 -0
- package/dist/components/instances.d.ts +41 -0
- package/dist/components/instances.d.ts.map +1 -0
- package/dist/components/layer.d.ts +34 -0
- package/dist/components/layer.d.ts.map +1 -0
- package/dist/components/light-helpers.d.ts +53 -0
- package/dist/components/light-helpers.d.ts.map +1 -0
- package/dist/components/lines.d.ts +5 -0
- package/dist/components/lines.d.ts.map +1 -0
- package/dist/components/mesh-filter.d.ts +24 -0
- package/dist/components/mesh-filter.d.ts.map +1 -0
- package/dist/components/mesh-renderer.d.ts +33 -0
- package/dist/components/mesh-renderer.d.ts.map +1 -0
- package/dist/components/point-light-shadow.d.ts +27 -0
- package/dist/components/point-light-shadow.d.ts.map +1 -0
- package/dist/components/point-light.d.ts +35 -0
- package/dist/components/point-light.d.ts.map +1 -0
- package/dist/components/points.d.ts +15 -0
- package/dist/components/points.d.ts.map +1 -0
- package/dist/components/post-process-params.d.ts +5 -0
- package/dist/components/post-process-params.d.ts.map +1 -0
- package/dist/components/scene-instance.d.ts +140 -0
- package/dist/components/scene-instance.d.ts.map +1 -0
- package/dist/components/skybox-background.d.ts +56 -0
- package/dist/components/skybox-background.d.ts.map +1 -0
- package/dist/components/skylight.d.ts +55 -0
- package/dist/components/skylight.d.ts.map +1 -0
- package/dist/components/sort-key.d.ts +44 -0
- package/dist/components/sort-key.d.ts.map +1 -0
- package/dist/components/spot-light.d.ts +81 -0
- package/dist/components/spot-light.d.ts.map +1 -0
- package/dist/components/sprite-animation.d.ts +74 -0
- package/dist/components/sprite-animation.d.ts.map +1 -0
- package/dist/components/sprite-instances.d.ts +51 -0
- package/dist/components/sprite-instances.d.ts.map +1 -0
- package/dist/components/sprite-playback-mode.d.ts +42 -0
- package/dist/components/sprite-playback-mode.d.ts.map +1 -0
- package/dist/components/sprite-region-override.d.ts +46 -0
- package/dist/components/sprite-region-override.d.ts.map +1 -0
- package/dist/components/tile-layer.d.ts +106 -0
- package/dist/components/tile-layer.d.ts.map +1 -0
- package/dist/components/tilemap.d.ts +25 -0
- package/dist/components/tilemap.d.ts.map +1 -0
- package/dist/components/visibility.d.ts +22 -0
- package/dist/components/visibility.d.ts.map +1 -0
- package/dist/construct-renderer.d.ts +19 -0
- package/dist/construct-renderer.d.ts.map +1 -0
- package/dist/construct-renderer.mjs +27462 -0
- package/dist/construct-renderer.mjs.map +1 -0
- package/dist/debug-draw-glue.d.ts +5 -0
- package/dist/debug-draw-glue.d.ts.map +1 -0
- package/dist/device/device-scope.d.ts +83 -0
- package/dist/device/device-scope.d.ts.map +1 -0
- package/dist/device/gpu-residency.d.ts +337 -0
- package/dist/device/gpu-residency.d.ts.map +1 -0
- package/dist/device/resource-types.d.ts +8 -0
- package/dist/device/resource-types.d.ts.map +1 -0
- package/dist/engine-metrics.d.ts +23 -0
- package/dist/engine-metrics.d.ts.map +1 -0
- package/dist/errors/ecs-validation.d.ts +3 -0
- package/dist/errors/ecs-validation.d.ts.map +1 -0
- package/dist/errors/index.d.ts +4 -0
- package/dist/errors/index.d.ts.map +1 -0
- package/dist/errors/recover.d.ts +105 -0
- package/dist/errors/recover.d.ts.map +1 -0
- package/dist/errors/render.d.ts +705 -0
- package/dist/errors/render.d.ts.map +1 -0
- package/dist/extract/visibility.d.ts +26 -0
- package/dist/extract/visibility.d.ts.map +1 -0
- package/dist/features/fullscreen.d.ts +19 -0
- package/dist/features/fullscreen.d.ts.map +1 -0
- package/dist/features/host.d.ts +106 -0
- package/dist/features/host.d.ts.map +1 -0
- package/dist/features/morph/morph-feature.d.ts +79 -0
- package/dist/features/morph/morph-feature.d.ts.map +1 -0
- package/dist/features/plan.d.ts +182 -0
- package/dist/features/plan.d.ts.map +1 -0
- package/dist/features/prepared-gpu-work.d.ts +117 -0
- package/dist/features/prepared-gpu-work.d.ts.map +1 -0
- package/dist/features/prepared-graphics-store.d.ts +66 -0
- package/dist/features/prepared-graphics-store.d.ts.map +1 -0
- package/dist/features/prepared-graphics.d.ts +215 -0
- package/dist/features/prepared-graphics.d.ts.map +1 -0
- package/dist/features/render-graph-compute.d.ts +13 -0
- package/dist/features/render-graph-compute.d.ts.map +1 -0
- package/dist/features/render-graph-contribution.d.ts +12 -0
- package/dist/features/render-graph-contribution.d.ts.map +1 -0
- package/dist/features/render-graph-raster.d.ts +38 -0
- package/dist/features/render-graph-raster.d.ts.map +1 -0
- package/dist/features/render-graph-resources.d.ts +11 -0
- package/dist/features/render-graph-resources.d.ts.map +1 -0
- package/dist/features/targets.d.ts +32 -0
- package/dist/features/targets.d.ts.map +1 -0
- package/dist/features/types.d.ts +68 -0
- package/dist/features/types.d.ts.map +1 -0
- package/dist/features/vocabulary.d.ts +14 -0
- package/dist/features/vocabulary.d.ts.map +1 -0
- package/dist/fullscreen-post-process-pass.d.ts +157 -0
- package/dist/fullscreen-post-process-pass.d.ts.map +1 -0
- package/dist/glyph-text-layout-system.d.ts +19 -0
- package/dist/glyph-text-layout-system.d.ts.map +1 -0
- package/dist/gpu-driven/batch-topology.d.ts +55 -0
- package/dist/gpu-driven/batch-topology.d.ts.map +1 -0
- package/dist/gpu-driven/production-raster.d.ts +51 -0
- package/dist/gpu-driven/production-raster.d.ts.map +1 -0
- package/dist/gpu-driven/view-gpu.d.ts +85 -0
- package/dist/gpu-driven/view-gpu.d.ts.map +1 -0
- package/dist/gpu-resource.d.ts +73 -0
- package/dist/gpu-resource.d.ts.map +1 -0
- package/dist/gpu-scene-schema.d.ts +78 -0
- package/dist/gpu-scene-schema.d.ts.map +1 -0
- package/dist/gpu-scene.d.ts +55 -0
- package/dist/gpu-scene.d.ts.map +1 -0
- package/dist/gpu-stage.d.ts +4 -0
- package/dist/gpu-stage.d.ts.map +1 -0
- package/dist/gpu-texture-usage.d.ts +6 -0
- package/dist/gpu-texture-usage.d.ts.map +1 -0
- package/dist/gpu-usage.d.ts +9 -0
- package/dist/gpu-usage.d.ts.map +1 -0
- package/dist/hdrp-buffers.d.ts +163 -0
- package/dist/hdrp-buffers.d.ts.map +1 -0
- package/dist/ibl/IblPipelineCache.d.ts +168 -0
- package/dist/ibl/IblPipelineCache.d.ts.map +1 -0
- package/dist/ibl/skylight-bind-group.d.ts +130 -0
- package/dist/ibl/skylight-bind-group.d.ts.map +1 -0
- package/dist/index.d.ts +31 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.mjs +169 -0
- package/dist/index.mjs.map +1 -0
- package/dist/inspection-types.d.ts +72 -0
- package/dist/inspection-types.d.ts.map +1 -0
- package/dist/instance-buffer-cache.d.ts +56 -0
- package/dist/instance-buffer-cache.d.ts.map +1 -0
- package/dist/internal.d.ts +2 -0
- package/dist/internal.d.ts.map +1 -0
- package/dist/internal.mjs +3 -0
- package/dist/internal.mjs.map +1 -0
- package/dist/lifecycle.d.ts +62 -0
- package/dist/lifecycle.d.ts.map +1 -0
- package/dist/light-buffer-layout.d.ts +164 -0
- package/dist/light-buffer-layout.d.ts.map +1 -0
- package/dist/materials.d.ts +47 -0
- package/dist/materials.d.ts.map +1 -0
- package/dist/mesh-material-bindings.d.ts +43 -0
- package/dist/mesh-material-bindings.d.ts.map +1 -0
- package/dist/pbr-pipeline.d.ts +301 -0
- package/dist/pbr-pipeline.d.ts.map +1 -0
- package/dist/pipeline/standard-forward-lane.d.ts +5 -0
- package/dist/pipeline/standard-forward-lane.d.ts.map +1 -0
- package/dist/pipeline/standard-pipeline.d.ts +31 -0
- package/dist/pipeline/standard-pipeline.d.ts.map +1 -0
- package/dist/pipeline/standard-profile.d.ts +40 -0
- package/dist/pipeline/standard-profile.d.ts.map +1 -0
- package/dist/pipeline-builder.d.ts +122 -0
- package/dist/pipeline-builder.d.ts.map +1 -0
- package/dist/pipeline-spec-types.d.ts +24 -0
- package/dist/pipeline-spec-types.d.ts.map +1 -0
- package/dist/pipeline-spec.d.ts +367 -0
- package/dist/pipeline-spec.d.ts.map +1 -0
- package/dist/plugin.d.ts +4 -0
- package/dist/plugin.d.ts.map +1 -0
- package/dist/points-lines/__tests__/bounds.unit.test.d.ts +2 -0
- package/dist/points-lines/__tests__/bounds.unit.test.d.ts.map +1 -0
- package/dist/points-lines/__tests__/cache-recovery.unit.test.d.ts +2 -0
- package/dist/points-lines/__tests__/cache-recovery.unit.test.d.ts.map +1 -0
- package/dist/points-lines/__tests__/inspection-lanes.integration.test.d.ts +2 -0
- package/dist/points-lines/__tests__/inspection-lanes.integration.test.d.ts.map +1 -0
- package/dist/points-lines/__tests__/inspection.unit.test.d.ts +2 -0
- package/dist/points-lines/__tests__/inspection.unit.test.d.ts.map +1 -0
- package/dist/points-lines/__tests__/lane-structural.integration.test.d.ts +2 -0
- package/dist/points-lines/__tests__/lane-structural.integration.test.d.ts.map +1 -0
- package/dist/points-lines/__tests__/points-lines.bench.d.ts +2 -0
- package/dist/points-lines/__tests__/points-lines.bench.d.ts.map +1 -0
- package/dist/points-lines/__tests__/raster-lane.integration.test.d.ts +2 -0
- package/dist/points-lines/__tests__/raster-lane.integration.test.d.ts.map +1 -0
- package/dist/points-lines/__tests__/snapshot.unit.test.d.ts +2 -0
- package/dist/points-lines/__tests__/snapshot.unit.test.d.ts.map +1 -0
- package/dist/points-lines/__tests__/view-ubo.unit.test.d.ts +2 -0
- package/dist/points-lines/__tests__/view-ubo.unit.test.d.ts.map +1 -0
- package/dist/points-lines/admission.d.ts +36 -0
- package/dist/points-lines/admission.d.ts.map +1 -0
- package/dist/points-lines/bounds.d.ts +8 -0
- package/dist/points-lines/bounds.d.ts.map +1 -0
- package/dist/points-lines/expansion-cache.d.ts +28 -0
- package/dist/points-lines/expansion-cache.d.ts.map +1 -0
- package/dist/points-lines/inspection.d.ts +53 -0
- package/dist/points-lines/inspection.d.ts.map +1 -0
- package/dist/points-lines/prepare.d.ts +67 -0
- package/dist/points-lines/prepare.d.ts.map +1 -0
- package/dist/points-lines/record.d.ts +60 -0
- package/dist/points-lines/record.d.ts.map +1 -0
- package/dist/points-lines/snapshot.d.ts +49 -0
- package/dist/points-lines/snapshot.d.ts.map +1 -0
- package/dist/post-process-errors.d.ts +182 -0
- package/dist/post-process-errors.d.ts.map +1 -0
- package/dist/prepare/prepared-graphics-resolver.d.ts +59 -0
- package/dist/prepare/prepared-graphics-resolver.d.ts.map +1 -0
- package/dist/record/__tests__/material-bg-cache.unit.test.d.ts +2 -0
- package/dist/record/__tests__/material-bg-cache.unit.test.d.ts.map +1 -0
- package/dist/record/__tests__/material-slot-plan.unit.test.d.ts +2 -0
- package/dist/record/__tests__/material-slot-plan.unit.test.d.ts.map +1 -0
- package/dist/record/__tests__/typed-frame-graph-plan.unit.test.d.ts +2 -0
- package/dist/record/__tests__/typed-frame-graph-plan.unit.test.d.ts.map +1 -0
- package/dist/record/__tests__/video-texture-view.unit.test.d.ts +2 -0
- package/dist/record/__tests__/video-texture-view.unit.test.d.ts.map +1 -0
- package/dist/record/frame-lighting.d.ts +121 -0
- package/dist/record/frame-lighting.d.ts.map +1 -0
- package/dist/record/frame-snapshot.d.ts +429 -0
- package/dist/record/frame-snapshot.d.ts.map +1 -0
- package/dist/record/frame-targets.d.ts +20 -0
- package/dist/record/frame-targets.d.ts.map +1 -0
- package/dist/record/frame.d.ts +71 -0
- package/dist/record/frame.d.ts.map +1 -0
- package/dist/record/helpers.d.ts +102 -0
- package/dist/record/helpers.d.ts.map +1 -0
- package/dist/record/main-pass-geometry.d.ts +28 -0
- package/dist/record/main-pass-geometry.d.ts.map +1 -0
- package/dist/record/main-pass-material.d.ts +204 -0
- package/dist/record/main-pass-material.d.ts.map +1 -0
- package/dist/record/main-pass-sprite-draws.d.ts +43 -0
- package/dist/record/main-pass-sprite-draws.d.ts.map +1 -0
- package/dist/record/main-pass.d.ts +20 -0
- package/dist/record/main-pass.d.ts.map +1 -0
- package/dist/record/mesh-ssbo.d.ts +446 -0
- package/dist/record/mesh-ssbo.d.ts.map +1 -0
- package/dist/record/render-context.d.ts +252 -0
- package/dist/record/render-context.d.ts.map +1 -0
- package/dist/record/shadow-pass.d.ts +52 -0
- package/dist/record/shadow-pass.d.ts.map +1 -0
- package/dist/record/skybox-post-pass.d.ts +33 -0
- package/dist/record/skybox-post-pass.d.ts.map +1 -0
- package/dist/record/typed-frame-graph.d.ts +35 -0
- package/dist/record/typed-frame-graph.d.ts.map +1 -0
- package/dist/record/view-ubo.d.ts +45 -0
- package/dist/record/view-ubo.d.ts.map +1 -0
- package/dist/render-contract.d.ts +424 -0
- package/dist/render-contract.d.ts.map +1 -0
- package/dist/render-data.d.ts +143 -0
- package/dist/render-data.d.ts.map +1 -0
- package/dist/render-graph-primitives.d.ts +76 -0
- package/dist/render-graph-primitives.d.ts.map +1 -0
- package/dist/render-pipeline.d.ts +110 -0
- package/dist/render-pipeline.d.ts.map +1 -0
- package/dist/render-system-extract.d.ts +868 -0
- package/dist/render-system-extract.d.ts.map +1 -0
- package/dist/render-system.d.ts +125 -0
- package/dist/render-system.d.ts.map +1 -0
- package/dist/scene/render-scene-types.d.ts +61 -0
- package/dist/scene/render-scene-types.d.ts.map +1 -0
- package/dist/scene/render-scene.d.ts +112 -0
- package/dist/scene/render-scene.d.ts.map +1 -0
- package/dist/scene-instances/post-spawn-resolve-joints.d.ts +30 -0
- package/dist/scene-instances/post-spawn-resolve-joints.d.ts.map +1 -0
- package/dist/shadow-atlas.d.ts +117 -0
- package/dist/shadow-atlas.d.ts.map +1 -0
- package/dist/ssao-buffers.d.ts +50 -0
- package/dist/ssao-buffers.d.ts.map +1 -0
- package/dist/ssao-config.d.ts +28 -0
- package/dist/ssao-config.d.ts.map +1 -0
- package/dist/systems/active-camera.d.ts +53 -0
- package/dist/systems/active-camera.d.ts.map +1 -0
- package/dist/systems/pass-selector.d.ts +24 -0
- package/dist/systems/pass-selector.d.ts.map +1 -0
- package/dist/systems/skin-palette-allocator.d.ts +49 -0
- package/dist/systems/skin-palette-allocator.d.ts.map +1 -0
- package/dist/systems/skin-palette-types.d.ts +14 -0
- package/dist/systems/skin-palette-types.d.ts.map +1 -0
- package/dist/systems/transparent-sort-config.d.ts +112 -0
- package/dist/systems/transparent-sort-config.d.ts.map +1 -0
- package/dist/tilemap-chunk-extract-system.d.ts +143 -0
- package/dist/tilemap-chunk-extract-system.d.ts.map +1 -0
- package/dist/typed-render-graph-primitives.d.ts +57 -0
- package/dist/typed-render-graph-primitives.d.ts.map +1 -0
- package/dist/typed-shadow-passes.d.ts +11 -0
- package/dist/typed-shadow-passes.d.ts.map +1 -0
- package/package.json +94 -0
- package/src/__tests__/authoring-path.unit.test.ts +23 -0
- package/src/__tests__/backend-selection-rhi-capture.test-d.ts +21 -0
- package/src/__tests__/callback-inference.test-d.ts +8 -0
- package/src/__tests__/cluster-binner.test.ts +272 -0
- package/src/__tests__/cluster-grid-default-surface.unit.test.ts +20 -0
- package/src/__tests__/construct-renderer-identity.unit.test.ts +23 -0
- package/src/__tests__/device-scope-lifecycle.unit.test.ts +151 -0
- package/src/__tests__/device-scope-stale-matrix.unit.test.ts +42 -0
- package/src/__tests__/direct-extract-consumer-contract.test-d.ts +23 -0
- package/src/__tests__/direct-light-snapshot.unit.test.ts +61 -0
- package/src/__tests__/factory-contract.integration.test.ts +280 -0
- package/src/__tests__/fallback-row-stride-surface.unit.test.ts +15 -0
- package/src/__tests__/frame-observation.contract.test.ts +112 -0
- package/src/__tests__/fullscreen-feature-plan.unit.test.ts +32 -0
- package/src/__tests__/glyph-text-layout-recovery.unit.test.ts +167 -0
- package/src/__tests__/gpu-driven-indirect-raster-evidence.ts +350 -0
- package/src/__tests__/gpu-driven-indirect-raster.browser.test.ts +12 -0
- package/src/__tests__/gpu-driven-indirect-raster.dawn.test.ts +16 -0
- package/src/__tests__/gpu-driven-production.integration.test.ts +436 -0
- package/src/__tests__/gpu-driven-scaling.unit.test.ts +87 -0
- package/src/__tests__/gpu-driven-view-gpu-evidence.ts +271 -0
- package/src/__tests__/gpu-driven-view-graph.integration.test.ts +290 -0
- package/src/__tests__/gpu-driven-view-reference.ts +111 -0
- package/src/__tests__/gpu-driven-view.browser.test.ts +30 -0
- package/src/__tests__/gpu-driven-view.dawn.test.ts +28 -0
- package/src/__tests__/gpu-driven-view.unit.test.ts +199 -0
- package/src/__tests__/gpu-resource-store-stride.unit.test.ts +59 -0
- package/src/__tests__/gpu-scene-render-graph-gpu.ts +308 -0
- package/src/__tests__/gpu-scene-render-graph.browser.test.ts +19 -0
- package/src/__tests__/gpu-scene-render-graph.dawn.test.ts +19 -0
- package/src/__tests__/gpu-scene-schema.unit.test.ts +16 -0
- package/src/__tests__/gpu-scene.dawn.test.ts +205 -0
- package/src/__tests__/gpu-scene.unit.test.ts +147 -0
- package/src/__tests__/ibl/face-uniforms.unit.test.ts +46 -0
- package/src/__tests__/infinite-grid-no-vertex-probe.unit.test.ts +92 -0
- package/src/__tests__/injection-kind-owner.test-d.ts +14 -0
- package/src/__tests__/ktx2-basis-gpu-consumer.dawn.test.ts +728 -0
- package/src/__tests__/light-buffer-layout.unit.test.ts +40 -0
- package/src/__tests__/material-contract-inventory.unit.test.ts +24 -0
- package/src/__tests__/material-cooked-projection.unit.test.ts +150 -0
- package/src/__tests__/material-snapshot-mutation.integration.test.ts +53 -0
- package/src/__tests__/material-static-dynamic-route.unit.test.ts +94 -0
- package/src/__tests__/material-stride-surface.unit.test.ts +32 -0
- package/src/__tests__/mesh-buffer-usage-surface.unit.test.ts +106 -0
- package/src/__tests__/mesh-material-bindings.unit.test.ts +89 -0
- package/src/__tests__/mesh-stride-surface.unit.test.ts +16 -0
- package/src/__tests__/morph-culling-reentry.dawn.test.ts +157 -0
- package/src/__tests__/morph-feature-gpu-work.integration.test.ts +80 -0
- package/src/__tests__/morph-feature-plan.unit.test.ts +53 -0
- package/src/__tests__/morph-visual-evidence.integration.test.ts +80 -0
- package/src/__tests__/nineslice-handle-surface.unit.test.ts +19 -0
- package/src/__tests__/post-process-error-policy-owner.unit.test.ts +201 -0
- package/src/__tests__/prepared-buffer-kind-owner.test-d.ts +29 -0
- package/src/__tests__/prepared-graphics-capability.unit.test.ts +65 -0
- package/src/__tests__/prepared-graphics-generation.unit.test.ts +161 -0
- package/src/__tests__/prepared-graphics-lifecycle.unit.test.ts +138 -0
- package/src/__tests__/prepared-graphics-pipeline-warmup.unit.test.ts +29 -0
- package/src/__tests__/prepared-graphics-resolver.unit.test.ts +285 -0
- package/src/__tests__/prepared-graphics-snapshot.unit.test.ts +105 -0
- package/src/__tests__/prepared-graphics-store.unit.test.ts +154 -0
- package/src/__tests__/prepared-graphics-validation.unit.test.ts +176 -0
- package/src/__tests__/profiler-default-off.test.ts +22 -0
- package/src/__tests__/profiler-phase-catalog.test.ts +66 -0
- package/src/__tests__/profiler-phase-integration.test.ts +62 -0
- package/src/__tests__/profiler-phase-token.test.ts +79 -0
- package/src/__tests__/public-surface.test-d.ts +94 -0
- package/src/__tests__/recover-error-policy-owner.unit.test.ts +107 -0
- package/src/__tests__/render-error-code-owner.test-d.ts +116 -0
- package/src/__tests__/render-error-detail-ssot.test-d.ts +139 -0
- package/src/__tests__/render-error-exhaustive.test-d.ts +110 -0
- package/src/__tests__/render-feature-assembly.test-d.ts +43 -0
- package/src/__tests__/render-feature-context.test-d.ts +57 -0
- package/src/__tests__/render-feature-contract.test-d.ts +49 -0
- package/src/__tests__/render-feature-diagnostics.unit.test.ts +149 -0
- package/src/__tests__/render-feature-docs.unit.test.ts +89 -0
- package/src/__tests__/render-feature-errors.unit.test.ts +47 -0
- package/src/__tests__/render-feature-gpu-work.integration.test.ts +316 -0
- package/src/__tests__/render-feature-plan.test-d.ts +161 -0
- package/src/__tests__/render-feature-plan.unit.test.ts +170 -0
- package/src/__tests__/render-feature-prepared-diagnostics.unit.test.ts +90 -0
- package/src/__tests__/render-feature-prepared-errors.test-d.ts +79 -0
- package/src/__tests__/render-feature-prepared-graphics-docs.unit.test.ts +80 -0
- package/src/__tests__/render-feature-prepared-graphics-isolation.unit.test.ts +72 -0
- package/src/__tests__/render-feature-prepared-graphics-negative.test-d.ts +36 -0
- package/src/__tests__/render-feature-prepared-graphics.test-d.ts +74 -0
- package/src/__tests__/render-feature-prepared-graphics.unit.test.ts +121 -0
- package/src/__tests__/render-feature-public-surface.test-d.ts +57 -0
- package/src/__tests__/render-feature-retry.unit.test.ts +87 -0
- package/src/__tests__/render-feature-scheduling.unit.test.ts +110 -0
- package/src/__tests__/render-feature-stage-failed-policy-owner.unit.test.ts +137 -0
- package/src/__tests__/render-feature-stage-fault-recovery.unit.test.ts +146 -0
- package/src/__tests__/render-feature-visibility-context.test-d.ts +33 -0
- package/src/__tests__/render-feature-visibility-context.unit.test.ts +37 -0
- package/src/__tests__/render-feature-zero-work.unit.test.ts +76 -0
- package/src/__tests__/render-graph-compute-raster-gpu.ts +342 -0
- package/src/__tests__/render-graph-compute-raster.browser.test.ts +16 -0
- package/src/__tests__/render-graph-compute-raster.dawn.test.ts +22 -0
- package/src/__tests__/render-graph-hzb-gpu.ts +239 -0
- package/src/__tests__/render-graph-hzb.browser.test.ts +16 -0
- package/src/__tests__/render-graph-hzb.dawn.test.ts +23 -0
- package/src/__tests__/render-graph-primitives.unit.test.ts +22 -0
- package/src/__tests__/render-graph-storage-indirect-gpu.ts +162 -0
- package/src/__tests__/render-graph-storage-indirect.browser.test.ts +21 -0
- package/src/__tests__/render-graph-storage-indirect.dawn.test.ts +28 -0
- package/src/__tests__/render-scene-projection.unit.test.ts +168 -0
- package/src/__tests__/renderer-factory-material-contract.unit.test.ts +121 -0
- package/src/__tests__/renderer-lifecycle.integration.test.ts +58 -0
- package/src/__tests__/rhi-backend-package-boundary.unit.test.ts +11 -0
- package/src/__tests__/scriptable-pack-consumer.test-d.ts +14 -0
- package/src/__tests__/shader-stage-surface.unit.test.ts +43 -0
- package/src/__tests__/ssao-config.unit.test.ts +36 -0
- package/src/__tests__/ssao-kernel-surface.unit.test.ts +14 -0
- package/src/__tests__/standard-clustered-pipeline.unit.test.ts +28 -0
- package/src/__tests__/standard-descriptors.test-d.ts +22 -0
- package/src/__tests__/standard-pipeline.dawn.test.ts +61 -0
- package/src/__tests__/standard-pipeline.integration.test.ts +124 -0
- package/src/__tests__/standard-profile-oracle.unit.test.ts +62 -0
- package/src/__tests__/surface-configuration.unit.test.ts +91 -0
- package/src/__tests__/texture-usage-surface.unit.test.ts +58 -0
- package/src/__tests__/typed-pipeline-topology.unit.test.ts +223 -0
- package/src/__tests__/urp-pipeline-targets.unit.test.ts +42 -0
- package/src/__tests__/urp-pipeline.unit.test.ts +14 -0
- package/src/__tests__/vertex-color-pipeline.unit.test.ts +132 -0
- package/src/__tests__/vertex-layout-consumer.unit.test.ts +25 -0
- package/src/__tests__/visibility-diagnostics.integration.test.ts +62 -0
- package/src/__tests__/visibility-extract.integration.test.ts +98 -0
- package/src/__tests__/visibility-extract.perf.test.ts +130 -0
- package/src/__tests__/visibility-feature-dedup.integration.test.ts +55 -0
- package/src/__tests__/visibility-hidden-report.unit.test.ts +36 -0
- package/src/__tests__/visibility-instances.integration.test.ts +46 -0
- package/src/__tests__/visibility-multi-world.integration.test.ts +86 -0
- package/src/__tests__/visibility-producer-matrix.integration.test.ts +168 -0
- package/src/__tests__/visibility-producer-matrix.unit.test.ts +96 -0
- package/src/__tests__/visibility-public-surface.test-d.ts +27 -0
- package/src/__tests__/visibility-resolver.unit.test.ts +85 -0
- package/src/__tests__/visibility-resource-short-circuit.unit.test.ts +80 -0
- package/src/__tests__/visibility-snapshot-contract.unit.test.ts +60 -0
- package/src/__tests__/vocabulary.unit.test.ts +21 -0
- package/src/assembly/backend-contract.ts +57 -0
- package/src/assembly/factory.ts +8130 -0
- package/src/assembly/host-contract.ts +101 -0
- package/src/assembly/material/assembly.ts +48 -0
- package/src/assembly/material/pipeline-projection.ts +63 -0
- package/src/assets/asset-decoders.ts +158 -0
- package/src/assets/render-asset-port.ts +44 -0
- package/src/assets/resolve-render-asset.ts +13 -0
- package/src/authoring.ts +17 -0
- package/src/cluster-binner.ts +700 -0
- package/src/components/__tests__/points-lines-admission.unit.test.ts +219 -0
- package/src/components/__tests__/points-lines-schema.unit.test.ts +56 -0
- package/src/components/__tests__/schema-contract.unit.test.ts +10 -0
- package/src/components/__tests__/schema-parity.unit.test.ts +25 -0
- package/src/components/__tests__/visibility-schema.unit.test.ts +35 -0
- package/src/components/camera.ts +512 -0
- package/src/components/directional-light.ts +120 -0
- package/src/components/glyph-text.ts +64 -0
- package/src/components/index.ts +54 -0
- package/src/components/instances.ts +206 -0
- package/src/components/layer.ts +69 -0
- package/src/components/light-helpers.ts +188 -0
- package/src/components/lines.ts +18 -0
- package/src/components/mesh-filter.ts +60 -0
- package/src/components/mesh-renderer.ts +61 -0
- package/src/components/point-light-shadow.ts +43 -0
- package/src/components/point-light.ts +65 -0
- package/src/components/points.ts +40 -0
- package/src/components/post-process-params.ts +35 -0
- package/src/components/scene-instance.ts +193 -0
- package/src/components/skybox-background.ts +103 -0
- package/src/components/skylight.ts +97 -0
- package/src/components/sort-key.ts +75 -0
- package/src/components/spot-light.ts +124 -0
- package/src/components/sprite-animation.ts +168 -0
- package/src/components/sprite-instances.ts +179 -0
- package/src/components/sprite-playback-mode.ts +79 -0
- package/src/components/sprite-region-override.ts +105 -0
- package/src/components/tile-layer.ts +167 -0
- package/src/components/tilemap.ts +48 -0
- package/src/components/visibility.ts +53 -0
- package/src/construct-renderer.ts +67 -0
- package/src/debug-draw-glue.ts +48 -0
- package/src/device/device-scope.ts +306 -0
- package/src/device/gpu-residency.ts +1822 -0
- package/src/device/resource-types.ts +20 -0
- package/src/engine-metrics.ts +82 -0
- package/src/errors/ecs-validation.ts +16 -0
- package/src/errors/index.ts +3 -0
- package/src/errors/recover.ts +161 -0
- package/src/errors/render.ts +1284 -0
- package/src/extract/visibility.ts +120 -0
- package/src/features/fullscreen.ts +46 -0
- package/src/features/host.ts +1363 -0
- package/src/features/morph/morph-feature.ts +377 -0
- package/src/features/plan.ts +447 -0
- package/src/features/prepared-gpu-work.ts +959 -0
- package/src/features/prepared-graphics-store.ts +449 -0
- package/src/features/prepared-graphics.ts +420 -0
- package/src/features/render-graph-compute.ts +69 -0
- package/src/features/render-graph-contribution.ts +75 -0
- package/src/features/render-graph-raster.ts +332 -0
- package/src/features/render-graph-resources.ts +38 -0
- package/src/features/targets.ts +70 -0
- package/src/features/types.ts +103 -0
- package/src/features/vocabulary.ts +24 -0
- package/src/fullscreen-post-process-pass.ts +363 -0
- package/src/glyph-text-layout-system.ts +421 -0
- package/src/gpu-driven/batch-topology.ts +245 -0
- package/src/gpu-driven/production-raster.ts +695 -0
- package/src/gpu-driven/view-gpu.ts +703 -0
- package/src/gpu-resource.ts +159 -0
- package/src/gpu-scene-schema.ts +136 -0
- package/src/gpu-scene.ts +722 -0
- package/src/gpu-stage.ts +9 -0
- package/src/gpu-texture-usage.ts +12 -0
- package/src/gpu-usage.ts +14 -0
- package/src/hdrp-buffers.ts +480 -0
- package/src/ibl/IblPipelineCache.ts +1006 -0
- package/src/ibl/skylight-bind-group.ts +513 -0
- package/src/index.ts +129 -0
- package/src/inspection-types.ts +80 -0
- package/src/instance-buffer-cache.ts +95 -0
- package/src/internal.ts +9 -0
- package/src/lifecycle.ts +168 -0
- package/src/light-buffer-layout.ts +346 -0
- package/src/materials.ts +214 -0
- package/src/mesh-material-bindings.ts +103 -0
- package/src/pbr-pipeline.ts +1137 -0
- package/src/pipeline/standard-forward-lane.ts +229 -0
- package/src/pipeline/standard-pipeline.ts +555 -0
- package/src/pipeline/standard-profile.ts +65 -0
- package/src/pipeline-builder.ts +382 -0
- package/src/pipeline-spec-types.ts +28 -0
- package/src/pipeline-spec.ts +1231 -0
- package/src/plugin.ts +69 -0
- package/src/points-lines/__tests__/bounds.unit.test.ts +21 -0
- package/src/points-lines/__tests__/cache-recovery.unit.test.ts +157 -0
- package/src/points-lines/__tests__/inspection-lanes.integration.test.ts +146 -0
- package/src/points-lines/__tests__/inspection.unit.test.ts +173 -0
- package/src/points-lines/__tests__/lane-structural.integration.test.ts +122 -0
- package/src/points-lines/__tests__/points-lines.bench.ts +400 -0
- package/src/points-lines/__tests__/raster-lane.integration.test.ts +44 -0
- package/src/points-lines/__tests__/snapshot.unit.test.ts +101 -0
- package/src/points-lines/__tests__/view-ubo.unit.test.ts +73 -0
- package/src/points-lines/admission.ts +238 -0
- package/src/points-lines/bounds.ts +23 -0
- package/src/points-lines/expansion-cache.ts +215 -0
- package/src/points-lines/inspection.ts +97 -0
- package/src/points-lines/prepare.ts +177 -0
- package/src/points-lines/record.ts +125 -0
- package/src/points-lines/snapshot.ts +130 -0
- package/src/post-process-errors.ts +302 -0
- package/src/prepare/prepared-graphics-resolver.ts +456 -0
- package/src/record/__tests__/material-bg-cache.unit.test.ts +41 -0
- package/src/record/__tests__/material-slot-plan.unit.test.ts +44 -0
- package/src/record/__tests__/typed-frame-graph-plan.unit.test.ts +41 -0
- package/src/record/__tests__/video-texture-view.unit.test.ts +90 -0
- package/src/record/frame-lighting.ts +1074 -0
- package/src/record/frame-snapshot.ts +500 -0
- package/src/record/frame-targets.ts +137 -0
- package/src/record/frame.ts +1598 -0
- package/src/record/helpers.ts +284 -0
- package/src/record/main-pass-geometry.ts +1065 -0
- package/src/record/main-pass-material.ts +1043 -0
- package/src/record/main-pass-sprite-draws.ts +1137 -0
- package/src/record/main-pass.ts +610 -0
- package/src/record/mesh-ssbo.ts +885 -0
- package/src/record/render-context.ts +384 -0
- package/src/record/shadow-pass.ts +698 -0
- package/src/record/skybox-post-pass.ts +593 -0
- package/src/record/typed-frame-graph.ts +461 -0
- package/src/record/view-ubo.ts +222 -0
- package/src/render-contract.ts +582 -0
- package/src/render-data.ts +385 -0
- package/src/render-graph-primitives.ts +811 -0
- package/src/render-pipeline.ts +259 -0
- package/src/render-system-extract.ts +4585 -0
- package/src/render-system.ts +1933 -0
- package/src/scene/render-scene-types.ts +67 -0
- package/src/scene/render-scene.ts +1087 -0
- package/src/scene-instances/post-spawn-resolve-joints.ts +165 -0
- package/src/shadow-atlas.ts +244 -0
- package/src/ssao-buffers.ts +334 -0
- package/src/ssao-config.ts +61 -0
- package/src/systems/active-camera.ts +116 -0
- package/src/systems/pass-selector.ts +49 -0
- package/src/systems/skin-palette-allocator.ts +251 -0
- package/src/systems/skin-palette-types.ts +14 -0
- package/src/systems/transparent-sort-config.ts +233 -0
- package/src/tilemap-chunk-extract-system.ts +1290 -0
- package/src/typed-render-graph-primitives.ts +541 -0
- package/src/typed-shadow-passes.ts +165 -0
package/README.md
ADDED
|
@@ -0,0 +1,647 @@
|
|
|
1
|
+
# `@forgeax/engine-render`
|
|
2
|
+
|
|
3
|
+
## Render happy path
|
|
4
|
+
|
|
5
|
+
`RenderScene -> Standard Pipeline -> DeviceScope -> FrameReceipt` is the only frame
|
|
6
|
+
model. The host calls `createRenderer`, `attach(world)`, and `draw(request)`; diagnostics use
|
|
7
|
+
`inspect`, `observe(receipt, request)`, and `recover`. `FrameReceipt` is the synchronous proof that
|
|
8
|
+
submit completed. A failed `Result` carries `code`, `hint`, and `detail`; repair the named owner,
|
|
9
|
+
rebuild or cold-cook its source, then retry the same request.
|
|
10
|
+
|
|
11
|
+
```ts
|
|
12
|
+
const created = await createRenderer(canvas);
|
|
13
|
+
if (!created.ok) throw created.error;
|
|
14
|
+
const renderer = created.value;
|
|
15
|
+
const attached = renderer.attach(world);
|
|
16
|
+
if (!attached.ok) throw attached.error;
|
|
17
|
+
const frame = renderer.draw({
|
|
18
|
+
leases: [attached.value],
|
|
19
|
+
camera: { lease: attached.value },
|
|
20
|
+
environment: { lease: attached.value },
|
|
21
|
+
});
|
|
22
|
+
if (!frame.ok) throw frame.error;
|
|
23
|
+
const observation = await renderer.observe(frame.value, { include: ['timings'] });
|
|
24
|
+
```
|
|
25
|
+
|
|
26
|
+
The Standard pipeline selects direct or clustered lighting from capabilities and keeps shadow,
|
|
27
|
+
PBR, IBL, SSAO, bloom, tone, antialiasing, sky, material, VFX, and debug feature ownership inside
|
|
28
|
+
the same graph and submit boundary. CPU and WebGL2 fallback are capability lanes of that pipeline,
|
|
29
|
+
not second renderer identities.
|
|
30
|
+
|
|
31
|
+
## Direct-light parity contract
|
|
32
|
+
|
|
33
|
+
The direct-light proposition is: one public `DirectionalLight`/`PointLight`/
|
|
34
|
+
`SpotLight` semantic snapshot must produce the same analytic result in every
|
|
35
|
+
Standard capability lane. The authority is the revision-pinned
|
|
36
|
+
[`three-r184-finite-range-authority.json`](../../apps/parity/color-lighting/cases/direct-light/calibration/three-r184-finite-range-authority.json).
|
|
37
|
+
It is `ready` only when its Three revision, source hash, config, and expected
|
|
38
|
+
samples are present. Missing authority or paired GPU captures is `blocked`; do
|
|
39
|
+
not repair that state with a multiplier, a backend profile, or a demo asset.
|
|
40
|
+
|
|
41
|
+
Run the focused contract checks with:
|
|
42
|
+
|
|
43
|
+
```sh
|
|
44
|
+
pnpm exec vitest run apps/parity/color-lighting/src/analytic/__tests__/three-r184-finite-range.test.ts
|
|
45
|
+
pnpm exec vitest run apps/parity/color-lighting/src/integration/__tests__/light-snapshot.test.ts
|
|
46
|
+
```
|
|
47
|
+
|
|
48
|
+
The public mapping is deliberately small:
|
|
49
|
+
|
|
50
|
+
| Fact | Contract | Owner or evidence |
|
|
51
|
+
|:--|:--|:--|
|
|
52
|
+
| World scale | `1` world unit is `1` meter | Light components and glTF bridge |
|
|
53
|
+
| Exposure | `1` by default; applied after lighting at tone/output | Camera tone contract and paired capture |
|
|
54
|
+
| Intensity | Directional uses lux; point and spot use candela | `DirectionalLight`, `PointLight`, `SpotLight` |
|
|
55
|
+
| Color | Linear RGB; no hidden global multiplier | Light snapshot and buffer layout |
|
|
56
|
+
| Range and decay | Positive range is meters; `Infinity` means no cutoff; runtime uses `e=2` | Three r184 authority |
|
|
57
|
+
| Cone | KHR radians import to component degrees; snapshot stores `cosInner` and `cosOuter` | glTF bridge and extract |
|
|
58
|
+
| Direction | KHR local `-Z` after world rotation; extract normalizes once; downstream shaders consume the result | Extract snapshot and Standard shaders |
|
|
59
|
+
|
|
60
|
+
The runtime finite-range factor is the Three r184 squared window:
|
|
61
|
+
`clamp(1 - (d / c)^4, 0, 1)^2`. The KHR
|
|
62
|
+
[`three-r184-khr-calibration.json`](../../apps/parity/color-lighting/cases/direct-light/calibration/three-r184-khr-calibration.json)
|
|
63
|
+
curve is an explicit unsquared import/reference curve only; it is not a
|
|
64
|
+
substitute for the runtime authority. The squared and unsquared samples are
|
|
65
|
+
kept separate so a replacement remains a visible falsification.
|
|
66
|
+
|
|
67
|
+
For a blocked case, inspect the authority fixture first, then the normalized
|
|
68
|
+
light snapshot and the independent Forge/Three captures. The parity report
|
|
69
|
+
must retain `provenance`, `captures`, `raw hash`, `analyticMax`, `roiMax`, and
|
|
70
|
+
`verdict` for each backend x pipeline x case. A same-canvas self-comparison or
|
|
71
|
+
analytic-only green result is not direct-light parity evidence.
|
|
72
|
+
|
|
73
|
+
## Particle feature boundary
|
|
74
|
+
|
|
75
|
+
Particle rendering is provided by
|
|
76
|
+
[`@forgeax/engine-vfx-render`](../vfx-render/README.md). This package owns the
|
|
77
|
+
generic RenderFeature host, prepared graphics resolver, pipeline readiness
|
|
78
|
+
contract, and structured renderer errors; it does not own VFX simulation or
|
|
79
|
+
particle asset authoring.
|
|
80
|
+
|
|
81
|
+
## Deferred lighting evidence
|
|
82
|
+
|
|
83
|
+
Deferred lighting validation is consumer evidence, not a Render production
|
|
84
|
+
subsystem. The learn-render smoke exercises the Standard clustered path and
|
|
85
|
+
the profiler captures bounded CPU ownership evidence; the WebKit fallback
|
|
86
|
+
gate exercises the browser delivery path. Runtime inspection uses the public
|
|
87
|
+
`inspect` and `observe` projections, while any future timestamp benchmark
|
|
88
|
+
belongs in `packages/render/bench` and its dev-verify producer. Render does
|
|
89
|
+
not expose a timing controller or a second membership-specific API.
|
|
90
|
+
|
|
91
|
+
## RenderFeature: the producer seam (first-read index)
|
|
92
|
+
|
|
93
|
+
### Material contract projection
|
|
94
|
+
|
|
95
|
+
Render consumes only the Pack-owned material publication projection. Its
|
|
96
|
+
inputs are runtime bool/value data, composed module slots, and the closed
|
|
97
|
+
compiler context; render never authors, cooks, writes DDC, or selects a
|
|
98
|
+
fallback material. The projection preserves `layoutIdentity`,
|
|
99
|
+
`programIdentity`, `cookIdentity`, and `materialPublicationIdentity` so a
|
|
100
|
+
stale draw can be traced to the first producer divergence.
|
|
101
|
+
|
|
102
|
+
The public route is one `RenderFeature<FrameData>` through the Standard
|
|
103
|
+
Pipeline and the active RenderGraph pass. In the examples below, `type FrameData`
|
|
104
|
+
is the producer-owned extracted value. A feature extracts one frame value,
|
|
105
|
+
then its mandatory `plan(data, context)` declares named resources and passes;
|
|
106
|
+
the host derives graph access, preparation, recording, and recovery from that
|
|
107
|
+
plan. Register it at construction with
|
|
108
|
+
`createRenderer(canvas, { features: [feature] })`. A feature never receives a
|
|
109
|
+
device, queue, encoder, staging builder, or submit callback.
|
|
110
|
+
|
|
111
|
+
> [!IMPORTANT]
|
|
112
|
+
> Render consumes the effective MaterialAsset snapshot produced by extract. Each texture slot carries its own coordinate set and transform into the built-in PBR binding layout; render records do not reinterpret authoring fields or manufacture shader artifacts. The effective `passes` are already validated.
|
|
113
|
+
|
|
114
|
+
## MaterialAsset render contract
|
|
115
|
+
|
|
116
|
+
Render owns this consumption route:
|
|
117
|
+
|
|
118
|
+
| Input | Render responsibility |
|
|
119
|
+
|:--|:--|
|
|
120
|
+
| `passes` and `values` | Consume the effective snapshot; do not reinterpret authoring data. |
|
|
121
|
+
| `parent` | Consume the already-resolved inheritance result. |
|
|
122
|
+
| texture `coordinates` | Bind the selected coordinate set and transform. |
|
|
123
|
+
| `cook` output | Record only validated shader artifacts. |
|
|
124
|
+
| `recovery` | Preserve the structured failure so the source contract or cooked module can be repaired. |
|
|
125
|
+
|
|
126
|
+
### Mesh material binding resolution
|
|
127
|
+
|
|
128
|
+
Render resolves one effective material table per logical mesh slot before
|
|
129
|
+
recording submesh draws. `MeshRenderer.materials[]` is a sparse per-instance
|
|
130
|
+
override vector: a missing entry or `0` inherits the corresponding
|
|
131
|
+
`MeshAsset.materialSlots[]` default. A slot without a declared mesh default
|
|
132
|
+
uses the neutral engine material.
|
|
133
|
+
|
|
134
|
+
> [!IMPORTANT]
|
|
135
|
+
> A declared mesh default is a required asset dependency. If it is unavailable,
|
|
136
|
+
> extract fails closed with the mesh GUID, slot index, and material GUID instead
|
|
137
|
+
> of silently painting the mesh gray. Invalid instance overrides fall back with
|
|
138
|
+
> a structured diagnostic; entries beyond the slot table are ignored and
|
|
139
|
+
> diagnosed.
|
|
140
|
+
|
|
141
|
+
The render path is `MaterialAsset` -> extract snapshot -> prepare resources -> record the per-slot `coordinates` and values. The effective `parent` is already resolved before extract. If a material contract or reflection binding fails, preserve the structured error and repair the source contract or cooked module before drawing again; that is the recovery route. The render package owns consumption, not material import or cook policy.
|
|
142
|
+
|
|
143
|
+
## Points and Lines authoring (M1)
|
|
144
|
+
|
|
145
|
+
Points and Lines are first-class render components. Their geometry remains a
|
|
146
|
+
normal `MeshAsset`, and their material remains the engine-owned
|
|
147
|
+
`Materials.unlit` asset. The M1 path validates the complete candidate before
|
|
148
|
+
any render publication; it does not add a second mesh, material, CLI, RPC, or
|
|
149
|
+
manifest authority.
|
|
150
|
+
|
|
151
|
+
```ts
|
|
152
|
+
import { Lines, Materials, PointShapeValue, Points, admitPointsLines } from '@forgeax/engine-render';
|
|
153
|
+
import { World } from '@forgeax/engine-ecs';
|
|
154
|
+
import type { MeshAsset } from '@forgeax/engine-types';
|
|
155
|
+
|
|
156
|
+
const positions = new Float32Array([0, 0, 0, 1, 0, 0, 2, 0, 0]);
|
|
157
|
+
const pointMesh = {
|
|
158
|
+
kind: 'mesh',
|
|
159
|
+
vertices: positions,
|
|
160
|
+
attributes: { position: positions },
|
|
161
|
+
submeshes: [{
|
|
162
|
+
indexOffset: 0,
|
|
163
|
+
indexCount: 0,
|
|
164
|
+
vertexCount: 3,
|
|
165
|
+
topology: 'point-list',
|
|
166
|
+
materialSlot: 0,
|
|
167
|
+
}],
|
|
168
|
+
materialSlots: [{ slotName: 'default' }],
|
|
169
|
+
} satisfies MeshAsset;
|
|
170
|
+
const material = Materials.unlit([1, 0.5, 0.25, 1], { castShadow: false });
|
|
171
|
+
const world = new World();
|
|
172
|
+
const entity = world.spawn({
|
|
173
|
+
component: Points,
|
|
174
|
+
data: { sizePx: 4, shape: PointShapeValue.circle },
|
|
175
|
+
}).unwrap();
|
|
176
|
+
const admitted = admitPointsLines({
|
|
177
|
+
entity,
|
|
178
|
+
points: { sizePx: 4, shape: PointShapeValue.circle },
|
|
179
|
+
mesh: pointMesh,
|
|
180
|
+
material,
|
|
181
|
+
});
|
|
182
|
+
if (!admitted.ok) throw new Error(admitted.error.hint);
|
|
183
|
+
|
|
184
|
+
world.spawn({ component: Lines, data: { widthPx: 2 } }).unwrap();
|
|
185
|
+
```
|
|
186
|
+
|
|
187
|
+
The style vocabulary is deliberately small in M1:
|
|
188
|
+
|
|
189
|
+
| Component | Field | Default | Accepted values |
|
|
190
|
+
|:--|:--|--:|:--|
|
|
191
|
+
| `Points` | `sizePx` | `4` | finite number greater than `0` |
|
|
192
|
+
| `Points` | `shape` | `square` | `square` or `circle` |
|
|
193
|
+
| `Lines` | `widthPx` | `1` | finite number greater than `0` |
|
|
194
|
+
|
|
195
|
+
Admission consumes one style component, one ordinary mesh topology, and one
|
|
196
|
+
unlit forward material. Indexed and non-indexed `point-list` meshes are valid
|
|
197
|
+
for `Points`; indexed and non-indexed paired `line-list` meshes are valid for
|
|
198
|
+
`Lines`.
|
|
199
|
+
|
|
200
|
+
| Candidate | M1 result | Reason |
|
|
201
|
+
|:--|:--:|:--|
|
|
202
|
+
| `Points` + `point-list` + finite positive `sizePx` + unlit forward material | supported | `square` and `circle` are the only point shapes |
|
|
203
|
+
| `Lines` + paired `line-list` + finite positive `widthPx` + unlit forward material | supported | each pair is one line segment |
|
|
204
|
+
| `line-strip`, triangle topology, mixed submeshes, or an odd line-list tail | refused | topology cannot be inferred or admitted atomically |
|
|
205
|
+
| both `Points` and `Lines` on one candidate | refused | one entity has one style lane |
|
|
206
|
+
| `Materials.standard`, shadow-caster, deferred, or another shader module | refused | M1 accepts one engine-owned unlit forward pass |
|
|
207
|
+
| candidate count over `maxPoints` or `maxSegments` | refused | bounded admission prevents partial publication |
|
|
208
|
+
|
|
209
|
+
When admission refuses a candidate, consume the structured result rather than
|
|
210
|
+
parsing its message. The result exposes `.code`, `.expected`, `.hint`, and a
|
|
211
|
+
code-specific `.detail` containing the relevant entity, component, mesh,
|
|
212
|
+
material, submesh, lane, generation, or stage facts:
|
|
213
|
+
|
|
214
|
+
```ts
|
|
215
|
+
const result = admitPointsLines({ entity, points: {}, mesh: pointMesh, material });
|
|
216
|
+
if (!result.ok) {
|
|
217
|
+
console.error(result.error.code);
|
|
218
|
+
console.error(result.error.expected);
|
|
219
|
+
console.error(result.error.hint);
|
|
220
|
+
console.error(result.error.detail);
|
|
221
|
+
}
|
|
222
|
+
```
|
|
223
|
+
|
|
224
|
+
M1 intentionally refuses strip expansion, joins, caps, dashes, picking, and
|
|
225
|
+
visible point/line draw preparation. Those are later implementation lanes, not
|
|
226
|
+
implicit fallbacks in authoring code.
|
|
227
|
+
|
|
228
|
+
## Points and Lines runtime contract
|
|
229
|
+
|
|
230
|
+
The complete public closure is `MeshAsset` topology, one `Points` or `Lines`
|
|
231
|
+
component, `Materials.unlit`, and the Standard renderer. The owner retains the
|
|
232
|
+
source view, derives expanded geometry during prepare, and records the dedicated
|
|
233
|
+
points-lines pipeline in the active main geometry pass. Applications do not
|
|
234
|
+
create a second mesh, GPU buffer, shader module, cache, recovery ledger, or
|
|
235
|
+
backend branch.
|
|
236
|
+
|
|
237
|
+
| Surface | Supported contract | Refused or not claimed |
|
|
238
|
+
|:--|:--|:--|
|
|
239
|
+
| topology | indexed or non-indexed `point-list` and paired `line-list` | strips, triangles, mixed topology, and odd line tails |
|
|
240
|
+
| style | finite positive `Points.sizePx` and `Lines.widthPx`; circle or square points | negative, non-finite, or lane-conflicting values |
|
|
241
|
+
| material | engine-owned `Materials.unlit` forward material | standard/PBR, deferred, shadow-only, or custom runtime shader |
|
|
242
|
+
| capability lane | direct WebGPU runtime; clustered unlit preserves the same authoring contract | CPU and WebGL2 require their declared capability route; no pixel result is inferred from RhiNull |
|
|
243
|
+
| structural lane | RhiNull records retained projection, preparation, bindings, and draw shape | RhiNull is never hardware or pixel evidence |
|
|
244
|
+
|
|
245
|
+
Prepare and record remain one lifecycle. A failed result is an owner fact, not a
|
|
246
|
+
request to fall back to a generic mesh draw. Inspect the structured error and
|
|
247
|
+
repair the source or producer, then retry the same renderer:
|
|
248
|
+
|
|
249
|
+
```ts
|
|
250
|
+
const inspection = renderer.inspect();
|
|
251
|
+
const pointsLines = inspection.renderScene.pointsLines;
|
|
252
|
+
// Repair the named source or producer, then retry inspection and draw.
|
|
253
|
+
report(pointsLines);
|
|
254
|
+
```
|
|
255
|
+
|
|
256
|
+
Inspection reports source bytes, derived bytes, vertex/index counts, cache
|
|
257
|
+
state, upload state, draw count, lane, and the retained `lastKnownGood` state.
|
|
258
|
+
Recovery is `inspect -> producer rebuild or cold-cook -> prepare -> record`.
|
|
259
|
+
It never publishes a partial expansion and never hides a stale-generation or
|
|
260
|
+
missing-resource error.
|
|
261
|
+
|
|
262
|
+
For visual evidence, use the topology probe and retain its raw screenshot,
|
|
263
|
+
readback, source/derived byte counts, draw count, and validation errors. A
|
|
264
|
+
focused direct-WebGPU probe is evidence for that lane only. The repository-wide
|
|
265
|
+
`pnpm test:browser` gate was explicitly skipped by human override in this
|
|
266
|
+
milestone and must not be reported as passed; the controlled Dawn attempt
|
|
267
|
+
timed out during environment build before Dawn Vitest ran.
|
|
268
|
+
|
|
269
|
+
The M5 boundary does not include strip joins, caps, dashes, picking, a new CLI
|
|
270
|
+
or RPC operation, application-local WGSL, a second Geometry factory, or a
|
|
271
|
+
separate cache/recovery authority.
|
|
272
|
+
|
|
273
|
+
> [!IMPORTANT]
|
|
274
|
+
> Owner: render vocabulary and the extract → prepare → record frame boundary. Runtime selects concrete services and calls this package; it does not re-own these tokens.
|
|
275
|
+
|
|
276
|
+
```ts
|
|
277
|
+
import { Camera, MeshFilter, MeshRenderer } from '@forgeax/engine-render';
|
|
278
|
+
import { createRenderer } from '@forgeax/engine-runtime';
|
|
279
|
+
|
|
280
|
+
const renderer = await createRenderer(canvas);
|
|
281
|
+
const attached = renderer.attach(world);
|
|
282
|
+
if (attached.ok) {
|
|
283
|
+
world.update(1 / 60).unwrap();
|
|
284
|
+
renderer.draw({
|
|
285
|
+
leases: [attached.value],
|
|
286
|
+
camera: { lease: attached.value },
|
|
287
|
+
environment: { lease: attached.value },
|
|
288
|
+
});
|
|
289
|
+
}
|
|
290
|
+
```
|
|
291
|
+
|
|
292
|
+
`attach` installs renderer-required derived-state systems once. Hosts built
|
|
293
|
+
with `createApp` get this wiring automatically. A custom loop attaches each
|
|
294
|
+
World before its first update, then keeps `draw` as a read-only consumer of the
|
|
295
|
+
state published by `World.update()`.
|
|
296
|
+
|
|
297
|
+
## Persistent render scene
|
|
298
|
+
|
|
299
|
+
The ordinary single-World path bootstraps one renderer-owned CPU projection,
|
|
300
|
+
then drains the World's bounded change journal. A no-change frame reuses the
|
|
301
|
+
last visible snapshot without traversing renderable archetypes; transform
|
|
302
|
+
changes update only their stable projection slots. Unrelated gameplay
|
|
303
|
+
component writes do not invalidate render state.
|
|
304
|
+
|
|
305
|
+
Mutable shared payloads use the same explicit-dirty rule: mutate the resolved
|
|
306
|
+
payload, then call `world.sharedRefs.markChanged(handle)`. The renderer compares
|
|
307
|
+
one monotonic shared-ref epoch on the no-change path, drains the bounded exact
|
|
308
|
+
mutation journal when it advances, and refreshes only projection slots indexed
|
|
309
|
+
by the changed material handle. Journal overflow and topology-changing material
|
|
310
|
+
edits remain explicit full-reconcile reasons rather than silent partial state.
|
|
311
|
+
|
|
312
|
+
When `RhiCaps.storageBuffer` is available, the same projection owns persistent
|
|
313
|
+
Primitive, Instance, Transform, DrawTemplate, and Material GPU tables. The
|
|
314
|
+
tables use independent stable ranges: one primitive can reference ordinary
|
|
315
|
+
instance-local transforms, multiple draw items, and multiple prepared material
|
|
316
|
+
records. The schema in `src/gpu-scene-schema.ts` derives byte offsets, signed
|
|
317
|
+
and unsigned scalar forms, strides, and WGSL declarations; dirty ranges become
|
|
318
|
+
coalesced `queue.writeBuffer` writes and no-change frames upload zero scene
|
|
319
|
+
bytes. Device recovery discards only device-owned tables and rebuilds them from
|
|
320
|
+
the retained CPU projection.
|
|
321
|
+
|
|
322
|
+
The typed render-graph evidence path imports those persistent tables without
|
|
323
|
+
transferring ownership, runs compute cull → compact → indirect args, and consumes
|
|
324
|
+
the result through a graph-owned raster pass. Companion Dawn and Chromium gates
|
|
325
|
+
also cover storage-buffer ping-pong, compute-generated indirect dispatch and draw
|
|
326
|
+
arguments, storage-texture sampling in raster, and per-mip HZB reduction. These
|
|
327
|
+
are real driver/pixel proofs for the GPU-driven boundary; they do not make
|
|
328
|
+
RhiNull a pixel backend or make the CPU projection cease to be the scene
|
|
329
|
+
authority.
|
|
330
|
+
|
|
331
|
+
Inspect the current path through `renderer.inspect()`. Its detached CPU snapshot exposes
|
|
332
|
+
full rebuilds, no-change and delta frames, transform/material/instance updates,
|
|
333
|
+
removals, the journal cursor, projection cardinality, and the last resync
|
|
334
|
+
reason. The nested `gpu` status is one of `inactive`, `unsupported`, `resident`,
|
|
335
|
+
`rebuild-pending`, or `error`; resident state additionally reports capacity,
|
|
336
|
+
upload ranges and bytes, grows, clears, rebuilds, and no-change frames. The
|
|
337
|
+
`gpuDriven` inspection reports whether stable frames materialized or validated
|
|
338
|
+
GPU-owned rows and whether candidate or batch topology bytes were uploaded.
|
|
339
|
+
GPU and renderer contract errors arrive through the single `renderer.subscribe`
|
|
340
|
+
event stream (`event.kind === 'error'`); the renderer does not expose a second
|
|
341
|
+
error listener registry.
|
|
342
|
+
|
|
343
|
+
## GPU-driven view kernel
|
|
344
|
+
|
|
345
|
+
`BatchTopology` groups eligible rigid draw items by immutable geometry,
|
|
346
|
+
material, render-state, and command compatibility. One primitive can contribute
|
|
347
|
+
multiple submesh draw items, and each draw item uses a closed indexed or
|
|
348
|
+
non-indexed five-word indirect command. A per-view typed graph records
|
|
349
|
+
`reset -> frustum/compact -> finalize` over persistent candidate and batch
|
|
350
|
+
buffers. The compute path validates generation and active flags, composes the
|
|
351
|
+
primitive world transform with each ordinary instance-local transform, writes a
|
|
352
|
+
compact `(instanceIndex, materialIndex)` stream, sets explicit overflow flags,
|
|
353
|
+
and emits indirect arguments with `firstInstance = 0`.
|
|
354
|
+
|
|
355
|
+
The Standard frame activates the production raster lane when compute, storage
|
|
356
|
+
buffers, and indirect drawing are available. The current lane accepts opaque,
|
|
357
|
+
rigid default-unlit passes with batch-stable render state, ordinary instances,
|
|
358
|
+
indexed or non-indexed geometry, multiple submeshes and material slots, and the
|
|
359
|
+
canonical `12F` vertex layout. It also accepts persistent rigid multi-World
|
|
360
|
+
composition. Candidates come from the complete persistent projection rather
|
|
361
|
+
than the CPU-visible snapshot. The same typed graph imports the scene and mesh
|
|
362
|
+
buffers, runs the three compute passes, and consumes generated arguments with
|
|
363
|
+
`drawIndexedIndirect` or `drawIndirect`. Entities accepted by that lane are not
|
|
364
|
+
also validated, uploaded, or recorded by the CPU forward loop on a stable
|
|
365
|
+
frame.
|
|
366
|
+
|
|
367
|
+
clustered, PBR and custom shader variants, texture/sampler/video resource bindings,
|
|
368
|
+
transparent meshes, skinning, morphing, non-canonical layouts, and shadow views
|
|
369
|
+
keep explicit CPU or specialized lanes. WebGL2 selects capability fallback from
|
|
370
|
+
the same persistent projection; it does not emulate compute. Visibility and
|
|
371
|
+
hierarchy changes, non-rigid multi-World composition, and some prepared-resource
|
|
372
|
+
changes still require bounded reconcile work. The implemented lane proves a
|
|
373
|
+
zero-upload stable data path and broad rigid geometry coverage, but hardware
|
|
374
|
+
100k timing, schema-derived material variants, stable world identities, and
|
|
375
|
+
GPU-driven shadows remain required before declaring P3 complete.
|
|
376
|
+
|
|
377
|
+
The bounded inspection reports topology revision, candidates, batches, visible
|
|
378
|
+
capacity, buffer capacities, update count, upload bytes, rebuild count, and CPU
|
|
379
|
+
fallback rows. RhiNull verifies graph dependency order and stable-frame zero
|
|
380
|
+
work; Dawn and Chromium verification consume indexed, non-indexed,
|
|
381
|
+
multi-submesh, and instanced arguments, read persistent scene tables in the
|
|
382
|
+
vertex path, and compare the resulting pixel. The renderer-level RhiNull
|
|
383
|
+
integration also proves that the built-in Standard graph contains the compute chain
|
|
384
|
+
before `main`, including rigid multi-World composition, without GPU plus CPU
|
|
385
|
+
duplicate draws. The renderer retains one graph, one compile owner, one
|
|
386
|
+
encoder, and one submit route.
|
|
387
|
+
|
|
388
|
+
> [!NOTE]
|
|
389
|
+
> Non-rigid multi-World composition, skinned lanes, visibility/hierarchy
|
|
390
|
+
> changes, and unsupported render-relevant structural changes currently take
|
|
391
|
+
> an explicit reconcile path. The projection and GPU tables already define
|
|
392
|
+
> stable slot, generation, create, update, remove, grow, clear, and rebuild
|
|
393
|
+
> semantics; later coverage can make those changes entity-local without adding
|
|
394
|
+
> another scene authority.
|
|
395
|
+
|
|
396
|
+
Features are supplied through the construction options (`features: [...]`) and
|
|
397
|
+
enter the same host-owned extract → plan → graph projection path. The public
|
|
398
|
+
`Renderer` intentionally has no install/uninstall methods: optional capability
|
|
399
|
+
lifetime belongs to the App host, while recovery re-runs the plan against the
|
|
400
|
+
replacement device generation.
|
|
401
|
+
|
|
402
|
+
| This package owns | Excluded concepts |
|
|
403
|
+
|:--|:--|
|
|
404
|
+
| Camera/light/mesh vocabulary, `Renderer`, render errors, documented pipeline operations | Backend selection, asset import, ECS scheduling, animation playback, optional text/tile/sprite authoring |
|
|
405
|
+
|
|
406
|
+
The stable surface is [`src/index.ts`](src/index.ts). `RenderError` is closed and carries actionable detail. Runtime alone owns host assembly and its `EngineEnvironmentError` rejection contract; render's construction seam is internal to that dependency path.
|
|
407
|
+
|
|
408
|
+
## Tone mapping output contract
|
|
409
|
+
|
|
410
|
+
The public mode names are the same names used by the Three r184 oracle:
|
|
411
|
+
|
|
412
|
+
| Mode | Public constant | Output behavior |
|
|
413
|
+
|:--|:--|:--|
|
|
414
|
+
| `linear` | `TONEMAP_LINEAR` | Exposure, then clamp to LDR |
|
|
415
|
+
| `reinhard` | `TONEMAP_REINHARD` | Per-channel Reinhard |
|
|
416
|
+
| `cineon` | `TONEMAP_CINEON` | Cineon filmic curve |
|
|
417
|
+
| `aces-filmic` | `TONEMAP_ACES_FILMIC` | ACES filmic curve |
|
|
418
|
+
| `agx` | `TONEMAP_AGX` | AgX curve |
|
|
419
|
+
| `neutral` | `TONEMAP_NEUTRAL` | Khronos neutral curve |
|
|
420
|
+
|
|
421
|
+
`TONEMAP_REINHARD_EXTENDED` is the existing ForgeaX luminance-domain curve. Its
|
|
422
|
+
separate `reinhard-extended` name is intentional: it is not a second formula
|
|
423
|
+
hidden behind the Three `reinhard` name.
|
|
424
|
+
|
|
425
|
+
Tone-enabled cameras use one output contract:
|
|
426
|
+
|
|
427
|
+
```text
|
|
428
|
+
linearHdr -- exposure + named tone curve --> linearLdr --> displayEncoded
|
|
429
|
+
```
|
|
430
|
+
|
|
431
|
+
The final capture is the encoded surface result. A linear capture, when a
|
|
432
|
+
parity adapter exposes one, remains a separate `linearHdr` or `linearLdr`
|
|
433
|
+
sample and must not be compared as if it were the final display capture. The
|
|
434
|
+
contract is available as `resolveToneOutputContract(camera.tonemap)` from the
|
|
435
|
+
render package. The camera remains the runtime entry point:
|
|
436
|
+
|
|
437
|
+
```ts
|
|
438
|
+
import { Camera, TONEMAP_AGX, perspective } from '@forgeax/engine-render';
|
|
439
|
+
|
|
440
|
+
world.spawn({
|
|
441
|
+
component: Camera,
|
|
442
|
+
data: {
|
|
443
|
+
...perspective({ fov: Math.PI / 4, aspect: 1 }),
|
|
444
|
+
tonemap: TONEMAP_AGX,
|
|
445
|
+
exposure: 1,
|
|
446
|
+
},
|
|
447
|
+
}).unwrap();
|
|
448
|
+
```
|
|
449
|
+
|
|
450
|
+
The built-in pass samples the HDR target and writes the LDR result through the
|
|
451
|
+
registered `forgeax::tonemap` fullscreen shader. Shader source authority is
|
|
452
|
+
[`packages/shader/src/tonemap.wgsl`](../shader/src/tonemap.wgsl); the render
|
|
453
|
+
package does not duplicate those formulas.
|
|
454
|
+
|
|
455
|
+
## Optional CPU profiling
|
|
456
|
+
|
|
457
|
+
Render accepts the host-owned `Profiler` capability through App assembly. It writes bounded CPU
|
|
458
|
+
phase evidence only while a capture is active; it does not add GPU timestamps, ECS spans, a UI, or
|
|
459
|
+
a remote method. The artifact and its owner-declared catalog are documented by
|
|
460
|
+
[`@forgeax/engine-profiler`](../profiler/README.md).
|
|
461
|
+
|
|
462
|
+
```ts
|
|
463
|
+
import { createProfiler, type Profiler } from '@forgeax/engine-profiler';
|
|
464
|
+
import { createRenderer } from '@forgeax/engine-runtime';
|
|
465
|
+
|
|
466
|
+
const profiler: Profiler = createProfiler();
|
|
467
|
+
const renderer = await createRenderer(canvas, { profiler });
|
|
468
|
+
```
|
|
469
|
+
|
|
470
|
+
Use the package's `validateProfileCapture` and `buildProfileModel` entries for offline analysis.
|
|
471
|
+
The render package remains the owner of render vocabulary and extract/plan/record execution.
|
|
472
|
+
|
|
473
|
+
## RenderFeature: the producer seam
|
|
474
|
+
|
|
475
|
+
Register one producer-owned feature at the renderer assembly boundary. The
|
|
476
|
+
same `FrameData` type flows through `extract` and the mandatory `plan`; the
|
|
477
|
+
host derives preparation, graph access, recording, and lifecycle isolation
|
|
478
|
+
from that one plan. Both paths execute inside the active RenderGraph and the
|
|
479
|
+
frame's single execute/submit boundary.
|
|
480
|
+
|
|
481
|
+
The smallest feature returns a closed plan with named resources and passes.
|
|
482
|
+
Graph access is derived from those declarations; there is no staging object or
|
|
483
|
+
second contribution API:
|
|
484
|
+
|
|
485
|
+
```ts
|
|
486
|
+
plan: (frame, context) => ok({
|
|
487
|
+
resources: [
|
|
488
|
+
{ kind: 'compute-program', name: 'compact.program', program },
|
|
489
|
+
{ kind: 'compute-bindings', name: 'compact.bindings', program: 'compact.program', entries },
|
|
490
|
+
],
|
|
491
|
+
passes: [{
|
|
492
|
+
kind: 'compute', name: 'compact', program: 'compact.program',
|
|
493
|
+
bindings: 'compact.bindings', dispatches,
|
|
494
|
+
}],
|
|
495
|
+
})
|
|
496
|
+
```
|
|
497
|
+
|
|
498
|
+
The plan contains cooked program descriptors, named buffers and bindings, logical
|
|
499
|
+
targets, and draw/dispatch commands. Graph buffer and texture access is derived
|
|
500
|
+
from those roles; producers never author a second `reads`/`writes` ledger and
|
|
501
|
+
never receive an encoder or submit authority.
|
|
502
|
+
|
|
503
|
+
### Five render terms
|
|
504
|
+
|
|
505
|
+
| Term | Meaning | Owner |
|
|
506
|
+
|:--|:--|:--|
|
|
507
|
+
| `RenderFeature` | Producer-owned extract/plan callbacks and frame data | Feature producer |
|
|
508
|
+
| `Standard Pipeline` | The single frame policy containing the supported capability/profile lanes | Render host |
|
|
509
|
+
| RenderGraph pass | One declared graph execution node in the active Standard Pipeline | Graph host |
|
|
510
|
+
| Material pass | One shader-facing pass in a `MaterialAsset` | Material asset |
|
|
511
|
+
| RenderFeaturePlan | One executable declaration of resources, bindings, targets, and commands | Feature producer |
|
|
512
|
+
|
|
513
|
+
### Prepared compute resources
|
|
514
|
+
|
|
515
|
+
`RenderFeature` producers declare cooked compute pipelines, reflected name-based bindings,
|
|
516
|
+
uniform/storage buffers, and dispatches. The renderer prepares those declarations,
|
|
517
|
+
imports the persistent buffers into the render graph, and derives `uniform-read`,
|
|
518
|
+
`storage-read`, or `storage-read-write` access. Producers do not repeat a string `reads/writes`
|
|
519
|
+
ledger and do not receive an encoder.
|
|
520
|
+
|
|
521
|
+
Compute and graphics passes use the same plan projection and submission boundary. The graph
|
|
522
|
+
owns `beginComputePass` / `end`; the plan records only named pipeline, bind group, and dispatch
|
|
523
|
+
commands. Persistent buffers retain device identity across frames,
|
|
524
|
+
rebuild with the feature-host generation, and retire only after queue completion. A storage buffer
|
|
525
|
+
may also be consumed as renderer-declared vertex data.
|
|
526
|
+
|
|
527
|
+
Feature contexts never expose raw GPU graphics state, a complete pipeline
|
|
528
|
+
context, submit authority, or a command encoder. They expose immutable
|
|
529
|
+
capabilities and logical targets for plan construction. The active RenderGraph
|
|
530
|
+
owns the frame boundary; do not cast a plan context to a backend object or
|
|
531
|
+
encoder. The executable contract examples live in the plan-focused tests under
|
|
532
|
+
`src/record/__tests__` and `src/features`.
|
|
533
|
+
|
|
534
|
+
### Failure and recovery
|
|
535
|
+
|
|
536
|
+
`RenderError` is a closed union. Switch on `error.code`, then read
|
|
537
|
+
`error.expected`, `error.hint`, and the code-specific `error.detail`.
|
|
538
|
+
|
|
539
|
+
Feature capability checks are based on `Readonly<RhiCaps>`, and recovery actions
|
|
540
|
+
consume the structured `error.detail` context.
|
|
541
|
+
|
|
542
|
+
| Diagnostic state or code | Recovery action |
|
|
543
|
+
|:--|:--|
|
|
544
|
+
| `active` | Continue the next frame |
|
|
545
|
+
| `failed` / `render-feature-stage-failed` | Correct producer data and retry on the next frame |
|
|
546
|
+
| `disabled` / `render-feature-capability-missing` | Provide the capability on a replacement device; after device-loss recovery call `await renderer.recover()`. On a live renderer, the public recovery boundary returns a structured renderer-state-invalid result, so rebuild on a capable device instead. |
|
|
547
|
+
| `render-feature-registration-conflict` | Fix identity/order at registration |
|
|
548
|
+
| `render-feature-pass-order-conflict` | Reorder the declared dependency and re-plan on the next frame |
|
|
549
|
+
| `render-feature-preparation-failed` | Repair the named prepared resource and retry on the action in `error.detail.recovery`; after device loss, verify that the feature's declared shader was included in the recovery prewarm set |
|
|
550
|
+
| `render-feature-prepared-state-mismatch` | Read the discriminated `error.detail.reason`, repair the generation/layout/format mismatch, and retry |
|
|
551
|
+
| `render-feature-draw-recording-failed` | Read `error.detail.backendReason`, then retry after the host reports renderer recovery |
|
|
552
|
+
| `disposed` | Terminal; create a new renderer/feature registration |
|
|
553
|
+
|
|
554
|
+
Use `renderer.inspect()` for a read-only snapshot. Call `renderer.dispose()`
|
|
555
|
+
once or repeatedly; disposal is idempotent. Feature plans are assembled once
|
|
556
|
+
and the Standard host owns graph replacement and last-known-good recovery.
|
|
557
|
+
|
|
558
|
+
For a temporary presentation-owner handoff, call `renderer.releaseSurface()`.
|
|
559
|
+
It unconfigures the canvas and makes `draw()` fail closed without disposing the
|
|
560
|
+
Renderer, AssetRegistry, or GPU declarations. After the temporary owner is
|
|
561
|
+
gone, `renderer.restoreSurface()` re-enables lazy surface configuration on the
|
|
562
|
+
next draw. Both calls are idempotent; `dispose()` remains the terminal path.
|
|
563
|
+
|
|
564
|
+
For the complete declaration shape, read
|
|
565
|
+
[`features/types.ts`](src/features/types.ts) and
|
|
566
|
+
[`features/plan.ts`](src/features/plan.ts). For Standard profile and lane
|
|
567
|
+
selection, read the internal pipeline implementation through the host seam;
|
|
568
|
+
there is no public full-pipeline registration API. The producer
|
|
569
|
+
asset contract is [`@forgeax/engine-vfx`](../vfx/README.md), while graph
|
|
570
|
+
ownership is [`@forgeax/engine-render-graph`](../render-graph/README.md).
|
|
571
|
+
|
|
572
|
+
> [!WARNING]
|
|
573
|
+
> Wave 2 delivered this generic prepared public seam. A downstream Wave 3 VFX
|
|
574
|
+
> integration owns visible particle draws; render must not gain a
|
|
575
|
+
> particle-kind switch or VFX production dependency. See the
|
|
576
|
+
> [VFX Wave 3 handoff](https://github.com/ForgeaXGame/forgeax-engine-harness/blob/main/docs/vfx-particle-runtime-design.md).
|
|
577
|
+
|
|
578
|
+
Dynamic consumers use the same boundary explicitly:
|
|
579
|
+
|
|
580
|
+
```ts
|
|
581
|
+
const { Camera, MeshFilter, MeshRenderer } = await import('@forgeax/engine-render');
|
|
582
|
+
```
|
|
583
|
+
|
|
584
|
+
`@forgeax/engine-runtime` remains the host assembly entry for `createRenderer` and backend policy. Import `Materials` from this package. Runtime is not a compatibility barrel for render components.
|
|
585
|
+
|
|
586
|
+
Optional text, tilemap, and sprite authoring is intentionally isolated from the
|
|
587
|
+
base vocabulary:
|
|
588
|
+
|
|
589
|
+
```ts
|
|
590
|
+
import {
|
|
591
|
+
GlyphText,
|
|
592
|
+
SpriteAnimation,
|
|
593
|
+
Tilemap,
|
|
594
|
+
TransparentSort,
|
|
595
|
+
} from '@forgeax/engine-render/authoring';
|
|
596
|
+
```
|
|
597
|
+
|
|
598
|
+
`authoring` also owns the grouped transparent-bucket configuration values. A
|
|
599
|
+
consumer that composes sprites with an existing 3D game can call
|
|
600
|
+
`TransparentSort.configure(world, { mode: TransparentSort.layerY, yzAlpha: 1 })`;
|
|
601
|
+
it should not reach into `/internal`.
|
|
602
|
+
|
|
603
|
+
The root barrel does not expose frame stores or extract/plan/record owners.
|
|
604
|
+
Applications contribute work through `RenderFeature` plans; the Standard
|
|
605
|
+
renderer owns graph compilation and submission.
|
|
606
|
+
|
|
607
|
+
The render package has one narrow construction seam owned by the host. It is
|
|
608
|
+
not an application API or a compatibility route. Standard profile and
|
|
609
|
+
capability lanes own MSAA target selection and resolve; applications do not
|
|
610
|
+
replace the frame topology.
|
|
611
|
+
|
|
612
|
+
```mermaid
|
|
613
|
+
flowchart LR
|
|
614
|
+
World["World data"] --> Extract["extract"]
|
|
615
|
+
Extract --> Prepare["prepare"]
|
|
616
|
+
Prepare --> Record["record"]
|
|
617
|
+
Record --> Rhi["RHI submission"]
|
|
618
|
+
```
|
|
619
|
+
|
|
620
|
+
## Visibility contract
|
|
621
|
+
|
|
622
|
+
Quick start:
|
|
623
|
+
|
|
624
|
+
```ts
|
|
625
|
+
import { Visibility, VisibilityStateValue, resolveVisibility } from '@forgeax/engine-render';
|
|
626
|
+
|
|
627
|
+
world.spawn({
|
|
628
|
+
component: Visibility,
|
|
629
|
+
data: { state: VisibilityStateValue.hidden },
|
|
630
|
+
}).unwrap();
|
|
631
|
+
const snapshot = resolveVisibility(world);
|
|
632
|
+
```
|
|
633
|
+
|
|
634
|
+
| Stage | Truth | Diagnostic |
|
|
635
|
+
|:--|:--|:--|
|
|
636
|
+
| Author intent | `Visibility.state` is `inherited`, `hidden`, or `visible` | Read the ECS field or reflected `labels` |
|
|
637
|
+
| Effective state | `resolveVisibility(world).effective(entity)` applies valid scene parents | Inspect `snapshot.diagnostics` and `VisibilityResolution.source` |
|
|
638
|
+
| Render result | Render producers skip hidden candidates before material work | Read `renderer.inspect().visibilityStats`; it is not a frustum or picking metric |
|
|
639
|
+
|
|
640
|
+
If the state write returns an error, preserve `code`, `expected`, `hint`, and
|
|
641
|
+
`detail`, correct the enum value, and retry through `world.set`. If hierarchy
|
|
642
|
+
diagnostics are present, repair the scene relation and resolve again. Do not
|
|
643
|
+
hide the issue with a custom mesh, camera workaround, or material substitute.
|
|
644
|
+
|
|
645
|
+
Out of scope: camera frustum policy, picking, app lifecycle, asset import, and
|
|
646
|
+
VFX shadow behavior. `@forgeax/engine-vfx-render` remains the producer-owned
|
|
647
|
+
particle bridge and consumes the same effective visibility boundary.
|