Would very much appreciate this; it should absolutely be a standard feature for Highlights. This option would give us the ability to add highlights to teammates or players occluded from the camera without making them too distracting.
This type of culling mode has been requested as it is useful in some cases. Unfortunately it is very hard to do efficiently do this for low end devices. We will continue to develop this feature to see if we come up with a good efficient solution for this and if so we can add it as a new depth mode.
To clarify the difficult bit is dealing with self occlusion. You don’t want the shading effect to apply when a part of the object in question is occluded by itself. Only by other objects in the world.
Is there more information about how the effect is rendered that can be shared? Just purely for curiosity.
Wondering if this is done with an edge detection algorithm over some intermediary texture. I imagine you could avoid self occlusion issues by using a texture that contains instance silhouettes by some id (e.g. outline group), but since that would have been done if that were possible I’m curious where the difficulty actually is. Maybe it’s the silhouette texture that’s the challenge?
Yes each instance of a highlight has a unique ID associated. A fullscreen pass will dry an outline if this ID is different either vertically or diagonally for each pixel.
This effect can be achieved by reading in the current depth buffer and outputting the ID only if the current depth is closer than the highlighted depth. Even then you may not want to overide a current depth which is closer to the camera.
The main difficulty is in the fallback pass for low end devices. These do not do an explicit full screen edge detect pass due to the cost. These render straight to the screen using a bayer screendoor pattern to simulate 4 levels of translucency.
Thank you for the detail! It sounds like that approach is very close to what I had expected. I think I get where the trouble is with self occlusion if you’re doing it that way. With respect to the fallback pass though, does that mean you’re (currently) just not doing the outlines on low end devices, and only the fill color?
It has been a while, have there been any progress on this feature? I don’t really find the highlight instance useful for my experiences without this option.
Bumping. This is a very important feature that should be added.
Complex maps that frequently block the player’s view can be quite jarring as they cannot see where their character is. Having highlights only show on occluded regions is very, very helpful in these cases.
Just wish to bump this because I am currently having to use a hacky solution to achieve the desired effect, I am currently using 2 Highlights. One set to AlwaysOnTop with your desired settings; then on game-start (or regularly because the effect does wear off after a bit) clone that whole object / model and set the new Highlight (under the cloned Model) to Occluded with 0.999OutlineTransparency and the 1FillTransparency. I’m well aware that this is betting on the order of drawing always being the same and that may not be the case, hence why I want this to be an official feature. This also creates visual artifacts in certain scenarios.
This is pretty cool, but it would be kind of problematic if your use case was to put the highlight on player’s character as duplicating them will have undesired behaviour. Creative though!
bump part 2 MY VIEWMODELS NEEED THIIIIS
(my viewmodel is parented to the camera, and it would be cool to add an occluded only highlight effect where the parts clipping into a wall would still be visible)