CGTalk > Technical > Graphics Programming
Login register
Thread Closed share thread « Previous Thread | Next Thread »  
Thread Tools Search this Thread Display Modes
Old 10-27-2003, 12:47 PM   #1
Lord of the posts
TheWriter's Avatar
Toby G.
Join Date: Mar 2002
Posts: 807
Texture Memory

Assume I have a plane with a 256x256 sized texture on it.

Now, I duplicate the plane, but use a 256x128 texture on it, but tile it two fold to make up the rez.

My question is, do both systems occupy the same amount of texture memory? Im tempted to think the 2n'd situation has some savings, but will cost more in speed?
Five sided polys suck...
Old 10-27-2003, 05:21 PM   #2
Ash Henstock
New Member
Join Date: Jul 2003
Posts: 5
Send a message via ICQ to Ash Henstock
The second option will use less video memory.

When you request for a polygon to be drawn it will first be transformed by the current modelling and perspective matrices and then be drawn to the framebuffer. The framebuffer resides in video memory and aswell as storing colour information at each fragment (each 'pixel' in the framebuffer is referred to as a fragment) it stores information such as depth buffer and stencil buffer values. The relevence of this to your question is that no matter what area the texture will be mapped to in the colour buffer the size of the texture used in the mapping does not effect the framebuffer size (this is dependent on the screen resolution and buffer bitdepths). As the texel data is stored as a regular array in video memory, the smaller texture should use less memory.

As far as the impact on rendering performance I would say it would probably result in a speed up, although it's really down to a number of implementation specific details. The fact is though that the smaller texture has a smaller memory footprint and so can be copied into memory faster (important especially if you are doing a lot of texture swapping) and is more likely to fit into any cache your board might have.

Hope that makes sense
Old 10-27-2003, 05:28 PM   #3
Lord of the posts
TheWriter's Avatar
Toby G.
Join Date: Mar 2002
Posts: 807
Ok I can relate to that. I just figured that since a tile needs to be tiled about.. it required more gpu cycles for extra calculations and may slow things down but I guess other speed increses make up for it.
Five sided polys suck...
Old 11-06-2003, 03:16 PM   #4
Erik Jackman
Crestron Programmer
Join Date: Oct 2003
Posts: 429
You may want to add some error checking and a spare 256x256 just in case the program is run on a machine with a graphics card or chip that can not handle irregular dimensioned sized textures.
"Game developers are like simple chemicals. (No, not because they're cheap and smelly.) In the right combination, they can make miracles. Screw up the mix, and you can blow up a city." - How to Screw Up a Perfectly Good Game Company in Ten Easy Steps,
Old 11-06-2003, 10:40 PM   #5
DaKrunch's Avatar
Davide Pesare
Artist wrangler
Pixar Animation Studios
San Francisco, USA
Join Date: Apr 2002
Posts: 365
in such cases you might consider putting 2 textures in the same file.
But those textures will be able to be seamless only in one direction.
Davide Pesare

There are only 10 types of people in the world those who understand trinary, those who don't, and those who mistake it for binary.
Old 01-16-2006, 01:00 PM   #6
CGTalk Moderation
CGTalk Forum Leader
Join Date: Sep 2003
Posts: 1,066,478
Thread automatically closed

This thread has been automatically closed as it remained inactive for 12 months. If you wish to continue the discussion, please create a new thread in the appropriate forum.
CGTalk Policy/Legalities
Note that as CGTalk Members, you agree to the terms and conditions of using this website.
Thread Closed share thread

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Society of Digital Artists

Powered by vBulletin
Copyright 2000 - 2006,
Jelsoft Enterprises Ltd.
Minimize Ads
Forum Jump

All times are GMT. The time now is 07:07 AM.

Powered by vBulletin
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.