Hello,
I am parsing TGA files for my textures and everything works fine.
The issue is when I get to 4096*4096 or 2048*2048 resolution on those images it is very very very slow !
I went into the code and optimized the memory allocation (now there is no waste) but the loading as fast at it can be.
This is my question : Should I read all the file at once in a char array and then parse the array (how can I do it when the TGA is compressed ?) ? Because as of yet I read the header at once and then when it comes to the image's data I read pixel by pixel, I guess this is what makes it slow...
I don't read all the file at once because if there is a lot (lot) of elements to load it would take a lot of memory (at worst twice).
Just a simple question
rXp