Repository navigation
Conversation
At wide aspects the menu backdrops are mirrored into the window's flanks (DrawBackdrop). Entering or leaving the Character page slides its backdrop (chr_bg) to the left with the main frame (bg16) right beside it. The menu draws the page after the frame, and while the page slid its mirror kept filling the right flank over the frame's own artwork. For the whole slide the right side showed a mirrored piece of the Character backdrop, cut off from the main frame at the 4:3 edge (TheMoonPeople#56). A page that has slid away from a flank now leaves that flank to the main frame's artwork when that artwork, drawn earlier in the frame, fills it. Settled pages, and the Make, ???, Options and Help slides, draw as before. MglibAspect.CharacterSlideLeavesTheRightFlankToTheMainFrame draws both backdrops where they are 14 frames into the exit: the right flank showed the page (red 160) and now shows the frame (red 80). Settled, it still shows the page's mirror.
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
At wide aspects, entering or leaving the Character page shows a hard vertical seam at the right edge of the 4:3 area. For the whole slide, the strip right of it shows a mirrored piece of the Character backdrop instead of the main menu's frame. This is the "weird artifact on the right side" reported in #56.
Part of #56. Its floor-map report was fixed by bd0bef8 (#88).
Cause
DrawBackdrop(port/src/menudraw_primquad.cpp) drawsbg16(the main frame) and the page backdrops (chr_bg,inv_bg,op_bg) with reflections into the window's sides.MENU_MAIN_FRAME_LEAVE_RIGHT/RETURN_RIGHTmovebg16, andchr_bgmoves with it: the page's right edge is the frame's left edge.bg16spans logical x 283–983 andchr_bg−229–283. The window shows −85.3 to 597.3 at 16:9.chr_bghas left the right edge, so it reflects into the right flank (512 to 597.3) about its own edge at 283. That coversbg16's artwork, which really is there. The seam sits at 512, where the reflection starts.Change
DrawBackdrop(port/src/menudraw_primquad.cpp) records the spanbg16's artwork covers in the current frame (mgPortFrameCount).bg16does not cover the page's height.MglibAspect.CharacterSlideLeavesTheRightFlankToTheMainFrame(port/src/tests/mglib_aspect_test.cpp) drawsbg16and thenchr_bgin one frame, at the exit's frame-14 positions and settled.Testing
Environment: macOS 26.6.2 arm64 (M4 Pro), Homebrew LLVM 23.1.5, MoltenVK 1.4.2, presets
macos-arm64(Debug) andmacos-arm64-release. PAL data (data_version20) for the replays.Replay (Release, 1280x720):
--jump town:10 --fast-loadwith Triangle at 400, Down at 470, Cross at 520 (Character) and Circle at 700 (back). Seam measure: the share of rows whose luminance step between x 1119 and 1120 is over 25 above the mean step of the columns around it.--jump event:26010, same input), exit frames 714 / 722MglibAspect.*, DebugMenuReplay.*with data (8 replays), Debug"Without change" for the replays used a Release build of the parent commit (bcd1967).
Not covered