Commit 1ea4365
CustomPixelShaderEffect: honor queried output sub-rect
Previous impl always returned m_lastOutputRect (the FULL output rect)
from MapOutputRectToInputRects regardless of which sub-rect D2D asked
for. That was the safe-with-TRIVIAL_SAMPLING fix from the Split atlas
debugging, but it also blocks D2Ds lazy-evaluation propagation: a
downstream consumer requesting only a sub-rect of our output cant
cascade that demand upstream because we keep reporting full-rect input
demand at every CustomPixelShaderEffect node in the chain.
Pass the queried output sub-rect through as the input demand. With
TRIVIAL_SAMPLING, our shaders read input pixel (x,y) for output pixel
(x,y) -- so the input rect needed is exactly the output rect being
requested.
Effects that need full output dimensions for math (Split Comparisons
center-of-image pivot, etc.) read them from host-injected OutputW/
OutputH cbuffer fields, not from the per-dispatch rect, so this change
is transparent to them. Verified Split pivot still lands at y=1080 of
2160 on the multi-branch reproducer that originally surfaced the bug.
Foundation step for upcoming preview-resolution scaling and per-input-
rect routing optimizations. 154/154 tests pass.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>1 parent c88e778 commit 1ea4365
1 file changed
Lines changed: 19 additions & 4 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
256 | 256 | | |
257 | 257 | | |
258 | 258 | | |
259 | | - | |
260 | | - | |
261 | | - | |
| 259 | + | |
| 260 | + | |
| 261 | + | |
| 262 | + | |
| 263 | + | |
| 264 | + | |
| 265 | + | |
| 266 | + | |
| 267 | + | |
| 268 | + | |
| 269 | + | |
| 270 | + | |
| 271 | + | |
| 272 | + | |
| 273 | + | |
| 274 | + | |
| 275 | + | |
| 276 | + | |
262 | 277 | | |
263 | 278 | | |
264 | | - | |
| 279 | + | |
265 | 280 | | |
266 | 281 | | |
267 | 282 | | |
| |||
0 commit comments