Take the 2-minute tour ×
Game Development Stack Exchange is a question and answer site for professional and independent game developers. It's 100% free, no registration required.

I assume that when texturing environments, one or several textures will be used, and the UVs of the environment geometry will likely overlap on these textures, so that e.g. a tiling brick texture can be used by many parts of the environment, rather than UV unwrapping the entire thing, and having several areas of the texture be identical. If my assumption is wrong, please let me know!

Now, when thinking about baking lighting, clearly this can't be done the same way - lighting in general will be unique to every face so the environment must be UV unwrapped without overlap, and lighting must be baked onto unique areas of one or several textures, to give each surface its own texture space to store its lighting.

My questions are:

  1. Have I got this wrong? If so, how?
  2. Isn't baking lighting going to use a lot of texture space?
  3. Will the geometry need two UV sets, one used for the colour/normal texture and one for the lighting texture?
  4. Anything else you'd like to add? :)
share|improve this question

1 Answer 1

up vote 8 down vote accepted
  1. I think you are right. You would really like to tile your bricks, because it saves a lot of memory space and is also quick in your GPU. Baking the lighting does need a unique texturing, because no place is the same. You could tile some parts of your texture, for example, on really straight long places. (I'm no UV wrapper, but I do think that is possible to tile just parts, right?)

  2. Yes, baking lighting uses texture space, but you could use different LOD's (level of detail's) to create your lighting. For instance, you could choose to just create a low-quality image as your baked lightmap.

  3. Yes, you will need two UV sets, because this is way better than baking your tiled bricks into the lighting map as well. UV maps are just a matter of asking what the coordinates are (which is fast), so storing an extra UV maps isn't that much of a burden.

  4. Shouldn't know what to add. It seems very clear. Just create 2 UV maps and create a lightmap if you want. It is always faster than casting realtime shadows.

share|improve this answer
2  
+1 for low-res lightmaps. Lightmaps can be surprisingly low-res while providing acceptable appearance, as long as the base texture looks good. –  ggambett Jan 17 '11 at 20:23
    
The only thing I'd add is that "baked lighting" can also (used to?) refer to baking the lighting data into the vertex attributes, which is lighter memory-wise than a lightmap, but obviously looks much worse. –  user744 Jan 17 '11 at 22:10
    
@Joe Wreschnig: True. Per vertex lighting almost all the time worse than per pixel lighting. –  Marnix Jan 17 '11 at 22:13
    
Well answered, that's confirmed a lot of stuff to me :) Thanks! –  Ben Hymers Jan 19 '11 at 19:37

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.