Search Unity

Vray lightmapping workflow in 3dsmax

Discussion in 'External Tools' started by Filto, Jul 7, 2010.

  1. Filto

    Filto

    Joined:
    Mar 15, 2009
    Posts:
    697
    Just sat down yesterday to figure out how to create lightmaps with vray. Maybe some people will benefit from it so here is what I discovered.

    * Always use vraymaterials or else lightmaps will come out incorrect

    * Use VrayRawTotalLightingMap when you render out your lightmaps in render to texture

    * In colormapping change Dark and Bright Multiplier to 0.5 (same as changing exposure to -1)

    * Use the Daniel Brauers lightmappingshader in

    http://forum.unity3d.com/viewtopic.php?t=24070

    Hope it helps people who struggle with this
     

    Attached Files:

  2. Tudor-Nita

    Tudor-Nita

    Joined:
    Dec 10, 2009
    Posts:
    336
    Good tips. Could get someone out of a jam.

    Another helpful tip for beginners would be to not use the Vray camera when rendering preview images in max (unless they completely understand how it works). The RTT textures will look significantly different.
     
  3. pzstar

    pzstar

    Joined:
    Aug 22, 2012
    Posts:
    9
    Is that possible not using Daniel Brauers lightmappingshader just use unity built in lightmap function (not the unity lightmap shader)?
     
  4. lazygunn

    lazygunn

    Joined:
    Jul 24, 2011
    Posts:
    2,749
    As Daniel says in the thread at the end, his shader has been supersceded by unity's own implementation, and their lightmap specific shader is included for legacy purposes

    I'm going to have a look at my dark and bright multipliers though because that might help
     
  5. pzstar

    pzstar

    Joined:
    Aug 22, 2012
    Posts:
    9
    thanks, nice to see you again,,, I am still trying to get the same quality like rendering in 3d max
     
  6. pzstar

    pzstar

    Joined:
    Aug 22, 2012
    Posts:
    9
    By the way, I found that:
    There are two way to add light map, one is to use lightmap shader, another is the way you used in your tutorial.
    same light map add to the model, different result.
     
  7. lazygunn

    lazygunn

    Joined:
    Jul 24, 2011
    Posts:
    2,749
    I think the lightmap shader might not count in the scene lights, however with unitys current lightmap if you have it on a lightable material, the light will illuminate it
     
  8. pzstar

    pzstar

    Joined:
    Aug 22, 2012
    Posts:
    9
    I dont understand, actually there is no light in my scene, I just use light map. After testing think your way is better than lightmap shader~~ but still a little difference with 3d max rendering ~~
     
  9. lazygunn

    lazygunn

    Joined:
    Jul 24, 2011
    Posts:
    2,749
    Might be your ambient light setting?

    Two things to look at for more accuracy is wether you use color mapping at all, set in your render to texture settings. Otherwise you can try what Filto suggests and look at your colormapping settings in the vray settings and changing your dark and bright multipliers, i havent tried this yet, havent felt there was something wrong but its worth a go definitely, might stop blown out highlights and things like that
     
  10. pzstar

    pzstar

    Joined:
    Aug 22, 2012
    Posts:
    9
    yeah, not the light setting.
    I think the gloss reflection is one reason,but still something wrong, for example, the bright part which is direct illuminated by the light is not that "bright" as rendered in 3d max. I think colormapping settings will helps.
    Still testing.
     
  11. Photon-Blasting-Service

    Photon-Blasting-Service

    Joined:
    Apr 27, 2009
    Posts:
    423
    Looks great. I notice the contact shadows in the corners and under the cube are bigger in the Unity version. Also the grain of the noise is a bit bigger. I assume this is due to the lightmap resolution in Unity?

    The fine line running along the length of the cylinder is a UV mapping issue?
     
    Last edited: Nov 12, 2012
  12. lazygunn

    lazygunn

    Joined:
    Jul 24, 2011
    Posts:
    2,749
    I would think you're correct on all counts there
     
  13. bbedwell

    bbedwell

    Joined:
    Nov 5, 2012
    Posts:
    37
    Will this work using Unity 4.3? Does the shader listed by the OP still work in Unity 4.3?