Quantcast

Jump to content

» «
Photo

[REL] ViceTXD Update

94 replies to this topic
Spooky
  • Spooky

    Prince of the Yolkfolk

  • Members
  • Joined: 13 Jan 2002

#1

Posted 10 September 2003 - 04:25 PM

Hey people,

I've updated ViceTXD, i've added some things people requested like 8bit texture support and a find feature, and also added a few other features...

You can now add textures to a TXD, in any format (DXT1, DXT3, 32bit or 8bit) but you can't add textures to a TXD thats inside an img archive... I'll sort this out for the next release. Until then just extract the TXD out of the archive with IMGTool and add whatever textures to it, then re-insert it into the archive with IMGTool again.

I'm afraid the people having problems replacing textures are still going to have that problem... this is due to your graphics card not supporting compressed textures. Sorry, but this can't be avoided till I find some decent DXT compressing code thats hardware independant.

I've had literally no time to test some of the new features, so this is still beta. If you have any problems or find a bug, please post here with as much info as possible. Thanks.

Download: ViceTxd_15b.exe (491kb)
'dexx edit: for months this link has been wrong (it went to img tool), i fixed it since i guess you got lazy, or forgot tounge.gif

Happy Modding.

DexX
  • DexX

    Black Hat

  • Feroci Racing
  • Joined: 16 May 2002

#2

Posted 10 September 2003 - 05:33 PM

Ok. uncompressed 32-bit images aren't displayed correctly, as you can see in this screenshot:http://gregval.phpwe...ds/txderror.jpg

Btw, whats the difference between a DXT1 and DXT3 compressed texture? Like the new features man, good work.

ZanderZ
  • ZanderZ

    GTA modder & tool writer

  • Members
  • Joined: 08 Sep 2002

#3

Posted 10 September 2003 - 05:48 PM

QUOTE (Spooky @ Sep 10 2003, 17:25)
find feature

YEAH! Thank you Spooky!
Haven't tested the new program fully yet, but the Find option works fine, the new Replace option is good too smile.gif
Two questions though:
1. Can you make a checkbox for the alpha that's always visible? Now you would have to press the 'Draw alpha channel' button or view the ExInfo... I'd rather see it right away. Or perhaps you could make it like in GTA3 Resource Hacker, that you have an option to show both image and alpha at the same time...
2. Any chance you will release the source code at some point in your life? ;D tounge.gif

JernejL
  • JernejL

    Big Homie

  • Feroci Racing
  • Joined: 11 Mar 2002

#4

Posted 10 September 2003 - 05:50 PM

QUOTE (ashdexx @ Sep 10 2003, 18:33)
Ok. uncompressed 32-bit images aren't displayed correctly, as you can see in this screenshot:http://gregval.phpwe...ds/txderror.jpg

Btw, whats the difference between a DXT1 and DXT3 compressed texture? Like the new features man, good work.

i think that that the display is right, the importing is wrong...

the dxt3 textures have bit better smoother quality alphas and bigger than dxt1
but use them only if you intend to use the alpha channel... otherwise the file
is bigger and the normal image quality same...

Spooky
  • Spooky

    Prince of the Yolkfolk

  • Members
  • Joined: 13 Jan 2002

#5

Posted 10 September 2003 - 05:53 PM

QUOTE (ashdexx @ Sep 10 2003, 17:33)
Ok. uncompressed 32-bit images aren't displayed correctly, as you can see in this screenshot:http://gregval.phpwe...ds/txderror.jpg

Oops, it seems they're BGRA not RGBA, i'll sort that now.

Spooky
  • Spooky

    Prince of the Yolkfolk

  • Members
  • Joined: 13 Jan 2002

#6

Posted 10 September 2003 - 06:10 PM

Sorted. Re-download it for the fix smile.gif .

REspawn
  • REspawn

    REgent

  • Members
  • Joined: 06 Jul 2002

#7

Posted 10 September 2003 - 06:50 PM

Excellent work! rah.gif

MPD
  • MPD

    Punk-ass Bitch

  • Members
  • Joined: 01 Aug 2003

#8

Posted 10 September 2003 - 08:46 PM

thats amazing colgate.gif the best texture editor rah.gif cookie.gif cookie.gif

DiCanio
  • DiCanio

    Foot Soldier

  • Members
  • Joined: 22 Jul 2002

#9

Posted 10 September 2003 - 08:58 PM

nice work Spooky wow.gif )

Demarest
  • Demarest

    what could be

  • BUSTED!
  • Joined: 12 Jul 2003

#10

Posted 10 September 2003 - 11:30 PM

I have to give Spooky props too. I'm a GTA3 guy, and with his tools, I need no others smile.gif

Spooky
  • Spooky

    Prince of the Yolkfolk

  • Members
  • Joined: 13 Jan 2002

#11

Posted 11 September 2003 - 09:49 AM

QUOTE (ZanderZ @ Sep 10 2003, 17:48)
1. Can you make a checkbox for the alpha that's always visible? Now you would have to press the 'Draw alpha channel' button or view the ExInfo... I'd rather see it right away. Or perhaps you could make it like in GTA3 Resource Hacker, that you have an option to show both image and alpha at the same time...
2. Any chance you will release the source code at some point in your life? ;D tounge.gif

1. Theres one now? The "Draw Alpha Channel" checkbox is always visible below the texture listbox :s.
2. At some point maybe, but not till i've cleaned it up.. alot.

ZanderZ
  • ZanderZ

    GTA modder & tool writer

  • Members
  • Joined: 08 Sep 2002

#12

Posted 11 September 2003 - 11:12 AM

QUOTE (Spooky @ Sep 11 2003, 10:49)
1. Theres one now? The "Draw Alpha Channel" checkbox is always visible below the texture listbox :s.

Okay, I should have put my question a little different... Right now, you can't see if an image has an alpha channel unless you have ExInfo enabled.
would like to see if an image has alpha right away. Perhaps you could disable the 'Draw Alpha Channel' when there's no alpha channel. This shouldn't be any problem I think...

Something like
CODE

if ImageHasAlpha then DrawAlphaCheckbox.Enabled:=True else DrawAlphaCheckBox:=False;

This way, if an image has no alpha, you can see it right away because the checkbox is disabled.

Spooky
  • Spooky

    Prince of the Yolkfolk

  • Members
  • Joined: 13 Jan 2002

#13

Posted 11 September 2003 - 11:21 AM

ViceTXD 1.4b is out! smile.gif

QUOTE
+1.4b (Beta)
- Make new TXD's! smile.gif
- Proper support for 32bit textures tounge.gif
- Few bugfixes etc...


Download: Setup.exe (491kb)

...and I added what you suggested ZanderZ.

ZanderZ
  • ZanderZ

    GTA modder & tool writer

  • Members
  • Joined: 08 Sep 2002

#14

Posted 11 September 2003 - 12:16 PM Edited by ZanderZ, 11 September 2003 - 12:18 PM.

QUOTE (Spooky @ Sep 11 2003, 12:21)
ViceTXD 1.4b is out! smile.gif

Download: Setup.exe (491kb)

...and I added what you suggested ZanderZ.

Great! Thanks!

Hm... I just noticed something. It's probably not a bug but something with my pc, but I thought I'd let you know just to be sure.
When I maximize the ViceTXD window, the 'txd scrollbar' (the top one) almost disappears. This looks very strange. When I switch to another window and go back, it looks fine again...

There's also a small error in ReadMe.txt
At the section HELP, it says "This is only a breif help section"

Spooky
  • Spooky

    Prince of the Yolkfolk

  • Members
  • Joined: 13 Jan 2002

#15

Posted 11 September 2003 - 01:14 PM

I've not noticed that ZanderZ, if anyone else mentions it, i'll look into it.

I've just fixed another bug thanks to illspirit smile.gif Everyone please re-download if you plan on making new TXD's and got it before I posted this message.

Download: Setup.exe (491kb)

ZanderZ
  • ZanderZ

    GTA modder & tool writer

  • Members
  • Joined: 08 Sep 2002

#16

Posted 11 September 2003 - 05:17 PM

I don't think it's a bug in your program though... But if anyone else notices it, then you should look at it.
I did find another small bug: when replacing a texture saved in Adobe Photoshop (24 bit bmp) I get the error 'Unable to relpace texture.'
Saving the image in Paint solves this first problem, but the spelling error remains wink.gif

Spooky
  • Spooky

    Prince of the Yolkfolk

  • Members
  • Joined: 13 Jan 2002

#17

Posted 11 September 2003 - 05:31 PM

I'm a programmer, that has very little sleep, please excuse the spelling mistakes smile.gif .

Also, as a note: When replacing 8bit textures, the texure + alpha bitmap cannot be more than 256 colours combined. Save as an 8bit bitmap and you can't go wrong smile.gif .

MPD
  • MPD

    Punk-ass Bitch

  • Members
  • Joined: 01 Aug 2003

#18

Posted 11 September 2003 - 05:50 PM Edited by MPD, 11 September 2003 - 05:51 PM.

i exported a 32 bit texture and alpha. i edited them in paint and saved it without changing the bit rate. when i replaced the same texture it said unable to replace texture. why does it do this. it worked on version 1.0b

also the pixels are the same size. its just the image thats different

Pagnell
  • Pagnell

    a.k.a. petebog

  • Members
  • Joined: 22 May 2002

#19

Posted 11 September 2003 - 08:56 PM

Yay! A find feature! biggrin.gif biggrin.gif biggrin.gif

Spooky
  • Spooky

    Prince of the Yolkfolk

  • Members
  • Joined: 13 Jan 2002

#20

Posted 12 September 2003 - 12:22 AM

QUOTE (MPD @ Sep 11 2003, 17:50)
i exported a 32 bit texture and alpha. i edited them in paint and saved it without changing the bit rate. when i replaced the same texture it said unable to replace texture. why does it do this. it worked on version 1.0b

also the pixels are the same size. its just the image thats different

Sorry about that, I totally missed out the code for replacing 32bit textures wow.gif . I had no 32bit textures in my default install of vice to test on, so it slipped through the net wow.gif .

I've fixed the bug and the fixed version is available at the same url...

Download: Setup.exe (491kb)

DexX
  • DexX

    Black Hat

  • Feroci Racing
  • Joined: 16 May 2002

#21

Posted 12 September 2003 - 03:35 AM Edited by ashdexx, 12 September 2003 - 03:36 AM.

heh, atleast you don't ignore the bugs. Do you (spooky) or anyone else know what the flags do? ive noticed texture with an alpha channel have flag 9 and 11 checked. "normal" textures, have flag 10 and 11. Some cutscene objects have flag 16 set and the txd's that contain tommy's extra skins also have flag 16 marked. Some of the 8-bit textures use flag 14.
Flag 10 is consistently checked off in all the ones ive checked, except those with an alpha channel.
Ive tested a few other combinations, some of which froze the game.

Speaking of which, spooky, i created an entirely new txd with your program, and when i tested it ingame, it froze the game on loading. it was a duplicate of a txd i knew worked, so something went wrong somewhere. I went to File > New and named it, then made 3 new textures, one with alpha channel support, and sized / named them appropriately. Are there any tips or suggestions you might have?

MPD
  • MPD

    Punk-ass Bitch

  • Members
  • Joined: 01 Aug 2003

#22

Posted 12 September 2003 - 09:42 AM

@Spooky. thanks. i needed that. colgate.gif

Spooky
  • Spooky

    Prince of the Yolkfolk

  • Members
  • Joined: 13 Jan 2002

#23

Posted 12 September 2003 - 10:35 AM

QUOTE (ashdexx @ Sep 12 2003, 03:35)
Speaking of which, spooky, i created an entirely new txd with your program, and when i tested it ingame, it froze the game on loading. it was a duplicate of a txd i knew worked, so something went wrong somewhere. I went to File > New and named it, then made 3 new textures, one with alpha channel support, and sized / named them appropriately. Are there any tips or suggestions you might have?

Which TXD did you reproduce? I've remade quite a few TXDs from gta3.img: radars, skins, buildings etc, keeping the flags as they were and had no problems sad.gif .

DexX
  • DexX

    Black Hat

  • Feroci Racing
  • Joined: 16 May 2002

#24

Posted 12 September 2003 - 06:24 PM

the txd i based it off was a custom txd that i had originally made with steve's txd builder. anyway, on seeing that the one i reproduced didnt work, i promptly deleted it and put the old one back in my game. however if it happens again, ill zip it and send it to you if ya want.

JernejL
  • JernejL

    Big Homie

  • Feroci Racing
  • Joined: 11 Mar 2002

#25

Posted 12 September 2003 - 06:42 PM Edited by Delfi, 12 September 2003 - 06:46 PM.

QUOTE (ashdexx @ Sep 12 2003, 04:35)
heh, atleast you don't ignore the bugs. Do you (spooky) or anyone else know what the flags do? ive noticed texture with an alpha channel have flag 9 and 11 checked. "normal" textures, have flag 10 and 11. Some cutscene objects have flag 16 set and the txd's that contain tommy's extra skins also have flag 16 marked. Some of the 8-bit textures use flag 14.
Flag 10 is consistently checked off in all the ones ive checked, except those with an alpha channel.
Ive tested a few other combinations, some of which froze the game.

Speaking of which, spooky, i created an entirely new txd with your program, and when i tested it ingame, it froze the game on loading. it was a duplicate of a txd i knew worked, so something went wrong somewhere. I went to File > New and named it, then made 3 new textures, one with alpha channel support, and sized / named them appropriately. Are there any tips or suggestions you might have?

"Some cutscene objects have flag 16 set and the txd's that contain tommy's extra skins also have flag 16 marked. "

i think you just found the "detail texturing" flag that would enable extremely quality
rendeering of textures in gtavc!

example: *can't find a example image of how this looks but was used in battlefield: 1741 game
the textures realy looked amazingly better!


if the flag is what i think it is then this is good news for car makers especialy!

maybe the flag can be chrome or differently shaded etc...

DexX
  • DexX

    Black Hat

  • Feroci Racing
  • Joined: 16 May 2002

#26

Posted 14 September 2003 - 01:56 AM

i tried flag 16 on a couple cars, and didnt notice any effect. whatever it does, IF it works on cars too, the effect is not obvious. maybe it only effects certain things...?

more testing is in order. Btw, what exactly do you mean by, "high quality rendering" ? if its cutscenes your talking about, i notice they do look better, but thats usually because of more detailed models, i didn't think the textures also had special attributes too.......hmm........

steve-m
  • steve-m

  • Members
  • Joined: 26 Jul 2002

#27

Posted 14 September 2003 - 04:49 PM

Great work Spooky, but:

- The second DWORD value in the TXD file is the size of the whole file minus 12, but in a test file I created it was a VERY huge number (wrong of course).

- The (empty) extension section (3) after the texture data section (1) is missing, but I guess it isn't needed anyway.

- When adding a new texture, could you make your tool automaticly get the dimensions of the texture and the texture/alpha name from the file name (without extension), so the user doesn't need to enter it everytime?

- What is that flag you are talking about? The DWORD before texture name? I just found three different values yet: 4353, 4354 and 4358. The hex look like this: 0x00001101, 0x00001102, 0x00001106. Only the first byte seems to change. Haven't done tests with that yet.

QUOTE
maybe the flag can be chrome or differently shaded etc...
Unlikely... dontgetit.gif

Steve

JernejL
  • JernejL

    Big Homie

  • Feroci Racing
  • Joined: 11 Mar 2002

#28

Posted 14 September 2003 - 05:10 PM

gah! we need a special "TXD Tech" topic for this kind of stuff,
talking here just scares people...

steve-m
  • steve-m

  • Members
  • Joined: 26 Jul 2002

#29

Posted 14 September 2003 - 06:44 PM Edited by ST.MU, 14 September 2003 - 06:44 PM.

QUOTE (Delfi @ Sep 14 2003, 19:10)
gah! we need a special "TXD Tech" topic for this kind of stuff,
talking here just scares people...

hehe, true biggrin.gif

But can I still get answers? tounge.gif

Spooky
  • Spooky

    Prince of the Yolkfolk

  • Members
  • Joined: 13 Jan 2002

#30

Posted 14 September 2003 - 07:13 PM

QUOTE (ST.MU @ Sep 14 2003, 16:49)
Great work Spooky, but:

- The second DWORD value in the TXD file is the size of the whole file minus 12, but in a test file I created it was a VERY huge number (wrong of course).

- The (empty) extension section (3) after the texture data section (1) is missing, but I guess it isn't needed anyway.

- When adding a new texture, could you make your tool automaticly get the dimensions of the texture and the texture/alpha name from the file name (without extension), so the user doesn't need to enter it everytime?

- What is that flag you are talking about? The DWORD before texture name? I just found three different values yet: 4353, 4354 and 4358. The hex look like this: 0x00001101, 0x00001102, 0x00001106. Only the first byte seems to change. Haven't done tests with that yet.

QUOTE
maybe the flag can be chrome or differently shaded etc...
Unlikely... dontgetit.gif

Steve

- I've just noticed a bug in my code there, the second dword is always 4, no matter what, but i guess Vice doesnt use it as the TXDs seem to work fine. I think you're refering to the 3rd dword, which Delfi informed me is the "gametype"... with "268697599" being ViceCity.

- I wasn't even aware of this extra data section wow.gif I've not come across a texture that doesn't start right after the texture before's data + mipmap data.

[Edit]
Oops, missed your third item smile.gif
[/Edit]

- Adding it now biggrin.gif

- The flags are in the dword right after the alpha name.




1 user(s) are reading this topic

0 members, 1 guests, 0 anonymous users