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

Textures: Hardcode resolutions and formats + generate wxHexEditor tagfile #16

Closed
wants to merge 1 commit into from

Conversation

JayFoxRox
Copy link
Member

@JayFoxRox JayFoxRox commented May 3, 2018

I've added a lot of experimental code, most of which is broken.

This adds a tag exporter for wxHexEditor so we can see where / how information could be stored.
However, to me, it appears as the texture information (resolution / format / filters) must be stored elsewhere. So likely in the modelblock or the games binary. Mostly in modelblock. See #17

I've also started to hardcoded texture information so the textures can actually be exported. Ideally someone will translate this into a dict, including the text-comments about the texture contents.
See comment below.

Many of these textures don't export correctly because the purpose of the "b" section is still unknown.
It appears that these textures use some palette, but I was unable to locate it / figure out how to use it.

The b section is the palette. But my code was buggy as b referred to the palette section offset, but also the blue color channel. So the code was/is producing garbage results.

b_size = c - b
print("Section-b: %d bytes" % (b_size))
assert((b_size == 32) or (b_size == 512))
#FIXME: Fix this codepath
Copy link
Member Author

Choose a reason for hiding this comment

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

Comment should be removed


if b == 0:
if length == 128:
if length == 32:
Copy link
Member Author

Choose a reason for hiding this comment

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

There should be a comment which states that this is trying to guess texture resolution / format

@JayFoxRox
Copy link
Member Author

I've moved the texture names to https://github.com/OpenSWE1R/openswe1r/wiki/List-of-Textures
I did not move the other information as we can collect it from the modelblock using #17 .

@JayFoxRox
Copy link
Member Author

Closing PR. wxHexEditor changes will be migrated another time.

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.

1 participant