Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix display bitmap flushing on modification when using SDL display subsystem #519

Merged
merged 2 commits into from
Dec 15, 2024

Conversation

nbriggs
Copy link
Collaborator

@nbriggs nbriggs commented Dec 14, 2024

Fixes issue Interlisp/medley#1908

In cases where the target of a PILOTBITBLT opcode, or the target of an FBITMAPBIT opcode, is the display bitmap, the SDL display subsystem needs to be notified of the "damage" so that the real display can be updated.

Slightly Improves performance for FBITMAPBIT in case where there is no soft cursor that would need to be taken down before accessing the screen bitmap.

When the target for a PILOTBITBLT operation is the display bitmap,
and the display bitmap is not memory-mapped from the actual display,
the display subsystem needs to be notified to flush the Lisp display
bitmap to the display so that changes are immediately visible.
The mechanism was present for X11 displays but needed to be implemented
for SDL displays.
Two problems fixed:
  * only in the case of a software cursor is it necessary to check if
  the bit being altered is within the region of the display covered by
  the cursor, and if it is, the cursor must be hidden before operating
  on the screen bitmap
  * SDL as well as X requires modifications to the screen bitmap be
  flushed to the actual display.
@hjellinek
Copy link

I just pulled the branch, built maiko SDL, and resumed the virtual memory image I had used to create the test case. Now CIRCLE-BUG displays the circles immediately. I then built maiko for X and tested that way with identical results.

Nice! Thanks for the quick fix, @nbriggs.

@abhikhasnain1, once this is merged you should get a new Maiko and run with that. Let us know if you need help with that.

@nbriggs
Copy link
Collaborator Author

nbriggs commented Dec 15, 2024

@hjellinek do you want to "officially" review/approve before I merge it, or should I just take the comment above as approval.

Copy link

@hjellinek hjellinek left a comment

Choose a reason for hiding this comment

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

J'approuve. It fixes the reported problem.

@nbriggs nbriggs merged commit b13a35e into master Dec 15, 2024
@nbriggs nbriggs deleted the nhb-fix-sdl-display-bitmap-flushing branch December 15, 2024 17:25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants