Skip to content

Outline of renderers with no material? #33

@STARasGAMES

Description

@STARasGAMES

It's potentially a good feature to be able to render outlines for invisible objects.

The easiest way to make object invisible is to disable the renderer component, but UnityFx.Outline ignores such renderers.

The second way is to remove all materials from renderer (what I previously was doing with another outline asset), but again, UnityFx.Outline just ignores such renderers.

As a workaround, I'm replacing empty materials with material, that draws nothing. Here is the shader code for this:

Shader "Custom/HiddenPass" {
    SubShader
    {
        Tags {"Queue" = "Geometry-1" }
 
        Lighting Off
 
        Pass
 
        {
            ZWrite Off
            ColorMask 0    
        }
    }
}

But maybe it makes sense to support this natively.

Metadata

Metadata

Assignees

Labels

enhancementNew feature or request

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions