SOA graphic assets

Get your graphics formats figures out here! Got details for others? Post here!
Post Reply
Sorans
n00b
Posts: 16
Joined: Thu Mar 25, 2010 8:53 pm
Has thanked: 13 times
Been thanked: 3 times

SOA graphic assets

Post by Sorans » Mon Jul 16, 2018 12:21 am

Hello there,

I'm trying to figure out how to read the image encoding used for Star Ocean Anamnesis graphic assets. I found out that it's a variant of ETC2 RGBA but I can't seem to display it properly with PVRTexTool.

Could I get some input on how to improve the rendering or how to determine the exact compression used? Thanks in advance!

A small sample is included in this post.
You do not have the required permissions to view the files attached to this post.
Last edited by Sorans on Mon Jul 23, 2018 2:16 pm, edited 1 time in total.

User avatar
Acewell
VIP member
VIP member
Posts: 1184
Joined: Wed Nov 05, 2008 12:16 pm
Has thanked: 2330 times
Been thanked: 686 times

Re: SOA graphic assets

Post by Acewell » Sun Jul 22, 2018 8:52 am

it is difficult to get accurate results from only one sample. what did your results look like?
i am not familiar with the graphics of this game, does this look correct to you? :]
sample1.png
i entered 512 wide by 1024 tall with ETC2 rgba and header size 768 bytes in PVRTextool to get that.
i scaled it down by 50 percent so it will fit in the attachment,
it looks like some shuffling or something is needed to me to remove the scanlines. (:
You do not have the required permissions to view the files attached to this post.

Sorans
n00b
Posts: 16
Joined: Thu Mar 25, 2010 8:53 pm
Has thanked: 13 times
Been thanked: 3 times

Re: SOA graphic assets

Post by Sorans » Sun Jul 22, 2018 9:25 am

Hello Ace,

Thanks for offering your help again :)
And yes, it does look good. That's the result I was able to get but I'm unable to remove the scanlines. I'm able to get all images after figuring out their size, but the scanlines are present in all of them.

How would one go about removing them?

I've included one more samples in case it can be of help to you.
You do not have the required permissions to view the files attached to this post.

akderebur
ultra-veteran
ultra-veteran
Posts: 322
Joined: Fri Jul 08, 2011 10:36 am
Has thanked: 44 times
Been thanked: 289 times

Re: SOA graphic assets

Post by akderebur » Mon Jul 23, 2018 12:09 pm

Those scanline artifacts seem to be because of the decryption. I think the bms script for the slz files isn't perfect yet.

You need to xor every 5th byte of 8 byte iterations, with 0x20. I mean like read 4 bytes, xor the 5th with 0x20, and read 3 bytes. It seems to produce the correct result.
soa_test.png
Edit :
@Sorans Can you post or pm me the unpacked version of the first image too? I mean the file before running the bms script on it.
You do not have the required permissions to view the files attached to this post.

Sorans
n00b
Posts: 16
Joined: Thu Mar 25, 2010 8:53 pm
Has thanked: 13 times
Been thanked: 3 times

Re: SOA graphic assets

Post by Sorans » Mon Jul 23, 2018 2:15 pm

Hello akderebur, thanks for your help!

Here's the original file you requested (for the image above)

You're also right about the SLZ script, it's not 100% finished and also cannot read some ADLD types according to what aluigi told me. I will replace the sample in my first post with the unreadable type.

EDIT: Would it be viable to edit the SLZ script to do what you said above, instead of XORing the file afterwards? (I'm not very familiar with the syntax yet)
You do not have the required permissions to view the files attached to this post.

akderebur
ultra-veteran
ultra-veteran
Posts: 322
Joined: Fri Jul 08, 2011 10:36 am
Has thanked: 44 times
Been thanked: 289 times

Re: SOA graphic assets

Post by akderebur » Mon Jul 23, 2018 3:44 pm

Sorans wrote: EDIT: Would it be viable to edit the SLZ script to do what you said above, instead of XORing the file afterwards? (I'm not very familiar with the syntax yet)
I am not very familiar with bms myself, but the attached script should do the trick. It xors the file before saving.
You do not have the required permissions to view the files attached to this post.

Sorans
n00b
Posts: 16
Joined: Thu Mar 25, 2010 8:53 pm
Has thanked: 13 times
Been thanked: 3 times

Re: SOA graphic assets

Post by Sorans » Mon Jul 23, 2018 3:50 pm

Thanks for your help!

Now that the old SLZ format can be decrypted correctly, I'll try looking into how to unpack the unknown type I mentioned above.

akderebur
ultra-veteran
ultra-veteran
Posts: 322
Joined: Fri Jul 08, 2011 10:36 am
Has thanked: 44 times
Been thanked: 289 times

Re: SOA graphic assets

Post by akderebur » Wed Jul 25, 2018 3:51 pm

Sorans wrote: Now that the old SLZ format can be decrypted correctly, I'll try looking into how to unpack the unknown type I mentioned above.
I am not sure if it will help at all with unpacking. The part I added xors the file after unpacking, so you still need to figure out the compression first.

Also I have noticed that Tri-Ace is changing more of the slz archives to type 7. Some model files that weren't type 7 before are now type 7. Mostly the character models. I hope someone can figure this out.

akderebur
ultra-veteran
ultra-veteran
Posts: 322
Joined: Fri Jul 08, 2011 10:36 am
Has thanked: 44 times
Been thanked: 289 times

Re: SOA graphic assets

Post by akderebur » Sat Aug 11, 2018 8:22 pm

Btw type 7 can be unpacked now. I have mostly used it for models, but might be useful for some texture files too. Check out this thread : http://zenhax.com/viewtopic.php?f=9&t=7149

Sorans
n00b
Posts: 16
Joined: Thu Mar 25, 2010 8:53 pm
Has thanked: 13 times
Been thanked: 3 times

Re: SOA graphic assets

Post by Sorans » Sat Aug 11, 2018 8:25 pm

That's going to be very useful. Thanks for relaying the info here :)

User avatar
chrrox
Moderator
Posts: 2512
Joined: Sun May 18, 2008 3:01 pm
Has thanked: 57 times
Been thanked: 1244 times

Re: SOA graphic assets

Post by chrrox » Sun Aug 12, 2018 7:28 pm

Image Type 0x2F - ETC2-RGB
Image Type 0x31 - ETC2-RGBA
Image Type 0x32 - EAC-RG11

Sorans
n00b
Posts: 16
Joined: Thu Mar 25, 2010 8:53 pm
Has thanked: 13 times
Been thanked: 3 times

Re: SOA graphic assets

Post by Sorans » Sun Aug 12, 2018 8:50 pm

That's in line with what I've found.

The only remaining thorn is that some of the encrypted files use different keys (different than even the one you helped me with on the other forum)
I've been trying to tweak the xor script to support those types too, without much success. (I've updated my post on the other forum)

Post Reply