X Tutup
Skip to content

GRAPHICS: Add palette constructor for ownership of data#6525

Merged
sev- merged 1 commit intoscummvm:masterfrom
OMGPizzaGuy:palette-dispose
Apr 27, 2025
Merged

GRAPHICS: Add palette constructor for ownership of data#6525
sev- merged 1 commit intoscummvm:masterfrom
OMGPizzaGuy:palette-dispose

Conversation

@OMGPizzaGuy
Copy link
Member

@OMGPizzaGuy OMGPizzaGuy commented Mar 31, 2025

One roadblock to expanded use of the palette class is my desire to not make extra memory copies the static palette data used in a number of classes. This new constructor with the use of DisposeAfterUse::NO and a const qualifier could be an answer to that problem.

Does this seem like a good path forward or are there alternate ideas?
Is this a silly concern and a small memory copy not a big enough deal to warrant a change?

@dreammaster
Copy link
Member

Just noticed the PR. It Looks good to me. I'm going to merge it in now

@dreammaster
Copy link
Member

Oh, it's still marked as a draft. Well, I have no objection to it being merged once you're ready for it

@sev-
Copy link
Member

sev- commented Apr 27, 2025

Yes, it is a step in the right direction. And we need to further fix/cleanup video code for using the Palette class. Merging this

@sev- sev- marked this pull request as ready for review April 27, 2025 12:31
@sev- sev- merged commit 40f6710 into scummvm:master Apr 27, 2025
8 checks passed
@OMGPizzaGuy OMGPizzaGuy deleted the palette-dispose branch July 1, 2025 01:42
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.

3 participants

X Tutup