memory reduction....
memory reduction....
hi,
I have asked similar questions before but this is a final one...i am doing a virtual walkthrough and i use lightmaps. What im facing is the huge memory needs of my app..
I am disabling mipmaps....for gettting some relief..
My question is if i use jpeg or such 24bit formats...will the texture made will also be 24 bit....or they reserve something for alpha??
I have asked similar questions before but this is a final one...i am doing a virtual walkthrough and i use lightmaps. What im facing is the huge memory needs of my app..
I am disabling mipmaps....for gettting some relief..
My question is if i use jpeg or such 24bit formats...will the texture made will also be 24 bit....or they reserve something for alpha??
skumar
Thanx for the help....
I am using Lightmaps....i dont need any alpha information in that anyway.So if i can represent it as 24bit information i can save a lot of memory. One arch model may contain more than 10 1024x1024 textures...
16bits will surely degrade the quality...so what i want is ...i want my tex to represented as RGB and no A
I am using Lightmaps....i dont need any alpha information in that anyway.So if i can represent it as 24bit information i can save a lot of memory. One arch model may contain more than 10 1024x1024 textures...
16bits will surely degrade the quality...so what i want is ...i want my tex to represented as RGB and no A
skumar
I have done a small test ....
I made a simple plane(2 triangle) textured it using a 104*1024 tex(jpg) and loaded into the mesh viewer....
Empty meshviewer meme = 4520k
Untexture plane loaded = 4568k
Textured plane = 13256k
****************************
On paper the 1024 x 1024 tex need 4 MB and after mipmapping....
~5.33MB
What is this 8716k footprint....???
Or im i doing a bad experiment....?????
I made a simple plane(2 triangle) textured it using a 104*1024 tex(jpg) and loaded into the mesh viewer....
Empty meshviewer meme = 4520k
Untexture plane loaded = 4568k
Textured plane = 13256k
****************************
On paper the 1024 x 1024 tex need 4 MB and after mipmapping....
~5.33MB
What is this 8716k footprint....???
Or im i doing a bad experiment....?????
skumar
-
hybrid
- Admin
- Posts: 14143
- Joined: Wed Apr 19, 2006 9:20 pm
- Location: Oldenburg(Oldb), Germany
- Contact:
The software renderer has completely different memory usage than the other drivers. And I don't think that it will work without GPU mem.
Textures are not refcounted because you can assign them manually to the materials (using assignment to the pointer member). So you'd have to do the refcounting on your own. Which makes it somewhat absurd.
Textures are not refcounted because you can assign them manually to the materials (using assignment to the pointer member). So you'd have to do the refcounting on your own. Which makes it somewhat absurd.
Hmm you are right but ressourcemanagment is a important for apps which change their drawn content permanently. Killing everything results often in crashes and/or long reloadtimes. May be the materials could be changed to class (or a struct with private ITexture) using a set for textures? Or do you have a good idea how to deal with unused ressources?
We could add a setTexture method to SMaterial struct, but we'd also have to eliminate any material copying within the engine.
Thinking about it, we could use a setTexture method to abstract away the stage numbers and replace them with an enumeration. This may increase the size of material struct but it would allow Irrlicht to understand the meaning of a texture slot and choose from a number of internal renderers.
Thinking about it, we could use a setTexture method to abstract away the stage numbers and replace them with an enumeration. This may increase the size of material struct but it would allow Irrlicht to understand the meaning of a texture slot and choose from a number of internal renderers.