Basics of Interior Lighting in Unity [URP] - Realtime Interior Lighting

Video Statistics and Information

Video
Captions Word Cloud
Reddit Comments
Captions
in this video we are going to learn about the very basics of lighting and how to set up both real time and back lighting for an interior scene like this one here this video is completely beginner friendly as i think lighting can be a very complicated topic but i'll make sure to keep this as simple as possible so yeah let's get started all right so we're gonna start off with a completely empty unity scene so i've just got the camera and the directional lighting but the first thing before we get started is to use the unity's universal render pipeline and i've already had this in my project but if you don't just go to windows and package manager and here search for universal rp so let's just go ahead and import this to your unity project and once it's finished importing all you need to do is right click and create go to rendering universal render pipeline and click on this and click on this pipeline asset and you'll see a couple icons like this one here and this will be your pipeline asset i've gone ahead and made a couple of copies for different quality settings high medium and low you actually need one to get started and as for the environment i'm using this one here from working dogs 3d free modular kit i've already installed it it's actually pretty low on size so we're just gonna go ahead and use this one so once you download it you will see a folder like this and inside of the 3d modular kit you will see a sample scene so what i have done is i have made a prefab of the whole level so if i just drag and drop this inside of my scene we'll have the complete environment in our scene it looks something like this and another thing that i've done is get all of the lightings inside another game object that i've saved as a prefab here so this scene doesn't have any lights so i'm just gonna go ahead and add the light fixtures using this prefab here it will add all of these lights inside of the scene as you can see here so now we have all of our light fixtures here if i just zoom in on one of them it looks something like this and each of these lights have this uh emissive neon material as you can see here all right so now basically our scene is ready so we're just gonna get rid of the directional lighting because we want to start from scratch all right but our scene still looks bright don't have any lights and you might be wondering why if we go to the lighting tab you will see we are using the skybox as the source of our environment lighting let's get rid of this and instead use color and now we can have more control over the environment lighting so let's just go complete dark and now we don't see any of the lighting here except for these emissive materials and we can also get rid of them for now so we can start from stretch and here you can see the emission is enabled we can just go ahead and disable this we won't be able to see any lighting inside scene whatsoever and we can also go ahead and change the color of this emissive material but for now we're gonna keep this as is and this seems to be a good starting point so let's go to the lighting step and what i'm gonna do is change the ambient color to uh slightly grayish so we can actually see our environment just a tiny bit and now we are ready to add the lighting to our environment but before we actually do that let's open up the project settings and here we need to find the player settings go to other settings and change the color best from gamma to linear so make sure you set it to linear as the environment appears more natural than the gamma lighting and now we are finally ready to add some lighting to our scene i already have the light fixtures so we can just go ahead and add lights to these uh light fixtures but i've already gone ahead and made a prefab that has all the positions and transform for each of the lighting and here we go so as you can see i have a bunch of spot lights in our scene now well technically these are the point lights as you can see these are these are actually point lights with pretty much the default settings as you can see i've just changed the color of some of the lights to blue and purple alright so yeah this is how the scene looks with the lighting so now we can just go ahead and play around with some of the light settings also if we zoom in on the unknown these emissive materials we can see they don't actually glow like like a light source so in order to make these look like lighting we need to go to the project settings and find the rendering pipeline asset that we are using and also make sure that you have assigned the pipeline asset to the rendering slot here so you can use the multiple quality settings like i've done here so different pipeline assets for different quality settings right now i'm using the high quality so i'm just gonna click on this go to the quality drop down and make sure the sdr is enabled and as soon as you enable this you can see a slight changing in the emissive material they begin to glow but still they don't act like a light source right and in order to make sure that they act like a light source we need to use the post processing effects so i'm just going to go ahead and create a new empty game object and i'm just going to call it post processing or pp for short and make sure the transform is reset and now let's add the volume script make sure the mod is set to global let's create a new cross processing profile here all right and now we can use the overrides here let's hit add override post processing and we're gonna use bloom to make sure that these emissive materials act like a light source and to enable all of these settings at once just click on alt and now we can play around with these settings let's set the intensity to 2 maybe yeah it seems a bit too much but we're going to change it later as for the threshold i'm just going to keep it at 1.5 or something so that only the brightness of the materials get to glow and now as you can see these msm materials start to act like a light source right and yeah i know i need to change the color of the lights but for now i'm just gonna keep it as is but as you can see the problem here is the emissive materials are glowing inside of the scene but in the gamecube we don't actually see anything and that is because we also need to uh make the camera render the post processing effects and here make sure the post processing is enabled and as soon as you do this we can see the post processing effects work on the game view and yeah it looks quite good already but i know we can do a much better job at this so let's go back and change this a bit and also i'm sure you can not notice these light artifacts that we can see here and that is because we are using the point lights instead of a spotlight so if we just go change the type you will see that the light no longer hits the series and that is what we want actually because the light fixtures are pointing down and not upwards so so yeah it would make sense if the light goes down and not hit the ceiling but as you can see our ceiling gets completely dark so for now we are going to use the point lights and i'm gonna show you how to fix this without changing the type to spotlights and the next thing we want to do is add some more reflections to our scene and for that we're just gonna add a reflection prop to our environment right click light and reflection pro here it is and if we have to focus on it you can see this bulk which indicates the area that this reflection will work and we can change this using this box size settings so let's increase the size to fix all of the environment something like this appears to be good right also what we need to do is enable the box projection oh and keep all of these settings as is for now and also change the type from back to real time because we want to see how it looks in real time and as you can see now the environment starts to reflect more lighting and it looks good so you can see the effect of the reflection probe on our environment also make sure you keep the refresh mode to on away if the scene is completely static like this one here we can also play around with the intensity let's bump it up to like 1.2 so whatever works for you you can just go crazy with it and yeah for now 1.2 looks to be a good value all right so after the reflection prop the next thing we need to do is go to the postpartum effects and we're gonna add another override which will be the um tone mappings let's just find the tone mapping here and let's enable this we're going to change the mode to s's and it will give our environment a more cinematic look as you can see but it also makes it a bit too dark for our test right so in order to counteract this we are going to add another override which will be a color adjustment and for this one i'm just gonna set the post exposure to 0.2 0.3 yeah 0.3 looks to be a good value and also set the contrast to maybe 10 10 is a bit too much so let's go with five yep five looks to be a good value for saturation i'm also gonna bump it up to five you can of course go crazy on this but five seems to be a good value all right and now we are ready to play this and yeah i think it starts to look good already doesn't it but yeah of course we can do a much better job and we will and also the first thing we need to do is bump up the reflection resolution so if we just close this and go to reflection probe and let's bump up the resolution to 512 all right and and now this should make the reflections look a bit vivid and clear and now we are ready to use the back lighting to make our scene look even more better but this video has grown out to be too long so i'm just gonna divide this into two parts so so in the second part we will handle all the back lighting so stay tuned for that and it will be out soon thanks for watching i'll see you in the next one you
Info
Channel: The Game Guy
Views: 39,056
Rating: undefined out of 5
Keywords: lighting, Interior lighting unity, unity lighting tutorial, unity lighting urp, interior lighting urp, basics of lighting in unity, environment lighting unity, unity urp, realtime lighting unity, unity interior lighting tutorial, unity lighting mobile, unity mobile lighting, unity environment lighting
Id: QhVPi1bfVEA
Channel Id: undefined
Length: 12min 9sec (729 seconds)
Published: Mon Mar 22 2021
Related Videos
Note
Please note that this website is currently a work in progress! Lots of interesting data and statistics to come.