Repository navigation
docs: wiring campaign inventory - #393
Conversation
|
Important
This repository does not receive automatic reviews because it has fewer than 10 stars. ⚙️ Run configuration
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
|
@coderabbitai review |
There was a problem hiding this comment.
The diff is documentation only. It adds no dependency, input path, credential handling, or network surface, and record_gated_presentation does not write simulation state. Fog time advances by the fixed 1/60 passed from composite_atmosphere. Cloud-shadow time is a presentation frame index. shadow_mode and GOAP telemetry do read Instant, and neither sys_ai_planning nor sys_spatial_tick calls AIArbiter, GoapPlanner, or advanced GOAP. recorded_line is still test-only. Those rows match the tree.
The budget table does not. The 7.397 ms figure is the GTX 1660 Ti cloud-shadow amortization delta (CloudShadowPass, 512², 16 steps, 32 slices, now 0.323 ms inside the 3.688 ms frame). gpu_frame_budget never enables VolumetricCloudsPass. The 2× SSGI miss sum drops the fog and god-ray terms the same table says are already on in Aravath, and the completed sum is over 11 ms. Atmosphere, SSGI, TAA, and depth of field are therefore not justified as default-on, and the exit column never records median_gpu_frame_ms.
Three “do not wire” rows describe types that are already gone (VolumetricFogNode, BrdfLutPass, weather_gpu.rs). Depth of field in the live pass is a 9-tap texture_depth_2d shader, and the gated normal and velocity targets SSGI and TAA sample are never written. Please correct the inventory before the follow-up pulls treat it as the order to turn passes on.
Sent by Cursor Automation: ASTRA PR AUDIT AGENT
|
@coderabbitai review |
There was a problem hiding this comment.
The inventory corrections hold. 7.397 ms is the CloudShadowPass amortization, the estimate table is gone, defaults stay off, depth of field is the 9-tap texture_depth_2d shader, and the deleted fog node, BRDF LUT, and weather_gpu.rs are no longer rows. No new dependency, credential path, or network surface. record_gated_presentation does not write simulation state. Cloud-raymarch time advances by the fixed 1/60 passed from that function. Atmosphere does not read a clock or an RNG. The shadow_mode / GOAP Instant row and the test-only recorded_line row match the tree. With every new flag left off, the unflagged heavy-scene binary and the replay hashes are unchanged.
The new measurement contract does not. gpu_frame_budget will not print median_gpu_frame_ms for --ssgi, --taa, or --dof: those paths sample or LoadOp::Load textures that nothing has cleared, the binary treats a validation scope as a failed frame, and it returns before the median. --clouds samples cloud_history before copying into it, and the composite never lands on HDR. --atmosphere can finish, and that frame replaces SkyRenderer rather than adding to the 3.688 ms baseline. The harness also accepts every flag at once, has no --upscale, and leaves the render trace (invariant 22 and the gpu_frame_budget notes) describing the unflagged tool.
Please make a clean frame scope and a single enabled pass the requirement for filling a cell, and keep SSGI, TAA, and temporal upscale out of that table until the normal and velocity targets are written.
Sent by Cursor Automation: ASTRA PR AUDIT AGENT
There was a problem hiding this comment.
Blocking: --atmosphere is not a fillable measurement cell.
Rejecting --ssgi, --taa, --upscale, --dof, and --clouds before the frame loop is the right gate. Those passes still sample unwritten targets or leave their image off HDR. No new crate dependency, no credential or network path, and the new flags are exact string matches. prepare_frame does not write simulation state and does not read a wall clock, so replay hashes stay untouched.
--atmosphere is the run this diff treats as clean. draw_into skips SkyRenderer, which is the HDR clear and the depth clear to 1.0. The main pass loads both. wgpu 25.0.2 does not fail that load: the init tracker zero-fills depth to 0.0. The static-mesh pipeline compares Less, so the heavy scene never lands. Aerial perspective does not read sky_view, and the copy onto HDR publishes that result. The validation scope can stay empty, so median_gpu_frame_ms can print a frame that is neither the 3.688 ms scene nor the Bruneton sky. A ≤ 11 reading of that print would approve an undercount.
The "exactly one gated flag" error cannot run. Only --atmosphere is pushed onto chosen; a blocked flag returns first.
The pull request body still says the binary accepts --ssgi, --taa, --dof, and --clouds and prints a median, and the test plan names 6f235edd. Head 591e2286 rejects those flags.
Still open: fog and god rays also turn off when aravath.cfg says volumetrics=off, and the shadow row still treats shadow_csm.rs and the PCSS sampler as one target. The normal and velocity exit still compares against a clear that never happens.
Sent by Cursor Automation: ASTRA PR AUDIT AGENT
|
@coderabbitai review |
There was a problem hiding this comment.
Blocking: --atmosphere is still not a measurement cell. 6debf550 only edits the inventory.
The two doc fixes hold. Fog and god rays now name the aravath.cfg switch, and light_the_world returns before both set_volumetric_fog_config and set_god_ray_config when that launch flag is false. shadow_csm.rs is the second atlas (CsmRenderer, tests and its own module only). shadow_quality.rs plus shadow_sampling.wgsl are ShadowParamsGpu and the PCSS / Poisson shader. shaders/shadow_common.wgsl does not include that shader. Invariant 20 already forbids wiring either beside the live cascades.
No new crate, lockfile entry, credential path, or network surface. The new flags are exact argv matches (--name or --name=true). set_atmosphere_enabled stores a bool. prepare_frame runs only from record_gated_presentation inside draw_into, with sun Vec3::Y, moon Vec3::NEG_Y, near 0.1, and far 200.0. That function does not read Instant or an RNG and does not write ECS, nav, or physics. With the flag off, the heavy-scene binary and the nineteen replay hashes are unchanged. This is presentation-only, and the GPU result is not read back into the sim.
The cell is still wrong. draw_into records SkyRenderer only while atmosphere_on is false. That pass is the HDR clear and LoadOp::Clear(1.0) of scene depth, with depth_write_enabled: false on the sky pipelines. The shadow clears are cascade layers, not scene depth. The main pass then LoadOp::Loads both attachments and the static-mesh pipeline compares Less. wgpu-core 25.0.2 (RenderPassInfo::add_pass_texture_init_actions) records NeedsInitializedMemory for LoadOp::Load, and clear_texture_via_render_passes fills color with transparent and depth with (0.0, 0). The validation scope stays empty, so warmup finishes and median_gpu_frame_ms prints.
Depth 0 fails Less, so the heavy scene never lands. aerial_perspective.wgsl treats depth_raw >= 0.9999 as sky and otherwise short-circuits when the reconstructed distance is under 0.001 km. A near plane of 0.1 m is under that, so the 16-step integral does not run and the store is scene color. The aerial bind group is params, scene color, depth, transmittance, sampler, and the storage output. sky_view is not in it. copy_texture_to_texture then replaces HDR with that result. The stamp named atmosphere is composite_atmosphere (fog and god rays), which this binary leaves off. The Bruneton dispatches run later, after bloom, outside that stamp. A ≤ 11 reading of this print is an undercount of both the scene and the sky.
prepare_frame still ignores the budget camera's light direction and Aravath's clock of 16.4. The clip planes match fixed_camera only because both are hardcoded to 0.1 and 200.
chosen still receives only --atmosphere. A blocked flag returns inside the loop, so chosen.len() > 1 cannot run. --atmosphere --ssgi reports only the SSGI reason. flag_on reads std::env::args(), the gate cannot be tested in-process, and it runs after the renderer, the heavy scene, and the GLB are built. A misspelled flag falls through as gated_measure=baseline.
The normal and velocity exit still says the textures are "not the cleared value." ensure_gated_aux allocates them and returns. Nothing clears them and nothing stores a normal or a motion vector.
Invariant 22 (the timestamp row) still cites gpu_frame_budget --scene heavy --atmosphere as the evidence, and the v1.43 notice says that run prints the whole frame. last_verified_commit is still 09d49dfe. The table also has a second row numbered 22 (fate-scars). The pull request body still says the binary accepts --ssgi, --taa, --dof, and --clouds and prints a median, and the test plan still names 6f235edd. Head 6debf550 rejects those flags.
Reject --atmosphere until the far depth clear and the HDR clear still happen, sky-depth pixels sample sky_view, and the post pass shows that sky. Do not fill the cell from a scope-clean median of the current path.
Sent by Cursor Automation: ASTRA PR AUDIT AGENT
|
@coderabbitai review |
There was a problem hiding this comment.
The harness gate is sound. reject_gated_flags runs before the GLB check and Renderer::new_headless, collects every hit, and the six reasons match the renderer. No Cargo.toml or lockfile change, no new crate edge, and the error text is the constant flag plus its constant reason. The new function does not read Instant or an RNG and does not write ECS, nav, or physics. With no gated flag, the binary still leaves atmosphere_on, ssgi_on, taa_on, upscale_on, dof_on, and cloud_raymarch_on at their defaults. Replay crates are untouched.
The inventory and invariant 22 are not yet a contract a follow-up can implement. The atmosphere row assigns fog and god rays to the atmosphere pull and also tells that pull to leave them on the light_the_world path. prepare_frame still feeds a zenith sun. The fog row describes the last line of aravath.cfg rather than the last matching key. Depth of field writes AdvancedPostFx's "TAA History" texture, which is not TaaPass's history. Invariant 22 marks the new reject sentence Yes against last_verified_commit 09d49dfe.
Security: argv is compared by equality to six literals. A hostile argument cannot land in the error string, a path, or a shell. Determinism: the baseline frame is the same presentation path as before this pull, including cloud shadows on and volumetrics off. The GPU result is not read back into the sim.
Sent by Cursor Automation: ASTRA PR AUDIT AGENT
There was a problem hiding this comment.
Blocking against current main (8b4caa27, trace v1.48). The harness gate itself is sound. Two documents are not.
reject_gated_flags runs before the GLB check and Renderer::new_headless, joins every exact hit, and the six reasons match this branch's renderer. --atmosphere still skips SkyRenderer (draw_into only calls sky.render while atmosphere_on is false). That render is the HDR clear and the depth clear to 1.0, with depth_write_enabled: false. The main pass then LoadOp::Loads both. --ssgi / --taa allocate gated normal and gated velocity and never store into them; SSGI and TAA also sample history that record_gated_presentation never copies. --dof writes AdvancedPostFx's "TAA History" with LoadOp::Load and the post pass still samples HDR. --clouds samples cloud_history inside execute and copy_cloud_to_history runs after that, with no copy of composited_texture onto HDR. No Cargo.toml or lockfile change. The bail text is the constant flag plus its constant reason, so a hostile argument cannot enter a path, a shell, or the error string. The new function does not read Instant or an RNG and does not write ECS, nav, or physics. Replay crates are untouched. With no gated flag, the binary still leaves the six presentation switches at their defaults. That path is presentation-only.
The cfg, DoF, and 9-tap versus shaders/dof.wgsl sentences match the code. parse_volumetrics_cfg keeps the last volumetrics=on|off key. light_the_world still calls both setters when volumetrics are on, with god rays at half resolution and 32 samples. prepare_frame on this head still passes sun Vec3::Y.
What does not hold is the trace stamp and the #395 assignment. Details are on the lines.
Still open on flag_on: it is closed over std::env::args(), nothing in this crate tests it, and --atmosphere true (the same two-token shape as --scene heavy) is not a hit. The process then prints gated_atmosphere=off and gated_measure=baseline from literals, not from the renderer. A typo takes that path. The --ssgi, --taa, and --upscale reasons still stop at the normal and velocity targets and do not mention the uncopied history images.
Sent by Cursor Automation: ASTRA PR AUDIT AGENT
List the presentation passes, the live owners that must not be duplicated, and the issues this campaign will not take. Co-authored-by: Andrew Brown <lazyxeon@users.noreply.github.com>
Record the 7.397 ms cloud-march measurement and the estimates scaled from it. Atmosphere, SSGI, TAA, and depth of field default on. The raymarch and temporal upscale stay off, with the reason next to the cost. Co-authored-by: Andrew Brown <lazyxeon@users.noreply.github.com>
7.397 ms is the cloud-shadow amortization, not the raymarch. gpu_frame_budget can enable atmosphere, SSGI, TAA, DoF, or clouds one flag at a time and print median_gpu_frame_ms. Defaults stay off until a GTX 1660 Ti heavy-scene median is at or under 11 ms. Co-authored-by: Andrew Brown <lazyxeon@users.noreply.github.com>
Reject a second gated flag. Reject SSGI, TAA, upscale, DoF, and the cloud raymarch before a frame: those paths sample uncleared textures or never write HDR. --atmosphere replaces SkyRenderer, so its median is the whole frame. Invariant 22 records that contract. Co-authored-by: Andrew Brown <lazyxeon@users.noreply.github.com>
aravath.cfg volumetrics=off turns fog and god rays off before the command-line switches. shadow_csm.rs is the second cascade map. shadow_quality.rs is the PCSS filter, not another atlas. Co-authored-by: Andrew Brown <lazyxeon@users.noreply.github.com>
gpu_frame_budget bails before the scene on --atmosphere as well as --ssgi, --taa, --upscale, --dof, and --clouds. The printed median stays the baseline frame. Every gated cell stays blank and every gated default stays off. Co-authored-by: Andrew Brown <lazyxeon@users.noreply.github.com>
Fog and god rays belong to #395, not to light_the_world. prepare_frame on this head still passes a zenith sun, and that gap stays with #395. The last matching aravath.cfg key wins. DoF writes AdvancedPostFx's "TAA History" texture, which is not TaaPass history, so both defaults stay off. Invariant 22 was re-read at 85ad478. Co-authored-by: Andrew Brown <lazyxeon@users.noreply.github.com>
The trace keeps main's v1.48 Hi-Z wording and adds the gated-flag reject sentence on the timestamp row. last_verified_commit is 83798b4. #395 owns the clear, the sky sample, and the sun. Fog and god rays stay light_the_world callers. flag_on accepts a bare flag, =true, and a two-token true, and the SSGI, TAA, and upscale errors name the uncopied history images. Co-authored-by: Andrew Brown <lazyxeon@users.noreply.github.com>
351559d to
f72defd
Compare
There was a problem hiding this comment.
Blocking. The gate and the rebased trace match this head. The campaign contract does not match the pull already stacked on it, and three gated passes still have no path onto HDR.
reject_gated_flags runs before the GLB check and Renderer::new_headless, joins every exact hit, and the atmosphere, depth-of-field, and cloud reasons match the renderer. No Cargo.toml or lockfile change, and no new crate edge. The bail text is the constant flag plus its constant reason, so a hostile argument cannot enter a path, a shell, or the error string. The new function does not read Instant or an RNG and does not write ECS, nav, or physics. Replay crates are untouched. With no gated flag, the binary still leaves atmosphere_on, ssgi_on, taa_on, upscale_on, dof_on, and cloud_raymarch_on at their defaults. That path is presentation-only. The two new stdout lines are literals on that same path.
The trace keeps main's v1.48 Hi-Z sentence and appends the reject sentence. last_verified_commit 83798b48 is the parent of f72defda and a descendant of main 8b4caa27. parse_volumetrics_cfg keeps the last volumetrics=on|off key, and a read or parse error calls startup::fatal. light_the_world still calls both setters when volumetrics are on, with god rays at half resolution and 32 samples. prepare_frame on this head still passes sun Vec3::Y. Aerial's bind group is params, scene color, depth, transmittance, sampler, and the storage output. SkyRenderer::render is still the HDR clear and LoadOp::Clear(1.0) of depth, with depth_write_enabled: false, and the main pass loads both under CompareFunction::Less (wgpu 25.0.2). The 9-tap texture_depth_2d shader, the separate 16-tap shaders/dof.wgsl, the shadow split, the deleted fog node, sys_ai_planning staying on RuleOrchestrator, and test-only recorded_line all match the tree. shadow_mode and GOAP telemetry still read Instant, off the tick.
#395 (cursor/wire-atmosphere-568b, base this branch) defines the only successful --atmosphere median as atmosphere_with_aravath_fog and returns before the print unless fog and god rays both build. This inventory says those medians stay blank and stay out of the atmosphere cell. The pull request body still says fog and god rays are #395 only and that last_verified_commit is 85ad4787.
SSGI, TAA, and temporal upscale write their own textures. record_gated_presentation never calls copy_to_history and never copies those textures onto hdr_tex. The post pass samples hdr_view. A history fix alone can still print a median of a frame that does not show the pass.
The third clause of flag_on repeats arg == name. --atmosphere false bails. --atmosphere=false falls through. The new test is on a bin with required-features = ["gpu-frame-budget"], and the required gate clippy is --lib, so that test is outside the required check. I inspected it. This environment has no render build, so I did not execute it.
Sent by Cursor Automation: ASTRA PR AUDIT AGENT
flag_on treats --name=false and --name false as off, so they do not bail. The parser and its tests live in budget_gate.rs, under the lib test and clippy gates. The inventory records #395's atmosphere median and the SSGI, TAA, and upscale HDR copy blocker. Co-authored-by: Andrew Brown <lazyxeon@users.noreply.github.com>
|
@coderabbitai review |
There was a problem hiding this comment.
The false-flag gate holds. Two contracts the follow-up will implement do not.
flag_on lives in budget_gate.rs, which cargo test --lib and clippy --lib both compile. Bare --name, --name=true, and --name true are on. --name=false and --name false are off and do not bail. bare_flag rejects a following token that does not start with -, so the true clause is reached. I compiled that module on its own (it depends only on anyhow) and reject_gated_flags_covers_each_form passed, including --atmosphere false beside a later --ssgi, a later bare --atmosphere, and =false. reject_gated_flags runs before the GLB check and Renderer::new_headless. The bail text is the constant flag plus its constant reason, so an argument cannot enter a path, a shell, or the error string. No Cargo.toml or lockfile change. The function does not read Instant or an RNG and does not write ECS, nav, or physics. With no enabled gated flag the binary still prints the literals gated_atmosphere=off and gated_measure=baseline and does not call the setters. Replay crates are untouched. On this head draw_into still records SkyRenderer only while atmosphere_on is false, so the atmosphere reason still matches this renderer. The trace keeps the Hi-Z sentence, and last_verified_commit f72defda is the parent of the v1.50 notice.
#395 (7fcd20b, base this branch, committed before this head) still enables atmosphere with arg == name || arg == format!("{name}=true"). --atmosphere false is on there, because the bare token matches. This inventory says that form is off. A rebase that keeps #395's parser measures a frame for a command this gate refuses. The zenith sentence is behind that same head. Details are on the lines.
The --ssgi, --taa, and --upscale reasons still stop at the unwritten inputs and the history sample. SsgiPass::execute writes denoised_view (and copies the trace into it when half_res is false). TaaPass::execute writes resolved_view and sharpened_view. TemporalUpscalePass::execute writes its sharpened view. record_gated_presentation never copies those onto hdr_tex. The post pass samples hdr_view. DoF and clouds already require the result on HDR. These three reasons need that sentence too.
Sent by Cursor Automation: ASTRA PR AUDIT AGENT
|
|
||
| ## Measured column | ||
|
|
||
| A cell is filled only by a GTX 1660 Ti heavy-scene run whose validation scope is clean and whose command line enables exactly one gated pass. This binary rejects an enabled gated flag before it builds the scene, including bare `--atmosphere`, `--atmosphere=true`, and `--atmosphere true`. `--atmosphere=false` and `--atmosphere false` are off and do not bail. Every gated cell on this binary stays blank. Every gated default stays off. #395 is the atmosphere measurement. It prints `atmosphere_with_aravath_fog` only when both fog and shafts build. Otherwise it bails and prints no median. |
There was a problem hiding this comment.
#395 at 7fcd20b does not use this flag_on.
Its gpu_frame_budget still has std::env::args().any(|arg| arg == name || arg == format!("{name}=true")). gated_atmosphere treats that as the enable. The argv token --atmosphere matches, and the following false is never read, so --atmosphere false enables the pass and can print median_gpu_frame_ms with label atmosphere_with_aravath_fog. --atmosphere=false does not match that predicate, so the two off forms this paragraph treats as the same switch take opposite paths on the measurement pull.
The label sentence matches 7fcd20b: both fog and shafts print atmosphere_with_aravath_fog and continue; any miss prints atmosphere_without_fog, atmosphere_without_shafts, or atmosphere_without_volumetrics and bails before the median. The parser sentence does not. The measurement caller has to call budget_gate::flag_on, so --atmosphere false stays off while a bare --atmosphere stays on.
|
|
||
| | Order | System | Issue | Current state | Wiring plan | Owner crate | Exit test | | ||
| |---|---|---|---|---|---|---| | ||
| | 1 | Atmosphere (`AtmospherePass`) | #226 | Flag defaults false. This binary rejects an enabled `--atmosphere`. #395 prints `atmosphere_with_aravath_fog` only when both fog and shafts build; otherwise it bails and prints no median. `record_gated_presentation` on this head calls `prepare_frame` with sun `Vec3::Y`, moon `Vec3::NEG_Y`, near `0.1`, and far `200.0`. | #395 is the one caller. It owns the clear, the sky sample, and the sun. The zenith sun on this head is that pull's gap. #226 tracks the pull. Fog and god rays stay on `light_the_world`. #395 does not remove those setters. Default stays off. | `astraweave-render` | This inventory does not enable the flag. Replay hashes unchanged. | |
There was a problem hiding this comment.
The Vec3::Y, 0.1, and 200.0 call is this head. It is not an open gap on #395.
7fcd20b prepare_frame takes toward_sun from camera_ubo.light_dir_pad and near/far from clip_planes(self.cached_proj). Zenith remains only when that vector is degenerate. update_view writes TimeOfDay::get_light_direction() unless a light override is set, and it ignores the RenderView light. The budget binary sets current_time = 16.4 and time_scale = 0.0 before the loop, then calls update_view before every draw_into. get_sun_position peaks overhead at noon. At 16.4 the sun is about (0.753, 0.565, 0.335). The budget camera far is GAME_ZFAR (500.0 in astraweave-camera).
That head also already has the other two pieces this row assigns: when atmosphere_on is set, draw_into clears HDR with hdri_sky_clear_color() and depth with LoadOp::Clear(1.0) before the main pass loads both, and the aerial bind group includes sky_view at binding 6. light_the_world still calls both volumetrics setters, and it adds set_atmosphere_enabled(PresentationQuality::default().atmosphere()). PresentationQuality::default() is Measured, so that call stores false. The setters stay. The hardcoded zenith call does not.
Say this head still passes Vec3::Y. Drop the claim that the zenith literal is still #395's gap.
The reject reasons still cite the unwritten inputs and history samples, and now also say each pass writes its own view and that view is never copied onto hdr_tex. Co-authored-by: Andrew Brown <lazyxeon@users.noreply.github.com>
|
@coderabbitai review |
There was a problem hiding this comment.
Blocking on the three new SSGI, TAA, and upscale reasons. The gate itself holds.
flag_on is on for bare --name, --name=true, and --name true, and off for --name=false and --name false. A following token that does not start with - keeps the bare flag off, so the true clause is the pair that reads the value. I ran those forms, a pair, --atmosphere false --ssgi, a repeated flag, and prefix lookalikes against that predicate. reject_gated_flags runs before the GLB check and Renderer::new_headless. The error is the constant table, not argv. No Cargo.toml or lockfile change. anyhow was already a workspace dependency. The module does not read Instant or an RNG and does not write ECS, nav, or physics. On this head draw_into still records SkyRenderer only while atmosphere_on is false, and the main pass still loads HDR and depth. A successful run still prints the literals gated_atmosphere=off and gated_measure=baseline.
The new sentences correctly say the pass result is not copied onto hdr_tex. record_gated_presentation never calls SsgiPass::copy_to_history, TaaPass::copy_to_history, or TemporalUpscalePass::copy_to_history. The only history write there is copy_cloud_to_history, after the cloud sample. "Sampled before copy_to_history" names an order this caller does not record. The methods document the other order: sample the previous history inside execute, then copy the new output into history. TAA's three textures are STORAGE_BINDING | TEXTURE_BINDING only, so neither copy_to_history nor a copy of sharpened_view onto hdr_tex is a legal copy_texture_to_texture. ssgi_denoised has COPY_DST and no COPY_SRC. Upscale textures already have both copy usages.
Two earlier contracts are unchanged. #395 at 7fcd20b still enables with arg == name || arg == format!("{name}=true"), so --atmosphere false draws there and --atmosphere=false does not. This head's atmosphere prepare_frame still passes Vec3::Y, 0.1, and 200.0. #395 already moved that call to record_bruneton, which takes toward_sun from light_dir_pad and near/far from clip_planes. The Vec3::Y left in #395's record_gated_presentation is the cloud march.
Sent by Cursor Automation: ASTRA PR AUDIT AGENT
| "normal and velocity targets are allocated and never written, and ssgi_history is sampled before copy_to_history; the pass writes denoised_view, and record_gated_presentation never copies it onto hdr_tex, so the post pass samples a frame that does not show it", | ||
| ), | ||
| ( | ||
| "--taa", | ||
| "normal and velocity targets are allocated and never written, and taa_history is sampled before copy_to_history; the pass writes resolved_view and sharpened_view, and record_gated_presentation never copies them onto hdr_tex, so the post pass samples a frame that does not show them", | ||
| ), | ||
| ( | ||
| "--upscale", | ||
| "normal and velocity targets are allocated and never written, and upscale_history is sampled before copy_to_history; the pass writes sharpened_view, and record_gated_presentation never copies it onto hdr_tex, so the post pass samples a frame that does not show it", |
There was a problem hiding this comment.
The hdr_tex clause matches the recorder. SsgiPass::execute, TaaPass::execute, and TemporalUpscalePass::execute run, and the only copy_texture_to_texture onto hdr_tex in record_gated_presentation is the aerial target. The post bind group is hdr_view. Rows 4–6 already withhold a median until that copy exists.
ssgi_history is sampled before copy_to_history is not an order this function records. renderer.rs calls copy_to_history nowhere. The cloud path is the one that writes history, and it writes after the sample (copy_cloud_to_history). The three copy_to_history methods say to call them after execute, so the sample of the previous history stays first. "Before" points that copy the wrong way. The inventory rows already say the caller does not call copy_to_history. These reasons should say that. The contains("copy_to_history") asserts stay green either way.
Two of the named HDR copies are also illegal as copy_texture_to_texture today:
TaaPass::newbuildstaa_history,taa_resolved, andtaa_sharpenedwithSTORAGE_BINDING | TEXTURE_BINDINGonly (taa.rsmake_tex).copy_to_historycopiesresolved_textureontohistory_texture. Neither side hasCOPY_SRCorCOPY_DST.sharpened_texturehas noCOPY_SRC, so copyingsharpened_viewontohdr_texfails the same check. Adding the call without those usages is a validation-scope bail, not a cell. Defaultsharpen_strengthis0.5, soexecutedoes writesharpened_viewwhen the pass runs.ssgi_denoisedisSTORAGE_BINDING | TEXTURE_BINDING | COPY_DSTand has noCOPY_SRC, so copyingdenoised_viewontohdr_texis not a legal copy.SsgiPass::copy_to_historyitself is legal: it copiesssgi_trace_denoised(COPY_SRC) ontossgi_history(COPY_DST). DefaultSsgiConfig::half_resis false, so that trace texture is full size. Name the missingCOPY_SRCondenoised, or nametrace_denoisedas the copy source.- Upscale textures already include
COPY_SRC | COPY_DST. Only the missingcopy_to_historyand the missing HDR copy apply there.
A history write alone still must not drop the reject. The presented frame samples HDR.
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
There was a problem hiding this comment.
Blocking on the merged tree (c0084368, merge 7427bc05). The gate's own false-form behavior holds. Three earlier contracts are still open, and the cloud and depth-of-field plans tell the next pull to perform copies the textures cannot do.
What holds. reject_gated_flags runs on args().skip(1) before the GLB check and Renderer::new_headless. Bare --name, --name=true, and --name true are on. --name=false and --name false are off. The bail text is the constant table, so an argument cannot enter a path, a shell, or the error string. No Cargo.toml or lockfile change. anyhow was already a workspace dependency of astraweave-render. pub mod budget_gate has a non-test caller in gpu_frame_budget. The new module does not read Instant or an RNG and does not write ECS, nav, or physics. Instant in the binary is the pre-existing measurement clock, and the new return happens before that loop. With no enabled gated flag the binary still prints the literals gated_atmosphere=off and gated_measure=baseline and does not call the setters. Replay crates are untouched. Determinism replay on this head succeeded on ubuntu, windows, and macos (determinism-replay compare, run 39584143604). parse_volumetrics_cfg still keeps the last volumetrics=on|off key, with the line, length, and control-character bounds. light_the_world still returns before both setters when volumetrics are off. recorded_line still has only test callers. On this head draw_into still records SkyRenderer only while atmosphere_on is false, and prepare_frame still passes Vec3::Y, 0.1, and 200.0.
Still open, re-checked against #395 at 7fcd20b:
- That pull's
flag_onis stillarg == name || arg == format!("{name}=true").--atmosphere falseenables there and can printatmosphere_with_aravath_fog.--atmosphere=falsedoes not. This binary treats both as off. record_brunetontakestoward_sunfromlight_dir_padand near/far fromclip_planes.Vec3::Ythere is only the degenerate-light fallback. TheVec3::Yleft in#395'srecord_gated_presentationis the cloud march. This head's atmosphere call is still the zenith literal. It is not an open gap on#395.record_gated_presentationnever callsSsgiPass::copy_to_history,TaaPass::copy_to_history, orTemporalUpscalePass::copy_to_history. The legal order those methods document is sample insideexecute, then copy. TAA's three textures areSTORAGE_BINDING | TEXTURE_BINDINGonly, so neithercopy_to_historynor a copy ofsharpened_viewontohdr_texis a legalcopy_texture_to_texture.ssgi_denoisedhasCOPY_DSTand noCOPY_SRC. Defaulthalf_resis false, sossgi_trace_denoised(COPY_SRC) is full size and is the legal history source. Upscale textures already have both copy usages. The post bind group ishdr_view. The onlycopy_texture_to_textureontohdr_texin this function is the aerial target.
#395 must not adopt this inventory as the implementation contract until those three are corrected. The two new lines are the same class of hole for clouds and depth of field, plus a silent baseline for unrecognized flag spellings.
Sent by Cursor Automation: ASTRA PR AUDIT AGENT
| let equals_true = format!("{name}=true"); | ||
| args.iter().enumerate().any(|(index, arg)| { | ||
| let next = args.get(index + 1).map(String::as_str); | ||
| (arg == name && bare_flag(next)) |
There was a problem hiding this comment.
flag_on fails closed for the two documented off forms. Other spellings of on do not bail, and the process then measures the baseline frame.
--ssgi=1, --ssgi on, --ssgi yes, --ssgi TRUE, and --ssgi=True all return false here. reject_gated_flags returns Ok. gpu_frame_budget prints the literals gated_atmosphere=off and gated_measure=baseline and still reaches median_gpu_frame_ms for the unflagged scene. A capture that keeps only the median line records the 3.688 ms baseline as a gated cell. reject_gated_flags_covers_each_form asserts the three on-forms and the two off-forms, so it stays green for this hole.
--ssgi --ssgi=false stays on. The bare token's next argument starts with -, so bare_flag is true before the =false token is considered. That is the safe direction for a reject gate. parse_volumetrics_cfg is last-key-wins. Matching this predicate to that rule would let a trailing =false hide an earlier bare flag and print the baseline median. Add the unrecognized on-spellings to the reject, and keep an earlier bare flag on when a later false form is also present.
| |---|---|---|---|---|---|---| | ||
| | 1 | Atmosphere (`AtmospherePass`) | #226 | Flag defaults false. This binary rejects an enabled `--atmosphere`. #395 prints `atmosphere_with_aravath_fog` only when both fog and shafts build; otherwise it bails and prints no median. `record_gated_presentation` on this head calls `prepare_frame` with sun `Vec3::Y`, moon `Vec3::NEG_Y`, near `0.1`, and far `200.0`. | #395 is the one caller. It owns the clear, the sky sample, and the sun. The zenith sun on this head is that pull's gap. #226 tracks the pull. Fog and god rays stay on `light_the_world`. #395 does not remove those setters. Default stays off. | `astraweave-render` | This inventory does not enable the flag. Replay hashes unchanged. | | ||
| | 2 | Depth of field | #232 | `set_dof_enabled` defaults false. Live shader is `advanced_post.rs` `DOF_SHADER`: `texture_depth_2d`, center sample plus 8 offsets (9 taps). `apply_dof` writes `AdvancedPostFx`'s texture labeled `"TAA History"` (`history_view`) with `LoadOp::Load`. `AdvancedPostFx::new` never clears it. That texture is not `TaaPass`'s `taa_history`. The post pass still reads HDR. `shaders/dof.wgsl` is a different 16-tap `texture_2d<f32>` shader and is not this pass. | The shared history name is a conflict. DoF and TAA stay at their defaults until those histories are separate, the DoF target is cleared, and the post pass reads the 9-tap output. No `--dof` before that. | `astraweave-render` | Default stays off. No measured cell until the histories are separate. | | ||
| | 3 | Cloud raymarch (`VolumetricCloudsPass`) | #229 | `execute` samples `cloud_history` and writes `composited_texture`. `copy_cloud_to_history` runs after the sample. `record_gated_presentation` does not copy the composite onto HDR. | Write history before the sample, and copy the composite onto HDR. Then add `--clouds`. Not the 7.397 ms shadow delta. | `astraweave-render` | A clean scope and a median of a frame that shows the composite. Default stays off until that cell is ≤ 11. | |
There was a problem hiding this comment.
The history write this row treats as a reorder is not a legal copy_texture_to_texture, and the HDR step it prescribes is not legal either.
make_half builds both cloud_raymarch and cloud_history with STORAGE_BINDING | TEXTURE_BINDING only (volumetric_clouds.rs). copy_cloud_to_history copies cloud_texture onto cloud_history. Neither side has COPY_SRC or COPY_DST. Moving that call to before execute still fails the budget binary's validation scope. The --clouds reason in budget_gate.rs describes this as an order problem ("samples cloud_history before writing it"). The call on this head is record_gated_presentation after execute (renderer.rs copy_cloud_to_history). The usages reject it in either order.
cloud_composited is STORAGE_BINDING | TEXTURE_BINDING only, full size, with no COPY_SRC. hdr_tex has COPY_DST. Copying the composite onto HDR is not a legal copy until cloud_composited gains COPY_SRC. The plan says to do that copy and then add --clouds. Dropping the reject after only a reorder still cannot print a median of a frame that shows the composite.
The same prepare_frame passes sun Vec3::Y, near 0.1, far 200.0, and dt 1.0/60.0. The step is a fixed 1/60, not a wall clock. The sun and the clip are not the budget camera. This head's fixed_camera light is (-1, -0.5, -1) normalized, and its far happens to be 200. #395 at 7fcd20b still passes Vec3::Y, 0.1, and 200.0 into the cloud march, while its budget projection far is GAME_ZFAR (500.0). The Vec3::Y in #395's record_bruneton is only the degenerate-light fallback. The cloud march is a different literal. Name the missing copy usages and this sun before a cell can be filled. The --clouds reject is what keeps the path off this binary today.
| | Order | System | Issue | Current state | Wiring plan | Owner crate | Exit test | | ||
| |---|---|---|---|---|---|---| | ||
| | 1 | Atmosphere (`AtmospherePass`) | #226 | Flag defaults false. This binary rejects an enabled `--atmosphere`. #395 prints `atmosphere_with_aravath_fog` only when both fog and shafts build; otherwise it bails and prints no median. `record_gated_presentation` on this head calls `prepare_frame` with sun `Vec3::Y`, moon `Vec3::NEG_Y`, near `0.1`, and far `200.0`. | #395 is the one caller. It owns the clear, the sky sample, and the sun. The zenith sun on this head is that pull's gap. #226 tracks the pull. Fog and god rays stay on `light_the_world`. #395 does not remove those setters. Default stays off. | `astraweave-render` | This inventory does not enable the flag. Replay hashes unchanged. | | ||
| | 2 | Depth of field | #232 | `set_dof_enabled` defaults false. Live shader is `advanced_post.rs` `DOF_SHADER`: `texture_depth_2d`, center sample plus 8 offsets (9 taps). `apply_dof` writes `AdvancedPostFx`'s texture labeled `"TAA History"` (`history_view`) with `LoadOp::Load`. `AdvancedPostFx::new` never clears it. That texture is not `TaaPass`'s `taa_history`. The post pass still reads HDR. `shaders/dof.wgsl` is a different 16-tap `texture_2d<f32>` shader and is not this pass. | The shared history name is a conflict. DoF and TAA stay at their defaults until those histories are separate, the DoF target is cleared, and the post pass reads the 9-tap output. No `--dof` before that. | `astraweave-render` | Default stays off. No measured cell until the histories are separate. | |
There was a problem hiding this comment.
"TAA History" cannot be the source of a copy_texture_to_texture onto HDR, and a failed create still continues the frame.
AdvancedPostFx::new builds that texture with RENDER_ATTACHMENT | TEXTURE_BINDING only. No COPY_SRC. apply_dof is a render pass into history_view() with LoadOp::Load, and new does not clear the texture. The post bind group samples hdr_view. Implementing "on HDR" as copy_texture_to_texture fails the validation scope the same way a copy of TAA's sharpened_view does. The legal path is a sampled read of this view, after the first frame clears or discards it. This texture is still not TaaPass's taa_history.
If AdvancedPostFx::new returns Err, record_gated_presentation logs depth of field pass was not created and leaves dof_pass as None. The setter can stay true while the 9-tap shader never runs. The exit for this row has to refuse a median on that path. The --dof reject is what keeps the budget binary off it today.
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: c0084368e5
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| (arg == name && bare_flag(next)) | ||
| || arg == &equals_true | ||
| || (arg == name && next == Some("true")) |
There was a problem hiding this comment.
Treat a gated flag before positional arguments as enabled
When a gated flag is followed by any non-option token other than true, bare_flag returns false and the benchmark proceeds. For example, --atmosphere heavy --glb ... is a valid heavy-scene spelling according to scene_is_heavy, but this gate treats atmosphere as disabled and prints a baseline median, contrary to the documented guarantee that a bare gated flag is rejected. Only an explicit false value should disable the flag; other following positional values should leave the bare flag enabled or cause an argument error.
Useful? React with 👍 / 👎.


Description
Draft. Does not merge. Rebased onto
mainat8b4caa27.gpu_frame_budgetrejects an enabled gated flag before it builds the scene.budget_gate::flag_onaccepts bare--atmosphere,--atmosphere=true, and--atmosphere true.--atmosphere=falseand--atmosphere falseare off and do not bail. The same parse applies to--ssgi,--taa,--upscale,--dof, and--clouds.The
--ssgi,--taa, and--upscaleerrors still name the uncopied history images. They also name the views those passes write (denoised_view,resolved_viewandsharpened_view,sharpened_view) and sayrecord_gated_presentationnever copies them ontohdr_tex, so the post pass samples a frame that does not show them. That is the same bar as DoF and clouds. The parser and its tests are inbudget_gate.rs, so they run undercargo test --liband clippy--lib.The trace keeps the Hi-Z sentence and the reject sentence on the timestamp row.
last_verified_commitisf72defda, the parent of the v1.50 notice.#395 is the one atmosphere caller, and #226 tracks it. #395 owns the clear, the sky sample, and the sun.
prepare_frameon this head still passes a zenith sun. Fog and god rays remainlight_the_worldcallers. #395 does not remove those setters. #395 printsatmosphere_with_aravath_fogonly when both fog and shafts build. Otherwise it bails and prints no median. After this merges, #395 rebases onto main and switches tobudget_gate::flag_on.SSGI, TAA, and temporal upscale each write their own texture.
record_gated_presentationnever copies that texture ontohdr_tex. No median counts until the presented frame contains the pass. DoF writesAdvancedPostFx's"TAA History"texture, which is notTaaPass'staa_history, so those defaults stay off.Type of change
Security Considerations
Checklist
Test plan
cargo test -p astraweave-render --lib reject_gated_flags_covers_each_form—falsestays off;--ssginamesdenoised_viewandhdr_tex;--taanamesresolved_viewandsharpened_view;--upscalenamessharpened_viewcargo clippy -p astraweave-render --locked --lib --no-deps -- -D warningsc0084368