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

Try to preserve mipmapping as much as possible. #2650

Open
djmrFunnyMan opened this issue Aug 9, 2024 · 2 comments
Open

Try to preserve mipmapping as much as possible. #2650

djmrFunnyMan opened this issue Aug 9, 2024 · 2 comments
Labels
S-needs-triage Status: Needs triage T-enhancement Type: Enhancement

Comments

@djmrFunnyMan
Copy link

Request Description

I assume this would complicate the mipmapping code greatly but I think it'd be worth it since it'll greatly improve the visuals for end users and shield them from the errors of mod and texturepack devs.

I have some ideas on how this could be done. If they're bad ignore them (I have no idea what I'm talking about) but don't discard the feature request because of them, I'll just edit them out and leave only the short description.

  1. If there's a low power of 2 texture, make duplicate mipmaps for it instead of lowering the mip levels. So for example, if there's an 4x4 texture, instead of lowering all mipmaps to 2x just have it use the same resolution for levels 0,1,2 and then generate mips normally for 3 and 4

So it'd look like this, for 8x8, 4x4 and 2x2 textures (and16x16 for reference)

  • level 0 8x8, 4x4, 2x2 (16x16)
  • level 1 8x8, 4x4, 2x2 (8x8)
  • level 2 4x4, 4x4, 2x2 (4x4)
  • level 3 2x2, 2x2, 2x2 (2x2)
  • level 4 1x1, 1x1, 1x1 (1x1)
  1. For NPOT textures idk. Maybe force them into a separate "npot atlas" so while they won't have mipmapping they won't break it globally.
@djmrFunnyMan djmrFunnyMan added S-needs-triage Status: Needs triage T-enhancement Type: Enhancement labels Aug 9, 2024
@Permdog99
Copy link

As the creator of Legacy Mipmaps, I've had to study how Java and other versions of MC create their mipmapping. In reality, it is better to add more mipmapping levels for higher resolution textures rather than trying to add more atlases specifically for a singular texture that is smaller than the rest (or even bigger).

Every sprite is on an atlas and is mipmapped before being put on that atlas (iirc). If you try to make a singular sprite use a different mipmapping level than other sprites, then that sprite would be significantly bigger on the atlas than all others. trying to get this to work would require severely altering how mipmapping and atlases are made which would break a lot of things.

It's a cool suggestion, but it doesn't have much of a benefit for performance and could do more harm than good

@Felix14-v2
Copy link

Better Mipmaps can offer texture upscaling and support for high resolution textures (up to 1024x).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
S-needs-triage Status: Needs triage T-enhancement Type: Enhancement
Projects
None yet
Development

No branches or pull requests

3 participants