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
Consider changing sf::Texture::invalidateMipmap()
from private to public
#2919
Comments
Can you elaborate what "texture appearance" means?
So is this about fully disabling the mipmaps or just invalidating the generate ones (those are two different features)? |
I mean the effect that generating mipmaps has on what is drawn on the screen.
To be honest, I'm not sure I understand the difference here. |
You said, you're making an image view application. I assume you're display the image at a lower resolution than the texture has? One thing that's unclear to me is, why do you generate mipmaps in the first place if it creates an undesired effect?
Okay, yeah it's a subtle difference, but you just want to disable it and not having regenerated or similar (i.e. invalidation doesn't necessarily imply disabling). |
Yes, it's an interactive image viewer, so zooming in and out is core functionality.
Whether or not mipmaps have an undesired effect depends on at least image content, zoom level, and user preference, so I've provided an on-off toggle key to match this. I understand this might be too niche a use case to justify any changes in sfml. |
Prerequisite Checklist
Describe your feature request here
Hello.
I'd like to suggest making
sf::Texture::invalidateMipmap()
public, if possible, as it is currently private for no apparent reason, other than lack of a use case.There is some earlier discussion about this here; to quote:
The problem with this reasoning is that even if the texture data does not change, the texture appearance does change between having mipmaps generated and not having them.
Currently, there is only a way to enable them, while disabling requires reloading the texture, which is less than optimal.
My use case for sfml is image viewing, so even slight changes in the perceived appearance are quite important.
Best regards.
Use Cases
API Example
No response
The text was updated successfully, but these errors were encountered: