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
Refactor GUI rendering (based on JGRPP) #8256
Closed
techgeeknz
wants to merge
22
commits into
OpenTTD:master
from
techgeeknz:jgr_master_gui_dirty_refactor
Closed
Refactor GUI rendering (based on JGRPP) #8256
techgeeknz
wants to merge
22
commits into
OpenTTD:master
from
techgeeknz:jgr_master_gui_dirty_refactor
Conversation
This file contains 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
This will need fixups, because the commit checker won't let me indent a nested #define.
Hash mark must go in first column, as per https://wiki.openttd.org/Coding_style#Other_important_rules
Since they are only ever called with an int and a (int)uint; the templating seems completely unnecessary and redundant.
This reverts commit 8652a4d. This is necessary to aid in the cherry-picking of commits from JGRPP.
…g window list. This is to speed up marking all viewports dirty, which is done very frequently.
…acked for later redrawing Track dirty viewport areas seperately form general screen redraws. Maintain a dirty block grid per viewport, with a smaller block size. Use even smaller block size in viewport map mode. Use a rectangle array for general screen redraws instead of a block grid. Add a dirty bit to windows and widgets, to simplify the common case of repainting a whole window or widget, without catching neighbouring windows or viewports.
AddDirtyBlocks is an internal implementation detail of SetDirtyBlocks, and its name should reflect that.
The viewport cache is transparently managed by the ViewportData struct, and memory associated with the viewport and cache is automatically managed using smart pointers.
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.
This is split off from #8217; part 2 of 3.
This should use #8255 as a base.