Welcome to the Second Life Forums Archive

These forums are CLOSED. Please visit the new forums HERE

Texture pixel size to prim size ratio?

Cliona Morellet
Registered User
Join date: 4 Jul 2006
Posts: 12
10-09-2006 11:01
I was just wondering if anyone has figuring out a ratio for making the texture look the best.

For instance:

Lets say I have a texture with a window on it and I want to put it on my shop front. I've made my 'wall' 5m high by 10 m long. Would a 256 x 512 texture look better than a 512 x 512 or 256x256? Or would perhaps a 512 x 1024 texture look better on my 5x10 wall?

If no one has figured this out, I might have to have a little experiment next time the game is up and running.
Chosen Few
Alpha Channel Slave
Join date: 16 Jan 2004
Posts: 7,496
10-09-2006 11:40
There's absolutely no correlation between pixels and prim size. They're not related in any way, shape, or form. Prims don't even really have "size" per se; meters and such are completely imaginary, only there to give human users some sense of correlation between what they think they're seeing on screen, and what they think they know about how a world works.

To illustrate what I'm talking about, try this. Rez a cube, and size it to 1x1x1. Zoom all the way out as far as the camera will go. That 1-meter cube is now just a few pixels wide. Now zoom in all the way so the cube fills the screen. If you've got an average size monitor, that same cube is now well over a thousand pixels wide, but it's still just one meter. Again, pixels have nothing to do with size in 3D.

The question you should be asking is not how many pixels should the texture be if my wall is ____ meters wide, but how many pixels on the average screen is that wall likely to occupy. If it's something people are likely to zoom in on and examine closely, then use a large texture. If it's something that's not likely to take much screen space, use a smaller one.

In any case, there's rarely any reason to go bigger than 256x256. That's more than enough room for detail in most cases.

Remember, the bigger the texture, the more memory and processing power it requires in order to be displayed. Every 1024x1024 uses 3 or 4 megabytes of texture memory while every 256x256 uses only 192 or 256 kilobytes. The biggest reason SL is so ungodly slow is because people constantly use textures that are too big, and they overwhelm your video card. When you look at a typical scene in SL, you're looking at gigabytes worth of textures while your poor little video card can only handle up to a few hundred megabytes at the most.

Always go as small as possible with textures. I usually recommend to people that about 80% of your textures should be 256x256 or smaller, about 15% should be 512x512, and about 5% or less should be 1024x1024. If everyone followed that rule, SL would be a much healthier place.
_____________________
.

Land now available for rent in Indigo. Low rates. Quiet, low-lag mainland sim with good neighbors. IM me in-world if you're interested.
Ceera Murakami
Texture Artist / Builder
Join date: 9 Sep 2005
Posts: 7,750
10-09-2006 12:43
The one thing I would add to what Chosen said is to use the aspect ratio that is the closest to what your prim shape will be, while still being a 'power of 2 multiple'. So for your 5 M high by 10M wide wall, a 256 x 512 texture would be more appropriate than a 512 x 512 would be.

If you were going to use the same texture for an 5 M high x 8 M wide wall, I would still stick with 256 x 512.

If something that will be on that wall texture needs to retain precise aspect ratios, then design the texture to the exact aspect ratio that you need, and then resize it to the most appropriate power of 2 multiple in each direction. For example a texture for an alpha-mapped round window, if designed at 256 x 512 and applied to a 5 M x 8 M wall, would be an oval in-world. Designing it at 500 pixels by 800 pixels, and then resizing that to 256 x 512 will give a texture that looks oval the other way if placed on a 5M x 10 M wall, but will be perfectly round when placed on your 5M x 8 M wall.
_____________________
Sorry, LL won't let me tell you where I sell my textures and where I offer my services as a sim builder. Ask me in-world.
Cliona Morellet
Registered User
Join date: 4 Jul 2006
Posts: 12
10-09-2006 20:01
Sweet. Thanks for the advice.