Square vs. Rectangular Textures

Started by
11 comments, last by JohnBolton 17 years, 9 months ago
Hey, a quick question from an artist. I know you can load rectangular and square textures equally easy (provided they are power of two in dimensions). The thing that puzzles me is why the majority of game source art I've seen uses square instead of rectangular textures (i.e., the textures for Quake, Doom, Half-Life, etc,). Is there a particular reason this is done? I'd like to know, because our coder has been complaining about wasted space in our maps, and has suggested using a rectangular texture to save save. Thoughts? -AvengingBob
Advertisement
*bump*
because many cards do not support rectanular textures, only squares and ^2
I think that all 3D cards can do rectangular power of 2 textures, even a PS2 can...
IMHO, it's just an habit, when artists create texture they first create a square one and don't necessary change for rectangular afterward (they would have to remap 3D objet(s) by changing the texture).
Uhh, mine doesnt
lots of older and low-end cards are Square Only
I never wrote a software rasterizer, but I'm pretty sure that there are operations done faster if the texture is a power-of-two square.
Don't remember wich operation though...
On older card this lead to that standard, today it doesn't matter anymore.
AFAIK, square power of two textures are used to texture 3D objects and rectangular or non power of two textures are used to do the GUI and the HUD. That's because rectangular textures have many limitations, like no mip-mapping and no repeat mode (at least in OpenGL).
deathkrushPS3/Xbox360 Graphics Programmer, Mass Media.Completed Projects: Stuntman Ignition (PS3), Saints Row 2 (PS3), Darksiders(PS3, 360)
Quote:Original post by deathkrush
That's because rectangular textures have many limitations, like no mip-mapping and no repeat mode (at least in OpenGL).
Ehm, do you have a source for this claim? Because I have none of such problems.
Are you sure you aren't confusing non-square with non-power-of-2?

Like I said, the limitations are for OpenGL, according to this Nvidia extention and this ARB extension. Maybe the newest cards don't have these limitations? But still, using rectangular textures for texturing 3D geometry sounds like a bad idea to me.
deathkrushPS3/Xbox360 Graphics Programmer, Mass Media.Completed Projects: Stuntman Ignition (PS3), Saints Row 2 (PS3), Darksiders(PS3, 360)
There should be no problems at all with rectangular textures, as long as the sides are a power of 2 in length. The extension allows non power of 2 textures. For all I know there may have been cards that required square textures, but if there are then I guess they don't fully support opengl 1.0 (and would be pretty darn old).

As for why it isn't done, I don't know, but I saw it done in unreal.
___________________________________________________David OlsenIf I've helped you, please vote for PigeonGrape!

This topic is closed to new replies.

Advertisement