ideal game texture sizes

A place for Ogre users to discuss non-Ogre subjects with friends from the community.
User avatar
tyan
Halfling
Posts: 63
Joined: Sat Oct 10, 2009 5:44 am
Location: Washington, USA

ideal game texture sizes

Post by tyan »

I am creating a model in blender for a game after mapping the UV image I applied a 2048X2048 texture size. I want to know if this will take to much memory in a game or if i should use a smaller size bitmap.
User avatar
xavier
OGRE Retired Moderator
OGRE Retired Moderator
Posts: 9481
Joined: Fri Feb 18, 2005 2:03 am
Location: Dublin, CA, US
x 22

Re: ideal game texture sizes

Post by xavier »

Smaller by a factor of 4 at least. High res textures in a game usually are in the 512x512 range, and generally smaller textures are used (128 and 256 being relatively common).

2048 is simply insane. Mipmapping will force much lower resolution versions to be used for rendered pixels anyway (you will almost never see the top mip level, and that will be only when you are super close up on your model). So 2048 is essentially wasted space for nothing...and lots of it. 2048x2048 in anything but DXT/BCx compression is 16MB in memory, and even with DXT1 compression, is still roughly 2.3MB.
Do you need help? What have you tried?

Image

Angels can fly because they take themselves lightly.
jjp
Silver Sponsor
Silver Sponsor
Posts: 597
Joined: Sun Jan 07, 2007 11:55 pm
Location: Cologne, Germany
Contact:

Re: ideal game texture sizes

Post by jjp »

One cannot tell what texture size is appropriate without knowing what kind of model you're talking about, from which distance it will be seen and what kind of systems you're targeting.
Enough is never enough.
User avatar
tuan kuranes
OGRE Retired Moderator
OGRE Retired Moderator
Posts: 2653
Joined: Wed Sep 24, 2003 8:07 am
Location: Haute Garonne, France
x 4
Contact:

Re: ideal game texture sizes

Post by tuan kuranes »

A good way to measure that is explained here :
http://http.developer.nvidia.com/GPUGem ... ter28.html
User avatar
tyan
Halfling
Posts: 63
Joined: Sat Oct 10, 2009 5:44 am
Location: Washington, USA

Re: ideal game texture sizes

Post by tyan »

Just creating a low poly first person shooter game model. I have been doing some reading and I now agree that 2048X2048 is indeed insane. I should try 512X512 but i will also experiment with smaller sizes to make sure I am not wasting memory in large texture sizes.
jjp
Silver Sponsor
Silver Sponsor
Posts: 597
Joined: Sun Jan 07, 2007 11:55 pm
Location: Cologne, Germany
Contact:

Re: ideal game texture sizes

Post by jjp »

tyan wrote:Just creating a low poly first person shooter game model. I have been doing some reading and I now agree that 2048X2048 is indeed insane.
For characters or weapons you already find textures of size 2048^2 in Unreal Tournament 2003. Generalizing that a 2048^2 texture for a model would be overkill is just wrong. In some cases it could even be too little.
Enough is never enough.
User avatar
tyan
Halfling
Posts: 63
Joined: Sat Oct 10, 2009 5:44 am
Location: Washington, USA

Re: ideal game texture sizes

Post by tyan »

thanks for the tip :D my teem and I agree that the main character and his weapons (along with other hardware) need to be very detailed because the player will be looking at them all the time. So I will just play around with the sizes until I find one that looks good at the lowest possible memory.
User avatar
Kojack
OGRE Moderator
OGRE Moderator
Posts: 7157
Joined: Sun Jan 25, 2004 7:35 am
Location: Brisbane, Australia
x 538

Re: ideal game texture sizes

Post by Kojack »

For characters or weapons you already find textures of size 2048^2 in Unreal Tournament 2003
That's fine, assuming the character/weapon is so close to the camera that it takes up the entire screen. Otherwise it's a waste (or they really suck at unwrapping models).
User avatar
xavier
OGRE Retired Moderator
OGRE Retired Moderator
Posts: 9481
Joined: Fri Feb 18, 2005 2:03 am
Location: Dublin, CA, US
x 22

Re: ideal game texture sizes

Post by xavier »

tyan wrote:thanks for the tip :D my teem and I agree that the main character and his weapons (along with other hardware) need to be very detailed because the player will be looking at them all the time. .
There is a very good article on this -- Tuan linked it above. Read it and understand it; it seems you have done neither yet.

Bear in mind that your players are not going to be looking at your weapon all the time, unless your game sucks -- they will be looking around the viewport for targets, or at the crosshair in the center of the screen; do you want to spend 16MB of VRAM on that too? ;)
Kojack wrote:
For characters or weapons you already find textures of size 2048^2 in Unreal Tournament 2003
That's fine, assuming the character/weapon is so close to the camera that it takes up the entire screen. Otherwise it's a waste (or they really suck at unwrapping models).

And not just any screen, but one running at least 1920 resolution (picked that because it's common) -- those didn't really exist in any practical fashion in 2003, so I lean towards "waste".

I would be on the fence for a 2048 texture if it's a non-repeated color texture for a terrain -- but even then I'd want the artists to figure out how to hide seams in the terrain with buildings or vegetation, and use smaller textures. Putting that much resolution on a character, when that resolution will never be used, is, like I said at first, insane.
Do you need help? What have you tried?

Image

Angels can fly because they take themselves lightly.
User avatar
Jabberwocky
OGRE Moderator
OGRE Moderator
Posts: 2819
Joined: Mon Mar 05, 2007 11:17 pm
Location: Canada
x 220
Contact:

Re: ideal game texture sizes

Post by Jabberwocky »

I usually tell my artists to create textures larger than I expect to use in game. This way, you should never run into a problem. If I expect to use a 1k by 1k texture in game, I ask for a 2k by 2k texture. It's easy to scale a big texture down. But if the texture is too small, scaling it up never works as well.

Having large textures may come in handy if you want to use the model in an advertisement or marketing material, and have it look as good as possible. (Maybe you render the model in 3dsmax/maya/etc rather than in your game engine for this.) Also, large textures guarantee your model will be useful for a number of years into the future, as graphics cards improve and VRAM increases.
Image
User avatar
xavier
OGRE Retired Moderator
OGRE Retired Moderator
Posts: 9481
Joined: Fri Feb 18, 2005 2:03 am
Location: Dublin, CA, US
x 22

Re: ideal game texture sizes

Post by xavier »

And damn the texture cache...who needs performant code or sensible memory usage, we'll just wait until Intel releases their next chip (it's the Microsoft model). Let them fix it in hardware.

If you couldn't tell, I don't agree with your philosophy.
Do you need help? What have you tried?

Image

Angels can fly because they take themselves lightly.
Vectrex
Ogre Magi
Posts: 1266
Joined: Tue Aug 12, 2003 1:53 am
Location: Melbourne, Australia
x 1
Contact:

Re: ideal game texture sizes

Post by Vectrex »

I don't see why you wouldn't model with the highest texture sizes you can do. The game or the producer/artist should decide on the final used size.
Also I know most people don't have good cards, but the new ones are over a GIG. Which is massively insane. So if you plan to finish your game in a year or two, I'd think ahead.
User avatar
xavier
OGRE Retired Moderator
OGRE Retired Moderator
Posts: 9481
Joined: Fri Feb 18, 2005 2:03 am
Location: Dublin, CA, US
x 22

Re: ideal game texture sizes

Post by xavier »

Again, read the article linked above. It explains why it's pointless.

I really shouldn't have to explain to this crowd why you don't need a 1024x1024 texture for a pair of eyeglasses.
Do you need help? What have you tried?

Image

Angels can fly because they take themselves lightly.
User avatar
mkultra333
Gold Sponsor
Gold Sponsor
Posts: 1894
Joined: Sun Mar 08, 2009 5:25 am
x 116

Re: ideal game texture sizes

Post by mkultra333 »

Just remember that for a really good arrow texture (for a bow and arrow) you'll need at least 1300x960 pixels.
http://au.gamespot.com/features/btg-dai ... p5_01.html
"In theory there is no difference between practice and theory. In practice, there is." - Psychology Textbook.
jjp
Silver Sponsor
Silver Sponsor
Posts: 597
Joined: Sun Jan 07, 2007 11:55 pm
Location: Cologne, Germany
Contact:

Re: ideal game texture sizes

Post by jjp »

Vectrex wrote:I don't see why you wouldn't model with the highest texture sizes you can do. The game or the producer/artist should decide on the final used size.
Time is precious. You don't want to waste it creating details no one will ever see.

While we're at it: a 2048^2 texture should not take up 16MB but only 4MB since one will usually use DXT compression (ok, more like approximately 5.3MB when mip maps are included).
Enough is never enough.
User avatar
Jabberwocky
OGRE Moderator
OGRE Moderator
Posts: 2819
Joined: Mon Mar 05, 2007 11:17 pm
Location: Canada
x 220
Contact:

Re: ideal game texture sizes

Post by Jabberwocky »

xavier wrote:And damn the texture cache...who needs performant code or sensible memory usage, we'll just wait until Intel releases their next chip (it's the Microsoft model). Let them fix it in hardware.

If you couldn't tell, I don't agree with your philosophy.
Feel free to disagree with me, but at least disagree with the point I've made.

Marketing material issue aside, imagine you made a character model in 2005. You made the texture at 512x512, and that's what was used in game at the time. Several years later, you want to reuse the character, with high-res settings on a modern computer. Or maybe it's an indie/hobby project that simply takes years to complete. You wish you had 1024x1024. But you don't. Crap.

The link about mip-maps is a handy resource, thanks for posting it. Still, game screen resolutions have changed from 800x600 to 1600x1280 (on a modern high-end gaming machine) over recent memory, and likely this trend will continue. Also, there are still many instances where you can get the camera close enough to a textured model to easily see the highest mip level. A big dragon, a wall texture, or a planet spherical texture come to mind.

Nobody is suggesting (or at least I'm not) using gigantic textures for eyeglasses or arrows (although that link was an interesting anecdote about non-industry artists). My suggestion was to go up one texture size beyond what you expect to use in game right now. Although it's a fair point that if the art takes significantly longer to create, you may want to reconsider. However, I don't think this is true in all cases.

Scalability and planning for future hardware changes are reasonable considerations here.
Image
jjp
Silver Sponsor
Silver Sponsor
Posts: 597
Joined: Sun Jan 07, 2007 11:55 pm
Location: Cologne, Germany
Contact:

Re: ideal game texture sizes

Post by jjp »

Jabberwocky wrote:Marketing material issue aside, imagine you made a character model in 2005. You made the texture at 512x512, and that's what was used in game at the time. Several years later, you want to reuse the character, with high-res settings on a modern computer.
I certainly disagree with this point. If you want an analogy from programming - compare it to the "you ain't gonna need it" idiom. Spending (significant) extra work because you may reuse a character in a few years is pretty pointless. You rarely are able to plan ahead this far. And then you have to assume that your future project will use the same style of graphics as the current one.
Enough is never enough.
User avatar
wacom
Gnome
Posts: 350
Joined: Sun Feb 10, 2008 2:07 pm

Re: ideal game texture sizes

Post by wacom »

Many artists (and books in this regard) recommend, when working on 1024x1024 textures, to make a 2048x2048 texture. The texture is just prettier when scaled down (with sharpness preserved), and there should be not really more time spent on details, as textures this size aren't drawn pixel by pixel anyway ...

At least it has nothing to with using the texture in five years, because in five years the meshes have far more vertices and the texture no matter which size became obsolete, as you won't use the mesh again. IMHO.
User avatar
Jabberwocky
OGRE Moderator
OGRE Moderator
Posts: 2819
Joined: Mon Mar 05, 2007 11:17 pm
Location: Canada
x 220
Contact:

Re: ideal game texture sizes

Post by Jabberwocky »

jjp wrote:"you ain't gonna need it" idiom. (...) you may reuse a character
You ain't gonna need it doesn't really apply to a situation where you may need it. ;)

As I said above, I agree you should consider the likelyhood of future reuse with the amount of extra effort to make the larger texture. You should talk to your artist about this, and consider the possible lifetime of your art assets.

Another programming analogy is scalability. If your boss tells you to create a server, and you expect about 10000 concurrent connections, you may want to plan ahead for supporting more. Again, it depends on the likelihood vs. the amount of work.

There are some scenarios where creating the larger texture may not be a significant amount of extra work. Say you're creating a tree or wall texture, and you're making use of a databank of bark or stone images. Another scenario - sometimes a lot of the detail in your texture is derived from an AO map, which again is free to generate from a high-poly model at whatever resolution you like.
Image
jjp
Silver Sponsor
Silver Sponsor
Posts: 597
Joined: Sun Jan 07, 2007 11:55 pm
Location: Cologne, Germany
Contact:

Re: ideal game texture sizes

Post by jjp »

Jabberwocky wrote:
jjp wrote:"you ain't gonna need it" idiom. (...) you may reuse a character
You ain't gonna need it doesn't really apply to a situation where you may need it. ;)
I think it does. The idiom says to only do things when you need them done and to not do things when you're unsure about needing them :)

Yes, of course things are different when e.g. a higher texture resolution basically comes for free.
Enough is never enough.
reptor
Ogre Magi
Posts: 1120
Joined: Wed Nov 15, 2006 7:41 pm
Location: Finland
x 5

Re: ideal game texture sizes

Post by reptor »

Reading the post-mortem article of the PC game Operation Flashpoint at gamasutra, one thing the developers of this game regretted was the quality of the graphics at the time of release.

The release of that game got delayed pretty much, I would say, as they lost a publisher (or several publishers?), and perhaps in the mean-time the hardware and techniques how to make graphics moved forward so much that their graphics were not up to the expected standard when they finally released the game.


The game absolutely rocks, still, by the way! I love it.
Vectrex
Ogre Magi
Posts: 1266
Joined: Tue Aug 12, 2003 1:53 am
Location: Melbourne, Australia
x 1
Contact:

Re: ideal game texture sizes

Post by Vectrex »

jjp wrote:
Jabberwocky wrote:
jjp wrote:"you ain't gonna need it" idiom. (...) you may reuse a character
You ain't gonna need it doesn't really apply to a situation where you may need it. ;)
I think it does. The idiom says to only do things when you need them done and to not do things when you're unsure about needing them :)

Yes, of course things are different when e.g. a higher texture resolution basically comes for free.
I find it ironic that on programming threads people are very harsh when someone suggests that their engine is only going to use 2 threads or the like. They usually get told to think about 4 and 8 and 16 core machines. Isn't this art argument exactly the same? Writing a 2 thread engine is simple. Writing a task based engine is way harder, so if the vast majority only have 2 core cpus for the next few years, why bother? Because you can't tell what will happen. Maybe your game takes way longer, maybe in 2 years everyone has 8 core because they became super cheap.. etc
So with art, why wouldn't you model in high mesh and texture res? The thing with art is it isn't much more work. It's not like it's 32x32 pixel art. The work comes in when reducing the mesh to the needed res. But if you just don't bother until the last minute it's the same amount of work (since everything is zbrushed now anyway). Just do a hack mesh reduction job for development and later retopologise them properly. Who knows, in 2 years some tool might come out that does a perfect job of reducing them anyway.
User avatar
mkultra333
Gold Sponsor
Gold Sponsor
Posts: 1894
Joined: Sun Mar 08, 2009 5:25 am
x 116

Re: ideal game texture sizes

Post by mkultra333 »

Looking through Epic's UDK, they suggest 1024x1024 or 2048x2048 main textures. They DXT everything too I think, so the memory is cut by a factor of 4 or 8. They use atlases for small textures.
"In theory there is no difference between practice and theory. In practice, there is." - Psychology Textbook.
User avatar
xavier
OGRE Retired Moderator
OGRE Retired Moderator
Posts: 9481
Joined: Fri Feb 18, 2005 2:03 am
Location: Dublin, CA, US
x 22

Re: ideal game texture sizes

Post by xavier »

mkultra333 wrote:Looking through Epic's UDK, they suggest 1024x1024 or 2048x2048 main textures. They DXT everything too I think, so the memory is cut by a factor of 4 or 8. They use atlases for small textures.
They suggest it for the FPS gun -- not for everything in sight. For the record, I disagree with that suggestion as well; as Kojack mentioned, if you need textures that big you should probably have a performance review with your art team. For something that is going to occupy a fraction of the screen space, 2048x2048 is a waste -- bear in mind that this is an artist telling you that on that Wiki page. :P
Do you need help? What have you tried?

Image

Angels can fly because they take themselves lightly.
User avatar
mkultra333
Gold Sponsor
Gold Sponsor
Posts: 1894
Joined: Sun Mar 08, 2009 5:25 am
x 116

Re: ideal game texture sizes

Post by mkultra333 »

xavier wrote:
mkultra333 wrote:Looking through Epic's UDK, they suggest 1024x1024 or 2048x2048 main textures. They DXT everything too I think, so the memory is cut by a factor of 4 or 8. They use atlases for small textures.
They suggest it for the FPS gun -- not for everything in sight. For the record, I disagree with that suggestion as well; as Kojack mentioned, if you need textures that big you should probably have a performance review with your art team. For something that is going to occupy a fraction of the screen space, 2048x2048 is a waste -- bear in mind that this is an artist telling you that on that Wiki page. :P
I can't remember now where I read the the 1024 or 2048 number, but another page suggests this:
When texturing a character, it's debatable how large to make the texture. Lee Perry of Epic writes: I personally wouldn't bother doing a skin less than 1024x1024 unless you just feel uncomfortable working that large. The UT2004 skins are actually 2 1024x1024 textures. Note that this is in regards to character skins. Static mesh textures should generally be much smaller, especially if the physical models are smaller. On the other hand, you may decide that some geometry demands higher resolution texture. This is a judgement that you'll have to make depending on the model size, the model importance, proximity to the camera, etc. For example, you may decide that the skybox of your world needs to be very high resolution, if the sky is important in giving ambience to your level.

It is recommended that you use DXT1 compression on character textures (if you are using 1024x1024), to avoid eating too much of the available texture memory. This of course limits you, in that you can't use full alpha channels on the model. The generally smaller static mesh textures can come in at DXT3 or DXT5.
http://udn.epicgames.com/Two/UnrealTexturing.html

So (at least for this page) they're using two 1024x1024 textures for player characters, one for the body and one for the head. But they suggest lower resolutions for meshes in the environment unless it is some special feature.
"In theory there is no difference between practice and theory. In practice, there is." - Psychology Textbook.
Post Reply