Jump to content
  • Advertisement

Archived

This topic is now archived and is closed to further replies.

Telamon

Rectangular Textures == Bad?

This topic is 5302 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

Is there any way to use power of two rectangular textures in DirectX without wasting video memory and without assigning weird texture coordinates to all your 3d objects (so as to render a rectangular portion of a square texture)? I''m looking for a general solution, as opposed to graphic card specific extensions. I have a feeling it''s not possible? I hope those DirectX people got some good performance gains out of ditching rectangular textures, because it''s kind of a pain... ---------------------------------------- Let be be finale of seem, seems to me. ---------------------------------------- Shedletsky''s Code Library: Open source projects and demos

Share this post


Link to post
Share on other sites
Advertisement
Guest Anonymous Poster
Who says textures have to be rectangle? That''s right, no one! Only limit is that textures MUST be power of two, so you can create textures like:

16x16
32x16
64x16
32x32
1024x32

and so on... And of course you can pack your tile/sprites into one texture, so that you don''t need to change current texture state so often.

Share this post


Link to post
Share on other sites
There is a CAP that says whether they have to be square or not. Have you checked it? If you want to run on an S3 Savage then you''ll have to deal with it, but if you''re working on anything released in the last 5 years I''d be surprised if it had that limit.

More info:
http://www.drunkenhyena.com/cgi-bin/view_article.pl?article=18

Stay Casual,

Ken
Drunken Hyena

Share this post


Link to post
Share on other sites
Oh...

I seem to remember way back when I was learning DX that one of the main differences between OpenGL and DX was that OpenGL allowed rectangular textures and DX didn''t. But it would seem like I am wrong. Whoops.

----------------------------------------
Let be be finale of seem, seems to me.
----------------------------------------

Shedletsky''s Code Library:

Open source projects and demos

Share this post


Link to post
Share on other sites
quote:
Original post by Telamon
Oh...

I seem to remember way back when I was learning DX that one of the main differences between OpenGL and DX was that OpenGL allowed rectangular textures and DX didn''t. But it would seem like I am wrong. Whoops.



If it was in the earlier days then it''s possible that it was a driver issue. OpenGL drivers were much more mature then so they would expose more functionality than the D3D drivers of the time.

Stay Casual,

Ken
Drunken Hyena

Share this post


Link to post
Share on other sites

  • 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!