@forgeax/engine-render 0.1.6 → 0.1.19
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/README.md +279 -2
- package/dist/.tsbuildinfo +1 -1
- package/dist/assembly/backend-contract.d.ts +12 -0
- package/dist/assembly/backend-contract.d.ts.map +1 -1
- package/dist/assembly/factory.d.ts +19 -2
- package/dist/assembly/factory.d.ts.map +1 -1
- package/dist/assembly/host-contract.d.ts +4 -0
- package/dist/assembly/host-contract.d.ts.map +1 -1
- package/dist/assembly/material/assembly.d.ts.map +1 -1
- package/dist/assembly/renderer-frame-transaction.d.ts +39 -0
- package/dist/assembly/renderer-frame-transaction.d.ts.map +1 -0
- package/dist/assembly/renderer-inspection.d.ts +22 -0
- package/dist/assembly/renderer-inspection.d.ts.map +1 -0
- package/dist/assembly/renderer-lifecycle.d.ts +4 -0
- package/dist/assembly/renderer-lifecycle.d.ts.map +1 -0
- package/dist/authoring.d.ts +1 -0
- package/dist/authoring.d.ts.map +1 -1
- package/dist/authoring.mjs +4 -2
- package/dist/authoring.mjs.map +1 -1
- package/dist/chunk-FJ6P52EE.mjs +46 -0
- package/dist/chunk-FJ6P52EE.mjs.map +1 -0
- package/dist/chunk-IPXCABEP.mjs +73 -0
- package/dist/chunk-IPXCABEP.mjs.map +1 -0
- package/dist/chunk-JDWARUOI.mjs +44 -0
- package/dist/chunk-JDWARUOI.mjs.map +1 -0
- package/dist/chunk-LOSO4CTV.mjs +901 -0
- package/dist/chunk-LOSO4CTV.mjs.map +1 -0
- package/dist/chunk-PCHBPYML.mjs +385 -0
- package/dist/chunk-PCHBPYML.mjs.map +1 -0
- package/dist/chunk-RJRUS55L.mjs +9323 -0
- package/dist/chunk-RJRUS55L.mjs.map +1 -0
- package/dist/{chunk-QC4VW3XJ.mjs → chunk-RXZ3RGOU.mjs} +4 -30
- package/dist/chunk-RXZ3RGOU.mjs.map +1 -0
- package/dist/{chunk-CQXZC5XI.mjs → chunk-VFPLTKCU.mjs} +79 -69
- package/dist/chunk-VFPLTKCU.mjs.map +1 -0
- package/dist/{chunk-SCRSAK5B.mjs → chunk-YTQ5C7YQ.mjs} +231 -127
- package/dist/chunk-YTQ5C7YQ.mjs.map +1 -0
- package/dist/components/atmosphere.d.ts +9 -0
- package/dist/components/atmosphere.d.ts.map +1 -0
- package/dist/components/camera.d.ts +2 -1
- package/dist/components/camera.d.ts.map +1 -1
- package/dist/components/fog.d.ts +8 -0
- package/dist/components/fog.d.ts.map +1 -0
- package/dist/components/index.d.ts +5 -0
- package/dist/components/index.d.ts.map +1 -1
- package/dist/components/lines.d.ts +5 -0
- package/dist/components/lines.d.ts.map +1 -0
- package/dist/components/motion-blur.d.ts +7 -0
- package/dist/components/motion-blur.d.ts.map +1 -0
- package/dist/components/points.d.ts +15 -0
- package/dist/components/points.d.ts.map +1 -0
- package/dist/construct-renderer.d.ts +2 -2
- package/dist/construct-renderer.d.ts.map +1 -1
- package/dist/construct-renderer.mjs +11419 -16442
- package/dist/construct-renderer.mjs.map +1 -1
- package/dist/device/device-scope.d.ts +4 -0
- package/dist/device/device-scope.d.ts.map +1 -1
- package/dist/environment/frame.d.ts +60 -0
- package/dist/environment/frame.d.ts.map +1 -0
- package/dist/environment/generation.d.ts +21 -0
- package/dist/environment/generation.d.ts.map +1 -0
- package/dist/environment/graph.d.ts +4 -0
- package/dist/environment/graph.d.ts.map +1 -0
- package/dist/environment/inspection.d.ts +48 -0
- package/dist/environment/inspection.d.ts.map +1 -0
- package/dist/environment/lifecycle.d.ts +39 -0
- package/dist/environment/lifecycle.d.ts.map +1 -0
- package/dist/environment/signature.d.ts +25 -0
- package/dist/environment/signature.d.ts.map +1 -0
- package/dist/errors/render.d.ts +217 -1
- package/dist/errors/render.d.ts.map +1 -1
- package/dist/extract/camera.d.ts +5 -0
- package/dist/extract/camera.d.ts.map +1 -0
- package/dist/extract/environment.d.ts +74 -0
- package/dist/extract/environment.d.ts.map +1 -0
- package/dist/extract/visibility.d.ts +1 -1
- package/dist/extract/visibility.d.ts.map +1 -1
- package/dist/features/host.d.ts +9 -2
- package/dist/features/host.d.ts.map +1 -1
- package/dist/features/motion-blur/motion-blur-feature.d.ts +16 -0
- package/dist/features/motion-blur/motion-blur-feature.d.ts.map +1 -0
- package/dist/features/motion-blur/motion-blur-params.d.ts +25 -0
- package/dist/features/motion-blur/motion-blur-params.d.ts.map +1 -0
- package/dist/features/plan.d.ts +17 -2
- package/dist/features/plan.d.ts.map +1 -1
- package/dist/features/prepared-gpu-work.d.ts +3 -1
- package/dist/features/prepared-gpu-work.d.ts.map +1 -1
- package/dist/features/prepared-graphics.d.ts +2 -1
- package/dist/features/prepared-graphics.d.ts.map +1 -1
- package/dist/features/render-graph-raster.d.ts +7 -2
- package/dist/features/render-graph-raster.d.ts.map +1 -1
- package/dist/features/targets.d.ts +3 -0
- package/dist/features/targets.d.ts.map +1 -1
- package/dist/features/types.d.ts +12 -0
- package/dist/features/types.d.ts.map +1 -1
- package/dist/fullscreen-post-process-pass.d.ts +7 -1
- package/dist/fullscreen-post-process-pass.d.ts.map +1 -1
- package/dist/gpu-driven/production-raster.d.ts.map +1 -1
- package/dist/gpu-scene.d.ts +2 -0
- package/dist/gpu-scene.d.ts.map +1 -1
- package/dist/ibl/skylight-bind-group.d.ts +5 -6
- package/dist/ibl/skylight-bind-group.d.ts.map +1 -1
- package/dist/index.d.ts +21 -6
- package/dist/index.d.ts.map +1 -1
- package/dist/index.mjs +8 -4
- package/dist/index.mjs.map +1 -1
- package/dist/inspection-types.d.ts +46 -1
- package/dist/inspection-types.d.ts.map +1 -1
- package/dist/internal.d.ts +2 -0
- package/dist/internal.d.ts.map +1 -1
- package/dist/internal.mjs +2 -0
- package/dist/materials.d.ts +22 -0
- package/dist/materials.d.ts.map +1 -1
- package/dist/pbr-pipeline.d.ts +12 -6
- package/dist/pbr-pipeline.d.ts.map +1 -1
- package/dist/pipeline/standard-forward-lane.d.ts.map +1 -1
- package/dist/pipeline/standard-pipeline.d.ts +3 -0
- package/dist/pipeline/standard-pipeline.d.ts.map +1 -1
- package/dist/pipeline/standard-post.d.ts +48 -0
- package/dist/pipeline/standard-post.d.ts.map +1 -0
- package/dist/pipeline/standard-profile.d.ts +3 -6
- package/dist/pipeline/standard-profile.d.ts.map +1 -1
- package/dist/pipeline-builder.d.ts +18 -0
- package/dist/pipeline-builder.d.ts.map +1 -1
- package/dist/pipeline-spec.d.ts.map +1 -1
- package/dist/plugin.d.ts.map +1 -1
- 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/record/frame-lighting.d.ts.map +1 -1
- package/dist/record/frame-snapshot.d.ts +100 -5
- package/dist/record/frame-snapshot.d.ts.map +1 -1
- package/dist/record/frame-targets.d.ts.map +1 -1
- package/dist/record/frame.d.ts +4 -2
- package/dist/record/frame.d.ts.map +1 -1
- package/dist/record/main-pass-geometry.d.ts +18 -0
- package/dist/record/main-pass-geometry.d.ts.map +1 -1
- package/dist/record/main-pass-material.d.ts +8 -5
- package/dist/record/main-pass-material.d.ts.map +1 -1
- package/dist/record/main-pass-sprite-draws.d.ts +8 -1
- package/dist/record/main-pass-sprite-draws.d.ts.map +1 -1
- package/dist/record/main-pass.d.ts +2 -0
- package/dist/record/main-pass.d.ts.map +1 -1
- package/dist/record/mesh-ssbo.d.ts.map +1 -1
- package/dist/record/render-context.d.ts +93 -18
- package/dist/record/render-context.d.ts.map +1 -1
- package/dist/record/shadow-pass.d.ts.map +1 -1
- package/dist/record/skybox-post-pass.d.ts +1 -11
- package/dist/record/skybox-post-pass.d.ts.map +1 -1
- package/dist/record/typed-frame-graph.d.ts +26 -2
- package/dist/record/typed-frame-graph.d.ts.map +1 -1
- package/dist/record/view-ubo.d.ts +10 -1
- package/dist/record/view-ubo.d.ts.map +1 -1
- package/dist/render-contract.d.ts +102 -10
- package/dist/render-contract.d.ts.map +1 -1
- package/dist/render-graph-primitives.d.ts.map +1 -1
- package/dist/render-pipeline.d.ts +50 -6
- package/dist/render-pipeline.d.ts.map +1 -1
- package/dist/render-system-extract.d.ts +32 -5
- package/dist/render-system-extract.d.ts.map +1 -1
- package/dist/render-system.d.ts +27 -5
- package/dist/render-system.d.ts.map +1 -1
- package/dist/scene/render-scene-types.d.ts +3 -0
- package/dist/scene/render-scene-types.d.ts.map +1 -1
- package/dist/scene/render-scene.d.ts +43 -2
- package/dist/scene/render-scene.d.ts.map +1 -1
- package/dist/temporal/coverage.d.ts +42 -0
- package/dist/temporal/coverage.d.ts.map +1 -0
- package/dist/temporal/frame-coordinator.d.ts +99 -0
- package/dist/temporal/frame-coordinator.d.ts.map +1 -0
- package/dist/temporal/gpu.d.ts +39 -0
- package/dist/temporal/gpu.d.ts.map +1 -0
- package/dist/temporal/history.d.ts +37 -0
- package/dist/temporal/history.d.ts.map +1 -0
- package/dist/temporal/index.d.ts +7 -0
- package/dist/temporal/index.d.ts.map +1 -0
- package/dist/temporal/index.mjs +8 -0
- package/dist/temporal/index.mjs.map +1 -0
- package/dist/temporal/inspection.d.ts +36 -0
- package/dist/temporal/inspection.d.ts.map +1 -0
- package/dist/temporal/scene-data-catalog.d.ts +48 -0
- package/dist/temporal/scene-data-catalog.d.ts.map +1 -0
- package/dist/temporal/scene-data.d.ts +43 -0
- package/dist/temporal/scene-data.d.ts.map +1 -0
- package/dist/temporal/standard-scene-data.d.ts +61 -0
- package/dist/temporal/standard-scene-data.d.ts.map +1 -0
- package/dist/temporal/taa-history-resources.d.ts +22 -0
- package/dist/temporal/taa-history-resources.d.ts.map +1 -0
- package/dist/temporal/taa-history-store.d.ts +27 -0
- package/dist/temporal/taa-history-store.d.ts.map +1 -0
- package/dist/temporal/taa-resolve.d.ts +15 -0
- package/dist/temporal/taa-resolve.d.ts.map +1 -0
- package/dist/temporal/temporal-view.d.ts +40 -0
- package/dist/temporal/temporal-view.d.ts.map +1 -0
- package/dist/temporal/transaction.d.ts +9 -0
- package/dist/temporal/transaction.d.ts.map +1 -0
- package/dist/temporal/view.d.ts +56 -0
- package/dist/temporal/view.d.ts.map +1 -0
- package/dist/transmission/backdrop.d.ts +147 -0
- package/dist/transmission/backdrop.d.ts.map +1 -0
- package/dist/transmission/inspection.d.ts +57 -0
- package/dist/transmission/inspection.d.ts.map +1 -0
- package/dist/transmission/oracle.d.ts +42 -0
- package/dist/transmission/oracle.d.ts.map +1 -0
- package/dist/transmission/projection.d.ts +37 -0
- package/dist/transmission/projection.d.ts.map +1 -0
- package/dist/typed-render-graph-primitives.d.ts +25 -2
- package/dist/typed-render-graph-primitives.d.ts.map +1 -1
- package/package.json +24 -19
- package/src/__tests__/ai-user-cold-start.integration.test.ts +59 -0
- package/src/__tests__/ai-user-public-surface.test-d.ts +45 -0
- package/src/__tests__/authoring-path.unit.test.ts +9 -0
- package/src/__tests__/bloom-exact-zero.unit.test.ts +202 -0
- package/src/__tests__/bloom-lifecycle.integration.test.ts +125 -0
- package/src/__tests__/construct-renderer-identity.unit.test.ts +4 -3
- package/src/__tests__/detached-inspection.integration.test.ts +177 -0
- package/src/__tests__/environment-fog-lanes.integration.test.ts +219 -0
- package/src/__tests__/environment-generation.integration.test.ts +141 -0
- package/src/__tests__/environment-selection.unit.test.ts +245 -0
- package/src/__tests__/factory-contract.integration.test.ts +1380 -9
- package/src/__tests__/frame-plan-contract.unit.test.ts +90 -0
- package/src/__tests__/fullscreen-feature-plan.unit.test.ts +7 -0
- package/src/__tests__/gpu-driven-indirect-raster-evidence.ts +12 -2
- package/src/__tests__/gpu-driven-production.integration.test.ts +74 -22
- package/src/__tests__/gpu-driven-view-graph.integration.test.ts +37 -0
- package/src/__tests__/gpu-scene.unit.test.ts +10 -0
- package/src/__tests__/injection-kind-owner.test-d.ts +2 -1
- package/src/__tests__/material-contract-inventory.unit.test.ts +62 -0
- package/src/__tests__/material-cooked-projection.unit.test.ts +18 -124
- package/src/__tests__/material-static-dynamic-route.unit.test.ts +28 -28
- package/src/__tests__/materials-transmission-validation.unit.test.ts +36 -0
- package/src/__tests__/morph-feature-plan.unit.test.ts +7 -0
- package/src/__tests__/motion-blur.pixel.integration.test.ts +121 -0
- package/src/__tests__/public-surface.test-d.ts +15 -1
- package/src/__tests__/render-error-code-owner.test-d.ts +15 -0
- package/src/__tests__/render-error-detail-ssot.test-d.ts +11 -2
- package/src/__tests__/render-error-exhaustive.test-d.ts +22 -0
- package/src/__tests__/render-feature-errors.unit.test.ts +33 -3
- package/src/__tests__/render-feature-gpu-work.integration.test.ts +44 -0
- package/src/__tests__/render-feature-plan.test-d.ts +22 -89
- package/src/__tests__/render-scene-projection.unit.test.ts +28 -0
- package/src/__tests__/render-temporal-environment-consumer.browser.test.ts +26 -0
- package/src/__tests__/render-temporal-environment-consumer.dawn.test.ts +21 -0
- package/src/__tests__/renderer-factory-material-contract.unit.test.ts +433 -1
- package/src/__tests__/renderer-frame-transaction.integration.test.ts +405 -0
- package/src/__tests__/renderer-lifecycle.integration.test.ts +22 -0
- package/src/__tests__/scene-data-catalog.unit.test.ts +59 -0
- package/src/__tests__/scene-data-consumer.integration.test.ts +67 -0
- package/src/__tests__/scene-data-contract.test-d.ts +35 -0
- package/src/__tests__/scene-data-inspection.unit.test.ts +41 -0
- package/src/__tests__/scene-data-public-surface.test-d.ts +34 -0
- package/src/__tests__/shader-manifest-fixture.ts +111 -0
- package/src/__tests__/skinned-shadow-caster.test.ts +102 -0
- package/src/__tests__/standard-clustered-pipeline.unit.test.ts +24 -3
- package/src/__tests__/standard-pipeline.dawn.test.ts +15 -0
- package/src/__tests__/standard-pipeline.integration.test.ts +543 -1
- package/src/__tests__/standard-profile-oracle.unit.test.ts +10 -2
- package/src/__tests__/standard-temporal-producer.integration.test.ts +35 -0
- package/src/__tests__/surface-configuration.unit.test.ts +211 -12
- package/src/__tests__/taa-transaction.integration.test.ts +30 -0
- package/src/__tests__/temporal-admission.integration.test.ts +40 -0
- package/src/__tests__/temporal-coverage.unit.test.ts +35 -0
- package/src/__tests__/temporal-demand.unit.test.ts +44 -0
- package/src/__tests__/temporal-frame-coordinator.unit.test.ts +64 -0
- package/src/__tests__/temporal-graph-topology.unit.test.ts +51 -0
- package/src/__tests__/temporal-history-lifecycle.unit.test.ts +170 -0
- package/src/__tests__/temporal-performance.integration.test.ts +615 -0
- package/src/__tests__/temporal-reset-matrix.unit.test.ts +97 -0
- package/src/__tests__/temporal-transaction.integration.test.ts +60 -0
- package/src/__tests__/temporal-view.unit.test.ts +152 -0
- package/src/__tests__/transmission-prewarm.unit.test.ts +93 -0
- package/src/__tests__/typed-pipeline-topology.unit.test.ts +230 -1
- package/src/__tests__/urp-pipeline-targets.unit.test.ts +25 -1
- package/src/__tests__/urp-pipeline.unit.test.ts +4 -3
- package/src/__tests__/visibility-extract.integration.test.ts +27 -1
- package/src/__tests__/visibility-producer-matrix.integration.test.ts +10 -0
- package/src/assembly/backend-contract.ts +47 -1
- package/src/assembly/factory.ts +1295 -507
- package/src/assembly/host-contract.ts +4 -0
- package/src/assembly/material/assembly.ts +2 -5
- package/src/assembly/renderer-frame-transaction.ts +75 -0
- package/src/assembly/renderer-inspection.ts +112 -0
- package/src/assembly/renderer-lifecycle.ts +6 -0
- package/src/authoring.ts +1 -0
- package/src/components/__tests__/motion-blur.unit.test.ts +14 -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 +6 -1
- package/src/components/atmosphere.ts +10 -0
- package/src/components/camera.ts +2 -1
- package/src/components/fog.ts +9 -0
- package/src/components/index.ts +10 -0
- package/src/components/lines.ts +18 -0
- package/src/components/motion-blur.ts +8 -0
- package/src/components/points.ts +40 -0
- package/src/construct-renderer.ts +40 -3
- package/src/device/device-scope.ts +15 -1
- package/src/environment/frame.ts +185 -0
- package/src/environment/generation.ts +23 -0
- package/src/environment/graph.ts +9 -0
- package/src/environment/inspection.ts +87 -0
- package/src/environment/lifecycle.ts +250 -0
- package/src/environment/signature.ts +55 -0
- package/src/errors/render.ts +429 -1
- package/src/extract/camera.ts +78 -0
- package/src/extract/environment.ts +171 -0
- package/src/extract/visibility.ts +38 -19
- package/src/features/host.ts +36 -5
- package/src/features/motion-blur/__tests__/motion-blur-feature.unit.test.ts +67 -0
- package/src/features/motion-blur/__tests__/motion-blur-params.unit.test.ts +53 -0
- package/src/features/motion-blur/motion-blur-feature.ts +119 -0
- package/src/features/motion-blur/motion-blur-params.ts +89 -0
- package/src/features/plan.ts +32 -3
- package/src/features/prepared-gpu-work.ts +21 -6
- package/src/features/prepared-graphics.ts +2 -1
- package/src/features/render-graph-raster.ts +24 -4
- package/src/features/targets.ts +24 -2
- package/src/features/types.ts +13 -0
- package/src/fullscreen-post-process-pass.ts +34 -4
- package/src/gpu-driven/production-raster.ts +6 -1
- package/src/gpu-scene.ts +24 -0
- package/src/ibl/skylight-bind-group.ts +30 -38
- package/src/index.ts +83 -6
- package/src/inspection-types.ts +52 -0
- package/src/internal.ts +5 -0
- package/src/materials.ts +119 -24
- package/src/pbr-pipeline.ts +66 -20
- package/src/pipeline/standard-forward-lane.ts +158 -101
- package/src/pipeline/standard-pipeline.ts +156 -105
- package/src/pipeline/standard-post.ts +373 -0
- package/src/pipeline/standard-profile.ts +11 -11
- package/src/pipeline-builder.ts +102 -12
- package/src/pipeline-spec.ts +9 -0
- package/src/plugin.ts +6 -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/record/__tests__/fullscreen-temporal-routing.unit.test.ts +25 -0
- package/src/record/__tests__/main-pass-geometry.unit.test.ts +47 -0
- package/src/record/__tests__/material-bg-cache.unit.test.ts +12 -1
- package/src/record/__tests__/material-pipeline-pending-cache.unit.test.ts +22 -0
- package/src/record/__tests__/sprite-material-abi.unit.test.ts +75 -0
- package/src/record/__tests__/standard-pbr-ubo-layout.unit.test.ts +67 -0
- package/src/record/__tests__/temporal-payload.unit.test.ts +164 -0
- package/src/record/__tests__/typed-frame-graph-plan.unit.test.ts +127 -0
- package/src/record/frame-lighting.ts +14 -2
- package/src/record/frame-snapshot.ts +129 -5
- package/src/record/frame-targets.ts +15 -6
- package/src/record/frame.ts +119 -4
- package/src/record/main-pass-geometry.ts +178 -40
- package/src/record/main-pass-material.ts +114 -66
- package/src/record/main-pass-sprite-draws.ts +79 -102
- package/src/record/main-pass.ts +83 -7
- package/src/record/mesh-ssbo.ts +22 -3
- package/src/record/render-context.ts +209 -23
- package/src/record/shadow-pass.ts +129 -28
- package/src/record/skybox-post-pass.ts +99 -42
- package/src/record/typed-frame-graph.ts +582 -42
- package/src/record/view-ubo.ts +99 -4
- package/src/render-contract.ts +121 -7
- package/src/render-graph-primitives.ts +18 -1
- package/src/render-pipeline.ts +100 -27
- package/src/render-system-extract.ts +264 -77
- package/src/render-system.ts +786 -43
- package/src/scene/render-scene-types.ts +3 -0
- package/src/scene/render-scene.ts +307 -9
- package/src/temporal/__tests__/taa-history-resources.unit.test.ts +45 -0
- package/src/temporal/coverage.ts +76 -0
- package/src/temporal/frame-coordinator.ts +311 -0
- package/src/temporal/gpu.ts +287 -0
- package/src/temporal/history.ts +92 -0
- package/src/temporal/index.ts +6 -0
- package/src/temporal/inspection.ts +97 -0
- package/src/temporal/scene-data-catalog.ts +200 -0
- package/src/temporal/scene-data.ts +149 -0
- package/src/temporal/standard-scene-data.ts +182 -0
- package/src/temporal/taa-history-resources.ts +128 -0
- package/src/temporal/taa-history-store.ts +79 -0
- package/src/temporal/taa-resolve.ts +34 -0
- package/src/temporal/temporal-view.ts +169 -0
- package/src/temporal/transaction.ts +17 -0
- package/src/temporal/view.ts +161 -0
- package/src/transmission/__tests__/capability.unit.test.ts +83 -0
- package/src/transmission/__tests__/composition.integration.test.ts +161 -0
- package/src/transmission/__tests__/inspection.unit.test.ts +241 -0
- package/src/transmission/__tests__/lifecycle.integration.test.ts +96 -0
- package/src/transmission/__tests__/oracle.unit.test.ts +131 -0
- package/src/transmission/__tests__/projection.unit.test.ts +71 -0
- package/src/transmission/__tests__/standard-transmission.dawn.test.ts +438 -0
- package/src/transmission/__tests__/transmission-backdrop-topology.unit.test.ts +109 -0
- package/src/transmission/__tests__/transmission-backdrop.dawn.test.ts +105 -0
- package/src/transmission/backdrop.ts +572 -0
- package/src/transmission/inspection.ts +190 -0
- package/src/transmission/oracle.ts +141 -0
- package/src/transmission/projection.ts +83 -0
- package/src/typed-render-graph-primitives.ts +162 -9
- package/dist/__tests__/authoring-path.unit.test.d.ts +0 -2
- package/dist/__tests__/authoring-path.unit.test.d.ts.map +0 -1
- package/dist/__tests__/backend-selection-rhi-capture.test-d.d.ts +0 -2
- package/dist/__tests__/backend-selection-rhi-capture.test-d.d.ts.map +0 -1
- package/dist/__tests__/callback-inference.test-d.d.ts +0 -2
- package/dist/__tests__/callback-inference.test-d.d.ts.map +0 -1
- package/dist/__tests__/cluster-binner.test.d.ts +0 -2
- package/dist/__tests__/cluster-binner.test.d.ts.map +0 -1
- package/dist/__tests__/cluster-grid-default-surface.unit.test.d.ts +0 -2
- package/dist/__tests__/cluster-grid-default-surface.unit.test.d.ts.map +0 -1
- package/dist/__tests__/construct-renderer-identity.unit.test.d.ts +0 -2
- package/dist/__tests__/construct-renderer-identity.unit.test.d.ts.map +0 -1
- package/dist/__tests__/device-scope-lifecycle.unit.test.d.ts +0 -2
- package/dist/__tests__/device-scope-lifecycle.unit.test.d.ts.map +0 -1
- package/dist/__tests__/device-scope-stale-matrix.unit.test.d.ts +0 -2
- package/dist/__tests__/device-scope-stale-matrix.unit.test.d.ts.map +0 -1
- package/dist/__tests__/direct-extract-consumer-contract.test-d.d.ts +0 -2
- package/dist/__tests__/direct-extract-consumer-contract.test-d.d.ts.map +0 -1
- package/dist/__tests__/direct-light-snapshot.unit.test.d.ts +0 -2
- package/dist/__tests__/direct-light-snapshot.unit.test.d.ts.map +0 -1
- package/dist/__tests__/factory-contract.integration.test.d.ts +0 -2
- package/dist/__tests__/factory-contract.integration.test.d.ts.map +0 -1
- package/dist/__tests__/fallback-row-stride-surface.unit.test.d.ts +0 -2
- package/dist/__tests__/fallback-row-stride-surface.unit.test.d.ts.map +0 -1
- package/dist/__tests__/frame-observation.contract.test.d.ts +0 -2
- package/dist/__tests__/frame-observation.contract.test.d.ts.map +0 -1
- package/dist/__tests__/fullscreen-feature-plan.unit.test.d.ts +0 -2
- package/dist/__tests__/fullscreen-feature-plan.unit.test.d.ts.map +0 -1
- package/dist/__tests__/glyph-text-layout-recovery.unit.test.d.ts +0 -2
- package/dist/__tests__/glyph-text-layout-recovery.unit.test.d.ts.map +0 -1
- package/dist/__tests__/gpu-driven-indirect-raster-evidence.d.ts +0 -6
- package/dist/__tests__/gpu-driven-indirect-raster-evidence.d.ts.map +0 -1
- package/dist/__tests__/gpu-driven-indirect-raster.browser.test.d.ts +0 -2
- package/dist/__tests__/gpu-driven-indirect-raster.browser.test.d.ts.map +0 -1
- package/dist/__tests__/gpu-driven-indirect-raster.dawn.test.d.ts +0 -2
- package/dist/__tests__/gpu-driven-indirect-raster.dawn.test.d.ts.map +0 -1
- package/dist/__tests__/gpu-driven-production.integration.test.d.ts +0 -2
- package/dist/__tests__/gpu-driven-production.integration.test.d.ts.map +0 -1
- package/dist/__tests__/gpu-driven-scaling.unit.test.d.ts +0 -2
- package/dist/__tests__/gpu-driven-scaling.unit.test.d.ts.map +0 -1
- package/dist/__tests__/gpu-driven-view-gpu-evidence.d.ts +0 -18
- package/dist/__tests__/gpu-driven-view-gpu-evidence.d.ts.map +0 -1
- package/dist/__tests__/gpu-driven-view-graph.integration.test.d.ts +0 -2
- package/dist/__tests__/gpu-driven-view-graph.integration.test.d.ts.map +0 -1
- package/dist/__tests__/gpu-driven-view-reference.d.ts +0 -15
- package/dist/__tests__/gpu-driven-view-reference.d.ts.map +0 -1
- package/dist/__tests__/gpu-driven-view.browser.test.d.ts +0 -2
- package/dist/__tests__/gpu-driven-view.browser.test.d.ts.map +0 -1
- package/dist/__tests__/gpu-driven-view.dawn.test.d.ts +0 -2
- package/dist/__tests__/gpu-driven-view.dawn.test.d.ts.map +0 -1
- package/dist/__tests__/gpu-driven-view.unit.test.d.ts +0 -2
- package/dist/__tests__/gpu-driven-view.unit.test.d.ts.map +0 -1
- package/dist/__tests__/gpu-resource-store-stride.unit.test.d.ts +0 -2
- package/dist/__tests__/gpu-resource-store-stride.unit.test.d.ts.map +0 -1
- package/dist/__tests__/gpu-scene-render-graph-gpu.d.ts +0 -7
- package/dist/__tests__/gpu-scene-render-graph-gpu.d.ts.map +0 -1
- package/dist/__tests__/gpu-scene-render-graph.browser.test.d.ts +0 -2
- package/dist/__tests__/gpu-scene-render-graph.browser.test.d.ts.map +0 -1
- package/dist/__tests__/gpu-scene-render-graph.dawn.test.d.ts +0 -2
- package/dist/__tests__/gpu-scene-render-graph.dawn.test.d.ts.map +0 -1
- package/dist/__tests__/gpu-scene-schema.unit.test.d.ts +0 -2
- package/dist/__tests__/gpu-scene-schema.unit.test.d.ts.map +0 -1
- package/dist/__tests__/gpu-scene.dawn.test.d.ts +0 -2
- package/dist/__tests__/gpu-scene.dawn.test.d.ts.map +0 -1
- package/dist/__tests__/gpu-scene.unit.test.d.ts +0 -2
- package/dist/__tests__/gpu-scene.unit.test.d.ts.map +0 -1
- package/dist/__tests__/ibl/face-uniforms.unit.test.d.ts +0 -2
- package/dist/__tests__/ibl/face-uniforms.unit.test.d.ts.map +0 -1
- package/dist/__tests__/infinite-grid-no-vertex-probe.unit.test.d.ts +0 -2
- package/dist/__tests__/infinite-grid-no-vertex-probe.unit.test.d.ts.map +0 -1
- package/dist/__tests__/injection-kind-owner.test-d.d.ts +0 -2
- package/dist/__tests__/injection-kind-owner.test-d.d.ts.map +0 -1
- package/dist/__tests__/ktx2-basis-gpu-consumer.dawn.test.d.ts +0 -2
- package/dist/__tests__/ktx2-basis-gpu-consumer.dawn.test.d.ts.map +0 -1
- package/dist/__tests__/light-buffer-layout.unit.test.d.ts +0 -2
- package/dist/__tests__/light-buffer-layout.unit.test.d.ts.map +0 -1
- package/dist/__tests__/material-contract-inventory.unit.test.d.ts +0 -2
- package/dist/__tests__/material-contract-inventory.unit.test.d.ts.map +0 -1
- package/dist/__tests__/material-cooked-projection.unit.test.d.ts +0 -2
- package/dist/__tests__/material-cooked-projection.unit.test.d.ts.map +0 -1
- package/dist/__tests__/material-snapshot-mutation.integration.test.d.ts +0 -2
- package/dist/__tests__/material-snapshot-mutation.integration.test.d.ts.map +0 -1
- package/dist/__tests__/material-static-dynamic-route.unit.test.d.ts +0 -2
- package/dist/__tests__/material-static-dynamic-route.unit.test.d.ts.map +0 -1
- package/dist/__tests__/material-stride-surface.unit.test.d.ts +0 -2
- package/dist/__tests__/material-stride-surface.unit.test.d.ts.map +0 -1
- package/dist/__tests__/mesh-buffer-usage-surface.unit.test.d.ts +0 -2
- package/dist/__tests__/mesh-buffer-usage-surface.unit.test.d.ts.map +0 -1
- package/dist/__tests__/mesh-material-bindings.unit.test.d.ts +0 -2
- package/dist/__tests__/mesh-material-bindings.unit.test.d.ts.map +0 -1
- package/dist/__tests__/mesh-stride-surface.unit.test.d.ts +0 -2
- package/dist/__tests__/mesh-stride-surface.unit.test.d.ts.map +0 -1
- package/dist/__tests__/morph-culling-reentry.dawn.test.d.ts +0 -2
- package/dist/__tests__/morph-culling-reentry.dawn.test.d.ts.map +0 -1
- package/dist/__tests__/morph-feature-gpu-work.integration.test.d.ts +0 -2
- package/dist/__tests__/morph-feature-gpu-work.integration.test.d.ts.map +0 -1
- package/dist/__tests__/morph-feature-plan.unit.test.d.ts +0 -2
- package/dist/__tests__/morph-feature-plan.unit.test.d.ts.map +0 -1
- package/dist/__tests__/morph-visual-evidence.integration.test.d.ts +0 -2
- package/dist/__tests__/morph-visual-evidence.integration.test.d.ts.map +0 -1
- package/dist/__tests__/nineslice-handle-surface.unit.test.d.ts +0 -2
- package/dist/__tests__/nineslice-handle-surface.unit.test.d.ts.map +0 -1
- package/dist/__tests__/post-process-error-policy-owner.unit.test.d.ts +0 -2
- package/dist/__tests__/post-process-error-policy-owner.unit.test.d.ts.map +0 -1
- package/dist/__tests__/prepared-buffer-kind-owner.test-d.d.ts +0 -2
- package/dist/__tests__/prepared-buffer-kind-owner.test-d.d.ts.map +0 -1
- package/dist/__tests__/prepared-graphics-capability.unit.test.d.ts +0 -2
- package/dist/__tests__/prepared-graphics-capability.unit.test.d.ts.map +0 -1
- package/dist/__tests__/prepared-graphics-generation.unit.test.d.ts +0 -2
- package/dist/__tests__/prepared-graphics-generation.unit.test.d.ts.map +0 -1
- package/dist/__tests__/prepared-graphics-lifecycle.unit.test.d.ts +0 -2
- package/dist/__tests__/prepared-graphics-lifecycle.unit.test.d.ts.map +0 -1
- package/dist/__tests__/prepared-graphics-pipeline-warmup.unit.test.d.ts +0 -2
- package/dist/__tests__/prepared-graphics-pipeline-warmup.unit.test.d.ts.map +0 -1
- package/dist/__tests__/prepared-graphics-resolver.unit.test.d.ts +0 -2
- package/dist/__tests__/prepared-graphics-resolver.unit.test.d.ts.map +0 -1
- package/dist/__tests__/prepared-graphics-snapshot.unit.test.d.ts +0 -2
- package/dist/__tests__/prepared-graphics-snapshot.unit.test.d.ts.map +0 -1
- package/dist/__tests__/prepared-graphics-store.unit.test.d.ts +0 -2
- package/dist/__tests__/prepared-graphics-store.unit.test.d.ts.map +0 -1
- package/dist/__tests__/prepared-graphics-validation.unit.test.d.ts +0 -2
- package/dist/__tests__/prepared-graphics-validation.unit.test.d.ts.map +0 -1
- package/dist/__tests__/profiler-default-off.test.d.ts +0 -2
- package/dist/__tests__/profiler-default-off.test.d.ts.map +0 -1
- package/dist/__tests__/profiler-phase-catalog.test.d.ts +0 -2
- package/dist/__tests__/profiler-phase-catalog.test.d.ts.map +0 -1
- package/dist/__tests__/profiler-phase-integration.test.d.ts +0 -2
- package/dist/__tests__/profiler-phase-integration.test.d.ts.map +0 -1
- package/dist/__tests__/profiler-phase-token.test.d.ts +0 -2
- package/dist/__tests__/profiler-phase-token.test.d.ts.map +0 -1
- package/dist/__tests__/public-surface.test-d.d.ts +0 -2
- package/dist/__tests__/public-surface.test-d.d.ts.map +0 -1
- package/dist/__tests__/recover-error-policy-owner.unit.test.d.ts +0 -2
- package/dist/__tests__/recover-error-policy-owner.unit.test.d.ts.map +0 -1
- package/dist/__tests__/render-error-code-owner.test-d.d.ts +0 -2
- package/dist/__tests__/render-error-code-owner.test-d.d.ts.map +0 -1
- package/dist/__tests__/render-error-detail-ssot.test-d.d.ts +0 -2
- package/dist/__tests__/render-error-detail-ssot.test-d.d.ts.map +0 -1
- package/dist/__tests__/render-error-exhaustive.test-d.d.ts +0 -2
- package/dist/__tests__/render-error-exhaustive.test-d.d.ts.map +0 -1
- package/dist/__tests__/render-feature-assembly.test-d.d.ts +0 -2
- package/dist/__tests__/render-feature-assembly.test-d.d.ts.map +0 -1
- package/dist/__tests__/render-feature-context.test-d.d.ts +0 -2
- package/dist/__tests__/render-feature-context.test-d.d.ts.map +0 -1
- package/dist/__tests__/render-feature-contract.test-d.d.ts +0 -2
- package/dist/__tests__/render-feature-contract.test-d.d.ts.map +0 -1
- package/dist/__tests__/render-feature-diagnostics.unit.test.d.ts +0 -2
- package/dist/__tests__/render-feature-diagnostics.unit.test.d.ts.map +0 -1
- package/dist/__tests__/render-feature-docs.unit.test.d.ts +0 -2
- package/dist/__tests__/render-feature-docs.unit.test.d.ts.map +0 -1
- package/dist/__tests__/render-feature-errors.unit.test.d.ts +0 -2
- package/dist/__tests__/render-feature-errors.unit.test.d.ts.map +0 -1
- package/dist/__tests__/render-feature-gpu-work.integration.test.d.ts +0 -2
- package/dist/__tests__/render-feature-gpu-work.integration.test.d.ts.map +0 -1
- package/dist/__tests__/render-feature-plan.test-d.d.ts +0 -2
- package/dist/__tests__/render-feature-plan.test-d.d.ts.map +0 -1
- package/dist/__tests__/render-feature-plan.unit.test.d.ts +0 -2
- package/dist/__tests__/render-feature-plan.unit.test.d.ts.map +0 -1
- package/dist/__tests__/render-feature-prepared-diagnostics.unit.test.d.ts +0 -2
- package/dist/__tests__/render-feature-prepared-diagnostics.unit.test.d.ts.map +0 -1
- package/dist/__tests__/render-feature-prepared-errors.test-d.d.ts +0 -2
- package/dist/__tests__/render-feature-prepared-errors.test-d.d.ts.map +0 -1
- package/dist/__tests__/render-feature-prepared-graphics-docs.unit.test.d.ts +0 -2
- package/dist/__tests__/render-feature-prepared-graphics-docs.unit.test.d.ts.map +0 -1
- package/dist/__tests__/render-feature-prepared-graphics-isolation.unit.test.d.ts +0 -2
- package/dist/__tests__/render-feature-prepared-graphics-isolation.unit.test.d.ts.map +0 -1
- package/dist/__tests__/render-feature-prepared-graphics-negative.test-d.d.ts +0 -2
- package/dist/__tests__/render-feature-prepared-graphics-negative.test-d.d.ts.map +0 -1
- package/dist/__tests__/render-feature-prepared-graphics.test-d.d.ts +0 -2
- package/dist/__tests__/render-feature-prepared-graphics.test-d.d.ts.map +0 -1
- package/dist/__tests__/render-feature-prepared-graphics.unit.test.d.ts +0 -2
- package/dist/__tests__/render-feature-prepared-graphics.unit.test.d.ts.map +0 -1
- package/dist/__tests__/render-feature-public-surface.test-d.d.ts +0 -2
- package/dist/__tests__/render-feature-public-surface.test-d.d.ts.map +0 -1
- package/dist/__tests__/render-feature-retry.unit.test.d.ts +0 -2
- package/dist/__tests__/render-feature-retry.unit.test.d.ts.map +0 -1
- package/dist/__tests__/render-feature-scheduling.unit.test.d.ts +0 -2
- package/dist/__tests__/render-feature-scheduling.unit.test.d.ts.map +0 -1
- package/dist/__tests__/render-feature-stage-failed-policy-owner.unit.test.d.ts +0 -2
- package/dist/__tests__/render-feature-stage-failed-policy-owner.unit.test.d.ts.map +0 -1
- package/dist/__tests__/render-feature-stage-fault-recovery.unit.test.d.ts +0 -2
- package/dist/__tests__/render-feature-stage-fault-recovery.unit.test.d.ts.map +0 -1
- package/dist/__tests__/render-feature-visibility-context.test-d.d.ts +0 -2
- package/dist/__tests__/render-feature-visibility-context.test-d.d.ts.map +0 -1
- package/dist/__tests__/render-feature-visibility-context.unit.test.d.ts +0 -2
- package/dist/__tests__/render-feature-visibility-context.unit.test.d.ts.map +0 -1
- package/dist/__tests__/render-feature-zero-work.unit.test.d.ts +0 -2
- package/dist/__tests__/render-feature-zero-work.unit.test.d.ts.map +0 -1
- package/dist/__tests__/render-graph-compute-raster-gpu.d.ts +0 -7
- package/dist/__tests__/render-graph-compute-raster-gpu.d.ts.map +0 -1
- package/dist/__tests__/render-graph-compute-raster.browser.test.d.ts +0 -2
- package/dist/__tests__/render-graph-compute-raster.browser.test.d.ts.map +0 -1
- package/dist/__tests__/render-graph-compute-raster.dawn.test.d.ts +0 -2
- package/dist/__tests__/render-graph-compute-raster.dawn.test.d.ts.map +0 -1
- package/dist/__tests__/render-graph-hzb-gpu.d.ts +0 -7
- package/dist/__tests__/render-graph-hzb-gpu.d.ts.map +0 -1
- package/dist/__tests__/render-graph-hzb.browser.test.d.ts +0 -2
- package/dist/__tests__/render-graph-hzb.browser.test.d.ts.map +0 -1
- package/dist/__tests__/render-graph-hzb.dawn.test.d.ts +0 -2
- package/dist/__tests__/render-graph-hzb.dawn.test.d.ts.map +0 -1
- package/dist/__tests__/render-graph-primitives.unit.test.d.ts +0 -2
- package/dist/__tests__/render-graph-primitives.unit.test.d.ts.map +0 -1
- package/dist/__tests__/render-graph-storage-indirect-gpu.d.ts +0 -12
- package/dist/__tests__/render-graph-storage-indirect-gpu.d.ts.map +0 -1
- package/dist/__tests__/render-graph-storage-indirect.browser.test.d.ts +0 -2
- package/dist/__tests__/render-graph-storage-indirect.browser.test.d.ts.map +0 -1
- package/dist/__tests__/render-graph-storage-indirect.dawn.test.d.ts +0 -2
- package/dist/__tests__/render-graph-storage-indirect.dawn.test.d.ts.map +0 -1
- package/dist/__tests__/render-scene-projection.unit.test.d.ts +0 -2
- package/dist/__tests__/render-scene-projection.unit.test.d.ts.map +0 -1
- package/dist/__tests__/renderer-factory-material-contract.unit.test.d.ts +0 -2
- package/dist/__tests__/renderer-factory-material-contract.unit.test.d.ts.map +0 -1
- package/dist/__tests__/renderer-lifecycle.integration.test.d.ts +0 -2
- package/dist/__tests__/renderer-lifecycle.integration.test.d.ts.map +0 -1
- package/dist/__tests__/rhi-backend-package-boundary.unit.test.d.ts +0 -2
- package/dist/__tests__/rhi-backend-package-boundary.unit.test.d.ts.map +0 -1
- package/dist/__tests__/scriptable-pack-consumer.test-d.d.ts +0 -2
- package/dist/__tests__/scriptable-pack-consumer.test-d.d.ts.map +0 -1
- package/dist/__tests__/shader-stage-surface.unit.test.d.ts +0 -2
- package/dist/__tests__/shader-stage-surface.unit.test.d.ts.map +0 -1
- package/dist/__tests__/ssao-config.unit.test.d.ts +0 -2
- package/dist/__tests__/ssao-config.unit.test.d.ts.map +0 -1
- package/dist/__tests__/ssao-kernel-surface.unit.test.d.ts +0 -2
- package/dist/__tests__/ssao-kernel-surface.unit.test.d.ts.map +0 -1
- package/dist/__tests__/standard-clustered-pipeline.unit.test.d.ts +0 -2
- package/dist/__tests__/standard-clustered-pipeline.unit.test.d.ts.map +0 -1
- package/dist/__tests__/standard-descriptors.test-d.d.ts +0 -2
- package/dist/__tests__/standard-descriptors.test-d.d.ts.map +0 -1
- package/dist/__tests__/standard-pipeline.dawn.test.d.ts +0 -2
- package/dist/__tests__/standard-pipeline.dawn.test.d.ts.map +0 -1
- package/dist/__tests__/standard-pipeline.integration.test.d.ts +0 -2
- package/dist/__tests__/standard-pipeline.integration.test.d.ts.map +0 -1
- package/dist/__tests__/standard-profile-oracle.unit.test.d.ts +0 -2
- package/dist/__tests__/standard-profile-oracle.unit.test.d.ts.map +0 -1
- package/dist/__tests__/surface-configuration.unit.test.d.ts +0 -2
- package/dist/__tests__/surface-configuration.unit.test.d.ts.map +0 -1
- package/dist/__tests__/texture-usage-surface.unit.test.d.ts +0 -2
- package/dist/__tests__/texture-usage-surface.unit.test.d.ts.map +0 -1
- package/dist/__tests__/typed-pipeline-topology.unit.test.d.ts +0 -2
- package/dist/__tests__/typed-pipeline-topology.unit.test.d.ts.map +0 -1
- package/dist/__tests__/urp-pipeline-targets.unit.test.d.ts +0 -2
- package/dist/__tests__/urp-pipeline-targets.unit.test.d.ts.map +0 -1
- package/dist/__tests__/urp-pipeline.unit.test.d.ts +0 -2
- package/dist/__tests__/urp-pipeline.unit.test.d.ts.map +0 -1
- package/dist/__tests__/vertex-color-pipeline.unit.test.d.ts +0 -2
- package/dist/__tests__/vertex-color-pipeline.unit.test.d.ts.map +0 -1
- package/dist/__tests__/vertex-layout-consumer.unit.test.d.ts +0 -2
- package/dist/__tests__/vertex-layout-consumer.unit.test.d.ts.map +0 -1
- package/dist/__tests__/visibility-diagnostics.integration.test.d.ts +0 -2
- package/dist/__tests__/visibility-diagnostics.integration.test.d.ts.map +0 -1
- package/dist/__tests__/visibility-extract.integration.test.d.ts +0 -2
- package/dist/__tests__/visibility-extract.integration.test.d.ts.map +0 -1
- package/dist/__tests__/visibility-extract.perf.test.d.ts +0 -2
- package/dist/__tests__/visibility-extract.perf.test.d.ts.map +0 -1
- package/dist/__tests__/visibility-feature-dedup.integration.test.d.ts +0 -2
- package/dist/__tests__/visibility-feature-dedup.integration.test.d.ts.map +0 -1
- package/dist/__tests__/visibility-hidden-report.unit.test.d.ts +0 -2
- package/dist/__tests__/visibility-hidden-report.unit.test.d.ts.map +0 -1
- package/dist/__tests__/visibility-instances.integration.test.d.ts +0 -2
- package/dist/__tests__/visibility-instances.integration.test.d.ts.map +0 -1
- package/dist/__tests__/visibility-multi-world.integration.test.d.ts +0 -2
- package/dist/__tests__/visibility-multi-world.integration.test.d.ts.map +0 -1
- package/dist/__tests__/visibility-producer-matrix.integration.test.d.ts +0 -2
- package/dist/__tests__/visibility-producer-matrix.integration.test.d.ts.map +0 -1
- package/dist/__tests__/visibility-producer-matrix.unit.test.d.ts +0 -2
- package/dist/__tests__/visibility-producer-matrix.unit.test.d.ts.map +0 -1
- package/dist/__tests__/visibility-public-surface.test-d.d.ts +0 -2
- package/dist/__tests__/visibility-public-surface.test-d.d.ts.map +0 -1
- package/dist/__tests__/visibility-resolver.unit.test.d.ts +0 -2
- package/dist/__tests__/visibility-resolver.unit.test.d.ts.map +0 -1
- package/dist/__tests__/visibility-resource-short-circuit.unit.test.d.ts +0 -2
- package/dist/__tests__/visibility-resource-short-circuit.unit.test.d.ts.map +0 -1
- package/dist/__tests__/visibility-snapshot-contract.unit.test.d.ts +0 -2
- package/dist/__tests__/visibility-snapshot-contract.unit.test.d.ts.map +0 -1
- package/dist/__tests__/vocabulary.unit.test.d.ts +0 -2
- package/dist/__tests__/vocabulary.unit.test.d.ts.map +0 -1
- package/dist/chunk-CQXZC5XI.mjs.map +0 -1
- package/dist/chunk-QC4VW3XJ.mjs.map +0 -1
- package/dist/chunk-SCRSAK5B.mjs.map +0 -1
- package/dist/components/__tests__/schema-contract.unit.test.d.ts +0 -2
- package/dist/components/__tests__/schema-contract.unit.test.d.ts.map +0 -1
- package/dist/components/__tests__/schema-parity.unit.test.d.ts +0 -2
- package/dist/components/__tests__/schema-parity.unit.test.d.ts.map +0 -1
- package/dist/components/__tests__/visibility-schema.unit.test.d.ts +0 -2
- package/dist/components/__tests__/visibility-schema.unit.test.d.ts.map +0 -1
- package/dist/record/__tests__/material-bg-cache.unit.test.d.ts +0 -2
- package/dist/record/__tests__/material-bg-cache.unit.test.d.ts.map +0 -1
- package/dist/record/__tests__/material-slot-plan.unit.test.d.ts +0 -2
- package/dist/record/__tests__/material-slot-plan.unit.test.d.ts.map +0 -1
- package/dist/record/__tests__/typed-frame-graph-plan.unit.test.d.ts +0 -2
- package/dist/record/__tests__/typed-frame-graph-plan.unit.test.d.ts.map +0 -1
- package/dist/record/__tests__/video-texture-view.unit.test.d.ts +0 -2
- package/dist/record/__tests__/video-texture-view.unit.test.d.ts.map +0 -1
|
@@ -0,0 +1,90 @@
|
|
|
1
|
+
import { describe, expect, it } from 'vitest';
|
|
2
|
+
import {
|
|
3
|
+
type AtmosphereParameters,
|
|
4
|
+
type EnvironmentCandidate,
|
|
5
|
+
type EnvironmentFrame,
|
|
6
|
+
type FogCandidate,
|
|
7
|
+
selectEnvironmentFrame,
|
|
8
|
+
} from '../extract/environment';
|
|
9
|
+
|
|
10
|
+
const atmosphereParameters: AtmosphereParameters = {
|
|
11
|
+
turbidity: 2,
|
|
12
|
+
rayleigh: 1,
|
|
13
|
+
mieCoefficient: 0.005,
|
|
14
|
+
mieDirectionalG: 0.8,
|
|
15
|
+
sunAngularRadius: 0.004675,
|
|
16
|
+
};
|
|
17
|
+
|
|
18
|
+
function unwrapFrame(result: ReturnType<typeof selectEnvironmentFrame>): EnvironmentFrame {
|
|
19
|
+
if (!result.ok) throw result.error;
|
|
20
|
+
return result.value;
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
const image = (entityKey: number, sourceKey: string): EnvironmentCandidate => ({
|
|
24
|
+
kind: 'image',
|
|
25
|
+
entityKey,
|
|
26
|
+
sourceKey,
|
|
27
|
+
});
|
|
28
|
+
const atmosphere = (entityKey: number, sourceKey: string): EnvironmentCandidate => ({
|
|
29
|
+
kind: 'atmosphere',
|
|
30
|
+
entityKey,
|
|
31
|
+
sourceKey,
|
|
32
|
+
atmosphere: atmosphereParameters,
|
|
33
|
+
});
|
|
34
|
+
const fog = (entityKey: number): FogCandidate => ({
|
|
35
|
+
entityKey,
|
|
36
|
+
color: [0.4, 0.5, 0.6],
|
|
37
|
+
density: 0.01,
|
|
38
|
+
heightFalloff: 0.2,
|
|
39
|
+
maxOpacity: 0.9,
|
|
40
|
+
});
|
|
41
|
+
|
|
42
|
+
describe('immutable frame plan contract', () => {
|
|
43
|
+
it('selects none, one image, or one atmosphere deterministically', () => {
|
|
44
|
+
expect(unwrapFrame(selectEnvironmentFrame([], [])).source.kind).toBe('none');
|
|
45
|
+
expect(unwrapFrame(selectEnvironmentFrame([image(2, 'image-a')], [])).source).toEqual({
|
|
46
|
+
kind: 'image',
|
|
47
|
+
sourceKey: 'image-a',
|
|
48
|
+
entityKey: 2,
|
|
49
|
+
});
|
|
50
|
+
expect(unwrapFrame(selectEnvironmentFrame([atmosphere(7, 'sky-a')], [])).source).toEqual({
|
|
51
|
+
kind: 'atmosphere',
|
|
52
|
+
sourceKey: 'sky-a',
|
|
53
|
+
entityKey: 7,
|
|
54
|
+
atmosphere: atmosphereParameters,
|
|
55
|
+
});
|
|
56
|
+
});
|
|
57
|
+
|
|
58
|
+
it('rejects mixed source kinds and conflicting source keys', () => {
|
|
59
|
+
expect(selectEnvironmentFrame([image(1, 'a'), atmosphere(2, 'b')], [])).toMatchObject({
|
|
60
|
+
ok: false,
|
|
61
|
+
error: { code: 'environment-source-conflict' },
|
|
62
|
+
});
|
|
63
|
+
expect(selectEnvironmentFrame([image(1, 'a'), image(2, 'b')], [])).toMatchObject({
|
|
64
|
+
ok: false,
|
|
65
|
+
error: { code: 'environment-source-conflict' },
|
|
66
|
+
});
|
|
67
|
+
});
|
|
68
|
+
|
|
69
|
+
it('keeps Fog independent from environment source and bounds cardinality', () => {
|
|
70
|
+
const withoutFog = unwrapFrame(selectEnvironmentFrame([], []));
|
|
71
|
+
expect(withoutFog.fog).toBeUndefined();
|
|
72
|
+
const withFog = unwrapFrame(selectEnvironmentFrame([], [fog(4)]));
|
|
73
|
+
expect(withFog.fog?.entityKey).toBe(4);
|
|
74
|
+
expect(selectEnvironmentFrame([], [fog(4), fog(8)])).toMatchObject({
|
|
75
|
+
ok: false,
|
|
76
|
+
error: { code: 'fog-cardinality' },
|
|
77
|
+
});
|
|
78
|
+
});
|
|
79
|
+
|
|
80
|
+
it('returns detached facts without GPU handles and freezes nested values', () => {
|
|
81
|
+
const result = selectEnvironmentFrame([image(1, 'stable')], [fog(3)]);
|
|
82
|
+
expect(result.ok).toBe(true);
|
|
83
|
+
if (!result.ok) return;
|
|
84
|
+
expect(Object.isFrozen(result.value)).toBe(true);
|
|
85
|
+
expect(Object.isFrozen(result.value.source)).toBe(true);
|
|
86
|
+
expect('device' in result.value).toBe(false);
|
|
87
|
+
expect('texture' in result.value).toBe(false);
|
|
88
|
+
expect('buffer' in result.value).toBe(false);
|
|
89
|
+
});
|
|
90
|
+
});
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { describe, expect, it } from 'vitest';
|
|
2
2
|
import { createFullscreenRenderFeature } from '../features/fullscreen';
|
|
3
3
|
import { freezeRenderFeaturePlan } from '../features/plan';
|
|
4
|
+
import { createSceneDataCatalog } from '../temporal/scene-data-catalog';
|
|
4
5
|
|
|
5
6
|
describe('fullscreen RenderFeature plan', () => {
|
|
6
7
|
it('keeps the cooked effect on the Standard post-stage owner', () => {
|
|
@@ -14,6 +15,12 @@ describe('fullscreen RenderFeature plan', () => {
|
|
|
14
15
|
frame: { frameNumber: 1 },
|
|
15
16
|
generation: 1,
|
|
16
17
|
targets: [{ name: 'scene-color', kind: 'color', format: 'rgba16float', sampleCount: 1 }],
|
|
18
|
+
sceneData: createSceneDataCatalog({
|
|
19
|
+
featureIdentity: 'test::fullscreen',
|
|
20
|
+
generation: 1,
|
|
21
|
+
planIdentity: 'test::fullscreen:1',
|
|
22
|
+
rgba16floatRenderable: true,
|
|
23
|
+
}),
|
|
17
24
|
});
|
|
18
25
|
|
|
19
26
|
expect(planned.ok).toBe(true);
|
|
@@ -102,7 +102,14 @@ export async function runGpuDrivenIndirectRasterEvidence(): Promise<GpuDrivenInd
|
|
|
102
102
|
const viewLayout = device
|
|
103
103
|
.createBindGroupLayout({
|
|
104
104
|
label: 'gpu-driven-production-view-bgl',
|
|
105
|
-
entries: [
|
|
105
|
+
entries: [
|
|
106
|
+
{ binding: 0, visibility: 0x1, buffer: { type: 'uniform' } },
|
|
107
|
+
{
|
|
108
|
+
binding: 10,
|
|
109
|
+
visibility: 0x1,
|
|
110
|
+
buffer: { type: 'uniform', hasDynamicOffset: true },
|
|
111
|
+
},
|
|
112
|
+
],
|
|
106
113
|
})
|
|
107
114
|
.unwrap();
|
|
108
115
|
const viewUniform = device
|
|
@@ -121,7 +128,10 @@ export async function runGpuDrivenIndirectRasterEvidence(): Promise<GpuDrivenInd
|
|
|
121
128
|
.createBindGroup({
|
|
122
129
|
label: 'gpu-driven-production-view-bg',
|
|
123
130
|
layout: viewLayout,
|
|
124
|
-
entries: [
|
|
131
|
+
entries: [
|
|
132
|
+
{ binding: 0, resource: { kind: 'buffer', value: { buffer: viewUniform } } },
|
|
133
|
+
{ binding: 10, resource: { kind: 'buffer', value: { buffer: viewUniform } } },
|
|
134
|
+
],
|
|
125
135
|
})
|
|
126
136
|
.unwrap();
|
|
127
137
|
|
|
@@ -4,6 +4,10 @@ import { deriveVertexLayoutProjection } from '@forgeax/engine-geometry';
|
|
|
4
4
|
import { RenderGraphBuilder } from '@forgeax/engine-render-graph';
|
|
5
5
|
import { type RhiNullDevice, rhi } from '@forgeax/engine-rhi-null';
|
|
6
6
|
import { Transform } from '@forgeax/engine-scene';
|
|
7
|
+
import {
|
|
8
|
+
DEFAULT_STANDARD_PBR_PARAM_SCHEMA,
|
|
9
|
+
DEFAULT_UNLIT_PARAM_SCHEMA,
|
|
10
|
+
} from '@forgeax/engine-shader';
|
|
7
11
|
import { ok } from '@forgeax/engine-types';
|
|
8
12
|
import { describe, expect, it } from 'vitest';
|
|
9
13
|
import { createRenderer as constructRenderer } from '../assembly/factory';
|
|
@@ -26,6 +30,61 @@ import { RenderScene } from '../scene/render-scene';
|
|
|
26
30
|
|
|
27
31
|
const EMPTY_RESOURCE_CLASS = JSON.stringify({ textures: [], samplers: [], video: [] });
|
|
28
32
|
|
|
33
|
+
const STANDARD_PBR_URP_VARIANT_KEY =
|
|
34
|
+
'CLUSTER_FORWARD_AVAILABLE=false+STORAGE_BUFFER_AVAILABLE=true+TRANSMISSION_AVAILABLE=false+VERTEX_COLOR_AVAILABLE=false';
|
|
35
|
+
const STANDARD_PBR_TRANSMISSION_VARIANT_KEY =
|
|
36
|
+
'CLUSTER_FORWARD_AVAILABLE=false+STORAGE_BUFFER_AVAILABLE=true+TRANSMISSION_AVAILABLE=true+VERTEX_COLOR_AVAILABLE=false';
|
|
37
|
+
|
|
38
|
+
function manifestDataUrl(): string {
|
|
39
|
+
const pbrWgsl = '/* pbr stub - calls f_schlick( */';
|
|
40
|
+
const unlitWgsl = '/* unlit stub */';
|
|
41
|
+
const tonemapWgsl = '/* tonemap stub - struct TonemapParams { exposure: f32 }; */';
|
|
42
|
+
const standardPbrVariant = (transmissionAvailable: boolean, definesKey: string) => ({
|
|
43
|
+
definesKey,
|
|
44
|
+
defines: {
|
|
45
|
+
CLUSTER_FORWARD_AVAILABLE: false,
|
|
46
|
+
STORAGE_BUFFER_AVAILABLE: true,
|
|
47
|
+
TRANSMISSION_AVAILABLE: transmissionAvailable,
|
|
48
|
+
VERTEX_COLOR_AVAILABLE: false,
|
|
49
|
+
},
|
|
50
|
+
composedWgsl: pbrWgsl,
|
|
51
|
+
});
|
|
52
|
+
const materialShader = (
|
|
53
|
+
identifier: string,
|
|
54
|
+
paramSchema: readonly unknown[],
|
|
55
|
+
composedWgsl: string,
|
|
56
|
+
variants: readonly unknown[] = [],
|
|
57
|
+
) => ({
|
|
58
|
+
identifier,
|
|
59
|
+
sourcePath: `${identifier}.wgsl`,
|
|
60
|
+
composedWgsl,
|
|
61
|
+
paramSchema: JSON.stringify(paramSchema),
|
|
62
|
+
variants,
|
|
63
|
+
});
|
|
64
|
+
return `data:application/json,${encodeURIComponent(
|
|
65
|
+
JSON.stringify({
|
|
66
|
+
schemaVersion: '1.0.0',
|
|
67
|
+
entries: [
|
|
68
|
+
{ hash: 'pbr00000', wgsl: pbrWgsl, glsl: '', bindings: '' },
|
|
69
|
+
{ hash: 'unlit000', wgsl: unlitWgsl, glsl: '', bindings: '' },
|
|
70
|
+
{ hash: 'tonemap0', wgsl: tonemapWgsl, glsl: '', bindings: '' },
|
|
71
|
+
],
|
|
72
|
+
materialShaders: [
|
|
73
|
+
materialShader(
|
|
74
|
+
'forgeax::default-standard-pbr',
|
|
75
|
+
DEFAULT_STANDARD_PBR_PARAM_SCHEMA,
|
|
76
|
+
pbrWgsl,
|
|
77
|
+
[
|
|
78
|
+
standardPbrVariant(false, STANDARD_PBR_URP_VARIANT_KEY),
|
|
79
|
+
standardPbrVariant(true, STANDARD_PBR_TRANSMISSION_VARIANT_KEY),
|
|
80
|
+
],
|
|
81
|
+
),
|
|
82
|
+
materialShader('forgeax::default-unlit', DEFAULT_UNLIT_PARAM_SCHEMA, unlitWgsl),
|
|
83
|
+
],
|
|
84
|
+
}),
|
|
85
|
+
)}`;
|
|
86
|
+
}
|
|
87
|
+
|
|
29
88
|
function snapshot(entityKey: number, assetHandle: number): RenderableSnapshot {
|
|
30
89
|
const material = {
|
|
31
90
|
baseColor: new Float32Array([0.25 * entityKey, 0.5, 0.75]),
|
|
@@ -293,16 +352,6 @@ describe('GPU-driven production projection', () => {
|
|
|
293
352
|
});
|
|
294
353
|
|
|
295
354
|
it('activates inside the renderer-owned URP graph and removes the CPU forward draw', async () => {
|
|
296
|
-
const manifest = `data:application/json,${encodeURIComponent(
|
|
297
|
-
JSON.stringify({
|
|
298
|
-
schemaVersion: '1.0.0',
|
|
299
|
-
entries: [
|
|
300
|
-
{ hash: 'pbr00000', wgsl: '/* pbr stub */', glsl: '', bindings: '' },
|
|
301
|
-
{ hash: 'unlit000', wgsl: '/* unlit stub */', glsl: '', bindings: '' },
|
|
302
|
-
{ hash: 'tonemap0', wgsl: '/* tonemap stub */', glsl: '', bindings: '' },
|
|
303
|
-
],
|
|
304
|
-
}),
|
|
305
|
-
)}`;
|
|
306
355
|
const canvas = {
|
|
307
356
|
width: 1,
|
|
308
357
|
height: 1,
|
|
@@ -310,7 +359,11 @@ describe('GPU-driven production projection', () => {
|
|
|
310
359
|
addEventListener: () => undefined,
|
|
311
360
|
removeEventListener: () => undefined,
|
|
312
361
|
} as unknown as HTMLCanvasElement;
|
|
313
|
-
const renderer = await constructRenderer(
|
|
362
|
+
const renderer = await constructRenderer(
|
|
363
|
+
canvas,
|
|
364
|
+
{ rhi },
|
|
365
|
+
{ shaderManifestUrl: manifestDataUrl() },
|
|
366
|
+
);
|
|
314
367
|
expect((await renderer.initialization).ok).toBe(true);
|
|
315
368
|
const world = new World();
|
|
316
369
|
expect(renderer.attach(world).ok).toBe(true);
|
|
@@ -345,9 +398,14 @@ describe('GPU-driven production projection', () => {
|
|
|
345
398
|
'main',
|
|
346
399
|
]),
|
|
347
400
|
);
|
|
401
|
+
expect(renderer.perFramePassNames).toContain('output-transform');
|
|
402
|
+
// Storage-buffer LDR frames keep the scene linear until the one output
|
|
403
|
+
// transform writes the encoded surface; the GPU-driven indirect raster
|
|
404
|
+
// draw and that fullscreen pass are the only draws in this topology.
|
|
348
405
|
expect(device.totalDrawCount).toBe(2);
|
|
349
406
|
expect(renderer.renderScene).toMatchObject({
|
|
350
407
|
worldEntitiesScanned: 0,
|
|
408
|
+
fullRebuilds: 1,
|
|
351
409
|
projectionRecords: 1,
|
|
352
410
|
topology: { batchCount: 1, candidateCount: 1 },
|
|
353
411
|
gpu: { status: 'resident' },
|
|
@@ -366,16 +424,6 @@ describe('GPU-driven production projection', () => {
|
|
|
366
424
|
});
|
|
367
425
|
|
|
368
426
|
it('keeps a stable multi-World composition resident and patches one World transform', async () => {
|
|
369
|
-
const manifest = `data:application/json,${encodeURIComponent(
|
|
370
|
-
JSON.stringify({
|
|
371
|
-
schemaVersion: '1.0.0',
|
|
372
|
-
entries: [
|
|
373
|
-
{ hash: 'pbr00000', wgsl: '/* pbr stub */', glsl: '', bindings: '' },
|
|
374
|
-
{ hash: 'unlit000', wgsl: '/* unlit stub */', glsl: '', bindings: '' },
|
|
375
|
-
{ hash: 'tonemap0', wgsl: '/* tonemap stub */', glsl: '', bindings: '' },
|
|
376
|
-
],
|
|
377
|
-
}),
|
|
378
|
-
)}`;
|
|
379
427
|
const canvas = {
|
|
380
428
|
width: 1,
|
|
381
429
|
height: 1,
|
|
@@ -383,7 +431,11 @@ describe('GPU-driven production projection', () => {
|
|
|
383
431
|
addEventListener: () => undefined,
|
|
384
432
|
removeEventListener: () => undefined,
|
|
385
433
|
} as unknown as HTMLCanvasElement;
|
|
386
|
-
const renderer = await constructRenderer(
|
|
434
|
+
const renderer = await constructRenderer(
|
|
435
|
+
canvas,
|
|
436
|
+
{ rhi },
|
|
437
|
+
{ shaderManifestUrl: manifestDataUrl() },
|
|
438
|
+
);
|
|
387
439
|
expect((await renderer.initialization).ok).toBe(true);
|
|
388
440
|
const cameraWorld = new World();
|
|
389
441
|
const sceneWorld = new World();
|
|
@@ -221,10 +221,47 @@ describe('GpuDrivenView graph projection', () => {
|
|
|
221
221
|
undefined,
|
|
222
222
|
prepared,
|
|
223
223
|
);
|
|
224
|
+
|
|
225
|
+
Object.defineProperty(device, 'surfaceViewFormats', {
|
|
226
|
+
configurable: true,
|
|
227
|
+
value: false,
|
|
228
|
+
});
|
|
229
|
+
Object.defineProperty(device, 'caps', {
|
|
230
|
+
configurable: true,
|
|
231
|
+
value: { ...device.caps, rgba16floatRenderable: false },
|
|
232
|
+
});
|
|
233
|
+
expect(compile(preparedFrame(view))).toBeNull();
|
|
234
|
+
expect(errors).toHaveLength(1);
|
|
235
|
+
expect(errors[0]).toMatchObject({
|
|
236
|
+
code: 'webgpu-runtime-error',
|
|
237
|
+
detail: { error: { code: 'surface-raw-endpoint-failed' } },
|
|
238
|
+
});
|
|
239
|
+
errors.length = 0;
|
|
240
|
+
delete (device as unknown as { caps?: unknown }).caps;
|
|
241
|
+
delete (device as unknown as { surfaceViewFormats?: unknown }).surfaceViewFormats;
|
|
242
|
+
|
|
224
243
|
const compiledPrevious = compile(preparedFrame(view));
|
|
225
244
|
expect(compiledPrevious).not.toBeNull();
|
|
226
245
|
if (compiledPrevious === null) return;
|
|
227
246
|
|
|
247
|
+
Object.defineProperty(device, 'surfaceViewFormats', {
|
|
248
|
+
configurable: true,
|
|
249
|
+
value: false,
|
|
250
|
+
});
|
|
251
|
+
Object.defineProperty(device, 'caps', {
|
|
252
|
+
configurable: true,
|
|
253
|
+
value: { ...device.caps, rgba16floatRenderable: false },
|
|
254
|
+
});
|
|
255
|
+
expect(compile(preparedFrame(view))).toBe(compiledPrevious);
|
|
256
|
+
expect(errors).toHaveLength(1);
|
|
257
|
+
expect(errors[0]).toMatchObject({
|
|
258
|
+
code: 'webgpu-runtime-error',
|
|
259
|
+
detail: { error: { code: 'surface-raw-endpoint-failed' } },
|
|
260
|
+
});
|
|
261
|
+
errors.length = 0;
|
|
262
|
+
delete (device as unknown as { caps?: unknown }).caps;
|
|
263
|
+
delete (device as unknown as { surfaceViewFormats?: unknown }).surfaceViewFormats;
|
|
264
|
+
|
|
228
265
|
const secondDelta = projection.apply([{ kind: 'create', snapshot: snapshot(2) }]);
|
|
229
266
|
sceneAvailability.scene.sync(secondDelta).unwrap();
|
|
230
267
|
topology.rebuild(projection.slotsSnapshot());
|
|
@@ -5,6 +5,7 @@ import { GpuScene } from '../gpu-scene';
|
|
|
5
5
|
import { GPU_SCENE_LAYOUTS, gpuSceneFieldOffset } from '../gpu-scene-schema';
|
|
6
6
|
import type { MaterialSnapshot, RenderableSnapshot } from '../render-system-extract';
|
|
7
7
|
import { RenderScene } from '../scene/render-scene';
|
|
8
|
+
import { classifySceneDataCoverage } from '../temporal/coverage';
|
|
8
9
|
|
|
9
10
|
interface WriteRecord {
|
|
10
11
|
readonly offset: number;
|
|
@@ -66,6 +67,15 @@ function createDevice(queue: RecordingQueue): RhiNullDevice {
|
|
|
66
67
|
}
|
|
67
68
|
|
|
68
69
|
describe('GpuScene', () => {
|
|
70
|
+
it('exposes GPU scene facts as exact temporal coverage', () => {
|
|
71
|
+
const coverage = classifySceneDataCoverage({
|
|
72
|
+
contributors: [{ id: 'gpu-scene', kind: 'exact' }],
|
|
73
|
+
requiredContributorIds: ['gpu-scene'],
|
|
74
|
+
});
|
|
75
|
+
expect(coverage.complete).toBe(true);
|
|
76
|
+
expect(coverage.exactContributorIds).toEqual(['gpu-scene']);
|
|
77
|
+
});
|
|
78
|
+
|
|
69
79
|
it('uploads only coalesced dirty ranges and performs no upload on no-change', () => {
|
|
70
80
|
const queue = new RecordingQueue();
|
|
71
81
|
const created = GpuScene.create(createDevice(queue), 4).unwrap();
|
|
@@ -4,11 +4,12 @@ import { appendInjection, INJECTION_KIND_LENGTHS, type InjectionKind } from '../
|
|
|
4
4
|
|
|
5
5
|
it('derives InjectionKind from the public length-map keys', () => {
|
|
6
6
|
expectTypeOf<InjectionKind>().toEqualTypeOf<keyof typeof INJECTION_KIND_LENGTHS>();
|
|
7
|
-
expectTypeOf<InjectionKind>().toEqualTypeOf<'shadow' | 'ibl' | 'lightmap'>();
|
|
7
|
+
expectTypeOf<InjectionKind>().toEqualTypeOf<'shadow' | 'ibl' | 'lightmap' | 'transmission'>();
|
|
8
8
|
expectTypeOf<'unknown'>().not.toExtend<InjectionKind>();
|
|
9
9
|
});
|
|
10
10
|
|
|
11
11
|
it('keeps the public map assignability and appendInjection narrowing', () => {
|
|
12
12
|
expectTypeOf(INJECTION_KIND_LENGTHS).toMatchTypeOf<Readonly<Record<InjectionKind, number>>>();
|
|
13
13
|
expectTypeOf(appendInjection).parameter(1).toEqualTypeOf<InjectionKind>();
|
|
14
|
+
expectTypeOf(appendInjection([], 'transmission')).toEqualTypeOf<GPUBindGroupLayoutEntry[]>();
|
|
14
15
|
});
|
|
@@ -3,7 +3,9 @@ import {
|
|
|
3
3
|
DEFAULT_STANDARD_PBR_PARAM_SCHEMA,
|
|
4
4
|
DEFAULT_UNLIT_PARAM_SCHEMA,
|
|
5
5
|
} from '@forgeax/engine-shader';
|
|
6
|
+
import { resolveMaterialAsset } from '@forgeax/engine-types';
|
|
6
7
|
import { describe, expect, it } from 'vitest';
|
|
8
|
+
import { Materials } from '../materials.js';
|
|
7
9
|
|
|
8
10
|
describe('vertex color does not change the material contract', () => {
|
|
9
11
|
it('keeps colored and plain materials on the same schema and resource identity', () => {
|
|
@@ -21,4 +23,64 @@ describe('vertex color does not change the material contract', () => {
|
|
|
21
23
|
expect(JSON.stringify(material)).not.toMatch(/hasColor|VERTEX_COLOR_AVAILABLE|colorBinding/i);
|
|
22
24
|
expect(material.passes?.[0]?.program).not.toHaveProperty('color');
|
|
23
25
|
});
|
|
26
|
+
|
|
27
|
+
it.each([
|
|
28
|
+
['unlit', Materials.unlit([0.5, 0.5, 0.5, 1])],
|
|
29
|
+
['standard', Materials.standard({ baseColor: [0.5, 0.5, 0.5, 1] })],
|
|
30
|
+
] as const)('keeps the %s factory fallback aligned with its color schema', (_name, material) => {
|
|
31
|
+
const resolved = resolveMaterialAsset('factory-fallback', {
|
|
32
|
+
'factory-fallback': material,
|
|
33
|
+
});
|
|
34
|
+
expect(resolved).toMatchObject({ ok: true });
|
|
35
|
+
});
|
|
36
|
+
|
|
37
|
+
it('keeps the standard authoring parameters derived from the shared schema', () => {
|
|
38
|
+
const material = Materials.standard({ baseColor: [1, 1, 1, 1] });
|
|
39
|
+
expect(material.parameters?.map((parameter) => parameter.name)).toEqual(
|
|
40
|
+
DEFAULT_STANDARD_PBR_PARAM_SCHEMA.map((entry) => entry.name),
|
|
41
|
+
);
|
|
42
|
+
expect(material.values).toMatchObject({
|
|
43
|
+
transmission: 0,
|
|
44
|
+
ior: 1.5,
|
|
45
|
+
thickness: 0,
|
|
46
|
+
attenuationColor: [1, 1, 1],
|
|
47
|
+
});
|
|
48
|
+
});
|
|
49
|
+
|
|
50
|
+
it('routes active transmission to Forward and ShadowCaster only', () => {
|
|
51
|
+
const material = Materials.standard({ baseColor: [1, 1, 1, 1], transmission: 0.5 });
|
|
52
|
+
expect(material.passes?.map((pass) => pass.name)).toEqual(['forward', 'shadow-caster']);
|
|
53
|
+
expect(material.passes?.[0]?.renderState).toMatchObject({ depthWriteEnabled: false });
|
|
54
|
+
});
|
|
55
|
+
|
|
56
|
+
it.each([
|
|
57
|
+
['transmission', { transmission: -0.1 }],
|
|
58
|
+
['ior', { ior: 0 }],
|
|
59
|
+
['thickness', { thickness: -0.1 }],
|
|
60
|
+
['attenuationDistance', { attenuationDistance: 0 }],
|
|
61
|
+
])('rejects invalid %s before material publication', (_name, options) => {
|
|
62
|
+
expect(() => Materials.standard({ baseColor: [1, 1, 1, 1], ...options })).toThrow();
|
|
63
|
+
});
|
|
64
|
+
|
|
65
|
+
it('rejects BLEND and depth writes for an active transmission material', () => {
|
|
66
|
+
expect(() =>
|
|
67
|
+
Materials.standard({
|
|
68
|
+
baseColor: [1, 1, 1, 1],
|
|
69
|
+
transmission: 0.5,
|
|
70
|
+
renderState: {
|
|
71
|
+
blend: {
|
|
72
|
+
color: { srcFactor: 'one', dstFactor: 'zero', operation: 'add' },
|
|
73
|
+
alpha: { srcFactor: 'one', dstFactor: 'zero', operation: 'add' },
|
|
74
|
+
},
|
|
75
|
+
},
|
|
76
|
+
}),
|
|
77
|
+
).toThrow();
|
|
78
|
+
expect(() =>
|
|
79
|
+
Materials.standard({
|
|
80
|
+
baseColor: [1, 1, 1, 1],
|
|
81
|
+
transmission: 0.5,
|
|
82
|
+
renderState: { depthWriteEnabled: true },
|
|
83
|
+
}),
|
|
84
|
+
).toThrow();
|
|
85
|
+
});
|
|
24
86
|
});
|
|
@@ -1,128 +1,22 @@
|
|
|
1
|
-
import
|
|
1
|
+
import { DEFAULT_STANDARD_PBR_PARAM_SCHEMA } from '@forgeax/engine-shader';
|
|
2
|
+
import { derive } from '@forgeax/engine-types';
|
|
2
3
|
import { describe, expect, it } from 'vitest';
|
|
3
|
-
import { assembleMaterialProjection } from '../assembly/material/assembly.js';
|
|
4
|
-
import { projectMaterialPipeline } from '../assembly/material/pipeline-projection.js';
|
|
5
4
|
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
fragmentEntry: 'fs_main',
|
|
23
|
-
},
|
|
24
|
-
renderState: { blend: 'opaque' },
|
|
25
|
-
},
|
|
26
|
-
],
|
|
27
|
-
parameters: [{ name: 'baseColor', type: 'color' }],
|
|
28
|
-
values: { baseColor: [0.2, 0.3, 0.4, 1] },
|
|
29
|
-
},
|
|
30
|
-
refs: {
|
|
31
|
-
parent: ['material-parent'],
|
|
32
|
-
textures: [],
|
|
33
|
-
samplers: [],
|
|
34
|
-
modules: ['project::standard'],
|
|
35
|
-
},
|
|
36
|
-
artifact: {
|
|
37
|
-
mediaType: 'text/wgsl',
|
|
38
|
-
path: 'material-leaf.wgsl',
|
|
39
|
-
digest: 'sha256:artifact',
|
|
40
|
-
bytes: new Uint8Array([1, 2, 3]),
|
|
41
|
-
},
|
|
42
|
-
receipt: {
|
|
43
|
-
schemaVersion: 'material-cook/2',
|
|
44
|
-
sourceClosure: ['project::standard'],
|
|
45
|
-
profile: 'forgeax-material-wgsl-v1',
|
|
46
|
-
compilerVersion: 'compiler/1',
|
|
47
|
-
inputDigest: 'specialization-key',
|
|
48
|
-
outputDigest: 'sha256:artifact',
|
|
49
|
-
layoutIdentity: 'sha256:layout',
|
|
50
|
-
derivedInterface: { layoutIdentity: 'sha256:layout' },
|
|
51
|
-
},
|
|
52
|
-
};
|
|
53
|
-
}
|
|
54
|
-
|
|
55
|
-
describe('cooked material render projection', () => {
|
|
56
|
-
it('projects cooked passes and artifact identity without exposing authored inheritance', () => {
|
|
57
|
-
const projection = assembleMaterialProjection(cookedRecord());
|
|
58
|
-
|
|
59
|
-
expect(projection).toMatchObject({
|
|
60
|
-
materialGuid: 'material-leaf',
|
|
61
|
-
specializationKey: 'specialization-key',
|
|
62
|
-
artifactHash: 'sha256:artifact',
|
|
63
|
-
passes: [
|
|
64
|
-
{
|
|
65
|
-
name: 'forward',
|
|
66
|
-
module: 'project::standard',
|
|
67
|
-
vertexEntry: 'vs_main',
|
|
68
|
-
fragmentEntry: 'fs_main',
|
|
69
|
-
},
|
|
70
|
-
],
|
|
71
|
-
});
|
|
72
|
-
expect('authored' in projection).toBe(false);
|
|
73
|
-
expect(projection.passes[0]?.artifactHash).toBe('sha256:artifact');
|
|
74
|
-
});
|
|
75
|
-
|
|
76
|
-
it('builds a pipeline projection from the cooked artifact, not the parent chain', () => {
|
|
77
|
-
const projection = assembleMaterialProjection(cookedRecord());
|
|
78
|
-
const pipeline = projectMaterialPipeline(projection);
|
|
79
|
-
|
|
80
|
-
expect(pipeline).toEqual({
|
|
81
|
-
specializationKey: 'specialization-key',
|
|
82
|
-
artifactHash: 'sha256:artifact',
|
|
83
|
-
passes: projection.passes,
|
|
84
|
-
});
|
|
85
|
-
});
|
|
86
|
-
|
|
87
|
-
it('keeps projections isolated when adjacent slots use different cooked identities', () => {
|
|
88
|
-
const firstRecord = cookedRecord();
|
|
89
|
-
const secondRecord: CookedMaterialRecord = {
|
|
90
|
-
...firstRecord,
|
|
91
|
-
guid: 'material-slot-2' as never,
|
|
92
|
-
authored: {
|
|
93
|
-
kind: 'material',
|
|
94
|
-
...firstRecord.authored,
|
|
95
|
-
parent: 'material-parent-2' as never,
|
|
96
|
-
values: { baseColor: [0, 1, 0, 1] },
|
|
97
|
-
},
|
|
98
|
-
resolved: {
|
|
99
|
-
...firstRecord.resolved,
|
|
100
|
-
values: { baseColor: [0.8, 0.1, 0.2, 1] },
|
|
101
|
-
},
|
|
102
|
-
artifact: {
|
|
103
|
-
...firstRecord.artifact,
|
|
104
|
-
path: 'material-slot-2.wgsl',
|
|
105
|
-
digest: 'sha256:artifact-2',
|
|
106
|
-
bytes: new Uint8Array([4, 5, 6]),
|
|
107
|
-
},
|
|
108
|
-
receipt: {
|
|
109
|
-
...firstRecord.receipt,
|
|
110
|
-
inputDigest: 'specialization-key-2',
|
|
111
|
-
outputDigest: 'sha256:artifact-2',
|
|
112
|
-
},
|
|
113
|
-
};
|
|
114
|
-
|
|
115
|
-
const first = assembleMaterialProjection(firstRecord);
|
|
116
|
-
const second = assembleMaterialProjection(secondRecord);
|
|
117
|
-
|
|
118
|
-
expect(second).not.toBe(first);
|
|
119
|
-
expect(first.materialGuid).toBe('material-leaf');
|
|
120
|
-
expect(first.specializationKey).toBe('specialization-key');
|
|
121
|
-
expect(first.artifactHash).toBe('sha256:artifact');
|
|
122
|
-
expect(second.materialGuid).toBe('material-slot-2');
|
|
123
|
-
expect(second.specializationKey).toBe('specialization-key-2');
|
|
124
|
-
expect(second.artifactHash).toBe('sha256:artifact-2');
|
|
125
|
-
expect(second.runtimeValues).not.toBe(first.runtimeValues);
|
|
126
|
-
expect('authored' in second).toBe(false);
|
|
5
|
+
describe('standard material cooked projection', () => {
|
|
6
|
+
it('uses one schema for reflection, uniform layout, and resource bindings', () => {
|
|
7
|
+
const derived = derive(DEFAULT_STANDARD_PBR_PARAM_SCHEMA);
|
|
8
|
+
const names = derived.numericMembers.map((member) => member.name);
|
|
9
|
+
expect(names).toEqual(expect.arrayContaining(['transmission', 'ior', 'thickness']));
|
|
10
|
+
expect(derived.coordinateRecords.map((record) => record.parameter)).toEqual(
|
|
11
|
+
expect.arrayContaining(['transmissionTexture', 'thicknessTexture']),
|
|
12
|
+
);
|
|
13
|
+
expect(derived.resourceBindings.map((binding) => binding.name)).toEqual(
|
|
14
|
+
expect.arrayContaining([
|
|
15
|
+
'transmissionTexture_sampler',
|
|
16
|
+
'transmissionTexture',
|
|
17
|
+
'thicknessTexture_sampler',
|
|
18
|
+
'thicknessTexture',
|
|
19
|
+
]),
|
|
20
|
+
);
|
|
127
21
|
});
|
|
128
22
|
});
|
|
@@ -1,5 +1,3 @@
|
|
|
1
|
-
import { resolveTilesetRuntime } from '@forgeax/engine-assets-runtime';
|
|
2
|
-
import { World } from '@forgeax/engine-ecs';
|
|
3
1
|
import type { CookedMaterialRecord } from '@forgeax/engine-pack';
|
|
4
2
|
import { describe, expect, it, vi } from 'vitest';
|
|
5
3
|
import { assembleMaterialProjection } from '../assembly/material/assembly.js';
|
|
@@ -9,13 +7,18 @@ import {
|
|
|
9
7
|
} from '../assembly/material/pipeline-projection.js';
|
|
10
8
|
|
|
11
9
|
const record: CookedMaterialRecord = {
|
|
12
|
-
schemaVersion: 'material-cook/
|
|
10
|
+
schemaVersion: 'material-cook/3',
|
|
13
11
|
guid: 'material-route',
|
|
12
|
+
specializationKey: 'route-key',
|
|
13
|
+
authored: {
|
|
14
|
+
kind: 'material',
|
|
15
|
+
values: { useNormalMap: false },
|
|
16
|
+
},
|
|
14
17
|
resolved: {
|
|
15
18
|
passes: [{ name: 'forward', program: { module: 'project::standard' } }],
|
|
16
19
|
parameters: [
|
|
17
20
|
{ name: 'baseColor', type: 'color' },
|
|
18
|
-
{ name: 'useNormalMap', type: 'bool'
|
|
21
|
+
{ name: 'useNormalMap', type: 'bool' },
|
|
19
22
|
],
|
|
20
23
|
values: { baseColor: [1, 1, 1, 1], useNormalMap: false },
|
|
21
24
|
},
|
|
@@ -27,13 +30,30 @@ const record: CookedMaterialRecord = {
|
|
|
27
30
|
bytes: new Uint8Array([4]),
|
|
28
31
|
},
|
|
29
32
|
receipt: {
|
|
30
|
-
schemaVersion: 'material-cook/
|
|
33
|
+
schemaVersion: 'material-cook/3',
|
|
31
34
|
sourceClosure: ['project::standard'],
|
|
32
35
|
profile: 'forgeax-material-wgsl-v1',
|
|
33
36
|
compilerVersion: 'compiler/1',
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
+
identity: {
|
|
38
|
+
materialContractDigest: 'sha256:contract',
|
|
39
|
+
sourceRevision: 'sha256:source',
|
|
40
|
+
sourceClosureDigest: 'sha256:closure',
|
|
41
|
+
layoutIdentity: 'sha256:layout',
|
|
42
|
+
programIdentity: 'sha256:program',
|
|
43
|
+
pipelineIdentity: 'sha256:pipeline',
|
|
44
|
+
materialPublicationIdentity: 'sha256:publication',
|
|
45
|
+
cookIdentity: 'sha256:input',
|
|
46
|
+
compilerFingerprint: 'sha256:compiler',
|
|
47
|
+
wasm: {
|
|
48
|
+
sourceContentKey: 'unavailable',
|
|
49
|
+
artifactSha256: 'unavailable',
|
|
50
|
+
glueSha256: 'unavailable',
|
|
51
|
+
},
|
|
52
|
+
artifactDigest: 'sha256:route',
|
|
53
|
+
valueGeneration: 1,
|
|
54
|
+
dependencyGeneration: 1,
|
|
55
|
+
cookGeneration: 1,
|
|
56
|
+
},
|
|
37
57
|
derivedInterface: { layoutIdentity: 'sha256:layout' },
|
|
38
58
|
},
|
|
39
59
|
};
|
|
@@ -72,23 +92,3 @@ describe('cooked material static and dynamic routing', () => {
|
|
|
72
92
|
});
|
|
73
93
|
});
|
|
74
94
|
});
|
|
75
|
-
|
|
76
|
-
describe('tileset atlas material projection', () => {
|
|
77
|
-
it('fails closed for a missing or wrong-kind atlas payload', () => {
|
|
78
|
-
const world = new World();
|
|
79
|
-
const missing = resolveTilesetRuntime(world, 'missing-atlas', () => undefined);
|
|
80
|
-
const wrongKind = resolveTilesetRuntime(
|
|
81
|
-
world,
|
|
82
|
-
'wrong-atlas',
|
|
83
|
-
() => ({ kind: 'audio' }) as never,
|
|
84
|
-
);
|
|
85
|
-
|
|
86
|
-
expect(missing).toMatchObject({ ok: false, error: { code: 'tileset-atlas-not-found' } });
|
|
87
|
-
expect(wrongKind).toMatchObject({ ok: false, error: { code: 'tileset-atlas-kind-mismatch' } });
|
|
88
|
-
});
|
|
89
|
-
|
|
90
|
-
it('reports stale atlas payloads instead of casting them into a handle', () => {
|
|
91
|
-
const result = resolveTilesetRuntime(new World(), 'stale-atlas', () => ({ code: 'stale' }));
|
|
92
|
-
expect(result).toMatchObject({ ok: false, error: { code: 'tileset-atlas-stale' } });
|
|
93
|
-
});
|
|
94
|
-
});
|