working with only one 1024x1024 texture. Is it a good idea?

Started by
9 comments, last by Mari_p 20 years, 3 months ago
Hi, I''m using sixteen 256x256 textures. To avoid texture switches, do you recommend to put them into one 1024x1024 texture? My card supports until 2048x2048 format. Thanks.
Advertisement
Sure.
No problem. The voodoo cards only supported 256x256 but starting with the old TNT card all cards support 2048x2048. The exception is I think the Kyro which only supports 1024x1024.
but then you can''t do texture wrapping, and with mipmapping, two textures that lay next to each other may blend

My Site
Thanks for the replies.
My card is a TNT2. Some of my textures have a alpha channel (TGA 32 bits). The others are BMP.
I intend to use only one 1024x1024 TGA texture. Can my fps decrease?
I''m guessing that since you''ll be doing less texture changes if any at all that your fps can only go up from here. Texture changes are something that you''d ideally want to keep to minimum and zero changes is definitely a minimum.

Other than that I don''t think much else will affect your program''s performance. But then again, I don''t know how much improvement you''ll see either. 16 texture changes vs no texture changes probably isn''t that huge of a difference.
-out
According to the DirectX documentation though, 256x256 textures are the fastest (I''d expect this as well, because they align on bits the best).

I''d only use larger textures to AVOID having to split up larger images... ie. don''t bother splitting a 512x512 image into 4 tiles in the modern day-and-age, but don''t artificially inflate your texture sizes. "SetTexture" commands are plenty-fast enough if they are correctly batched.
Combining textures into a larger page can save more than just SetTexture switches. Far more importantly it makes it easier to get larger batches per DrawPrimitive call.

And while it is documented that 256x256 are the fastest, I haven''t seen anything measurable to back that up (at least as it applies to this topic). I have definitely seen performance increases from reducing SetTextures (slight) and from making bigger batches (significant).


Stay Casual,

Ken
Drunken Hyena
Stay Casual,KenDrunken Hyena
yes, i''m doing similar thing with my game engine, i mostly use 512x512 texture, for cleaner/simplier SetTexture & DrawPrimitive batching, very good in static VB objects.
quote:Original post by DrunkenHyena
Combining textures into a larger page can save more than just SetTexture switches. Far more importantly it makes it easier to get larger batches per DrawPrimitive call.

And while it is documented that 256x256 are the fastest, I haven''t seen anything measurable to back that up (at least as it applies to this topic). I have definitely seen performance increases from reducing SetTextures (slight) and from making bigger batches (significant).


Stay Casual,

Ken
Drunken Hyena



Depends what you are doing, texture caches on GPU''s are pretty tiny so if you access them in some random way you will notice huge perf differences between texture sizes. Any easy way to see this is to do enviroment mapping - the size of the enviroment map makes a big difference in perf.

Basically, the only way to know is to try.
EvilDecl81

This topic is closed to new replies.

Advertisement