Search Unity

Light & Shadows, based in Paris, has used HDRP to produce stunningly realistic real-time images and videos. This blog post from Light & Shadows walks through the processes they’ve used to achieve these excellent results.

History of Light and Shadows

Unity has worked closely with Light & Shadows on projects to demonstrate lifelike visual quality in real time. This blog post has been written by Light & Shadows to provide technical insight into how they used Unity’s new HD Render Pipeline to produce an amazingly realistic video of the Lexus LC 500 in real time. Light & Shadows was founded in 2009 in response to growing demand by major industrial companies for compelling visual content. From its founding, the company has thrived by continuously adapting and innovating the delivery of new capabilities to its customers, including the generation of high-quality rendering together with cost reduction and productivity improvement. The rest of this blog post is from Light & Shadows.

Real-time rendering: A game changer for the automotive industry

Technology is transforming the way we experience, sell and buy cars. Light and Shadows has deep experience with automotive visualization and offline rendering, as evidenced by the PSA car configurator and projects with Dassault Aviation. Although we primarily used a different real-time engine until recently, we have now partnered with Unity to deliver real-time rendering results using HDRP that achieve new levels of visual quality and performance. To prove these new capabilities, we recently created a video demonstrating real-time rendering of a Lexus LC500.

The project from start to finish

CAD data preparation tools and process

For the LC500 project, Lexus provided us with access to boundary representation (B-rep) CAD data for all visible surfaces and certain internal geometry. This was helpful, as we didn’t need to do any hard surface modeling. However, the model is very complex and so organizing and preparing the data was a challenge. To meet this challenge, we selected PiXYZ software for its advanced tessellation and scriptable data preparation features.

As is typical of most complex products, the model of the Lexus is organized into an extensive hierarchy of objects, in this case representing thousands of components of the car. We decided to separate the outside and inside of the car, which gave us more flexibility and allowed us to work on the two parts of the model in parallel. We were also able to segregate design content including the powertrain, chassis, and vehicle structural components.

The source data is not organized as a single vehicle per file, but instead as a collection of parts covering all the geometric options of the same vehicle. This provided us the opportunity to organize the data in a logical way to mirror the variants (options) available to a Lexus customer. We used an XML file to logically connect each part in the source data with the relevant option logic. Using this XML together with a custom script, we were able to isolate the different variants of the vehicle into a form where a visual representation of each option combination can be readily assembled.

Once the different parts were isolated, the next step was tessellation. This process involves transforming CAD data (B-rep) into a tessellated form (triangles) which can be used in applications such as 3ds Max or Unity. By using PiXYZ software, we were able to produce relatively lightweight tessellated models and still produce excellent visual quality.

Options to achieve optimal lighting and baking

To achieve the very high standard for visual quality that we set for ourselves, we used lightmaps to enhance lighting. As part of this workflow, we needed to unwrap every single part of the car without any overlaps. We used automatic unwrapping tools together with interactive (manual) unwrapping where needed to optimize seam placement.

UVs wrapped across visible surfaces

We evaluated two options to compute the lightmaps – directly in Unity with its built-in lightmapper, and in 3ds Max using a third party renderer such as Octane or V-Ray. We decided to evaluate both methods so we could compare the quality level resulting from each, and to test the workflow to integrate external lightmaps with Unity’s built-in lightmapper. The interior lightmaps of the vehicle were calculated directly in Unity, and with the right settings, the results were very convincing. The direct lighting is provided by real-time lights, while the indirect lighting is baked. With this technique, we are able to provide realistic visuals even when animating interactive parts of the scene such as turning the steering wheel and opening the doors. Using the built-in lightmapper in Unity was very straightforward and yielded excellent results.

Interior with and without lightmaps

We chose to experiment with the Octane lightmapper to interactively tailor specular occlusion for each exterior object in the model. We edited the standard shader in HDRP to properly incorporate a separated UV channel. The result was satisfying and enabled us to generate a visual result which is very realistic, especially in gaps between the body panels. Using these two approaches allowed us to evaluate tradeoffs between the flexibility of an external lightmapper and the ease of use of the integrated lightmapper. Ultimately we concluded that we could achieve the desired results with either approach.

Exterior with and without lightmaps

Tailored materials to achieve photorealism

With our years of experience in the world of automotive offline rendering, we have accumulated a large collection of high-res textures in the form of diffuse maps, height maps, specular maps, normal maps and more. For this Lexus project we wanted to use our favorite maps to get the best results, but to optimize performance Unity needs metallic, smoothness and AO maps combined into the RGB channels of a single map. This approach is optimal for performance but creates challenges to interactively tweak maps and shaders precisely. Because the Shader Graph wasn’t available for HDRP when we started this project, we asked our development team to create a custom texture editor tool allowing us to load and tweak each map in our textures independently and directly in the standard HDRP shader. This editor tool enabled us to work very efficiently by fine-tuning materials directly in Unity. Now that the Shader Graph is available for HDRP, this same capability is available to all Unity customers.

Custom texture editing


Post-processing is essential to give a film-like and realistic feeling to a 3D scene. HDRP provides many available options to tweak the final look of a scene, including color grading, bloom, vignetting, depth of field, and more.

Door interior with and without post-processing

Depth of field is an essential visual effect to achieve realistic visualization. It helps the viewer to focus on a specific area and feel immersed in the scene. Applying fixed values for the depth of field focus point within a real-time app could produce unnatural results, so we made a small camera script that automatically sets the focus on the closest object in front of the camera. It was very easy in Unity for us to cast rays within the scene to determine the closest object.

Interior with and without depth-of-field effect

Important details

We used Cinemachine in Unity to make what we call a “Demo” mode, a kind of cinematic showcase mode with predefined camera paths, to show key features of the product even when nobody is actively interacting with the car.

To accurately represent the car, we provided a way to manage its many different configurations. Not only did we need to switch among variants in the runtime (executable) app, but also within the Unity Editor, to ensure that all variants were correctly defined. To achieve this, we created a configuration management script that records “scene states” and provides automatic material assignment.

Variant configuration logic

Four different interior variants

What’s next

Our experience with this project has given us the confidence to use HDRP to pursue new customer projects demanding the highest level of visual quality. We are able to deploy new projects very efficiently through the use of PiXYZ for data preparation together with the latest rendering, cinematic, and post-processing tools in Unity and our own in-house custom tools and scripts.

We at Unity would like to thank Light & Shadows for this blog post and for the great work they did on this video. More information about Unity’s solutions for Automotive and Transportation can be found here.


Subscribe to comments

Leave a reply

You may use these HTML tags and attributes: <a href=""> <b> <code> <pre>

  1. Wow, nice showcase, this is really amazing! Best practice in realtime!!!

    How did you solve the UV unwrapping, you wrote that you used ‘automatic unwrapping tools together with interactive (manual) unwrapping’… Which tools did you use? Can this be done in PiXYZ or can you recommend any tools to do such tasks?


    1. Hi Joe, in this specific case automatic unwrapping was done with the Unwrella plugin within Autodesk 3ds Max (for lightmaps), and manual unwrapping was done manually with built-in 3ds Max tools.

  2. One thing I do not understand, is that how could they do that in VR with the current version of Unity and HDRP that is not actually ready for VR ? (The video say VR Mode at the beginning.)

    1. Hi Jonathan, we’ve demoed VR in HDRP already, starting at SIGGRAPH 2018. Instructions for doing this are at I’d also encourage you to try out the 2019.1 beta

  3. If even the professional CGI studios don’t want to use your merged map approach, you need to take the hint.
    Nobody who uses a standard shader is packing their maps in RGB channels. Professionals who merge maps don’t use a standard shader, all you do is make quick tests very tedious and add a burden of knowledge 90% of users won’t understand or don’t even have a means of achieving (as it requires a software like Photoshop)

    1. That said, the Demo was very impressive and surely the best ive seen achieved in realtime so far, most offline GPU renderers couldn’t do really better

      1. Please take a look at the Stack Lit shader included with HDRP. Does this cover your requirements? It has separate texture channels like you are suggesting. It also also support for Clear Coat which makes it great for Car Paint materials.

      2. Alex is exactly right – the new Stack Lit shader in HDRP addresses this issue, and adds clear coat as well. It produces great results, especially for carpaint. The (soon to be released) Measured Materials Library includes Stack Lit materials. We think you’ll find it very useful for projects like this.

        1. Could you please tell me where to select and use the Stack Lit shader? Is it included in HDRP 4.9? I’ve tried Unity 2018.3 and the latest beta 2019 with HDRP 5.2.3 but could not find the Stack Lit shader in the Material menu? Or is it meant to be created and edited with shader graph, there I found the option “StackLit Graph”?! I assumed Stack Lit shader is something like the default HDRP Lit shader…

  4. First of all a Really Great! demo of Unity’s HDRP. However there are few things we unity should also include in its LIT shader such as separate slot for metallic, smoothness and AO maps. For now it a bit difficult to edit and reuse the textures.
    I am also waiting for a proper Car Paint Shader in HDRP.
    For those who wants to learn more about HD Render Pipeline I have started a you tube series on HDRP.
    If anybody is interested please watch it here.

    1. The new Stack Lit shader is the answer to your question. Better yet, we’ve now unveiled the first materials library supporting Stack Lit, including a cool new carpaint material. These can be edited in Shader Graph so that you can customize materials to meet your specific needs. Look for more details on the blog soon, and I’m interested in your feedback!

  5. I would like to know more about the modification of the render you performed.

    1. There was no modification to the rendering pipeline, this project used the (2018.2) preview of HDRP available to all Unity customers. As mentioned in the article, Light & Shadows created some custom materials using their own process, since Shader Graph became available for HDRP in 2018.3, after this project was completed.

      1. Are they using StackLit shader?

        1. Yes, Light & Shadows used an early version of the Stack Lit shader. Since then, we’ve made some significant improvements to Stack Lit, and we used Stack Lit for the new HDRP version of the Measured Materials Library.

      2. Does StackLit suitable for game in terms of performance?

        1. Yes, it is. Stack Lit has slightly higher computational demands than Lit, but in practice it performs very well. I’d encourage you to try it out for yourself. Note that Stack Lit is HDRP only.

  6. Hey, I just published an article about improving visual quality within Unity, using tools such as post processing and shader graph. I thought people here might find it helpful. Please let me know if you have any thoughts and if you liked it –

    1. Very cool, Divij! What I love about working at Unity is learning about all of the amazing ways in which Unity can be adapted to nearly any application a person can imagine. I like what you did to take a data viz problem and turn it into a visually engaging project.

      1. Thanks Edward, I’m glad you liked it! I was tasked to do this at my job – my company wants to experiment with biology inspired AI, and this worm is an inspiration for everyone. It was a different challenge for me, that’s for sure.

  7. DOF is the thing that should never exist – neither in gamedev, nor in archvis! =\
    Let my eyes decide what to look at!

  8. 2018.3 is out since more than a month, but there’s no trace of the promissed car materials yet.

    1. Hi Besjan, we’re very close to releasing the new measured materials library. We’re wrapping up some documentation now. It will be worth the wait!

      1. Cool, thanks.

        1. Hi Besjan, I’m happy to tell you that the measured materials are now available (for HDRP / Stack Lit)!

  9. Really nice.
    Will you show the process of creation this ?
    Also there is a bug with texture in video (1:11) around safe belt hole ;)

    1. Hi Denis, good eye! I think that is a shadow at 1:11. If you’re interested in learning more about the process, please reach out to Light & Shadows.

  10. Very nice.

    I have said Unity should provide a basic shader that doesn’t read the metallic from an alpha, but they expect it to be in an alpha channel for some reason, unlike any other app on the planet…

    1. Also, every HD material website provides them as separate maps.

    2. Exactly this. The layered map approach is a very poor choice for a standard shader. Nobody who actually layers maps uses a standard shader. All it does it makes quick tests extremely tedious and confuse new users.

      1. Please take a look at the Stack Lit shader included with HDRP. Does this cover your requirements? It has separate texture channels like you are suggesting. It also also support for Clear Coat which makes it great for Car Paint materials.

        1. Could you please tell me where to select and use the Stack Lit shader? Is it included in HDRP 4.9? I’ve tried Unity 2018.3 and the latest beta 2019 with HDRP 5.2.3 but could not find the Stack Lit shader in the Material menu? Or is it meant to be created and edited with shader graph, there I found the option “StackLit Graph”?! I assumed Stack Lit shader is something like the default HDRP Lit shader…

        2. I’m replying to Martin … please try out the new materials library at I think it will solve your question!