Converting jpg files in hl2 textures

Converting jpg files in hl2 textures

Re: Converting jpg files in hl2 textures Posted by erbetal on Fri Nov 14th 2008 at 5:38pm
erbetal
87 posts
Posted 2008-11-14 5:38pm
erbetal
member
87 posts 11 snarkmarks Registered: Mar 29th 2008 Location: Canada
How can i convert a jpg or other image files in a HL2 texture, and in which steam directory i must place my custom textures?
Re: Converting jpg files in hl2 textures Posted by Riven on Fri Nov 14th 2008 at 9:09pm
Riven
1640 posts
Posted 2008-11-14 9:09pm
Riven
Wuch ya look'n at?
super admin
1640 posts 1266 snarkmarks Registered: May 2nd 2005 Occupation: Architect Location: Austin, Texas, USA
If you want to get your custom .jpg file into Half-Life 2, you have a couple of options.

The easiest way (with the least options) is to use a third party program called 'VTFedit' And you can get it here.

The VDC explains it the best, you can find out how to work with it there.

I'll explain simply what all is involved with the process.

First you have to get your texture to become a format the Source engine can 'read'. This format is called VTF or 'Valve Texture File'. VTFedit will help you convert your .jpg into a .vtf file and place it in the right place for you in order for the game to 'see' it. Then you will want to write a .vmt file; vmt files are a simple text file (normally written in notepad) the only difference is that they end with the extension .vmt rather than .txt (you just simply change that before saving) And they too must be placed wherever you placed your .vtf files at. -They also should be named the same thing (for organization's sake).

restart Hammer (or the SDK if need be) and you should be able to find them in the texture browser with ease (use the filter). And that's all there is to it!

The other option is to do this all the old way (my preference), where you need to convert your jpg file into a .tga file then drop it into Vmex.exe in the SDKbin folder, then place it in the folder of your choice, and then write your vmt file. OR you can download a plugin for photoshop here. That will write your vmt file for you.

As you can see, the process is not really all that hard, and you can copy other vmt files to use for your own. There is a lot you can do with this, so have at it!
Blog: www.playingarchitecture.net
LinkedIn: Eric Lancon
Twitter:@Riven202
Re: Converting jpg files in hl2 textures Posted by Le Chief on Fri Nov 14th 2008 at 9:39pm
Le Chief
2605 posts
Posted 2008-11-14 9:39pm
Le Chief
member
2605 posts 937 snarkmarks Registered: Jul 28th 2006 Location: Sydney, Australia
The quickest way is to use VTF Edit and import the jpeg and export it as a vtf file.

Remember, you need a vmt for the vtf if you want it to work, just copy and paste a vmt file for a texture that is similar to yours (eg, if your making a metal texture, copy one of the vmts for a metal texture).

You can stick the vmt and vmf anywhere you like in the materials folder but I'd suggest you stick in in a sub directory that most suits your texture.

edit: Ha ha, Riven got in there before I did :Cry:
Aaron's Stuff
Re: Converting jpg files in hl2 textures Posted by erbetal on Sat Nov 15th 2008 at 2:32am
erbetal
87 posts
Posted 2008-11-15 2:32am
erbetal
member
87 posts 11 snarkmarks Registered: Mar 29th 2008 Location: Canada
lol