Home Technical Talk

How to create Point Light Maps?

I was reading up on the texture guide for the Dota 2 characters and the one technique I have never tried was creating Point Light Maps. Question is how :) ? I read them saying about using point lights and rendering the scene, but if anyone has any tips about the best way to go about it, I would appreciate it.

Replies

  • Quack!
    Offline / Send Message
    Quack! polycounter lvl 17
    Max, Maya, ???
  • McBradd
    Offline / Send Message
    McBradd polycounter lvl 12
    I had the same question after reading through their character texture guide.

    I work in Maya, but once I've got my High and Low poly models ready for texturing, I usually start by baking out Normal and AO maps in xNormal. I've had much better results there than using Maya's 'Transfer maps.'

    Using Maya to render out a Point Light Map, as in the guide, would you just use the transfer maps tool and use the Shaded map option? I assigned a default blinn to my High-poly model and baked it out. The results were ok, but not nearly as crisp and detailed as the example map. Is there a better way to do this?
  • couchcommando
    McBradd wrote: »
    I had the same question after reading through their character texture guide.

    I work in Maya, but once I've got my High and Low poly models ready for texturing, I usually start by baking out Normal and AO maps in xNormal. I've had much better results there than using Maya's 'Transfer maps.'

    Using Maya to render out a Point Light Map, as in the guide, would you just use the transfer maps tool and use the Shaded map option? I assigned a default blinn to my High-poly model and baked it out. The results were ok, but not nearly as crisp and detailed as the example map. Is there a better way to do this?

    ^ this
  • krazypoe
    Also looking for an answer to this!

    Does it have a different name?

    I managed to find something maybe related to this?

    http://cg.tutsplus.com/tutorials/autodesk-maya/baking-ambient-occlusion-color-and-light-maps-in-maya-using-mentalray-3/
  • McBradd
    Offline / Send Message
    McBradd polycounter lvl 12
    @couchcommando - Do you mean 'This' is how to do it, or 'This' is what I also want to know?

    @krazypoe - That link is fine for baking in general, but the main point here is how to bake high-poly information (Normals, Ambient Occlusion, and Light Maps) onto your low-poly geometry with a high level of fidelity.

    I've asked this question in the Steam forums as well. I think I may shoot off an email to valve if no one seems to have a solid answer...
  • throttlekitty
    Do you have pics to show how much difference you're looking at? I've made many lightbakes with generally no issues. It can tend to highlight facets if the high poly isn't that high.
  • McBradd
    Offline / Send Message
    McBradd polycounter lvl 12
    I can post some examples after work tonight... mostly I'm just asking if this is the correct workflow, or is there a better approach?
  • r_fletch_r
    Offline / Send Message
    r_fletch_r polycounter lvl 9
    Any light baking tutorial for maya should cover this all fine.
  • Pangahas
    Offline / Send Message
    Pangahas polycounter lvl 10
    is it the same as setting up a dome lighting rig and baking out the lighting info?
  • Neox
    Offline / Send Message
    Neox veteran polycounter
    If you want to render it out quick. apply the baked normals to the lowpoly light it and bake that. you don't need project the highpoly for that
  • krazypoe
    Neox wrote: »
    If you want to render it out quick. apply the baked normals to the lowpoly light it and bake that. you don't need project the highpoly for that

    In maya, what should we bake it as?
  • McBradd
    Offline / Send Message
    McBradd polycounter lvl 12
    @throttlekitty- Sorry I didn't get a chance to upload some images. I'm looking more for workflow suggestions than a specific texture critique. I think the Sculpted hair on the example model may just be giving me the impression that something 'extra' was done beyond just a light-bake.

    2xbuvbe7yt-PointLightMap.jpg

    @r_fletch_r- I use light bakes in my everyday work at the studio, I'm looking for ways to improve the quality of them over the basic 'Transfer Maps' method. In the same way that you can generate a normal map with a variety of methods and tools (Transfer Maps, Positive/Negative colored lighting, xNormal, Crazybump, nDo, nVidia Photoshop filters, etc...) I'd like to know if there are any specific tools or techniques out there to help me achieve Light-map results on par with the Valve example above.

    @Pangahas- Yes, the workflow I mentioned earlier in the thread basically is. I'm interested in learning if there is a better way, or at least get tips on improving my current approach.

    @Neox- That's a good point, it solves the problem of getting the Lightmap to Sync with externally generated Normal and AO maps. (from xNormal in my current workflow.)
  • aivanov
    Offline / Send Message
    aivanov polycounter lvl 5
    I really don't know if there's any special trick to enhance it; they're most certainly also baking gradient maps and using them with the Point Light Maps to push the value gradation. Other than also manually painting lighting in the diffuse by using more saturated versions of the colors, there probably isn't much to it.

    I guess you could also enhance by baking the inverted lighting for a shadow map. They did that for at least the weapons in TF2. But the workflow presented in the Dota guide suggests they avoid shadows, what with the light map clamping and all.

    'Course I'm no expert and could be talking out the rear.
  • indavisual
    Offline / Send Message
    indavisual polycounter lvl 17
    My guess is they use Batch Bake (mental ray), if using Maya. And the Use bake set overide (only lighting). Then choose your persp camera to bake from. Then its all down to getting the right angle of light hitting your model and tweaking your material settings to get the best spec highlights.
  • McBradd
    Offline / Send Message
    McBradd polycounter lvl 12
    indavisual wrote: »
    My guess is they use Batch Bake (mental ray), if using Maya. And the Use bake set overide (only lighting)...

    Are you suggesting unwrapping the High-poly model, Batch baking the lighting info to texture, then transferring mapping that to the Low-poly UV's?

    That may possibly produce some better result, but Maya just bakes sooo slooow... That's my main reason for baking my AO in xNormal. Well, that and I generally us a cage when generating my normal maps, so by using xNormal for both, the AO matches the normal detail exactly.
  • Will Faucher
    Offline / Send Message
    Will Faucher polycounter lvl 12
    May I ask exactly what it is a point light map does?
  • tryl
    Offline / Send Message
    tryl polycounter lvl 7
    Hi there,

    So, I'm not sure as to how exactly they achieved this map, but I was able to get a similar effect by using the same workflow you do with Zbrush/xNormal. So hopefully this is helpful.

    I used the Basic Material shader in Zbrush for my high poly model. (Cleared out any polypainting with white)
    Added an extra light (In Zbrush) until it looked similar to the tutorial image.
    Used ZAppLink (in Zbrush) to bake the material onto the models PolyPaint. (You'll probably need to do a few passes to cover it all)
    Created a Texture from the Polypaint, cloned it, flipped it vertically, exported it as a .psd.
    In xNormal I added the meshes (the low poly version with uv's, and my high poly zbrush model). Hooked up the texture I exported from Zbrush as the "Base texture to bake" in xNormal.
    And then used "Bake base texture" map to create the light map.
  • McBradd
    Offline / Send Message
    McBradd polycounter lvl 12
    Prophecies wrote: »
    May I ask exactly what it is a point light map does?

    The short answer is, it's a quick way to enhance the details of a texture map. The same way you'd add Ambient Occlusion, or use a Cavity map to add a lot of detail quickly, rather than doing it all by hand. Interestingly enough, when used correctly (And not as a crutch to bypass actual hand-painting) you can get some pretty spectacular results, such as the clean, hand-painted look of the Dota 2 Champions.

    This entire discussion came up from wanting to figure out one of the steps in Valve's Texture Guide, Here's the PDF.

    It's from their Dota 2 Workshop website.

    In retrospect, my 'short answer' was a lot longer than expected...
  • Neox
    Offline / Send Message
    Neox veteran polycounter
    it is just lighting baked down, isn't there a way to do that maya? in max its super simple, set up lights, apply normalmap to lowpoly, bake a complete map - done.
  • r_fletch_r
    Offline / Send Message
    r_fletch_r polycounter lvl 9
    Neox wrote: »
    it is just lighting baked down, isn't there a way to do that maya? in max its super simple, set up lights, apply normalmap to lowpoly, bake a complete map - done.

    I'm pretty sure its the same, i just googled it and loads of tutorials came up. guess their google is broken.

    http://download.autodesk.com/us/maya/2011help/index.html
    comp_Transfer_Maps_Icons_85_2.png
    looks like you bake a 'shaded' map
  • aivanov
    Offline / Send Message
    aivanov polycounter lvl 5
    You don't even need to bake a 'Complete Map' in Max. At least in 2011, there's a Lighting Map option.
  • McBradd
    Offline / Send Message
    McBradd polycounter lvl 12
    r_fletch_r wrote: »
    I'm pretty sure its the same, i just googled it and loads of tutorials came up. guess their google is broken.

    http://download.autodesk.com/us/maya/2011help/index.html
    comp_Transfer_Maps_Icons_85_2.png
    looks like you bake a 'shaded' map

    I outlined this method in the third post, but the results aren't anywhere near as nice as the Valve example. The title of the thread should probably read "How to create REALLY GOOD Point Light Maps?"
  • sprunghunt
    Offline / Send Message
    sprunghunt polycounter
    McBradd wrote: »
    I outlined this method in the third post, but the results aren't anywhere near as nice as the Valve example. The title of the thread should probably read "How to create REALLY GOOD Point Light Maps?"

    what problems are you having with generating them? perhaps you should post pictures of what you've got and then people will understand what you mean.
  • r_fletch_r
    Offline / Send Message
    r_fletch_r polycounter lvl 9
    McBradd wrote: »
    I outlined this method in the third post, but the results aren't anywhere near as nice as the Valve example. The title of the thread should probably read "How to create REALLY GOOD Point Light Maps?"

    i wasn't referring to what you'd said it was the OP.
  • Neox
    Offline / Send Message
    Neox veteran polycounter
    sprunghunt wrote: »
    what problems are you having with generating them? perhaps you should post pictures of what you've got and then people will understand what you mean.

    this
  • Jeff Parrott
    Offline / Send Message
    Jeff Parrott polycounter lvl 19
    Here's a quick one I baked out. For repeating elements (aside from mirrored) and exploded models it'll be a mess. But it does seem like it helps the texture.

    maya_point_lightmap_01.jpg
  • Swizzle
    Offline / Send Message
    Swizzle polycounter lvl 15
    There are various problems with baking lighting using point lights. The most prominent is that specular highlights will kick you in the ass if you don't adjust your gloss and overall intensity properly before baking. The wider the specular highlight, the smoother the shading will be. This is essential if you're using any sort of point light source.

    Slightly less of a problem (but still an issue, depending upon your renderer and hardware) is actually getting consistent shading over your entire model. If you're baking with point lights, I'd suggest baking with at least 17 to get smooth shading over your entire model. I've achieved good results in the past with this method, even before I'd heard about Valve's method. If you do your lighting with fewer than 17 (one above, a ring of 8 at 45 degrees and another ring of 8 at floor level for your model), you should get lighting that's smooth and consistent.

    A slightly costlier alternative is to use a dome/sky light. It'll take longer to render, but the setup time is faster because you don't have to noodle around with 17 frickin' lights, any one of which could get screwed up accidentally.

    Here's an example render from Modo, though you should be able to get similar results in basically any renderer. The model is just a fairly random rough shape I sculpted and then decimated.

    cXmUU.jpg

    Here's the model itself:

    NCLQ1.jpg

    The render setup:

    ywjiM.jpg

    Notice that even with the specular glossiness set very low (roughness 75.0%, similar settings can be found in other programs), I get banding and very separate highlights from my various light sources when using point lights. You'll get similar results to the point light baking method using directional lights, though the highlights should be slightly smoother since they aren't really point light sources.

    I'd suggest that if you plan on baking lightmaps using the Valve Dota method, you do it with very rough specular highlights and either a lot of lights or a dome/sky light. The dome light will give you the most consistent results every single time and the output can be easily adjusted in Photoshop with levels or curves and various masking techniques.
  • indavisual
    Offline / Send Message
    indavisual polycounter lvl 17
    McBradd wrote: »
    Are you suggesting unwrapping the High-poly model, Batch baking the lighting info to texture, then transferring mapping that to the Low-poly UV's?

    That may possibly produce some better result, but Maya just bakes sooo slooow... That's my main reason for baking my AO in xNormal. Well, that and I generally us a cage when generating my normal maps, so by using xNormal for both, the AO matches the normal detail exactly.

    I am suggesting you take the Normal that you have baked out of ZBrush/Mudbox and apply that to your UV'd low poly model inside Maya. Make sure your Color channel is white because you will need to use "Light and Color" within the Batch Bake Override settings that i will describe next. Now set up a point light in your scene at an angle that looks good and makes sense with the space that your model will live in (ie: lit from above in an outdoor setting). Once your light is set up, normal applied to your model, and your color set to white (so you get a grey scale mask when you bake) then you can go to the Polygons drop down menu and choose Color > Batch Bake (mental ray) option box. Give it the settings I have shown in the image attached to this post and you should have a point light map. Do this several more times with various light positions so you can tweak and combine within Photoshop.

    Oh yeah, and tweak the specular options on your shader before doing the batch bake.

    You shouldn't have to bring your high poly into Maya at all.
  • McBradd
    Offline / Send Message
    McBradd polycounter lvl 12
    Oh wow, Thanks to Jeff Parrott, Swizzle, and indavisual for the examples and tips.

    We're got a project coming up that is going to include some workshop content as bonuses, so I'd like to figure out as much of this as possible ahead of time to reduce the amount of trial-and-error I have later. This will be a huge head-start!

    @indivisual - Why do you recommend comping several renders with various light positions over the Dome/Point Array example Swizzle showed? More specific shadows, more control over the light direction?

    @Swizzle - You rendered out the diffuse shading, and the Spec as separate passes, was that for the example, or do suggest doing it that way for more control when comping them into your texture?
  • DeadlyFreeze
    Offline / Send Message
    DeadlyFreeze polycounter lvl 17
    Swizzles examples seem way too ambient and dark.

    They should have called it a value map since that's what your trying to get, a range of white's and dark's that define and exaggerate the surface volume.
  • indavisual
    Offline / Send Message
    indavisual polycounter lvl 17
    McBradd wrote: »
    @indivisual - Why do you recommend comping several renders with various light positions over the Dome/Point Array example Swizzle showed? More specific shadows, more control over the light direction?

    Doing separate bakes is so that you can easily adjust intensity and falloff within Photoshop. You could do it in Maya but I don't recommend it. You will spend a lot of time trying not to blow out areas where the lights cross paths as well as adjusting fall offs and intensities. This will end up in you having to do more bakes than are necessary. It all comes down to having more control and having those separate elements to work with later.
  • SinAmos
    @indavisual

    So, I incorporated your settings in the override with a LIGHT only approach with my HiRez and received some beautiful results. I used 3 point lights. I'm going to do some tweaks and experiment a bit. Is everyone generating their textures at 2048 and then downsizing them later?
  • Neox
    Offline / Send Message
    Neox veteran polycounter
    indavisual wrote: »
    Doing separate bakes is so that you can easily adjust intensity and falloff within Photoshop. You could do it in Maya but I don't recommend it. You will spend a lot of time trying not to blow out areas where the lights cross paths as well as adjusting fall offs and intensities. This will end up in you having to do more bakes than are necessary. It all comes down to having more control and having those separate elements to work with later.

    well ideally you would use one lightdome thats tweaked for the production needs - and set up the math in photoshop and the you do that with any asset inthe production. so the time you need for tweaking will only be needed once so you don't have to teeak dozens of layers on dozens of models und everyone in the production knows what will come out in the end.
  • indavisual
    Offline / Send Message
    indavisual polycounter lvl 17
    Neox wrote: »
    well ideally you would use one lightdome thats tweaked for the production needs - and set up the math in photoshop and the you do that with any asset inthe production. so the time you need for tweaking will only be needed once so you don't have to teeak dozens of layers on dozens of models und everyone in the production knows what will come out in the end.

    Yes, that is true for a studio environment when you are working on a team with established lighting and you have a large set of assets that need to be created. I suppose if you plan on creating more than one asset for DoTA 2, as a solo artist, then you should establish a lighting stage that provides the results that you are looking for and hold on to that scene. Then just drop your assets in when they are ready to be baked.
  • Swizzle
    Offline / Send Message
    Swizzle polycounter lvl 15
    McBradd:
    I suggest doing individual passes, at least if you're doing multiple assets. That way you'll be able to tweak settings on a case-by-case basis, allowing you to be sure that everything matches. I tend to do absurd numbrs of passes and masks and stuff, though, so it may not be strictly necessary to do it in more than one pass if you get a good render setup.

    DeadFreeze:
    They're certainly pretty dark, but that could easily be adjusted by bumping up the intensity of the lights or adjusting the levels in Photoshop. The ambient feeling comes from having all the lights at the same intensity. You could get stronger lighting by changing the intensity of the light directly above.
  • Ariza
    The best results ive found to render a point light map in maya is pretty simple. Here is my method...use a default blinn, then create a single point light, place in front/above the hero, change the decay rate to quadratic, and then increase the light intensity til you have a nice gradient from the top of the hero down (at dota character scale ive found you need to go as high as 10,000 in some instances). Next turn off the default light/and all other shadows in the scene and use transfer maps to render from your high poly to low. Repeat this process for the side, back, etc. Try to vary the light intensity based on where you want the focus of the character to be. Then take all of your maps and composite then into a single map in photoshop.

    While refining this process i found using a default lighting scene and/or multiple light set up you end up with consistent lighting results every time. Which might be good if all of your heros are similar (ex similiar biped humans). But when dealing with characters that have varied body shapes and sizes and having more control over the positioning will allow a more finite control over the focal points of every hero.

    Also here is another tip the Turtle plugin for maya renders out much nicer (and faster) normal maps and light maps. Hope this helps you guys!

    Cheers,
    Ricardo
  • apple
    Hi guys, do you know something about wall worm model tools, and other tools of wall worm. leaning wot i have seen in the tutorial wall worm replaces several plug-ins and programs: compiling softwares, notepad++, V.T.F edit, S.M.D import and esmort plug-ins So guys if you know about wall worm please tell me, I'll be appreciated.
  • bounchfx
    Do you need to use the high poly to do this? Or can you, like max, bake from a normal mapped low poly?
  • JamesWild
    Offline / Send Message
    JamesWild polycounter lvl 8
    I think you'll want the high poly for better shadows.
  • beaver_knight
    Offline / Send Message
    beaver_knight polycounter lvl 9
    indavisual wrote: »
    I am suggesting you take the Normal that you have baked out of ZBrush/Mudbox and apply that to your UV'd low poly model inside Maya. Make sure your Color channel is white because you will need to use "Light and Color" within the Batch Bake Override settings that i will describe next. Now set up a point light in your scene at an angle that looks good and makes sense with the space that your model will live in (ie: lit from above in an outdoor setting). Once your light is set up, normal applied to your model, and your color set to white (so you get a grey scale mask when you bake) then you can go to the Polygons drop down menu and choose Color > Batch Bake (mental ray) option box. Give it the settings I have shown in the image attached to this post and you should have a point light map. Do this several more times with various light positions so you can tweak and combine within Photoshop.

    Oh yeah, and tweak the specular options on your shader before doing the batch bake.

    You shouldn't have to bring your high poly into Maya at all.

    Thank you for instruction! :)
  • beaver_knight
    Offline / Send Message
    beaver_knight polycounter lvl 9
    Maybe some 1 have advice, how to light object for best results? For DOTA 2 purpose. Object like standing character. What are good position to place lights? :)

    Sorry for my english.
  • rip3rs
    indavisual wrote: »
    I am suggesting you take the Normal that you have baked out of ZBrush/Mudbox and apply that to your UV'd low poly model inside Maya. Make sure your Color channel is white because you will need to use "Light and Color" within the Batch Bake Override settings that i will describe next. Now set up a point light in your scene at an angle that looks good and makes sense with the space that your model will live in (ie: lit from above in an outdoor setting). Once your light is set up, normal applied to your model, and your color set to white (so you get a grey scale mask when you bake) then you can go to the Polygons drop down menu and choose Color > Batch Bake (mental ray) option box. Give it the settings I have shown in the image attached to this post and you should have a point light map. Do this several more times with various light positions so you can tweak and combine within Photoshop.

    Oh yeah, and tweak the specular options on your shader before doing the batch bake.

    You shouldn't have to bring your high poly into Maya at all.


    Thank you :)
  • fatihG_
    Offline / Send Message
    fatihG_ polycounter lvl 14
    Hey Guys,

    I was trying to figure out how to do that what was asked in this topic.

    I kind of got it working, but the results I get are strange. Nothing on the UV is mirrored except for the hands and shoes of the character. The parts that are mirrored are off set a UV tile to the right. (the normal map and AO for example baked just fine)
    When I bake the lighting on the model with the normal maps applied the lights on the baked map seem to be inverted for one side of the model.

    I have no idea what is going on. The vertex normals are fine, they all point outwards. UV's are fine, they are all blue in the UV window.

    I use the exact same settings as what was posted before.

    Any help here would be appreciated =]
  • fatihG_
    Offline / Send Message
    fatihG_ polycounter lvl 14
    I ended up using Cinema4d for baking my light info.
  • Moonlight604
    Offline / Send Message
    Moonlight604 polycounter lvl 6
    How do you get mental ray to bake light from just normal map and not the smoothed normals that give bad shading?
  • Bubba91873
    Offline / Send Message
    Bubba91873 polygon
    Dota 2 Workshop - Taking your textures to the next level with light baking

    http://steamcommunity.com/sharedfiles/filedetails/?id=183672148
Sign In or Register to comment.