View Full Version : Whats your opinion on TGA's? Help please
12-20-2002, 02:43 PM
I'm writing a TGA/JPG/RAW texturing class to work with my loaded BSP maps. The BSP format (the quake 3 map format) textures items using TGA's and JPEG's. (I'm throwing raw in for good measure) My question is this: Do I need to implement black and white, along with color mapped TGA's into my texture code? I read the TGA specification like 20 times and I still don't understand how color mapping TGA's works, or the exact format for black and white tga's.
Does the bsp format use TGA's that are always true color? Gamedev.net wrote a bsp loader and they only load true color tga's. Does this seem reasonable?
Thank you for your time.
12-20-2002, 09:38 PM
my honest advice would be to dodge these issues entirely by using a more standard library to handle image loading and saving. that way, you'll have support for every image file type you'll ever need, and you can be reasonably certain the code works (since it's probably been thoroughly tested). further, you can spend your time on more important (and fun) graphics programming pursuits.
i recommend DevIL (the Developer's Image Library), which you can find at http://openil.sourceforge.net. it might seem like a lot more than you're looking for, but it's actually easy to use and is very well documented.
to answer your question though, i imagine that standard color images and perhaps grayscale images would be all you'd need. i don't think anyone uses color mapped images for anything anymore (though i could be wrong).
12-21-2002, 07:03 PM
I'm a bit discouraged, my tga loader WILL NOT LOAD this one tga and I dont know why... its a supported format of my loader too (and I've tried converting it to other formats). It successfully loads the 25 before it and then the program just infinately hangs on the 26th image. Any ideas?
12-21-2002, 07:29 PM
Ok I found the problem with my tga loader. It was a problem with the run length compression. I used the same decompression scheme as gamedev.net but I really don't understand run length compression. I understand the concept behind it but not how it is implemented into tga's.
01-02-2003, 07:46 AM
31337 it seems like you are taking on too much at one time. Rather than try to re-create quake, try something a little easier. I've seen a few of your topics and you are trying to write a quake 3 bsp loader/renderer and can't load images yet? Get to understand the code first.
Powered by vBulletin® Version 4.2.2 Copyright © 2014 vBulletin Solutions, Inc. All rights reserved.