View Full Version : 3D texture performance
12-12-2003, 08:42 AM
i wanted to know if 3D texture where really slower than others...
i'm doing my some dynamic lightmapping, and i wondered if mapping a single 3D texture wasn't faster than mapping a 1D and a 2D texture...
12-12-2003, 10:07 AM
I had something like 98-99% on NV34/Det50 of 2D texture performance(probably, it is specific to my card)
12-12-2003, 12:37 PM
I wouldn't be terribly surprised if 3D textures weren't as fast as others on modern hardware. However, and this is important, the 3D equivalent of your 2D/1D lookup is much bigger than a 2D and 1D texture. As such, it's a memory vs. performance tradeoff.
12-12-2003, 02:14 PM
As such, it's a memory vs. performance tradeoff.
What tradeoff? If 3D textures are not only slower than using a 2D and 1D AND take up more memory, then there is no tradeoff here. It's just plain bad all the way around.
12-12-2003, 03:30 PM
If 3D textures are not only slower than using a 2D and 1D AND take up more memory, then there is no tradeoff here. It's just plain bad all the way around.
Unless, of course, 1 3D texture access is faster than 1 2D and 1 1D texture access. Which "ayaromenok" reports is true for his NV34.
12-12-2003, 03:31 PM
If you don't need trilinear interpolation don't use 3D textures. They are definately slower. Due to 8 neighbor memory fetches (instead of 4 for bilinear) this should be no wonder for anybody.
If you need to access a 3D array but only require bilinear interpolation, flatten the 3D array, i.e. use a big tiled 2D texture with sub-texture coordinates.
[This message has been edited by Klaus (edited 12-12-2003).]
How do you get 8 neighbors, Klaus? Wouldn't there be 6?
12-12-2003, 10:30 PM
well I did my dynamic lightmapping with 3D texture and compared, and it looks like i've got approximatly the same frame rate than 1D/2D
though, as you said, Korval, there is the huge increase of used memory...
Well now my program support the two ways to do it, so i guess that will be the user's choice =)
for information, what is your card ayaromenok ?
thanks all for your answers
12-14-2003, 11:30 AM
Remember that the 3D texture is used with an hardware extension so perhaps, that the fps will be the same.
For a 2D texture : 64*64 = 4ko
For a 3D textyre : 64*64*64 = 256ko
[This message has been edited by Leyder Dylan (edited 12-14-2003).]
Powered by vBulletin® Version 4.2.0 Copyright © 2013 vBulletin Solutions, Inc. All rights reserved.