Jump to content
  • Advertisement
Sign in to follow this  
AvengingBob

Square vs. Rectangular Textures

This topic is 4384 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

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

Share this post


Link to post
Share on other sites
Advertisement
Guest Anonymous Poster
*bump*

Share this post


Link to post
Share on other sites
Guest Anonymous Poster
because many cards do not support rectanular textures, only squares and ^2

Share this post


Link to post
Share on other sites
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).

Share this post


Link to post
Share on other sites
Guest Anonymous Poster
Uhh, mine doesnt
lots of older and low-end cards are Square Only

Share this post


Link to post
Share on other sites
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.

Share this post


Link to post
Share on other sites
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).

Share this post


Link to post
Share on other sites
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?

Share this post


Link to post
Share on other sites
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.

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!