SteamVR

SteamVR

SteamVR Workshop
Customize your SteamVR experience by finding new backgrounds, 3D environments, controllers and base station models.
Learn More
Improper Shadows / Lighting (Source 2)
Hi, I'm trying to make a house map with an interior and exterior. Unfortunately, it seems like the light is not casting shadows correctly. Here are screenshots showing the interior and exterior.
https://photos.app.goo.gl/a1WhTNC9bPpjuycj8
I've tried rebuilding my cubemaps but it does nothing. Any ideas? Thanks.
< >
Showing 1-15 of 15 comments
Nolan the Fox 8 4 Mar, 2022 @ 2:39pm 
Originally posted by Rectus:
Looks like you need to bake the lighting.
https://developer.valvesoftware.com/wiki/SteamVR/Environments/Environment_Tutorial:_Hammer_and_Basic_Lighting#Basic_Lighting
Sorry, I guess I said that wrong, when I say rebuild, I meant re-bake.
Nolan the Fox 8 4 Mar, 2022 @ 2:41pm 
https://photos.app.goo.gl/2vQ24jqAdGXVbyFy8
Here's a view of the cubemaps as well.
I had at one point also tried making one giant cubemap that encompassed the entire map, including exterior, but that did not work either, it looked the same.
Last edited by Nolan the Fox; 4 Mar, 2022 @ 2:42pm
Rectus 13 4 Mar, 2022 @ 2:52pm 
Cubemaps and light probe volumes only affect specular lighting and dynamic objects respectively. they don't affect how diffuse lighting is baked onto static surfaces.

From your images it looks like no indirect lights are baked. What settings are you using on your light_environment?
Last edited by Rectus; 4 Mar, 2022 @ 2:53pm
Nolan the Fox 8 4 Mar, 2022 @ 3:05pm 
Originally posted by Rectus:
Cubemaps and light probe volumes only affect specular lighting and dynamic objects respectively. they don't affect how diffuse lighting is baked onto static surfaces.

From your images it looks like no indirect lights are baked. What settings are you using on your light_environment?


Originally posted by Rectus:
Cubemaps and light probe volumes only affect specular lighting and dynamic objects respectively. they don't affect how diffuse lighting is baked onto static surfaces.

From your images it looks like no indirect lights are baked. What settings are you using on your light_environment?

My settings are the default for the light_environment. Indirect lighting is set to baked.
Nolan the Fox 8 4 Mar, 2022 @ 3:08pm 
It seems almost as if only the walls cast shadows, it's strange.
Nolan the Fox 8 4 Mar, 2022 @ 3:09pm 
Oh, I'm an idiot! That was exactly it. I checked under the materials, somehow, on my roof material, "Do Not Cast Shadows" was turned on.
Rectus 13 4 Mar, 2022 @ 3:10pm 
Are you baking the lighting from the menu bar with Preview Baked Lighting -> Bake All Lighting?
Nolan the Fox 8 4 Mar, 2022 @ 3:11pm 
Originally posted by Rectus:
Are you baking the lighting from the menu bar with Preview Baked Lighting -> Bake All Lighting?
Yes, I am.
Rectus 13 4 Mar, 2022 @ 3:23pm 
Guessing the shadows being pitch black is caused by vertices being occluded and low vertex density. You may need to clean up your geometry to get it to light properly, as well as adding some subdivisions.

You can also get better (and vertex density independent) lighting resolution by using lightmapping instead of vertex lighting. It is enabled by compiling the map itself with Custom settings, and checking the Generate Lightmaps option. It will only show up in-game, not in the editor. It can also take a very long time to generate depending on the resolution setting.
Nolan the Fox 8 4 Mar, 2022 @ 3:45pm 
Originally posted by Rectus:
Guessing the shadows being pitch black is caused by vertices being occluded and low vertex density. You may need to clean up your geometry to get it to light properly, as well as adding some subdivisions.

You can also get better (and vertex density independent) lighting resolution by using lightmapping instead of vertex lighting. It is enabled by compiling the map itself with Custom settings, and checking the Generate Lightmaps option. It will only show up in-game, not in the editor. It can also take a very long time to generate depending on the resolution setting.

Ok, thanks.
Also, I added a bunch of lights, they seem to not always render, you have to be looking directly at them / within a range. Is there a way to fix this? Some areas appear dark because of this.
Rectus 13 4 Mar, 2022 @ 4:07pm 
It's limited to 16 real-time lights visible at the same time. To get more, you will have to bake them. I don't think fully baking them works properly with vertex lighting, only when using the lightmapper.
Nolan the Fox 8 4 Mar, 2022 @ 4:17pm 
Originally posted by Rectus:
It's limited to 16 real-time lights visible at the same time. To get more, you will have to bake them. I don't think fully baking them works properly with vertex lighting, only when using the lightmapper.
Ah ok, thanks.
< >
Showing 1-15 of 15 comments
Per page: 1530 50