SteamVR
SteamVR Workshop
Customize your SteamVR experience by finding new backgrounds, 3D environments, controllers and base station models.
了解更多
Nolan the Fox 8 2022 年 3 月 4 日 下午 2:00
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.
< >
正在显示第 1 - 15 条,共 15 条留言
Nolan the Fox 8 2022 年 3 月 4 日 下午 2:39 
引用自 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 2022 年 3 月 4 日 下午 2:41 
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.
最后由 Nolan the Fox 编辑于; 2022 年 3 月 4 日 下午 2:42
Rectus 13 2022 年 3 月 4 日 下午 2:52 
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?
最后由 Rectus 编辑于; 2022 年 3 月 4 日 下午 2:53
Nolan the Fox 8 2022 年 3 月 4 日 下午 3:05 
引用自 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?


引用自 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 2022 年 3 月 4 日 下午 3:08 
It seems almost as if only the walls cast shadows, it's strange.
Nolan the Fox 8 2022 年 3 月 4 日 下午 3:09 
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 2022 年 3 月 4 日 下午 3:10 
Are you baking the lighting from the menu bar with Preview Baked Lighting -> Bake All Lighting?
Nolan the Fox 8 2022 年 3 月 4 日 下午 3:11 
Nolan the Fox 8 2022 年 3 月 4 日 下午 3:11 
引用自 Rectus
Are you baking the lighting from the menu bar with Preview Baked Lighting -> Bake All Lighting?
Yes, I am.
Rectus 13 2022 年 3 月 4 日 下午 3:23 
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 2022 年 3 月 4 日 下午 3:45 
引用自 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 2022 年 3 月 4 日 下午 4:07 
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 2022 年 3 月 4 日 下午 4:17 
引用自 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.
< >
正在显示第 1 - 15 条,共 15 条留言
每页显示数: 1530 50