Skip to content

Add option to include complete CI format details in texture filenames - #719

Open
LucretiaArc wants to merge 5 commits into
Fast-64:mainfrom
LucretiaArc:ci-texture-filename
Open

Add option to include complete CI format details in texture filenames#719
LucretiaArc wants to merge 5 commits into
Fast-64:mainfrom
LucretiaArc:ci-texture-filename

Conversation

@LucretiaArc

Copy link
Copy Markdown
Contributor

Texel format information is missing from the filenames of exported CI textures when using the "Save Textures As PNGs" option, which is a problem when converting those textures. Some toolchains could work around this by assuming the texel format (like OoT does), but to allow projects to fully support exports with PNG CI textures, the texel format should be included in the filename.

I haven't verified the adjustments in z64/model_classes.py via export, but the result should be the same when the new option is disabled, and the toolchains for those projects would need to be modified to accept exports with the option enabled.

@Dragorn421 Dragorn421 left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the PR :)

So based on getTextureSuffixFromFormat your proposal is (when the option is checked in fast64 settings) replace .ci[48].png with .ci[48]-{rgba16,ia16}.png
I think that's a good idea and it looks easy to implement in oot at least
I think it'd be better to use an underscore _ as separator for consistency with oot's separators in texture file extension information (eg shared tluts are indicated with a .tlut_theTlutName. suffix) but lmk why you chose - if you have a reason

I'll raise the topic of this suffix idea in the n64brew discord since that may be used there too, may as well discuss it https://discord.com/channels/205520502922543113/974342113850445874/1533042856388853830

Out of curiosity what are you needing IA palettes for? I find them pretty much useless

Comment thread __init__.py Outdated
@Dragorn421 Dragorn421 added enhancement New feature or request f3d Has to do with the "f3d" code common to all games labels Aug 1, 2026
@LucretiaArc

Copy link
Copy Markdown
Contributor Author

So based on getTextureSuffixFromFormat your proposal is (when the option is checked in fast64 settings) replace .ci[48].png with .ci[48]-{rgba16,ia16}.png
I think that's a good idea and it looks easy to implement in oot at least
I think it'd be better to use an underscore _ as separator for consistency with oot's separators in texture file extension information (eg shared tluts are indicated with a .tlut_theTlutName. suffix) but lmk why you chose - if you have a reason
I'll raise the topic of this suffix idea in the n64brew discord since that may be used there too, may as well discuss it https://discord.com/channels/205520502922543113/974342113850445874/1533042856388853830

I chose a hyphen mostly just as a sensible default, but if OoT already has an established separator for similar information then I'm happy to go with an underscore, pending any feedback from the N64brew discussion.

Out of curiosity what are you needing IA palettes for? I find them pretty much useless

I don't have anything specific in mind, I'm more interested in making sure that the format is available for people who want to use it than actually using it in this case. I'm working on HackerSM64's support for CI texture image conversion, and it would be nice to build that in a way that supports IA palettes in case anyone wants to use them.

Comment thread fast64_internal/utility.py Outdated
@Dragorn421

Copy link
Copy Markdown
Contributor

If you want you can take a look at the document describing how oot handles pngs, in particular how it handles CI formats (which oot does use, contrarily to sm64 which afaik does not use any) https://github.com/zeldaret/oot/blob/main/docs/assets/images.md

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request f3d Has to do with the "f3d" code common to all games

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants