XeNTaX Forum Index
Forum MultiEx Commander Tools Tools Home
It is currently Mon Dec 10, 2018 7:56 am

All times are UTC + 1 hour


Forum rules


Please click here to view the forum rules



Post new topic Reply to topic  [ 12 posts ] 
Author Message
 Post subject: SOA graphic assets
PostPosted: Mon Jul 16, 2018 12:21 am 
Offline
n00b

Joined: Thu Mar 25, 2010 8:53 pm
Posts: 16
Has thanked: 13 times
Have thanks: 3 times
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.


Attachments:


You do not have the required permissions to view the files attached to this post. Register to gain access.



Last edited by Sorans on Mon Jul 23, 2018 2:16 pm, edited 1 time in total.

Top
 Profile  
 
 Post subject: Re: SOA graphic assets
PostPosted: Sun Jul 22, 2018 8:52 am 
Offline
VIP member
VIP member
User avatar

Joined: Wed Nov 05, 2008 12:16 pm
Posts: 1117
Has thanked: 2257 times
Have thanks: 637 times
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? :]

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. (:


Attachments:


You do not have the required permissions to view the files attached to this post. Register to gain access.


_________________
Noesis
Hex2obj
QuickBMS
Asset Studio
TextureFinder


Top
 Profile  
 
 Post subject: Re: SOA graphic assets
PostPosted: Sun Jul 22, 2018 9:25 am 
Offline
n00b

Joined: Thu Mar 25, 2010 8:53 pm
Posts: 16
Has thanked: 13 times
Have thanks: 3 times
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.


Attachments:


You do not have the required permissions to view the files attached to this post. Register to gain access.



Top
 Profile  
 
 Post subject: Re: SOA graphic assets
PostPosted: Mon Jul 23, 2018 12:09 pm 
Offline
mega-veteran
mega-veteran

Joined: Fri Jul 08, 2011 10:36 am
Posts: 276
Has thanked: 42 times
Have thanks: 227 times
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.



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.


Attachments:


You do not have the required permissions to view the files attached to this post. Register to gain access.



Top
 Profile  
 
 Post subject: Re: SOA graphic assets
PostPosted: Mon Jul 23, 2018 2:15 pm 
Offline
n00b

Joined: Thu Mar 25, 2010 8:53 pm
Posts: 16
Has thanked: 13 times
Have thanks: 3 times
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)


Attachments:


You do not have the required permissions to view the files attached to this post. Register to gain access.



Top
 Profile  
 
 Post subject: Re: SOA graphic assets
PostPosted: Mon Jul 23, 2018 3:44 pm 
Offline
mega-veteran
mega-veteran

Joined: Fri Jul 08, 2011 10:36 am
Posts: 276
Has thanked: 42 times
Have thanks: 227 times
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.


Attachments:


You do not have the required permissions to view the files attached to this post. Register to gain access.



Top
 Profile  
 
 Post subject: Re: SOA graphic assets
PostPosted: Mon Jul 23, 2018 3:50 pm 
Offline
n00b

Joined: Thu Mar 25, 2010 8:53 pm
Posts: 16
Has thanked: 13 times
Have thanks: 3 times
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.


Top
 Profile  
 
 Post subject: Re: SOA graphic assets
PostPosted: Wed Jul 25, 2018 3:51 pm 
Offline
mega-veteran
mega-veteran

Joined: Fri Jul 08, 2011 10:36 am
Posts: 276
Has thanked: 42 times
Have thanks: 227 times
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.


Top
 Profile  
 
 Post subject: Re: SOA graphic assets
PostPosted: Sat Aug 11, 2018 8:22 pm 
Offline
mega-veteran
mega-veteran

Joined: Fri Jul 08, 2011 10:36 am
Posts: 276
Has thanked: 42 times
Have thanks: 227 times
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


Top
 Profile  
 
 Post subject: Re: SOA graphic assets
PostPosted: Sat Aug 11, 2018 8:25 pm 
Offline
n00b

Joined: Thu Mar 25, 2010 8:53 pm
Posts: 16
Has thanked: 13 times
Have thanks: 3 times
That's going to be very useful. Thanks for relaying the info here :)


Top
 Profile  
 
 Post subject: Re: SOA graphic assets
PostPosted: Sun Aug 12, 2018 7:28 pm 
Offline
Moderator
User avatar

Joined: Sun May 18, 2008 3:01 pm
Posts: 2503
Has thanked: 57 times
Have thanks: 1248 times
Image Type 0x2F - ETC2-RGB
Image Type 0x31 - ETC2-RGBA
Image Type 0x32 - EAC-RG11


Top
 Profile  
 
 Post subject: Re: SOA graphic assets
PostPosted: Sun Aug 12, 2018 8:50 pm 
Offline
n00b

Joined: Thu Mar 25, 2010 8:53 pm
Posts: 16
Has thanked: 13 times
Have thanks: 3 times
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)


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 12 posts ] 

All times are UTC + 1 hour


Who is online

Users browsing this forum: No registered users and 1 guest


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group