FanTranslatorsInternational / Kuriimu2

Kuriimu is a general purpose game translation project manager and toolkit for authors of fan translations and game mods.
GNU General Public License v3.0
308 stars 56 forks source link

Format 6 is not supported by Encoding Definition (JTEX problem) #316

Open joyingwol opened 5 months ago

joyingwol commented 5 months ago

Game Name: Medarot Girls Mission: Kuwagata Ver.
Console: 3DS
Format extension(s): .jtex
Type: image

First 8 or more bytes of the file(s): [extension] - [bytes in hex] - [bytes in ASCII]

.jtex 11 80 00 04 04 80 00 00 00 06 20 03 90 01 13 00 F0 20... [Unknown]

(The hex is from original file.)

More details: The header seems to be a LZ11 compression so I try it but it didn't work, and showed Format 6 is not supported by Encoding Definition on both original file and decompressed file.

Another information is that some of the jtex files with similar header can be extracted with a wrong palette.

This knid of files comes with different hex on the 10th position:

11 80 00 04 04 80 00 00 00 03

Wrong palette image

And some of the files with similar header can be extracted with a correct palette:

Correct palette image

This kind of files also comes with different hex on the 10th position:

11 80 00 04 04 80 00 00 00 04

My only purpose is to know how to deal with hex-06 case. And if possible, please add it to the soft.

Sample files: Note:1.jtex is available to be opened with a wrong palette, 2.jtex is related to 1.jtex,while 3.jtex is another random file which can not be opened. 4.jtex is opened without problem. https://drive.google.com/drive/folders/1gzqBPj4rDwxieBt7AwuX0-FRQLLV9npy?usp=sharing

RealDarkCraft commented 4 months ago

If you want I can send you an version of kurrimu that's I have compiled (i don't have compiled all plugins but i just compiled Nintendo plugins because i have fix you'r jtex error actually your problem was, just missing formats for the image format padding (for jtex)

RealDarkCraft commented 4 months ago

actually jtex 2 and 3 can't be opened with kuriimu but 1 and 4 can be corrtly oppened (you probably use the release version but this is a old version and to get the newest version you need to compile it)

RealDarkCraft commented 4 months ago

I just added that's line : [6] = ImageFormats.Rgb565()

in RawJtexSupport.cs

joyingwol commented 4 months ago

I just added that's line : [6] = ImageFormats.Rgb565()

in RawJtexSupport.cs

Oh, if it's possible please share me with your .cs file, thks.

RealDarkCraft commented 4 months ago

try to open the file with this : https://mega.nz/file/RPMXDTyB#3HlVB9xcJdrlhsEkUFM-Av2hblY3RC9eVTEFKX5Yvx0