Textures in Memory, DXT or Raw?
by Matthew Hoesterey · in Torque X 2D · 11/03/2008 (9:48 am) · 4 replies
Does Torque or XNA convert the texture into some other format such as .dxt? I'm guessing torque coverts everything DXT 1 or 5 so that each 4x4 block is either 64 or 128 bit * 1.33 for the mips. I'm I correct in that assumption or does torque un-compress textures into raw bitmap data?
I'm trying to do memory budgets for my game and am having trouble without this information. Thanks!
I'm trying to do memory budgets for my game and am having trouble without this information. Thanks!
#2
11/04/2008 (4:36 pm)
Sorry I'm not familiar with the content processor settings. Where do I find those?
#3
The more interesting question is how TX or XNA uses the resulting .xnb when they are loaded. When the .xnb contains a DXT the resulting texture is also in this format. For the other cases I am not sure. I suppose that in these cases (NoChange and Color) the texture will be used uncompressed.
Attached a screenshot of how to set content processor options:
11/05/2008 (6:45 am)
You can set what the content pipline should do in Visual Studio. The settings for images are DXT Compressed, NoChange, Color. These three options define what format the resulting .xnb gets. If you specify DXT Comrepssion you will end up with DXT1 or DXT5 - depending on the alpha channel of your image. If you use Color the resulting .xnb is umcompressed. NoChange will leave the format of the image untouched. The more interesting question is how TX or XNA uses the resulting .xnb when they are loaded. When the .xnb contains a DXT the resulting texture is also in this format. For the other cases I am not sure. I suppose that in these cases (NoChange and Color) the texture will be used uncompressed.
Attached a screenshot of how to set content processor options:
#4
I really appreciate the help.
11/05/2008 (11:02 am)
Thanks so much for the info! I'm so happy that the Xnb will convert the resulting texture to DXT after those settings are set. I was getting nervous that I would have to change my design a bit as my characters currently load a ton of anims at 3megs per 1024 I would be cutting it close to my memory budget but since xna uses DXT compression I'm going to be way under my memory budget! I really appreciate the help.
Torque Owner Christian Rousselle
Default Studio Name