07-30-2021, 03:07 PM
(This post was last modified: 07-03-2023, 10:45 AM by rufaswan.
Edit Reason: updated for Quad Player v0.2
)
(07-13-2021, 08:54 AM)leafthelast Wrote: I don't understand "In short"
"pad it" mean add 0x10000 bytes(0x200 * 0x100)? Or adding 8 null bytes to each 8 bytes?
Hi! Sorry for late reply. "Pad it" means add zeroes to the end of pixel buffer, so a 512x256 image can become 512x512. It is line 305 on the source code : https://github.com/rufaswan/Web2D_Games/...n_FTEX.php
Just like Gunvolt, let's just put up a step-by-step tutorial on how to use my scripts:
Step 1) Get PHP 7.0+ from https://windows.php.net/download/ . You'll only need 3 files from the archive, "php.exe", "php7ts.dll", and "php.ini" (renamed from "php.ini-development"). My scripts doesn't need any PHP extensions.
Step 2) Download my GitHub repo https://github.com/rufaswan/Web2D_Games/ . You'll only need "psxtools" folder under "tools/psxtools".
PS2 GrimGrimoire + Odin Sphere
Step 3) Extract "DISC.CVM" from the game ISO. Use a CVM tool to extract its content.
UPDATE : to decrypt and extract the content of DISC.CVM, run
Code:
php.exe psxtools/ps2_odin_CVMH_decrypt.php DISC.CVM
php.exe psxtools/php_isolist.php DISC.CVM
Step 4) Open cmd.exe , convert all .FTP to standard .RGBA/.CLUT file with
Code:
php.exe psxtools/ps2_odin_FTEX.php *.ftp
NDS Kumatanchi
Step 3) Extract all files from the game ISO.
Step 4) Open cmd.exe , convert all .FTX to standard .RGBA/.CLUT file with
Code:
php.exe psxtools/nds_kuma_FTEX.php *.ftx
Wii Muramasa
Step 3) Extract all files from the game ISO. Run this to decompress them.
Code:
php.exe psxtools/wii_mura_FCMP_decode.php *
Step 4) Open cmd.exe , convert all .FTX to standard .RGBA/.CLUT file with
Code:
php.exe psxtools/wii_mura_FTEX.php *.ftx
PSP Grand Knights History
Step 3) Extract all files from the game ISO.
Step 4) Open cmd.exe , convert all .FTX to standard .RGBA/.CLUT file with
Code:
php.exe psxtools/psp_grand_FTEX.php *.ftx
VITA Muramasa Rebirth + Odin Sphere Leifthrasir + Dragon Crown
Step 3) Extract all files from the game ISO.
Step 4) Open cmd.exe , convert all .FTX to standard .RGBA/.CLUT file with
Code:
php.exe psxtools/vita_mura_FTEX.php *.ftx
PS3 Dragon Crown + Odin Sphere Leifthrasir
Step 3) Extract all files from the game ISO.
Step 4) Open cmd.exe , convert all .FTX to standard .RGBA/.CLUT file with
Code:
php.exe psxtools/ps3_odin_FTEX.php *.ftx
PS4 Dragon Crown Pro + Odin Sphere Leifthrasir + 13 Sentinels: Aegis Rim
Step 3) Extract all files from the game ISO with LibOrbisPkg
https://github.com/maxton/LibOrbisPkg
Step 4) Open cmd.exe , convert all .FTX to standard .RGBA/.CLUT file with
Code:
php.exe psxtools/ps4_13sent_FTEX.php *.ftx
Step 5) As I do not use any image library, those CLUT and RGBA files are actually raw pixel data. You can convert them into PNG by running:
Code:
php.exe psxtools/img_clut2png.php FILE.clut
php.exe psxtools/img_clut2png.php FILE.rgba
NOTE : the .tm2/.tpl/.gim/.gxt/.gtf/.gnf from Step 4 are actually decoded CLUT/RGBA , and can also be convert to PNG
Code:
php.exe psxtools/img_clut2png.php FILE.tm2
php.exe psxtools/img_clut2png.php FILE.tpl
php.exe psxtools/img_clut2png.php FILE.gim
php.exe psxtools/img_clut2png.php FILE.gxt
php.exe psxtools/img_clut2png.php FILE.gtf
php.exe psxtools/img_clut2png.php FILE.gnf
Step 6) Since all .MBP/.MBS files are just revisions with added features, they are now merged into one script to make it easier to understand them. It is now convert to .V55 file instead.
.V55 is version 55 used on PS2 Odin Sphere.
Code:
php.exe psxtools/quad_vanillaware_FMBP_FMBS.php [game] *.mbp/*.mbs
game =
ps2_grim 2007 PS2 GrimGrimoire
ps2_odin 2007 PS2 Odin Sphere
nds_kuma 2008 NDS Kumatanchi
wii_mura 2009 Wii Muramasa - The Demon Blade
ps3_drag 2013 PS3 Dragon's Crown
ps3_odin 2016 PS3 Odin Sphere Leifthsar
ps4_odin 2016 PS4 Odin Sphere Leifthsar
ps4_drag 2018 PS4 Dragon's Crown Pro
ps4_sent 2019 PS4 13 Sentinels: Aegis Rim
psp_gran 2011 PSP Gran Knights History
vit_mura 2013 Vita Muramasa Rebirth + DLC
vit_drag 2013 Vita Dragon's Crown
vit_odin 2016 Vita Odin Sphere Leifthsar
Step 7) .V55 file can then be convert to .QUAD for Quad Player v0.2.
Code:
php.exe psxtools/quad_vanillaware_v55.php FILE.v55
Just like Gunvolt before https://www.vg-resource.com/thread-38568...#pid667970 , you can use tsr_cmdloop.php to loop through all of them. This is the usage command:
Code:
php.exe psxtools/tsr_cmdloop.php EXTENSION "COMMAND"
On estimate, the total file size for this project, in QUAD+PNG pair for Quad Player, is around 3.5 GB. Converting them into PNG spritesheet is expected to be 20x-50x larger, so you'll have about 70 GB - 165.5 GB of stuff to upload.
Hope it helps. Enjoy!
- Rufas