Skip to content

render: floor the camera screen residual top-down on every backend - #5201

Merged
jakildev merged 2 commits into
masterfrom
claude/5190-gl-camera-residual-floor
Nov 19, 2026
Merged

jakildev merged 2 commits into
masterfrom
claude/5190-gl-camera-residual-floor

Conversation

@jakildev

@jakildev jakildev commented Nov 19, 2026 •

Copy link
Copy Markdown
Owner

Summary

On OpenGL, a camera with a fractional y screen residual drew the whole frame one screen row lower than Metal, and lower than where the receiver-shadow oracle places it. IRMath::cameraSubPixelOffsets and its continuous-zoom twin cameraRasterScreenResidual applied the iso-to-screen sign inside floor(), so GL's -1 turned the floor into a ceil. Both helpers now floor top-down and sign afterwards, like the framebuffer half already does. Metal's sign is +1, so it is unchanged by construction.

Every residual reader (the blit, sprites, depth-tested primitives, probes, mouse mapping) takes its value from these helpers, so all of them move with the frame. 27 windows-debug references whose camera has a fractional y residual are re-blessed. Each one is the old image moved up exactly one row.

Acceptance evidence

Criterion Check run Observed
1. Unit test pins the y sense (positive fire) fleet-run IrredenEngineTest --gtest_filter='CameraSubPixel*:CameraRaster*:CameraZoom*' 59/59 pass on the PR head
1. …and fails on the pre-fix formula camera_subpixel_test.cpp compiled standalone against a header copy with the sign moved back inside both floors fixed header: 20/20 pass. Pre-fix header: 5 fail, among them the 3 new y-sense tests (FractionalYResidualFloorsTopDown… ×2, FractionalYIsMonotoneTopDown…)
2. GL oracle, subpos/subneg yaw 0.6, fog 0 and 16, IR_PERAXIS_SURFACE_LIGHTING=1, no shift the issue's Repro driver at native 2560×1440, then render_receiver_shadow_polygon.check_image all 4 rows 0/0/0 (issue reading on master: 21/26/0)
3. GL: near ×4, mid ×4, origin ×8 same driver, fog 0 and 16 all 32 rows 0/0/0; every capture RESULT=CLEAN, 2560×1440 target, no GL errors
3. Metal unchanged by construction: floor(a)·1 = floor(a·1); the new tests run the +1 sign explicitly on this host and pass unverifiable on windows-debug: no macOS host here, and no macOS CI job runs IrredenEngineTest. The mac smoke lane runs it
4. Render-verify GL rows: IRShapeDebug python3 scripts/render-verify.py --target IRShapeDebug 15 FAIL before the bless, then 180 PASS / 6 SKIP after
4. Render-verify GL rows: IRFogDemo python3 scripts/render-verify.py --target IRFogDemo 8 FAIL before the bless, then 53 PASS / 16 SKIP after
4. Render-verify GL rows: IRPerfGrid python3 scripts/render-verify.py --target IRPerfGrid 12 FAIL (4 refs × 3 passes) before the bless, then 21 PASS / 14 SKIP after
4. Render-verify GL rows: IRCanvasStress python3 scripts/render-verify.py --target IRCanvasStress 31 PASS / 28 SKIP, nothing re-blessed
4. Re-blessed rows are a one-row move old reference vs new on the interior (4 px margin), new(x, y) == old(x, y + 1) 22 of 27 at 100.000%. Four of the other five are ≥ 99.957%; fog_ceiling_treatment_yaw9 reads 99.417%, with a largest delta of 10. Every residual pixel is within the comparator's max_delta 64 (largest 57). Each unshifted comparison reads 91.1–99.98%
Full suite fleet-run IrredenEngineTest 4132 pass; the only failures are ToolSpawnTest ×2 and FontMakerSource.SavedHeadersCompile, tracked Windows-host failures (#5180)
Reviewer notes

Plan departures

  • The plan's pinned-test list named two tests. A third also encoded the GL asymmetry: test/render/depth_tested_primitives_test.cpp GeometryUsesCameraPixelPhaseAtFractionalPan expected +0.5 on GL. It now expects -0.5 on both backends, the same rewrite as SnappedPlacementMatchesTheDisplayedRaster.
  • Explicit-sign form (the plan left it to the implementer): both helpers take a trailing screenSign parameter, defaulting to IRPlatform::kIsoToScreenSign. Existing call sites are unchanged.
  • The continuous residual's y-sense test lives in camera_subpixel_test.cpp next to the snapped one (CameraRasterScreenResidual.FractionalYResidualFloorsTopDownUnderEitherScreenSign), not in camera_zoom_policy_test.cpp.

Notes for reviewer

Closes #5190

🤖 Generated with Claude Code

The screen-pixel half of the camera sub-pixel split applied the iso-to-
screen sign inside floor(). On OpenGL (screen Y bottom-up, sign -1) that
made floor(-a) = -ceil(a), so a camera with a fractional y residual drew
the whole frame one screen row lower than Metal and the receiver-shadow
oracle put it. Both residual helpers (the snapped split and its
continuous-zoom twin) now floor top-down and sign afterwards, the same
convention as the framebuffer half. Metal's sign is +1, so it is
unchanged by construction.

Every reader (the blit, sprites, depth-tested primitives, probes, mouse
mapping) takes the residual from these helpers, so they move with the
frame. An explicit screen-sign parameter lets the new tests pin both
backends' y sense on any host. Twenty-seven windows-debug references with
a fractional-y camera are re-blessed; each is the old image moved up one
row.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@jakildev jakildev added fleet:author-claude Implementation last authored by Claude; route review to Codex fleet:authored-on-windows PR was opened from a Windows (MSYS2) host labels Nov 19, 2026
@github-actions

Copy link
Copy Markdown

Perf gate

Head host slug: linux-x86_64-epyc-7763-64-unknown

perf comparison: c03fe48 → deb11d0-ci

baseline: /home/runner/work/_temp/perf-baseline/history/linux-x86_64-epyc-7763-64-unknown/c03fe48dab87d5d300542d0e688ff4393bf7b202
head: /home/runner/work/IrredenEngine/IrredenEngine/save_files/perf/deb11d058-ci

host calibration

  • host: linux-x86_64-epyc-7763-64-unknown (matches baseline)
  • ref_ms: head 103.85 vs baseline 103.65 (load_factor 1.00×)
  • calibration target: 50.00 ms (informational)
  • baseline capture: perf-baseline@c03fe48da (branch tip); master 44955ae9f, finished 2026-11-17T21:35:04Z, 1.6 d before the head run, ref_ms 103.65
  • weighting: raw (class-matched capture; load_factor 1.00×; no calibration-scaling entry)
  • attribution: no measured master improvement between capture master 44955ae9f and merge base 00b5da049 (27 commits)

thresholds: regress ≥ 10%, improve ≥ 5%

voxel cull effectiveness

cell ratio (base→head) avg visible total avg feeder
target=IRLuaPerfGrid,zoom=1,sub_mode=full,sub_base=1 1.000 → 1.000 (+0.0pp) 262144 → 262144 1024 → 1024 0 → 0
target=IRLuaPerfGrid,zoom=4,sub_mode=full,sub_base=1 0.598 → 0.598 (+0.0pp) 156630 → 156637 1024 → 1024 0 → 0
target=IRPerfGrid,zoom=1,sub_mode=full,sub_base=1 1.000 → 1.000 (+0.0pp) 262144 → 262144 1024 → 1024 0 → 0
target=IRPerfGrid,zoom=4,sub_mode=full,sub_base=1 0.975 → 0.975 (+0.0pp) 255592 → 255592 1024 → 1024 0 → 0

frame timing (ms)

cell avg p99
target=IRLuaPerfGrid,zoom=1,sub_mode=full,sub_base=1 553.91 → 544.97 (-1.6%) 1865.43 → 1811.45 (-2.9%)
target=IRLuaPerfGrid,zoom=4,sub_mode=full,sub_base=1 1276.14 → 1251.74 (-1.9%) 2584.83 → 2571.16 (-0.5%)
target=IRPerfGrid,zoom=1,sub_mode=full,sub_base=1 738.18 → 726.47 (-1.6%) 14006.37 → 13211.25 (-5.7%) ↓
target=IRPerfGrid,zoom=4,sub_mode=full,sub_base=1 1810.79 → 1812.32 (+0.1%) 3053.63 → 3078.04 (+0.8%)

GPU frame timing (ms; separate from stage samples)

cell envelope (base→head) buffer spans (base→head) coverage (base→head)
target=IRLuaPerfGrid,zoom=1,sub_mode=full,sub_base=1 unavailable → unavailable unavailable → unavailable unavailable → unavailable
target=IRLuaPerfGrid,zoom=4,sub_mode=full,sub_base=1 unavailable → unavailable unavailable → unavailable unavailable → unavailable
target=IRPerfGrid,zoom=1,sub_mode=full,sub_base=1 unavailable → unavailable unavailable → unavailable unavailable → unavailable
target=IRPerfGrid,zoom=4,sub_mode=full,sub_base=1 unavailable → unavailable unavailable → unavailable unavailable → unavailable

GPU stage timing (avg ms per sampled invocation)

cell canvasClear voxelCompact voxelStage1 voxelCardinalElect voxelStage2 voxelSunFaces textToTrixel buildLightOcclusionGrid computeVoxelAO bakeSunShadowMap computeSunShadow computeLightVolume lightingToTrixel fogToTrixel trixelToFb resolvePerAxisScreenDepth fbToScreen
target=IRLuaPerfGrid,zoom=1,sub_mode=full,sub_base=1 22.95→22.84 65.28→66.28 56.26→56.44 0.96→0.98 55.56→55.71 95.85→95.47 — 0.00→0.00 2.88→2.80 27.62→26.87 12.77→12.17 23.67→22.92 4.00→3.94 1.29→1.31 0.17→0.18 — 8.14→8.14
target=IRLuaPerfGrid,zoom=4,sub_mode=full,sub_base=1 22.70→22.38 321.26→319.33 261.87→259.58 4.09→4.04 239.39→237.11 148.78→145.78 — 0.00→0.00 2.54→2.46 46.99→45.72 11.74→11.07 ↓ 21.25→20.24 9.22→8.80 1.87→1.48 ↓ 0.22→0.20 ↓ — 7.87→7.42 ↓
target=IRPerfGrid,zoom=1,sub_mode=full,sub_base=1 20.96→20.85 81.11→79.57 62.43→61.75 13.66→13.23 51.00→50.86 89.96→90.06 1.23→1.19 0.00→0.00 16.89→16.83 74.51→72.48 11.73→10.60 ↓ 61.24→59.68 8.38→8.35 1.91→1.87 0.19→0.19 0.00→0.00 10.03→9.66
target=IRPerfGrid,zoom=4,sub_mode=full,sub_base=1 22.06→21.78 524.35→523.00 425.10→425.58 6.58→6.36 373.96→373.21 155.83→154.96 1.19→1.20 0.00→0.00 2.57→2.57 60.19→60.67 12.40→12.77 21.50→22.00 7.21→7.42 1.79→1.49 ↓ 0.16→0.16 0.00→0.00 7.75→7.62

top CPU systems by avg ms (head)

target=IRLuaPerfGrid,zoom=1,sub_mode=full,sub_base=1

pipeline system avg ms (base→head)
RENDER SingleVoxelToCanvasFirst 298.046 → 298.924 (+0.3%)
RENDER ComputeLightVolume 35.887 → 34.591 (-3.6%)
RENDER ComputeSunShadow 19.925 → 19.315 (-3.1%)
RENDER CanvasToFramebuffer 18.227 → 17.885 (-1.9%)
RENDER BakeSunShadowMap 10.420 → 10.202 (-2.1%)
UPDATE FogRevealEval 6.578 → 6.293 (-4.3%)
UPDATE PropagateTransform 4.948 → 4.570 (-7.6%) ↓
RENDER ComputeVoxelAO 4.434 → 4.366 (-1.5%)

target=IRLuaPerfGrid,zoom=4,sub_mode=full,sub_base=1

pipeline system avg ms (base→head)
RENDER SingleVoxelToCanvasFirst 992.838 → 983.287 (-1.0%)
RENDER ComputeSunShadow 40.580 → 39.630 (-2.3%)
RENDER ComputeLightVolume 32.529 → 30.991 (-4.7%)
RENDER CanvasToFramebuffer 17.101 → 16.462 (-3.7%)
RENDER ComputeVoxelAO 11.089 → 10.800 (-2.6%)
RENDER LightingToTrixel 9.445 → 9.018 (-4.5%)
RENDER BakeSunShadowMap 8.988 → 8.757 (-2.6%)
UPDATE FogRevealEval 6.633 → 6.064 (-8.6%) ↓

target=IRPerfGrid,zoom=1,sub_mode=full,sub_base=1

pipeline system avg ms (base→head)
RENDER SingleVoxelToCanvasFirst 346.948 → 335.583 (-3.3%)
RENDER ComputeSunShadow 67.001 → 65.217 (-2.7%)
RENDER LightingToTrixel 38.626 → 38.105 (-1.3%)
RENDER ComputeLightVolume 35.479 → 33.301 (-6.1%) ↓
RENDER BakeSunShadowMap 23.074 → 22.806 (-1.2%)
RENDER CanvasToFramebuffer 18.942 → 18.784 (-0.8%)
RENDER FogToTrixel 7.359 → 7.356 (-0.0%)
UPDATE PropagateTransform 6.053 → 7.339 (+21.2%) ⚠

target=IRPerfGrid,zoom=4,sub_mode=full,sub_base=1

pipeline system avg ms (base→head)
RENDER SingleVoxelToCanvasFirst 1504.717 → 1501.892 (-0.2%)
RENDER ComputeSunShadow 53.380 → 54.088 (+1.3%)
RENDER ComputeLightVolume 33.333 → 34.295 (+2.9%)
RENDER CanvasToFramebuffer 16.508 → 16.416 (-0.6%)
RENDER BakeSunShadowMap 9.077 → 8.900 (-1.9%)
RENDER ComputeVoxelAO 8.784 → 8.799 (+0.2%)
RENDER LightingToTrixel 7.400 → 7.623 (+3.0%)
UPDATE PropagateTransform 6.169 → 6.492 (+5.2%)

@jakildev jakildev left a comment

Copy link
Copy Markdown
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Review — render: floor the camera screen residual top-down on every backend

Verdict: needs-fix

The sign-after-floor change is coherent across the snapped and continuous paths, and the reference updates match the intended one-row move, but the PR's own formatting gate is red.

Needs-fix

  • test/math/camera_subpixel_test.cpp::CameraSubPixelOffsets.MatchesTheReferenceDecomposition — the current head fails format-check; clang-format 22.1.3 rewrites the six-element cameraSamples initializer onto separate lines. Apply the CI diff (or run fleet-build --target format-changed) and push so the required validator is green.

Acceptance (issue #5190)

  • 3 of 4 criteria are established by the shipped tests and Windows/OpenGL evidence.
  • Metal runtime verification is deferred: the formula is unchanged for Metal's +1 sign and the explicit-sign tests cover it, but this review did not complete an IrredenEngineTest run on macOS.

Praise

  • Both residual helpers use the same top-down convention, and the positive-fire tests exercise both backend signs rather than trusting the review host's compile-time backend.

Checked

  • Read the complete PR and issue #5190 threads, the plan corrections, the full diff, and all changed source/test/design files in context.
  • Confirmed head 6398edc2b18256d42e376107a7440d6d4926f763; standalone base is master.
  • fleet-jobs wait --timeout 540 20261119T122614Z-build-0a38bd: succeeded, exit 0; IrredenEngineTest built on macOS/Metal.
  • Independently compared all 27 changed Windows PNG references against origin/master; every interior is an exact one-row upward translation.
  • git diff --check origin/master...HEAD: clean.
  • GitHub format-check: failed because clang-format rewrites the cameraSamples initializer; linux-build and perf-gate were still in progress when reviewed.

Test plan the author should run before merge

  • Apply clang-format 22.1.3's rewrite and confirm format-check passes on the amended head.
  • Re-run the camera residual tests on the amended head; retain the macOS smoke debt until a clean Metal run records it.

🤖 Reviewed by Codex GPT-5 (review-pr skill, opus review class)

Opus recheck not required (reviewed at opus class).

@jakildev jakildev added fleet:reviewing-mac-pool-1 fleet:needs-fix Fleet reviewer found issues — author must address and removed fleet:reviewing-mac-pool-1 labels Nov 19, 2026
@jakildev jakildev removed the fleet:needs-fix Fleet reviewer found issues — author must address label Nov 19, 2026
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@jakildev jakildev added fleet:changes-made Agent addressed human feedback — ready for human re-review and removed fleet:amending-windows-pool-1 labels Nov 19, 2026
@jakildev

Copy link
Copy Markdown
Owner Author

Addressed feedback:

  • format-check (cameraSamples initializer in test/math/camera_subpixel_test.cpp): applied clang-format 22.1.3's rewrite verbatim, one element per line (ac8e1b6). The camera residual tests re-run on the amended head on windows-debug: 59/59 pass.
  • linux-build was red on the reviewed head because apt mirrors returned 503 while it installed dependencies. That is CI infrastructure, not PR code, and the push re-runs it.
  • Metal runtime verification is still owed to the macOS smoke lane, as the review recorded.
    — worker

@github-actions

Copy link
Copy Markdown

Perf gate

Head host slug: linux-x86_64-xeon-6975p-c-03-0-vga

perf comparison: 622ec2a → 55ae438-ci

baseline: /home/runner/work/_temp/perf-baseline/history/linux-x86_64-xeon-6975p-c-03-0-vga/622ec2a4e3d8b8dffae4b249b935dcad3aee257a
head: /home/runner/work/IrredenEngine/IrredenEngine/save_files/perf/55ae4389b-ci

host calibration

  • host: linux-x86_64-xeon-6975p-c-03-0-vga (matches baseline)
  • ref_ms: head 69.96 vs baseline 69.88 (load_factor 1.00×)
  • calibration target: 50.00 ms (informational)
  • baseline capture: perf-baseline@622ec2a4e (branch tip); master 4c35a9da0, finished 2026-11-19T04:20:10Z, 0.4 d before the head run, ref_ms 69.88
  • weighting: raw (class-matched capture; load_factor 1.00×; no calibration-scaling entry)
  • attribution: no measured master improvement between capture master 4c35a9da0 and merge base 00b5da049 (5 commits)

thresholds: regress ≥ 10%, improve ≥ 5%

voxel cull effectiveness

cell ratio (base→head) avg visible total avg feeder
target=IRLuaPerfGrid,zoom=1,sub_mode=full,sub_base=1 1.000 → 1.000 (+0.0pp) 262144 → 262144 1024 → 1024 0 → 0
target=IRLuaPerfGrid,zoom=4,sub_mode=full,sub_base=1 0.598 → 0.598 (+0.0pp) 156637 → 156637 1024 → 1024 0 → 0
target=IRPerfGrid,zoom=1,sub_mode=full,sub_base=1 1.000 → 1.000 (+0.0pp) 262144 → 262144 1024 → 1024 0 → 0
target=IRPerfGrid,zoom=4,sub_mode=full,sub_base=1 0.975 → 0.975 (+0.0pp) 255592 → 255592 1024 → 1024 0 → 0

frame timing (ms)

cell avg p99
target=IRLuaPerfGrid,zoom=1,sub_mode=full,sub_base=1 443.80 → 451.78 (+1.8%) 1181.69 → 1190.36 (+0.7%)
target=IRLuaPerfGrid,zoom=4,sub_mode=full,sub_base=1 951.46 → 945.50 (-0.6%) 1722.43 → 1709.42 (-0.8%)
target=IRPerfGrid,zoom=1,sub_mode=full,sub_base=1 509.73 → 519.01 (+1.8%) 6897.09 → 6945.28 (+0.7%)
target=IRPerfGrid,zoom=4,sub_mode=full,sub_base=1 1346.20 → 1388.75 (+3.2%) 2038.19 → 2076.33 (+1.9%)

GPU frame timing (ms; separate from stage samples)

cell envelope (base→head) buffer spans (base→head) coverage (base→head)
target=IRLuaPerfGrid,zoom=1,sub_mode=full,sub_base=1 unavailable → unavailable unavailable → unavailable unavailable → unavailable
target=IRLuaPerfGrid,zoom=4,sub_mode=full,sub_base=1 unavailable → unavailable unavailable → unavailable unavailable → unavailable
target=IRPerfGrid,zoom=1,sub_mode=full,sub_base=1 unavailable → unavailable unavailable → unavailable unavailable → unavailable
target=IRPerfGrid,zoom=4,sub_mode=full,sub_base=1 unavailable → unavailable unavailable → unavailable unavailable → unavailable

GPU stage timing (avg ms per sampled invocation)

cell canvasClear voxelCompact voxelStage1 voxelCardinalElect voxelStage2 voxelSunFaces textToTrixel buildLightOcclusionGrid computeVoxelAO bakeSunShadowMap computeSunShadow computeLightVolume lightingToTrixel fogToTrixel trixelToFb resolvePerAxisScreenDepth fbToScreen
target=IRLuaPerfGrid,zoom=1,sub_mode=full,sub_base=1 16.83→16.59 48.35→48.31 41.27→41.66 0.76→0.79 41.18→41.82 70.16→69.84 — 0.00→0.00 1.47→1.48 16.91→17.11 14.27→14.16 11.96→12.12 2.68→2.88 0.96→1.02 0.16→0.17 — 6.60→6.88
target=IRLuaPerfGrid,zoom=4,sub_mode=full,sub_base=1 17.18→17.15 240.15→239.65 179.81→179.29 2.99→2.99 170.41→169.87 113.95→114.78 — 0.00→0.00 1.32→1.33 29.35→29.40 12.71→12.49 10.65→10.49 4.76→4.93 1.02→1.05 0.16→0.18 ⚠ — 6.31→6.36
target=IRPerfGrid,zoom=1,sub_mode=full,sub_base=1 15.76→15.60 56.05→56.26 44.23→44.39 6.63→6.62 37.15→37.33 65.54→65.56 1.28→1.31 0.00→0.00 4.28→4.41 40.34→40.70 13.03→12.74 29.54→29.84 4.90→5.00 1.41→1.41 0.15→0.16 0.00→0.00 7.15→7.29
target=IRPerfGrid,zoom=4,sub_mode=full,sub_base=1 16.32→16.90 389.15→399.44 290.61→299.16 4.67→4.75 267.17→274.88 126.93→129.12 1.33→1.38 0.00→0.00 1.32→1.39 38.50→38.89 13.89→14.07 11.22→11.64 4.18→4.32 1.17→1.20 0.14→0.17 ⚠ 0.00→0.00 6.09→6.43

top CPU systems by avg ms (head)

target=IRLuaPerfGrid,zoom=1,sub_mode=full,sub_base=1

pipeline system avg ms (base→head)
RENDER SingleVoxelToCanvasFirst 220.332 → 220.758 (+0.2%)
RENDER ComputeLightVolume 25.801 → 25.853 (+0.2%)
RENDER CanvasToFramebuffer 14.533 → 15.036 (+3.5%)
RENDER ComputeSunShadow 12.367 → 12.542 (+1.4%)
UPDATE FogRevealEval 8.528 → 8.812 (+3.3%)
RENDER BakeSunShadowMap 5.893 → 5.933 (+0.7%)
UPDATE PropagateTransform 3.649 → 3.619 (-0.8%)
UPDATE LuaWaveStateToOffset 2.998 → 3.413 (+13.8%) ⚠

target=IRLuaPerfGrid,zoom=4,sub_mode=full,sub_base=1

pipeline system avg ms (base→head)
RENDER SingleVoxelToCanvasFirst 722.030 → 721.137 (-0.1%)
RENDER ComputeSunShadow 25.501 → 25.441 (-0.2%)
RENDER ComputeLightVolume 23.044 → 22.605 (-1.9%)
RENDER CanvasToFramebuffer 13.772 → 13.568 (-1.5%)
UPDATE FogRevealEval 7.590 → 7.074 (-6.8%) ↓
RENDER ComputeVoxelAO 6.878 → 6.923 (+0.7%)
RENDER BakeSunShadowMap 5.167 → 5.383 (+4.2%)
RENDER LightingToTrixel 4.889 → 5.066 (+3.6%)

target=IRPerfGrid,zoom=1,sub_mode=full,sub_base=1

pipeline system avg ms (base→head)
RENDER SingleVoxelToCanvasFirst 236.216 → 236.450 (+0.1%)
RENDER ComputeSunShadow 35.942 → 36.125 (+0.5%)
RENDER ComputeLightVolume 24.511 → 23.914 (-2.4%)
RENDER LightingToTrixel 18.975 → 19.625 (+3.4%)
RENDER CanvasToFramebuffer 14.572 → 14.725 (+1.0%)
RENDER BakeSunShadowMap 8.014 → 8.288 (+3.4%)
UPDATE FogRevealEval 7.175 → 7.342 (+2.3%)
UPDATE PropagateTransform 4.643 → 4.786 (+3.1%)

target=IRPerfGrid,zoom=4,sub_mode=full,sub_base=1

pipeline system avg ms (base→head)
RENDER SingleVoxelToCanvasFirst 1093.643 → 1123.250 (+2.7%)
RENDER ComputeSunShadow 34.490 → 34.709 (+0.6%)
RENDER ComputeLightVolume 24.729 → 25.381 (+2.6%)
RENDER CanvasToFramebuffer 13.456 → 13.847 (+2.9%)
UPDATE FogRevealEval 7.599 → 7.558 (-0.5%)
RENDER ComputeVoxelAO 5.789 → 5.912 (+2.1%)
RENDER BakeSunShadowMap 5.163 → 5.396 (+4.5%)
UPDATE PropagateTransform 4.736 → 4.852 (+2.4%)

@jakildev jakildev left a comment

Copy link
Copy Markdown
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Review — render: floor the camera screen residual top-down on every backend

Prior-review resolution

  • ✅ test/math/camera_subpixel_test.cpp::CameraSubPixelOffsets.MatchesTheReferenceDecomposition — the requested clang-format 22.1.3 initializer layout is present at ac8e1b692, and the live format-check is green.

Verdict: approve

The only post-review change is the requested formatting fix; it resolves the prior finding without changing executable behavior, and all current required checks are green.

Acceptance (issue #5190)

  • 3 of 4 criteria are established by the shipped tests and Windows/OpenGL evidence.
  • Criterion 3's Metal runtime clause remains unverifiable on the author host; the sign-after-floor change is algebraically unchanged for Metal's +1 sign and explicitly tested, while the macOS smoke lane retains the runtime verification debt.

Checked

  • Confirmed exact head ac8e1b692db4b90d11a9a35d487b5cacab15b23f on standalone base master.
  • Compared the amend against the previously reviewed head: one test initializer was reformatted; no executable code, render references, or other files changed.
  • git diff --check origin/master...HEAD: clean.
  • Live GitHub checks are green, including format-check, linux-build, perf-gate, and the aggregate all-checks status.
  • Re-read the complete PR and issue #5190 threads, the prior review, worker response, amended diff, and applicable math/test/demo rules. No local executable was run for this delta-only re-review.

Test plan the author should run before merge

  • Re-run the focused camera residual tests on the amended head (author reports 59/59 pass).
  • Record the deferred Metal runtime result through the macOS smoke lane.

🤖 Reviewed by Codex GPT-5 (review-pr skill, opus review class)

Opus recheck not required (reviewed at opus class).

@jakildev jakildev added fleet:approved Fleet reviewer approved — ready for human merge and removed fleet:changes-made Agent addressed human feedback — ready for human re-review fleet:reviewing-mac-pool-1 labels Nov 19, 2026
@jakildev
jakildev merged commit 6afc513 into master Nov 19, 2026
16 checks passed
jakildev added a commit that referenced this pull request Nov 20, 2026
Re-runs the subpos/subneg receiver-shadow polygon matrix on
Windows/OpenGL at master 1bff5ea, which carries PR #5201's fix for
the one-row camera residual offset. All 26 captures are RESULT=CLEAN.
Every graded row's count dictionary equals Metal's: 0/0/0 with the
opt-in on, and the fallback arms reproduce 18/638/0. With the earlier
origin and near/mid passes, the polygon criterion holds at all 18
placements.

Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

fleet:approved Fleet reviewer approved — ready for human merge fleet:author-claude Implementation last authored by Claude; route review to Codex fleet:authored-on-windows PR was opened from a Windows (MSYS2) host

Projects

None yet

Development

Successfully merging this pull request may close these issues.

render/opengl: a fractional-y camera screen residual places the frame one row low (ceil, not floor)

1 participant