Jump to content

DDS to XBM converter


Recommended Posts

Hi there,

 

I wanted to make some changes on Geralt's face and eyes, for that i first have to convert the XBM files to DDS through quickbms. Quickbms pulls out two files one .dds file and one .bin file. I use PS to edit the DDS files. After that i tried to transform it back into one XBM files through the help of quickbms. That's when i received this error message:

 

incomplete input file number 1, can't read 65536 bytes.

anyway don't worry, it's possible that the BMS script has been written

to exit in this way if it's reached the end of the archive so check it

or contact its author or verify that all the files have been extracted

 

Now here's the odd thing, with some files it works like "geralt_eye_s.xbm" and with some it doesn't like "geralt_eye.xbm".

 

Can someone help me with that?

Link to comment
Share on other sites

A nice guide on how to use quickbms would also be nice! :thumbsup:

 

 

For some reason when i have texmod active and have it attach to tw2 my performance slows to a crawl, without any packages even.Weirdness, maybe driver or gpu setting issue.

 

Anyhow i actually tried modding the hairs too (although to black) so i know where they are (for a change ;p) Sorry for assuming all this knowledge, i will explain properly ;)

 

1) The game files are compressed in the pack0.dzip - so first you have to unpack it

see here -> http://www.gog.com/en/forum/the_witcher_2/how_to_unpack_the_pack0_dzip_for_modders - make sure you extract it somewhere, where somewhere is not inside tw2 directory.

 

2) Get the zip file http://filesmelt.com/dl/witcher2_texture_converter.zip , and get rid of the bat files inside (they don't work for me at all). Copy the entire contents in the same directory where you have quickbms (which you will have once you follow the how to unpack the pack0 file)

 

3) see attachment how your folder should look ;p

 

Now its really simple browse your extracted files (wherever you extracted pack0.dzip to) and find characters\player\model\head

 

inside you find

geralt__c1.xbm (Color)

geralt__c1_n.xbm (Normals)

geralt__c1_s.xbm (Specular)

 

Now start quickbms.exe - point it to the w2_xbm2dds.bms then in the 2nd dialog - point it to geralt__c1.xbm . It extracts the file (you can also shift select more xbm files)

 

Now you have a geralt__c1_DXT1.dds and bin , drag the dds file simply on nvdecompress.exe to get a tga, edit the tga, save it, and drag it on nvcompress to get a dds again.

 

Now rename (your modified) geralt__c1_DXT1.dds to geralt__c1.dds (so , just drop the DXT1 its something the unpack script does)

 

Now the last step is simply to run quickbms.exe again, but this time point it to w2_dds2xbm.bms - select your "new" geralt__c1.dds file and you get, tada, an xbm file that the game should read if you put it in the right place. (make sure you don't "lose" the bin file Note And don't forget to remove the dxt1 part from the bin file as well!, its required for the final step ,p)

 

So basically, to "properly" recreate the xmb file make sure do this and have these 2 files

rename geralt__c1_DXT1.dds to geralt__c1.dds

rename geralt__c1_DXT1.bin to geralt__c1.bin

then just select the DDS file when you are using quickbms (it will auto-read the bin file)

 

The right place for that particular file would be here

The Witcher 2\CookedPC\characters\player\model\head

 

Quote is from a guy/gal who goes by the name "eRe4s3r". Found it in the GOG Forums.

Link to comment
Share on other sites

Whoop! Just figured it out myself.

 

It's quite simple actually. When you use quickbms to convert the files into dds, the name changes too. For example:

 

geralt__h1.xbm becomes geralt__h1_DXT1.dds/.bin

 

and

 

geralt__h1_n.xbm becomes geralt__h1_DXT5.dds/.bin

 

If you (like me) use Photoshop with the DDS-Plugin from nVidia, you should be able to open and save dds-files with Photoshop. When you save the file as a dds the nVidia Format Window pops up and asks you for further options.

 

Now to the simple yet important part. If the name of your file says "DXT5" at the end, choose DXT5 ARGB 8 bpp | interpolated alpha in the options menu, next to the SAVE Button. If it says "DXT1" choose DXT1 RGB 4 bpp | no alpha.

 

Done. You will now be able to convert it back to xbm without any bugs. Happy texturing.

Link to comment
Share on other sites

Hey there.

I`ve found a strange solution for that "incomplete input file number 1" thing. Maybe it`s just for me, but when i`ve recived that error, i took a closer look to my texture`s ".bin" file with notepad++ tool, and found out, that it has different filepath, than my extracted files are. So i manually changed it to my current extraction path, saved, and it worked like a charm.

I hope this will help someone.

Edited by skims
Link to comment
Share on other sites

Okay, silly question... How come when i save my retextured file, in game armor remains the same?

I thought maybe its the file path. So i put it in the characters/player/model/trunk/leather_armor but it still remains unchanged.. Its the dragon scale armor that im playing with btw. and im pretty sure i got the right .dds.

 

EDIT:

Got it now...

Edited by markoBG
Link to comment
Share on other sites

Hi there,

 

I wanted to make some changes on Geralt's face and eyes, for that i first have to convert the XBM files to DDS through quickbms. Quickbms pulls out two files one .dds file and one .bin file. I use PS to edit the DDS files. After that i tried to transform it back into one XBM files through the help of quickbms. That's when i received this error message:

 

incomplete input file number 1, can't read 65536 bytes.

anyway don't worry, it's possible that the BMS script has been written

to exit in this way if it's reached the end of the archive so check it

or contact its author or verify that all the files have been extracted

 

Now here's the odd thing, with some files it works like "geralt_eye_s.xbm" and with some it doesn't like "geralt_eye.xbm".

 

Can someone help me with that?

I have the same error ... it's specular texture and I saved it as dds DXT5 ARGB 8 bpp | interpolated alpha.

Then I use quickbms to convert it back to xmb but I have this crap things.

 

NVM we have to generate mip maps.

It works thanks buddy.

Edited by Kiori
Link to comment
Share on other sites

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...