PDA

View Full Version : Why rttex files is so big?



mmortall
07-02-2011, 02:19 PM
In RT3DApp size of all images is 991 kb. After packing images in rttex its size become
4 000 kb. Why so big O_o?

I disable mipmap generation but this no helps.
How to decrease image size?

Seth
07-04-2011, 01:02 AM
I checked the RT3DApp bin folder, I didn't see any 4 MB rttex files..?

.rttex is sort of a wrapper that can house many kinds of image types and formats. rtpack attempts to put things in a form that can be directly loaded onto a video surface after zlib decompression without additional conversion - it doesn't keep things in .jpg form. It's more like .png, non-lossy and zlib compressed. (it also supports certain HW extensions like powerVR's texture compression, for iOS only)

If you had a large .jpg, the resulting .rttex could be much bigger than the original .jpg file in the worst case scenario - however, it would load much faster and not actually waste any more video memory during runtime.

But it will be much faster to load.

Irrlicht itself does load .jpg and other formats directly btw, but if you needed the Proton menu system to load raw .jpgs you'd have to write some code for that I guess. (good for say.. a book-app that just wanted to show .jpgs)

mmortall
07-04-2011, 10:24 PM
I checked the RT3DApp bin folder, I didn't see any 4 MB rttex files..?
I means the sum of all rttex files.



If you had a large .jpg, the resulting .rttex could be much bigger than the original .jpg file in the worst case scenario - however, it would load much faster and not actually waste any more video memory during runtime.

But it will be much faster to load.

Aaa, I got this issue. My jpg files become much bigger (30kb -> 200kb).

But if rttex load much faster then jpg it is very good.
May be I will use both jpg and rttex textures for my game.
Thanks for you help.