1. Welcome to VRCat! Please note that this message board is not related to VRChat in any official manner. It is run entirely by the community, and moderated by the community. Any content present has not been reviewed by VRChat moderators or staff. Your use of these forums implies understanding of this message. Thanks!
    Dismiss Notice

Worlds Xiexe's Lighting Tutorial : "How to Get Good at Baked Lighting : 101"

Discussion in 'Tutorials and Tools' started by Xiexe, Jul 17, 2018.

  1. Xiexe

    Xiexe Member

    Joined:
    May 1, 2018
    Messages:
    17
    Likes Received:
    32
    VRChat:
    Xiexe
    Greetings! Over my course of playing VRChat I've noticed that most worlds, mainly the ones that have baked lighting, are done poorly, or in an incorrect way.

    Today, I'll be teaching you how to fix this - and make your worlds go from flat, to an actual 3d looking, believable, environment.

    Don't worry! This tutorial may get long, but I've made it as easy to follow as I can, with screenshots along the way to help out!

    In to the tutorial!

    By Far the biggest and most annoying issue I see, is that most people who have worlds with baked lighting, anything reflective seems to lose all or most of the reflections from the light sources, and metals becomes black. This is for one of two reasons, I will go over those shortly, and this guide will fix that issue for your world if it has it.

    For this tutorial, I'll be using a small scene I created, The Fox Den.

    Now, here's some screenshots side by side of how The Fox Den looks properly lit, alongside how it would look in a lot of the baked lighting worlds I've seen in VRChat.

    Pay attention to the sphere here - its a sphere with Standard shader with Metallic at 1 and a color of Gray. Notice that it doesn't turn black, but instead acts like metal in the after picture.

    Before:
    [​IMG]
    After:
    [​IMG]

    Notice that not only do the metals read as metal now, but we gain a lot of extra information in everything.

    Our wood looks varnished and smooth, our leather seats look like leather, and everything is bouncing light as we'd mostly expect it to.

    That is because of two reasons, the first being that I have Reflection Probes in the scene - those wont do it alone though. The second reason is that I have physical light sources in my scene where my lights are placed.

    The biggest issue with most worlds is that there are usually no physical emissive sources of light, which means that the reflection probe is just reflecting a diffuse, boring environment.

    Having physical emissive sources in our scene is absolutely needed to get correct lighting - in fact, this is even mentioned in Unity's documentation for baked lighting.


    Getting Started and Organized


    Now, I'll go over the basics of how to actually set up a simple scene.

    First things first, let's set up our lighting settings for quick iteration once we get to the baking phase.
    On the top bar, go to Window > Lighting > Settings.
    [​IMG]

    You will open a window on the right that looks like this.
    [​IMG]

    So, a lot of this stuff can be changed, and will just affect the quality of your lighting by the end.

    First things first - Make sure that you UNCHECK "Auto Generate" at the bottom of this window. We don't want our light to keep trying to bake while we're working.

    Now I'll go over most of the settings I change, and what they do here.

    So at the very top, under "Environment", for Indoor scenes like this, I always set the ambient to a Color, and set the color to a neutral gray tone, or a color/gradient that matches the color scheme of your map and what kind of colors you want to go for.


    I don't always delete the skybox, and in fact recommend you don't so long as you can find a skybox that makes sense for the scene you have.

    Environment reflections I've turned off in this scene since I don't have a skybox.
    I've turned it off by setting it to custom and leaving it empty. This means you wont reflect anything that you shouldn't be from the scene.

    You should leave Realtime Lighting checked as it allows you to adjust any emissive materials in the scene that are casting light into the world realtime, after baking.

    One thing to note is that if you want your shadowed areas to not be completely black, you should set your indirect intensity to something that isn't 0. If you leave realtimeGI on, you will be able to adjust this on the fly after you bake.

    Mixed lighting should be checked, and I personally prefer to used Baked Indirect for most if not everything. Unity tells you the difference in the modes as you select them.

    Under the Lightmapping Settings I would copy everything I have there for now, other than what I mentioned previously. Later on, when we are mostly finalized, we can turn on things like Final Gather and Ambient Occlusion, which will just sharpen things up at the cost of baking time.

    Next, we'll start by setting up a few empty objects in the scene to keep things organized. You can do that by right clicking in your hierarchy, and hitting "Create Empty."



    You should create multiple - in my case, I like to create one for Lighting, and then under that, I have one for each type of light in my scene, and one for the different types of probes, along with one for any particles in the scene if I have any. In this case, I have rain outdoors, and some dust floating indoors, so I went ahead and made those.
    [​IMG]


    Next to our lighting "folder," I also like to create an empty to put all of my static, and non static objects under. In this case, I have only static objects, so everything will be under static

    By the end of organization, your final hierarchy should look very clean when it's all collapsed, and you should be able to find and edit things very easily with this organization.
    [​IMG]

    Static means that you plan on never having that object move from the spot it is in - and objects need to be static to cast shadowing in a baked scenario - it is OK to have non static objects for baked lighting, but only things you plan on have the player interact with shouldn't be. To mark an object as static, you can select it in the hierarchy, and then in the inspector, hit the "Static" checkbox at the top right.
    [​IMG]
    ProTip: With my organization, you can just select the object that everything is under, and hit static. A popup will show that asks if you want to apply this to all children. Hit yes, assuming your objects should all be static, and that will make every object static under that object.

    Please take into consideration that when you add a new object to the hierarchy, it will need to also be marked as static. You can un-check the parent and re-check it without affecting the already baked lightmap.

    That means you don't need to go through one by one in a larger scene and mark every single object as static.

    Anyways, those who are astute may have noticed there is a dropdown menu next to the Static checkbox. I will go over what each of these options does, but the main options we care about currently are "Lightmap Static" and "Reflection Probe Static."

    • Lightmap Static: Lightmap Static just means that our object will be taken into consideration when baking the light. Generally, this can be left on - however, if you have a lot of small object in the scene and notice that light is taking too long to bake, you can turn it off for those smaller objects without losing a lot of detail in your lightmap.

    • Occluder Static: Occluder static marks an object as able to occlude when you have occlusion culling baked in your world. A prime example would be a wall. If you have a wall marked, and you bake occlusion, that means that if there is something behind the wall, it wont be rendered, because you can't see it.

    • Batching Static: Batching static means that unity batches multiple objects together so that it all gets rendered in chunks, which means you should be keeping your map segmented. Do NOT import your map as one mesh. Keep it segmented, and Unity will do the work for you. (If you do keep it all one mesh, your lighting will be completely wrong, more on that soon.)

    • Navigation Static: Navigation static just means that the mesh will be taken into consideration when baking a navmesh - not needed unless you have AI in your world that you want to walk around.

    • Occludee Static: Occludee Static means that the object can be occluded by the aforementioned Occluder.

    • Off Mesh Link Generation: Again, not needed for anything other than AI, but it allows you to define a path that isn't represented by a walk-able surface, or allow you to bridge two walk-able surfaces together if this is on.

    • Reflection Probe Static: This marks an object as able to be baked into the reflections of a scene. This is extremely important to make a scene look believable.

    Alright, now that we've gone over that, we have a solid understanding of what each option in that list does. The most important by far for lighting is Reflection Probe Static, and Lightmap Static -

    Batching static is also very important - I've heard rumors of people importing maps as one mesh, and you should not be doing this. Not only does it stop Occlusion from working, but it also stops lighting from working properly!

    Don't worry, Unity takes care of optimizing the map for you so long as you do the setup! I will go over how to bake Occlusion Culling in a later chapter.



    Lights, Lights, and more Lights!

    Alright, with our basic understanding and our scene imported and marked static in the appropriate locations, let's start placing our lights.

    It is very important that your scene have physical objects to represent your light sources. In my case, I've got two types of lamps, a long bar lamp, and a small ceiling circle light.

    [​IMG]

    It's JUST as important that these lights have emissive surfaces on them to represent the light bulb or area that would be casting the light. They cannot be black, they need to be lit. In my case, the bar light is emissive where the tube lights are, and the ceiling lights where the LEDs would be.

    Now, once we've got our material nice and emissive, we need to place the appropriate types of light sources next to our lights. In my case, I've used Area lights, and spot lights for this scene.

    I will go over what each type of light does, and you can decide for yourself what type of light best suits your light source.

    • Area: Area lights emit light evenly from a surface area. Imagine a light like the florescent tube lights you'd see in school hallways.

    • Point: Point lights emit light from a point in space - imagine a normal light-bulb.

    • Spot: Spotlights emit light in a cone, imagine a flashlight. The further away something is, the larger tha circle of light gets.

    • Directional: Directional lights emit light coming from a direction. You can think of this as a sun. You should never really have more than one directional light. Directional lights have no range, they are infinite.

    Now, here's a few examples of how I set up my lights.

    For my bar lights, I've set up an area light in the general area that the bulbs are, with the line pointing down. This means the light will be coming from above, and will be lighting how we expect the bar light to, well, light things. I've also resized it to fit within the cover, so that it casts a slight shadow of the cover to each side. This is why the light on the wall comes down in a sort of faded triangle.
    [​IMG]
    In the case of these area lights, I've set the intensity to 20 in the inspector, and set a nice warm color using the "Use Color Temperature" mode via the checkbox.
    [​IMG]
    Obviously, these settings will be different per light, and per environment, you will not always want super warm reddish lights for your environment, so this will require you to play around with, and see what looks nice!


    For my circle lights, I've got a simple spot light with a fairly long range and low intensity, and again, have selected a color using temperature.
    [​IMG]
    [​IMG]
    I keep shadows on for most of my light sources! You should too! These shadows will be baked, and will produce a very nice result, with no performance cost.

    * To resize most light sources, you can grab the small yellow square handles, and pull them, or change the settings for range in the inspector.


    Now that we have our basic lights set up, we should set them to be baked. In the inspector for your lights, go ahead and selected "Baked" under the "Mode" drop down menu. You must do this for every light.

    You can shift select multiple lights of the same type to change a bunch at once.

    They will behave as real-time lights until we bake our light later, but we're doing it now so we don't forget!
    Reflection Probes


    Now that we our emissive materials set up and our lights next to them, we need to set up Reflection Probes.
    These bad boys are what give us our specular reflections, and are needed to make our environment believable and lit well.

    To create a reflection probe, right click in the hierarchy, and go to Light > Reflection Probe.
    [​IMG]

    The first thing you'll notice upon creating this object is a ball, with a big box around it.

    Let me briefly go over how a Reflection Probe works - Reflection Probes work essentially like a camera that will take an image of the environment from all angles.

    Now, the ball in the center that you see in the box is your sampling point, in other terms, it's where the camera would be located. That means that the ball should be closer to objects that you would want to be more dominantly reflected.

    To move the sampling point, you can click the 4 way arrow icon in the inspector, and then use the arrows in the scene view to move it around. Once you're done moving it, you can click the 4 way arrow in the inspector again.
    [​IMG]

    The box around the sampling point is what is affected by the probe, anything inside of that box will be receiving reflections from the probe.

    The probe does capture things that are outside of the box, remember, it's a camera. It will capture anything it can see at the moment you bake it.

    To resize the area of effect, you can click the 3 linked dots next to the icon you clicked to move the sampling point, and then click and drag the handles on any of the faces of the box.


    Next, we will go over the different projection modes for the probe.

    There are only two - Box Projection, and Spherical projection.

    To enable box projection, check the box in the inspector - it otherwise defaults to spherical.

    Box projection is good for small square rooms, or things like long hallways and corridors - it will allow you to get a mostly accurate representation of where the walls are.

    Spherical projection however, acts more like a skybox - the reflections are at an infinite distance away, and are not aligned to the edges of the area of effect.

    Here's an example of Box Projection vs Spherical:

    Box:
    [​IMG]

    Spherical:
    [​IMG]

    Box projection will always stay aligned, from any angle with where our walls are, where-as spherical will not. So in my case, I will go with box projection.



    In my case, I've gone with 4 reflection probes for this scene.

    I have two in the bar, and two out front on the road.

    Here's how they look, all selected!
    [​IMG]

    You will need to play around with the sampling point position, and the bounds of the probe to get what you think looks good - that will be the last step though, as probes bake fast, and lighting does not.

    I have two in the bar with the same effect radius to get two different sampling points, this ensures that I'm able to get all of the lights in a manner that isn't distorted - overlapping Reflections Probes mix, so doing this allows me to get more accurate reflections.
    [​IMG]

    In the case of the road, I have two, one for each side of the road, so that I can get two different sampling points of where the street lights are, and thus, a fairly good reflection of the lights themselves.
    [​IMG]

    That being said, it is important that you play around with where these are located, and the area they effect. Having two probes overlapping with the same area of effect may not always work - it just happened that in my case, that's what looked best.


    Light Probes
    Now that we've got our reflection probes roughly placed in positions that we think will look good, it's time to place light probes.

    Light probes are what we use to tell our non static meshes what lighting info exists in the scene. They work by taking the captured light from the bake, and then sampling the closest three points, and averaging the result for the light intensity and color to the object within the group of probes.

    This is an important step, don't skip it or players and dynamic objects wont be lit in your scene.

    Let's get started. To start placing light probes, right click in the hierarchy, go to Light>Light Probe Group.

    You should see a box with yellow dots on either corner and pink lines inbetween.
    [​IMG]

    I know, this looks overwhelming at first, but don't worry. It's actually fairly fast to place, and fairly simple to understand.

    I do recommend creating different Light Probe Group objects for each room if you have a multi room scene.

    Each yellow point in the box is a sampling point, or, in other words, where the group will store lighting information about the environment.

    The pink lines represent the different relations between the sampling points, you don't really need to pay attention to them. Let's just focus on those pesky yellow dots.

    So, to start editing your light probe group, select the object, and in the inspector, hit the button next to "Edit Light Probes"
    [​IMG]

    Now, you can drag select in the scene to select multiple of the yellow dots, or click each one individually to drag it around.

    There are two ways to place light probes. One will provide much more accurate lighting, and the other will provide mostly accurate and OK lighting. I will show both methods.

    First, the mostly OK method, which is what I just like to call the grid method.

    This one is fairly simple, and will get you decent results. Select the entire group of yellow dots, drag it to the corner of your room, and duplicate them with CTRL + D, then drag those to an even spacing, and do it again. Fill the room with a grid, and then you're done.

    By the end, the grid method should look something like this.
    [​IMG]
    This is the fast method and meh method.

    My other method for light probes is a bit more complicated and time consuming, but can result in better results if the time is taken to carefully consider where the probes should be placed.

    It involves making a line of probes down from each light source, and also each shadowed area.

    Something like this.
    [​IMG]
    As you can see, each light has a line of 4 probes coming down from it, long with 4 probes in the dark corner, and 4 near the neon sign.

    The idea here is to have 4 points per light, one at the floor for lowest possible brightness from that light, two in-between, and one up top for the brightest possible brightness coming from that light.

    Since these are more intentionally placed, they will provide better results to what you may want in the scene, as you've got a lot more control over how they behave, so it's a trade-off of time vs speed.

    Once you've got your light probes placed, it's finally time to set up the bake. Yippee! Here we go!

    NOTE: Silent has linked to some very helpful tools to make placing Light Probes extremely fast.
    https://github.com/AlexanderVorobyov/simple-light-probe-placer
    https://github.com/laurenth-unity/LightProbesPlacement

    Thanks for that!


    Baking the Goods

    Alright! We're finally to the stage where we see how this all comes together! The Baking stage! Let's put our lighting into the oven and give it a few minutes, and see how it looks so far.

    Alright, so, here's my preferred way to set up the baking. First, we need to get to the lighting window again. As a reminder if you closed it, to do that, go to Window > Lighting > Settings.

    Now that we're here, verify that you still have the settings that I mentioned before (mainly for the Lightmapper) and hit the "Generate Lighting" button at the bottom.

    The first time your scene bakes, it may take awhile. Let Unity do it's thing. it's an extensive process, you can see the progress in the bottom right. Try to avoid changing things while it's baking. It may look like it gets stuck at some points, don't worry, it's most likely not stuck.

    Once it's done, you should get a feel for how your scene will look - but shadows will be a bit blocky, and not great looking.

    In my case, here's how my scene looks with those settings from before. As you can see, the shadow under the shelf is very blotching and doesn't particularly look good. That's fine, we're using this first bake as a draft to see *about* how our scene will look, not the final product.
    [​IMG]


    Now, you may have noticed at this point that lights may be either too bright or too dark, go ahead and tweak and adjust until you've got what you think might look better, and bake again.

    Once you've done your first bake, you can also bake reflection probes without having to go through the whole process of the actual light baking. If you hit the drop down arrow next to Generate Lighting and click "Bake Reflection Probes" It'll bake all reflection probes, without redoing the actual lighting in the scene.

    This means you are able to move them around and play with that, and they bake fairly fast.

    You're also able to bake one reflection probe individually again by selecting the object and hitting bake in the inspector for that object.

    Now, I'll assume that by the time you're reading this sentence you'll have achieved a result that you like in terms of how bright lights are, and how reflections look. (Remember that reflections will changed based on the smoothness of your materials, so make sure you set them up properly.)

    Once you've achieved a result you like, go ahead and turn on Final Gather, and AO, in the Lighting tab. While you're at it, bump the Lightmap Resolution up to something a bit higher. Personally, I chose to do my final bake with these settings.

    [​IMG]
    Here's how it looks from that same angle from before!
    [​IMG]

    Notice how the shadows and lighting all look much sharper, and way nicer than before.

    Once you're done baking, you can adjust Indirect Intensity and Albedo boost to lighten or darken your entire scene real-time.

    Now, we move on to the fun part. Post Processing.



    Post Processing, and The Magic it Creates


    First of all, let me just congratulate you for getting this far. Lighting a map is no easy task, and takes a lot of time, but the results it can create when done correctly are fantastic.

    Now that the compliments are out of the way, I've got a confession to make. I've been slightly bamboozling you all this entire time. You see, all my lighting was showcased after I put post processing on it.

    Without Post Processing, it actually looks like this.
    [​IMG]

    As you can see, it's not bad, but it's also not great. So let's fix that up - I'm sorry that your scene looks kind of bland at the moment!

    First of all, if you haven't head over to the Unity Asset Store and download the Post Processing Stack

    Once you've got that downloaded and added to your project, find the Main Camera in your scene and select it. Over in the inspector for it, click "Add Component" and search for "Post Processing Behaviour"
    [​IMG]

    Next, we need to create our Post Processing Profile.

    So lets go ahead and create that. In your Project files, right click in an empty space and go to Create > Post Process Profile
    [​IMG]

    Once created, go back to the main camera, and drag your profile into the slot under the Post Processing Behaviour script we added earlier.
    [​IMG]
    Before we can start tweaking how this looks, we need to make sure our changes will be seen in the scene view, as it will allow us to fly around and look at everything better than relying on only the camera. We also need to make sure that our stack will be applied in game.

    To make sure we see our Post Processing in the Scene, go to the top of the Scene window and click the drop down next to the painting icon, and make sure "Image Effects" is checked.
    [​IMG]

    To make sure it's applied in game, find your world descriptor and drag your main camera into the "Reference Camera" slot.
    [​IMG]

    Now, we can start tweaking about in the post processing!
    To easily get to our settings, just select the main camera and double click the profile in the slot. That will take you to a page similar to this.
    [​IMG]

    The only things you should be turning on in VR are as follows.

    Eye Adaptation, Bloom, Color Grading, and Dithering.

    The other settings may not support VR, and can or will result in buggy unexpected results once you see them in VRC.

    Let's start with the Bloom.

    Bloom is important, as it does happen naturally and will allow for us to keep our lighting capable of going into HDR.

    To start setting up Bloom, hit the check box, and then click it to make it expand.
    [​IMG]

    The Intensity adjusts how much bloom there is overall, while threshold adjusts how bright something has to be to bloom. Soft Knee effects how much leeway there is for the threshold, and Radius effects how far the bloom spreads.

    Mess with these settings until you're happy. I would put the threshold fairly high and then adjust the intensity of the emissives in your scene to bloom, rather than the other way around. This makes sure that people don't have supernova avatars in the scene with their emissives, while maintaining that your lights can look the way you want them to.

    Next up is Eye Adapatain. Enable it the same way you did bloom.
    This one I'm not really entirely sure how to get it to look good, as I just mess around until it works.
    Basically, it calculates how bright your entire screen is, and then adjusts the exposure down or up to compensate for things being too bright or dark. This is good for things like my neon sign, where if you get close, it blooms a lot less to be a lot less intrusive.

    Here's an example.

    With Eye Adaptation:

    Far: [​IMG]
    Close: [​IMG]

    Without Eye Adaptation:

    Far: [​IMG]
    Close:[​IMG]

    It's important, but a bit finnicky. This is one of those things you'll need to mess with to get to look how you like it.

    Next up is Color Grading.

    This is where the real magic can happen, and you can make the scene go from Bland to Moody to all out trippy.

    Here's the way my scene looks before and after color grading.
    Before:
    [​IMG]
    After:
    [​IMG]

    As you can see, it adds a lot.


    Once you enable color grading, I recommend settings the ToneMapper to Filmic.

    Once set to Filmic, you'll need to mess with the Post Exposure and different channels to create a style that you like. Keep in mind that if you adjust the exposure up or down too much, anything using an unlit shader will become closer to either white or black.

    If anything, you should always aim to over-brighten all of your lights, and then correct it back down by lowering the exposure. Do not try to correct for an overly bright scene by adjusting the exposure up.

    Again, this is all down to personal taste. Have fun with the color grading until you get the look you personally want. Feel free to try the other Tonemapper as well.

    Next up is Dithering. All dithering does is gets rid of banding in reflection probes and other things.
    Generally, you should turn it on, but it can produce a very subtle "noisy" effect in game, so if you don't like that and you'd prefer to have banding, then leave it off.

    The Final Touches

    As promised, here's a quick rundown of how to do Occlusion Culling, and why splitting your meshes is important for performance, and for your scene.

    First, I'll explain why Occlusion Culling is important, and why you shouldn't be exporting your map as one mesh.

    The reasoning I've heard behind this theory that one mesh is more optimized for worlds is that it's more optimized for Avatars to be one mesh. While it's true that its more optimized for Avatars, that's mostly only because Avatars are what we refer to as Skinned Meshes.

    Skinned meshes take up more CPU time to calculate how and where each vertex of the mesh is moving and deforming based on the Armature it's rigged with.

    Our world is not a skinned mesh. It does not need to be one mesh. Since we marked everything as static, Unity will render it in chunks, and will optimize that for us, and Occlusion culling will make sure we're only rendering the things we need to be, based on what our camera can see.

    As for how this effects lighting, say you have a two floor building with a shiny floor and a unique pattern on the ceiling of both floors.
    You bake a Reflection Probe on the bottom floor, and one on the top.
    The expected result would be that the floor would reflect each pattern from the ceiling based on the floor you were on.

    I.E. Floor 1 would reflect Floor 1's ceiling. Floor 2 would reflect Floor 2's ceiling.
    If your map is one mesh, youll be reflecting both ceilings on both floors.

    Both reflection probes are touching the mesh, and therefore both get mixed together on the mesh, and reflect no matter where you are.

    However, if you have 4 meshes (this is a minimum for this setup to work) one for the floor, and one for the ceiling of the 1st floor, and the same for the second, then your reflection probes will not be touching the neighboring meshes and therefore reflections will behave as you'd expect.


    As for while Occlusion culling combats this, and what it does. This should demonstrate it nicely.



    Notice that anything I can't see (aside from the walls of the bar) are not rendered at all when the camera isn't looking at it.

    The walls however, are always rendered, no matter where you look, because it's all one mesh, and you're always seeing at least a part of it. Now, imagine if that was the entire map, and your scene was a large scene. Not Good.

    Now, I'll go over how to set up Occlusion. First I'll assume you've split your map into multiple meshes.

    First, create an empty game object in the scene and call it Occlusion Area. Select that Object and Add a Component, search for Occlusion Area and add it.

    Once added, you will see a green box with handles on it. Drag the handles until the box covers your scene, like so.
    [​IMG]
    Now, on the top bar of unity, go to Window > Occlusion Culling

    You'll see a window open that looks like this
    [​IMG]

    Go ahead and click the bake button once you're happy with your occlusion area from before.
    This will bake it with defaults settings. If you want to edit the parameters, you can click the "Bake" tab at the top to mess with it. Default is fine for most cases.

    Once it's baked, you can click "Visualization" at the top right of the occlusion window to see how it looks for the camera like I was doing in the Gif. Just click the main camera and move it around, spin it, etc.

    Make sure there's nothing getting hidden that you can see, and then you're golden. Your map is now mostly optimized in terms of lighting fidelity, and Occlusion.

    And that's it! You're done with the lighting of your map! Obviously, the settings for how bright lights are will changes based on the environment, but you now have a basis to go on, and a process. Now all you have to do is use the knowledge you've gained, and apply it.

    I look forward to seeing what comes of this tutorial!

    Special Thanks to all of my friends who have helped me while I've been learning, and who have given me feedback on the scenes I've lit in the past.

    Error.MDL, TCL, CubedParadox, Callay, NepsyNeptune, PC_, Mimi, Silent, and Morra!


    If you find any typos or issues with this tutorial, please message me on Discord or join my server and let me know! (clicky clicky to join my server)
    [​IMG]

    Patreon for those who would like to support me in my endeavors.
    [​IMG]
     
    #1 Xiexe, Jul 17, 2018
    Last edited: Sep 18, 2018
    Arcadia, Taiga, shotariya and 7 others like this.
  2. Silent

    Silent Member

    Joined:
    Nov 19, 2017
    Messages:
    32
    Likes Received:
    22
    This is a good guide, and I hope lots of people see it. Good lighting is, visually speaking, the most important thing for any world to get right.

    A few comments...
    I would advise against this. For one thing, objects will receive no ambient light if they aren't inheriting from light probes. This is bad if someone turns off light probe usage on their avatar to save frames. I would suggest using a neutral grey, or manually setting a gradient based on the map colours. (For outdoor maps, using the skybox is probably best.)

    When doing this, you should probably move your empty object to the origin position (0, 0, 0) first, or else you might have some annoying problems crop up later if you try to move areas around.

    While this will apply to objects currently in that hierarchy, it won't apply to anything new added afterwards.

    ...At least, I don't think it does, but it might just not apply to already existent objects you drag in.

    For placing light probes like this, I like using these tools that automatically place a grid within a defined area. The second one can follow terrain, making it great for outdoor areas. After they've placed the probes you can edit them if you want (though they both are more suited towards letting you recreate whole groups).

    https://github.com/AlexanderVorobyov/simple-light-probe-placer
    https://github.com/laurenth-unity/LightProbesPlacement

    Thanks for writing this guide! I hope lots of people benefit from it.
     
    Xiexe likes this.
  3. Xiexe

    Xiexe Member

    Joined:
    May 1, 2018
    Messages:
    17
    Likes Received:
    32
    VRChat:
    Xiexe

    Thanks for the feedback.

    I do agree that on outdoor maps you should definitely use the skybox as the ambient color, as for indoors.

    Do people actually turn off light probe sampling? I've not met anyone who does that, but if that's the case then I guess ambient gray is fine.

    I've not run into anyone who does that, but that's a fair enough of a point.


    Static doesn't apply to anything new in the heirarchy, but you can uncheck and recheck static on the parent without breaking previous lightmaps, so there is that.

    0,0,0 is also a good point, didn't figure I should specify that though as by default anything created through the heirarchy should go to 0, as opposed to something dragged into the scene.

    Speaking of probes, I should probably have gone over the anchor overrides for reflection probes. You reminded me of that.

    I will go through and update the guide with some more useful stuff once my power comes back online!
     
  4. Mimi

    Mimi New Member

    Joined:
    Nov 18, 2017
    Messages:
    7
    Likes Received:
    14