Skip to content

Commit 295aead

Browse files
bpeelavivaceISSOtm
authored
scrolling: Add note about disabling/re-enabling the window mid-frame (#584)
Adds a note explaining how the tile map is used if the window is disabled and then re-enabled for a portion of the frame. --------- Co-authored-by: Antonio Vivace <[email protected]> Co-authored-by: Eldred Habert <[email protected]>
1 parent 0afe916 commit 295aead

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

src/Scrolling.md

+3
Original file line numberDiff line numberDiff line change
@@ -62,3 +62,6 @@ For the window to be displayed on a scanline, the following conditions must be m
6262

6363
If the WY condition has already been triggered and at the start of a row the window enable bit was set,
6464
then resetting that bit before the WX condition gets triggered on that row yields a nice window glitch pixel where the window would have been activated.
65+
66+
The way the Window selects which line of its tilemap to render may be surprising: the Y position is selected by an internal counter, which is reset to 0 during VBlank and **only** incremented when the Window starts being rendered on a given scanline.
67+
In particular, this means that hiding the Window mid-frame in any way (via either `WX` or `LCDC`, usually to display a status bar at the top *and* bottom of the screen) will also inhibit incrementing that Y-position counter.

0 commit comments

Comments
 (0)