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

Decreased SolidBrush creation/destruction #4

Merged
merged 1 commit into from
Dec 4, 2018
Merged

Decreased SolidBrush creation/destruction #4

merged 1 commit into from
Dec 4, 2018

Conversation

BarryNolte
Copy link
Contributor

Built cache for SolidBrush creation, saves about 3-4% on render. This will have to be modified for large palettes (start destroying least used brushes), but this should be good for the 95% case.

Built cache for SolidBrush creation, saves about 3-4% on render.  This will have to be modified for large palettes (start destroying least used brushes), but this should be good for the 95% case.
@BarryNolte
Copy link
Contributor Author

The real win to be had here, I'm sure you've figured out, is the RenderOpen dispose in SetCellCharacter. That was too much surgery for me ;) and I see you're working on it already.

@doubleyewdee
Copy link
Owner

Oh nice! Yeah this is excellent. We probably want some sort of eviction policy/LRU so we don't overdo caching. Spot on with the changes to improve rendering (I'm slowly getting there) but even then caching these will be a big win. The render cost is still way higher than I'd like it to be so even ~5% incremental improvements here are huge.

I'm going to try and get my Big Render Change branch into a functional state and then take this PR or a modified varinat.

@doubleyewdee doubleyewdee merged commit c3cec4a into doubleyewdee:master Dec 4, 2018
@doubleyewdee
Copy link
Owner

Going to grab this and then implement the LRU stuff over top quickly.

@BarryNolte
Copy link
Contributor Author

BarryNolte commented Dec 5, 2018 via email

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