Home Technical Talk

how to unwrap uv's for lightmaping purposes?

polycounter lvl 10
Offline / Send Message
boyluya polycounter lvl 10
How to unwrap uv's for lightmaping purposes? And what are the restrictions? Is it fine if I just use auto-uv and call it done? Thanks. :poly121:

Replies

  • Ben Apuna
    Options
    Offline / Send Message
    If you asking about light mapping for UDK/UT3 check this post out. And generally speaking "No" you won't get good results with auto unwrapping and calling it done.

    EDIT:

    Also it's a good idea to keep light map resolutions as small as possible. With instancing each individual mesh gets it's own light map texture so in a level/environment all those textures can add up fast.
  • SHEPEIRO
    Options
    Offline / Send Message
    SHEPEIRO polycounter lvl 17
    bens link has some good info info, generally i used exactly the same techniques, if you had a good tpage for an object already then its dead easy just get rid of any layered or mirrored parts

    one thing ive found very usefull is the softening or hardening of edges by using lightmap seams....the lightmap wont be filtered across these so if you want a propper hard edge split the uvs here, but conversly not spliting them will kind of give you the effect of a chamfered edge (width depending on texel size) which is also very usefull... if your using directional lightmaps then the normal maps will also have an effect here.

    going on from bens statement to keep the lightmap reses as small as possible, if in your chosen engine you have the ability to give each instance an independant res (ive used one like this very usefull, packed all instances of an object into 1 lightmap with uv offsets) you can then reduce the size of instances that are in complete shadow etc to save space. this is also true of unique meshes, you will need more resoloution where strong changes of light exsist, like the entrance of a cave compared to the deep interior, sometimes you can do a nice soft selection on your mesh to exentuate the space used by the entrance and squeeze the interior into a much smaller space...
  • sama.van
    Options
    Offline / Send Message
    sama.van polycounter lvl 14
    About lightmap, auto uvs is not really the best way....

    Try to attach wall together, also floor and ceiling if you can....

    Try to work with instanced object as far you can, creating the 2nd uv set too.
    When starting the lightmap, you can do a Uvs layout playing with parameters, and it will create right space between the uvs parts.

    Lightmap size depends of the size of your level.

    Here is an example for iphone, I am still using a 1024x1024px lightmap for the full level :

    http://samavan.deviantart.com/art/iPhone-Shuriken-Game-2-145376053
  • Ged
    Options
    Offline / Send Message
    Ged interpolator
    SHEPEIRO wrote: »
    one thing ive found very usefull is the softening or hardening of edges by using lightmap seams....the lightmap wont be filtered across these so if you want a propper hard edge split the uvs here, but conversly not spliting them will kind of give you the effect of a chamfered edge (width depending on texel size) which is also very usefull... if your using directional lightmaps then the normal maps will also have an effect here.

    interesting tip Shepeiro do you think splitting my uvs on my pillar in this scene: http://boards.polycount.net/showthread.php?t=71419&page=3&highlight=syndicate will fix the wierd shadowing( at the moment it looks like the shadows are trying to make the square pillar rounded/smooth) or is this a smoothing groups issue carried over from max?
  • boyluya
    Options
    Offline / Send Message
    boyluya polycounter lvl 10
    Thanks for the help guys. Actually, it's just solo props (vehicles, weapons, etc) that I'm planning to render inside udk. Do I have to unwrap another uv's for lightmaping? Thanks.
  • Gilgamesh
    Options
    Offline / Send Message
    Gilgamesh polycounter lvl 12
    For static things (non-first person and non-moving) you will need a second UV set for lightmapping but for dynamic objects (weapons/vehicles) will usually be lit dynamically meaning that no second UV set will be needed.
  • Xoliul
    Options
    Offline / Send Message
    Xoliul polycounter lvl 14
    I'd never do it for solo stuff. Especially not vehicles and weapons, since those are almost always dynamic. It's more work to unwrap and tends to look worse than dynamic. though with lightmass that's arguably different, it still takes more work.
    But if you'd place your dynamic object in a map (not just in viewer), you can get better ambient if you use lightmass and an importancevolume (it does some sort of cubemapped IBL with ambient nodes).
  • r_fletch_r
    Options
    Offline / Send Message
    r_fletch_r polycounter lvl 9
    thats really clever. kinda like voxels but each one represents the average ambient light per grid unit.
    http://udn.epicgames.com/Three/Lightmass.html#Character lighting
Sign In or Register to comment.