Spiderman custom PVR format

Get your graphics formats figures out here! Got details for others? Post here!
krystalgamer
beginner
Posts: 21
Joined: Mon May 02, 2016 11:20 pm
Has thanked: 1 time
Been thanked: 12 times

Re: Spiderman custom PVR format

Post by krystalgamer » Tue Jul 11, 2017 12:39 pm

AceWell wrote:
krystalgamer wrote:How did you compile the code and what's the system you compiled in?
Did you run make or simply gcc?
i don't know how to use the "Makefile", i'm fairly new to compiling sources and i'm not a programmer :D

Code: Select all

gcc -std=c99 -o psx.exe psx.c psx.h bmp.c
edit
nevermind i got it working, i used the "CFLAGS" you had in the "Makefile" instead (although i've no idea what they mean) :dance:

Code: Select all

gcc -std=c11 -g -mno-ms-bitfields -o psx.exe psx.c psx.h bmp.c
my psx.exe is 70.2kb
You're compiling it manually. When there's a Makefile just type "make". It'll do everything for you.

-std=c11 defines the newer standard of C, the C11, which i use for the anonymous structures
-g is for debug symbols
-mno-ms-bitfields is used because newer versions of gcc have trouble packing the structures, even expliciting telling it (__attribute__((packed))) is not enough.

krystalgamer
beginner
Posts: 21
Joined: Mon May 02, 2016 11:20 pm
Has thanked: 1 time
Been thanked: 12 times

Re: Spiderman custom PVR format

Post by krystalgamer » Tue Jul 11, 2017 3:44 pm

Update!!! :D

My texture repacker is finally done :D Check the code here: https://github.com/krystalgamer/spidey-tools
For real, it's a huge pain in the ass to create custom textures. You're limited to 256 patterns of 4 colors. Unless someone develops a plugin or a image editor that allows to keep count of them custom textures won't happen this way.

If you intend to create custom textures make sure to save them as BMP 16Bit RGB565! The only image editor i know that allows to do so is photoshop :/ sorry, hope everyone interested can find its ways.

Btw here's a little demo of the tool: https://www.youtube.com/watch?v=bLyL9-Jk5ks

This + the custom file loader allows me to live edit the textures which is amazing for testing :D

I'll be writting a custom texture loader that allows to load them from the disk ;)

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

Re: Spiderman custom PVR format

Post by Acewell » Wed Jul 12, 2017 5:08 am

krystalgamer wrote:You're compiling it manually. When there's a Makefile just type "make". It'll do everything for you.

-std=c11 defines the newer standard of C, the C11, which i use for the anonymous structures
-g is for debug symbols
-mno-ms-bitfields is used because newer versions of gcc have trouble packing the structures, even expliciting telling it (__attribute__((packed))) is not enough.
thanks! but whenever i type "make" i just get this error:
'make' is not recognized as an internal or external command, operable program or batch file.
i launch MinGW command prompt and change directory to where the makefile is and type "make" but get that error always. :?

edit
ok i got it working by typing "mingw32-make" instead :D

Rutabaga
veteran
Posts: 115
Joined: Tue Jan 26, 2016 2:26 pm
Has thanked: 5 times
Been thanked: 6 times

Re: Spiderman custom PVR format

Post by Rutabaga » Wed Jul 12, 2017 7:19 am

krystalgamer wrote:Update!!! :D

My texture repacker is finally done :D Check the code here: https://github.com/krystalgamer/spidey-tools
For real, it's a huge pain in the ass to create custom textures. You're limited to 256 patterns of 4 colors. Unless someone develops a plugin or a image editor that allows to keep count of them custom textures won't happen this way.

If you intend to create custom textures make sure to save them as BMP 16Bit RGB565! The only image editor i know that allows to do so is photoshop :/ sorry, hope everyone interested can find its ways.

Btw here's a little demo of the tool: https://www.youtube.com/watch?v=bLyL9-Jk5ks

This + the custom file loader allows me to live edit the textures which is amazing for testing :D

I'll be writting a custom texture loader that allows to load them from the disk ;)
Thanks for such amazing tool,can't wait for release (i know,i can download tool now,but i'm noob in compiling and etc. stuff)
Btw,what means "you're limited to 256 patterns of 4 colors" if i wanna create skin from PS4 game or CW/Homecoming i can't then?
Thanks.

Edit: I made a homecoming SM chest,it has no webs (working on it)
can you test it plz?
https://mega.nz/#!b851wJ7R!opjK7o5qn-bf ... F7cY55VFj8

krystalgamer
beginner
Posts: 21
Joined: Mon May 02, 2016 11:20 pm
Has thanked: 1 time
Been thanked: 12 times

Re: Spiderman custom PVR format

Post by krystalgamer » Wed Jul 12, 2017 12:18 pm

AceWell wrote:
krystalgamer wrote:You're compiling it manually. When there's a Makefile just type "make". It'll do everything for you.

-std=c11 defines the newer standard of C, the C11, which i use for the anonymous structures
-g is for debug symbols
-mno-ms-bitfields is used because newer versions of gcc have trouble packing the structures, even expliciting telling it (__attribute__((packed))) is not enough.
thanks! but whenever i type "make" i just get this error:
'make' is not recognized as an internal or external command, operable program or batch file.
i launch MinGW command prompt and change directory to where the makefile is and type "make" but get that error always. :?

edit
ok i got it working by typing "mingw32-make" instead :D
Nice, if you want you can rename the mingw32-make.exe to make.exe or if you're using MSYS2 you can run pacman -S make to install it. (Also mingw32-make is just as fine as make ;))
Rutabaga wrote:
krystalgamer wrote:Update!!! :D

My texture repacker is finally done :D Check the code here: https://github.com/krystalgamer/spidey-tools
For real, it's a huge pain in the ass to create custom textures. You're limited to 256 patterns of 4 colors. Unless someone develops a plugin or a image editor that allows to keep count of them custom textures won't happen this way.

If you intend to create custom textures make sure to save them as BMP 16Bit RGB565! The only image editor i know that allows to do so is photoshop :/ sorry, hope everyone interested can find its ways.

Btw here's a little demo of the tool: https://www.youtube.com/watch?v=bLyL9-Jk5ks

This + the custom file loader allows me to live edit the textures which is amazing for testing :D

I'll be writting a custom texture loader that allows to load them from the disk ;)
Thanks for such amazing tool,can't wait for release (i know,i can download tool now,but i'm noob in compiling and etc. stuff)
Btw,what means "you're limited to 256 patterns of 4 colors" if i wanna create skin from PS4 game or CW/Homecoming i can't then?
Thanks.

Edit: I made a homecoming SM chest,it has no webs (working on it)
can you test it plz?
https://mega.nz/#!b851wJ7R!opjK7o5qn-bf ... F7cY55VFj8
There's a a space of 0x800 bytes for the colors on the PSXPVR file. Since it is 16bpp then there's a max of 0x400 colors there but the colors are being read 4 at once, that's what i call i pattern. Because of that the max number of patterns is 0x100 aka 256. If you want an ideia of what's a pattern in the actual image, set your pencil brush to a square brush of 2 px wide, this way you'll be using a pattern when paiting, BUT paint only odd and even rows and columns, or else you could be end up creating 4 new patterns.

With this i mean considering the pixel count start from 0, a pattern is ((1,1);(1,2);(2,1);(2,2)) if you paint this you'll be adding a pattern(if it already is not used) but if you paint ((1,2);(1,3);(2,2);(2,3)) you'll be creating 4 new patterns.

Doesn't work way too many patterns. Yours uses 4746. Also i had to save again your texture.
Make sure to save it has a 16bit bitmap RGB565 and FLIP ROW ORDER as I showed in the video.

krystalgamer
beginner
Posts: 21
Joined: Mon May 02, 2016 11:20 pm
Has thanked: 1 time
Been thanked: 12 times

Re: Spiderman custom PVR format

Post by krystalgamer » Fri Jul 14, 2017 12:22 am

Rutabaga wrote:
krystalgamer wrote:Update!!! :D

My texture repacker is finally done :D Check the code here: https://github.com/krystalgamer/spidey-tools
For real, it's a huge pain in the ass to create custom textures. You're limited to 256 patterns of 4 colors. Unless someone develops a plugin or a image editor that allows to keep count of them custom textures won't happen this way.

If you intend to create custom textures make sure to save them as BMP 16Bit RGB565! The only image editor i know that allows to do so is photoshop :/ sorry, hope everyone interested can find its ways.

Btw here's a little demo of the tool: https://www.youtube.com/watch?v=bLyL9-Jk5ks

This + the custom file loader allows me to live edit the textures which is amazing for testing :D

I'll be writting a custom texture loader that allows to load them from the disk ;)
Thanks for such amazing tool,can't wait for release (i know,i can download tool now,but i'm noob in compiling and etc. stuff)
Btw,what means "you're limited to 256 patterns of 4 colors" if i wanna create skin from PS4 game or CW/Homecoming i can't then?
Thanks.

Edit: I made a homecoming SM chest,it has no webs (working on it)
can you test it plz?
https://mega.nz/#!b851wJ7R!opjK7o5qn-bf ... F7cY55VFj8

First version of my texture loader is done :D
Your skin appears on the video: https://www.youtube.com/watch?v=VDDz1mZ8vSI
I won't release now since there's a weird bug where the costume gets reseted, after i fix it, everyone will be able to use it ;)

Rutabaga
veteran
Posts: 115
Joined: Tue Jan 26, 2016 2:26 pm
Has thanked: 5 times
Been thanked: 6 times

Re: Spiderman custom PVR format

Post by Rutabaga » Fri Jul 14, 2017 6:21 am

Amazing,thanks for all your hard work.
My texture looks strange btw (looks like i should make a total revamp)
And is there any chance for export/import models or maybe mod the hud head (spidey's head)?
Thanks.

krystalgamer
beginner
Posts: 21
Joined: Mon May 02, 2016 11:20 pm
Has thanked: 1 time
Been thanked: 12 times

Re: Spiderman custom PVR format

Post by krystalgamer » Mon Jul 31, 2017 3:27 pm

Custom texture loader is finally released!
https://www.youtube.com/watch?v=fZ5rSIQ6ZuA

Everything is explained in the video. Thanks everyone for the help!

Rutabaga
veteran
Posts: 115
Joined: Tue Jan 26, 2016 2:26 pm
Has thanked: 5 times
Been thanked: 6 times

Re: Spiderman custom PVR format

Post by Rutabaga » Tue Aug 01, 2017 5:27 pm

krystalgamer wrote:Custom texture loader is finally released!
https://www.youtube.com/watch?v=fZ5rSIQ6ZuA

Everything is explained in the video. Thanks everyone for the help!
Amazing,btw,do you still have plans about Model Extractor?

User avatar
ikskoks
mega-veteran
mega-veteran
Posts: 293
Joined: Thu Jul 26, 2012 5:06 pm
Location: Poland, Łódź
Has thanked: 357 times
Been thanked: 89 times
Contact:

Re: Spiderman custom PVR format

Post by ikskoks » Tue Aug 01, 2017 6:29 pm

If you have some free time now, maybe try to work on font replacer and text replacer :p

krystalgamer
beginner
Posts: 21
Joined: Mon May 02, 2016 11:20 pm
Has thanked: 1 time
Been thanked: 12 times

Re: Spiderman custom PVR format

Post by krystalgamer » Mon Aug 07, 2017 12:13 pm

ikskoks wrote:If you have some free time now, maybe try to work on font replacer and text replacer :p
From what i've seen the font is actually a bitmap which contains the letters in sequential order since it's loaded through the same function as the other bitmaps. Now the text replacer is actually easy to do, sadly the strings are in the exe(except the map notes). In fact i was able to do even more, i can now render more strings in the game :D

https://www.youtube.com/edit?o=U&video_id=V-HVpzkJAHg

User avatar
ikskoks
mega-veteran
mega-veteran
Posts: 293
Joined: Thu Jul 26, 2012 5:06 pm
Location: Poland, Łódź
Has thanked: 357 times
Been thanked: 89 times
Contact:

Re: Spiderman custom PVR format

Post by ikskoks » Mon Aug 07, 2017 11:29 pm

Cool. :) But the link is broken. Is it possible to replace strings which are longer than original?

krystalgamer
beginner
Posts: 21
Joined: Mon May 02, 2016 11:20 pm
Has thanked: 1 time
Been thanked: 12 times

Re: Spiderman custom PVR format

Post by krystalgamer » Thu Aug 24, 2017 1:18 pm

ikskoks wrote:
Cool. :) But the link is broken. Is it possible to replace strings which are longer than original?
Sorry, completly forgot about this: https://www.youtube.com/watch?v=V-HVpzkJAHg
Yes you can.

User avatar
ikskoks
mega-veteran
mega-veteran
Posts: 293
Joined: Thu Jul 26, 2012 5:06 pm
Location: Poland, Łódź
Has thanked: 357 times
Been thanked: 89 times
Contact:

Re: Spiderman custom PVR format

Post by ikskoks » Sun Sep 16, 2018 9:20 pm

@krystalgamer, do you plan to create some tools to support export/import text from TRG/EXE files or edit FNT font files? :)

krystalgamer
beginner
Posts: 21
Joined: Mon May 02, 2016 11:20 pm
Has thanked: 1 time
Been thanked: 12 times

Re: Spiderman custom PVR format

Post by krystalgamer » Sun Nov 11, 2018 11:24 am

ikskoks wrote:@krystalgamer, do you plan to create some tools to support export/import text from TRG/EXE files or edit FNT font files? :)

I can already edit the text but not yet the fonts. Currently I'm busy with exams and other stuff but you can contact me so we can work it out.
krystalgamer#5397 on discord.

Post Reply