TGA Import Error
[color=#888888][font=arial, sans-serif]
[background=rgb(245, 245, 245)]
I have a problem with importing and loading TGA images.
I had this problem initially when I started to use TGA images for textures.
http://www.organicbit.com/closecombat/formats/tga.html
http://tgalib.sourceforge.net/api/r28.html
I believe that tutorial may be old, check the listed resources and try updating your header format to best resemble the examples from the resources.
You can double check by simply printing out the variables to double check what is saved in each variable matches what you have in GIMP. By default, I recommend using 32bit RGBA export settings.
http://www.organicbit.com/closecombat/formats/tga.html
http://tgalib.sourceforge.net/api/r28.html
I believe that tutorial may be old, check the listed resources and try updating your header format to best resemble the examples from the resources.
You can double check by simply printing out the variables to double check what is saved in each variable matches what you have in GIMP. By default, I recommend using 32bit RGBA export settings.
Type 2 is raw data and type 10 is run-length encoded data.
Now you need to handle indexed data, black-and-white data, and true-color data.
Read the TGA specifications to find out how.
L. Spiro
Now you need to handle indexed data, black-and-white data, and true-color data.
Read the TGA specifications to find out how.
L. Spiro
What do you need it for? This is a good opportunity to read the TGA spec and implement a very simple reader that suits your needs.
In my case, some time ago I needed a TGA loader for a simple arcade game. I implemented a simple, small reader that only read 24bit uncompressed images that I had exported from GIMP. Good enough for my needs and I was a better programmer when I finished.
Read the spec, you will learn a lot and you will have a lot more fun because you will have understanding.
In my case, some time ago I needed a TGA loader for a simple arcade game. I implemented a simple, small reader that only read 24bit uncompressed images that I had exported from GIMP. Good enough for my needs and I was a better programmer when I finished.
Read the spec, you will learn a lot and you will have a lot more fun because you will have understanding.
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement