From the course: Unity: Building VR User Interfaces

Unlock the full course today

Join today to access over 22,600 courses taught by industry experts or purchase this course individually.

A better occlusion strategy

A better occlusion strategy - Unity Tutorial

From the course: Unity: Building VR User Interfaces

Start my 1-month free trial

A better occlusion strategy

- So about that occlusion strategy. When we started, we used a very simple occlusion strategy of setting all of our geometry to the transparency layer. Now, that's not a very sustainable model and we've seen that already. So now there's no one size fits all occlusion strategy. 3D projects are very complicated with a lot of different rendering pipelines, but one of my favorites is to use a stencil. Now, here on the unity 3D documentation site, under the ShaderLab Stencil, we've got some great resources for writing Stencil Shaders. We are going to be using approach directly from this documentation that's sitting right at the bottom. So let's scroll to the bottom. So here you can see the strategy that we're going to use. We're going to punch a hole directly into our 3D geometry, and we're going to put our dialogue inside. So now let's go back to the unity project. And now, to the exercise files for this video. That's going to be…

Contents