Irregular size textures ?
by Andy Wright · in Artist Corner · 03/23/2009 (5:41 am) · 2 replies
Hi, Im trying to work out why my dif isnt loading ingame, does torque have issues with irregular size textures ? the one in question is 1024x640... or would i have to resize to 1024x512 so its to a power2 size and rescale in constructor?
Or would 11000 surfaces more likely be the issue ?
It compiles to dif ok with no errors... im a lil bit konfuzzled
Or would 11000 surfaces more likely be the issue ?
It compiles to dif ok with no errors... im a lil bit konfuzzled
About the author
#2
1024x640 results in a number that is even (divisible by two) but not a power of two. I can't remember off the top of my head, but there are irregular texture sizes that consist of two numbers that aren't powers of two that multiply out to a power of two. If you don't know any, then sticking with using only powers of two is a sure fire way to end up with a kosher texture size. 64x32 works, 1024x128 works etc.
-Dan
03/23/2009 (8:48 am)
You can have irregular texture sizes, but they must also multiply to a power of two. The reason people recommend using 1024x512 and 1024x1024 is that multiplying a number that is a power of two by another number that is a power of two will always result in a number that is a power of two. You can't reduce the number 640 to a bunch of 2x2x2x2x2x2.... etc. eventually, it has a five.1024x640 results in a number that is even (divisible by two) but not a power of two. I can't remember off the top of my head, but there are irregular texture sizes that consist of two numbers that aren't powers of two that multiply out to a power of two. If you don't know any, then sticking with using only powers of two is a sure fire way to end up with a kosher texture size. 64x32 works, 1024x128 works etc.
-Dan
Torque 3D Owner Andy Wright
BrokeAss Games