Home Technical Talk

Question on Light Maps and Vertex Lighting

Hi new guy here. I thought I knew lowpoly but I guess not. And most of the time I do a search of the term in question polycount pops up, so i decided to join. I just want a clear understanding to these:

What exactly is vertex lighting? Is it the same with vertex coloring? Could someone at least point me to a tutorial or something coz the only thing I found is the one from Bobo
http://www.bobotheseal.com/tuts_vertex_bake01.htm
If you guys know any other one besides this please do share (either Maya or Max) Thank you :)

Another one is Light Maps. Is this different from AO maps? because maybe I'm just searching the wrong terms. (I might misunderstood this but..) Is it possible to light up a scene with only a light map (no scene lights)?

I'm trying to learn these stuff for making iPhone game assets. But apparently I don't understand the whole low poly game asset process enough... yet. Thank You.

Replies

  • MoP
    Options
    Offline / Send Message
    MoP polycounter lvl 18
    Yes, vertex lighting is just a method of baking lighting values into the vertex colour information of any given geometry.
    As a result the quality varies hugely depending on the complexity and topology of your mesh. For example, long thin triangles with different vertex colour values at each point of the triangle will look bad because it will make it very obvious where the triangle is.

    "AO maps" are just a very specific type of light map - all a light map is, is the lighting/shadowing information of your scene baked down into a texture. If you only have a global (sky) light, and no directional/point lights, then all you will get is ambient occlusion since there is no direct light.
    You can get more technical with stuff like directional light maps where the normals are taken into into account, but for iPhone game assets using basic light maps or vertex colour is going to be fine.

    With either of these techniques it is possible to light an entire scene with no dynamic lights in the engine (although obviously this lighting will be completely static and pre-baked) ... to do this, just set up your lighting and scene in your modelling application (eg Max or Maya) and then use the tools to bake the lighting information into the geometry (for vertex colouring) or into a texture (for this to work well you'll need to unwrap the UVs for the entire scene onto a unique UV channel, otherwise you may get overlaps or artifacts when baking the lightmap).
  • Baki
    Options
    Offline / Send Message
    Thanks MoP.
    Sorry if my follow up questions are noobish.

    "As a result the quality varies hugely depending on the complexity and topology of your mesh."
    - By this you mean the quality of vertex lighting would highly depend on the number of vertex you have on a a given mesh? Wouldn't this idea be a contradiction, since you will be using them for low poly mesh having low vertex count?

    "long thin triangles with different vertex colour values at each point of the triangle will look bad because it will make it very obvious where the triangle is."
    - Correct me if I'm wrong, it is much more recommended to have all points of the triangle have the same vertex colour.

    On Light maps, so I need to treat it like baking an AO map only with your own lighting setup.

    "or into a texture (for this to work well you'll need to unwrap the UVs for the entire scene onto a unique UV channel"
    -I'm trying to use this technique from Ben Mathis called thirding (http://www.poopinmymouth.com/process/tips/thirding.jpg) in the diffuse map since it gives a significant boost in texture quality without having a higher size map. However if I use a Light Map this thirding technique would (most probably) cause artifacts. Or is there a technique out there to make this two work together? If not then, would it be much better to have a mesh with light map but with low texture quality or the one without a light map but greater texture quality?
  • cman2k
    Options
    Offline / Send Message
    cman2k polycounter lvl 17
    It may seem like a contradiction, but adding 20 more triangles to a mesh will always be WAY cheaper than having a dynamic light, especially on a mobile device. The intent here is not to make all of your geometry subdivided or higher resolution, it's to only add geometry where you really need it (for example, where you may want more geo on the floor specifically where a shadow falls).

    If all points of a triangle have the same color, and all triangles touch each other, than all of the vertices would have the same color...? You have to have a break somewhere, and ideally that break would be where a shadow is supposed to fall or lighting should realistically change. You just need to make sure you support that, rather than work against it.

    You should be able to use thirding, because traditionally lightmaps are not combined with your standard diffuse textures, they are stored seperately and use an entirely DIFFERENT UV channel. You need to learn how to use a 2nd UV channel, how to unwrap a 2nd UV channel without screwing up your first one, how to render-to-texture with a 2nd uv channel, etc. 2nd UVs for lightmaps will need every face to be unique and non-overlapping in 0 to 1 UV space, while your first channel can overlap, use thirding, etc.

    As always for some more info, Check the Polycount wiki!
  • Jet_Pilot
    Options
    Offline / Send Message
    Jet_Pilot polycounter lvl 10
    Mop hit the nail on the head.
  • Baki
    Options
    Offline / Send Message
    Wow thank you a lot cman2k! This is actually the first time I heard that you can have a 2nd UV and I didn't even know there was a polycount wiki ><;;
    I just do this as a hobby but I love it so much I just want to learn more about it.
    Again Thank you :D
Sign In or Register to comment.