Fix display window, HBLANK timing, sprite visibility and STRLONG#7
Open
thbreidenbach wants to merge 1 commit intoendofexclusive:masterfrom
Open
Fix display window, HBLANK timing, sprite visibility and STRLONG#7thbreidenbach wants to merge 1 commit intoendofexclusive:masterfrom
thbreidenbach wants to merge 1 commit intoendofexclusive:masterfrom
Conversation
Correct multiple display issues by comparing against the amiga_replacement_project Denise implementation: - Fix HBLANK start/stop constants (was 3/85, now $013/$061) to match real Denise/Minimig timing. Fixes display shifted left with right side cut off. - Add STRLONG (long-line) support for interlaced modes. The beam counter now holds for one extra CLK7 cycle when STRLONG is received. - Improve display window (DIW) pipeline: add vertical window tracking (vwin, set by BPL1DAT writes, cleared at HPOS $13), multi-stage horizontal window (hwin0/hwin1/hwin2) for proper pipeline alignment. - Reset HPOS to 2 at line start (was $1FE), matching real Denise. - Mask bitplane pixels to zero outside DIW directly in stage E bplbus generation, separately for lores and hires modes. - Allow sprites to display outside the display window (border region). Real Amiga Denise draws sprites independently of DIW — the mouse pointer, status bar sprites and demo effects rely on this. The previous code killed all sprites outside DIW. - In stage G priority output, only blank playfield colors (bit 4 = 0) outside DIW; preserve sprite colors (bit 4 = 1, registers 16-31). Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Background
Analysis was performed by comparing this implementation against the amiga_replacement_project Verilog Denise implementation, which correctly handles all of the above cases. The key architectural insight is that in real Denise hardware, the display window only gates bitplane output — sprites operate on an independent path and must remain visible in border/overscan areas.
Test plan
🤖 Generated with Claude Code