cakeslice / Outline-Effect

Outline Image Effect for Unity

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Rendering LODs

miroki123 opened this issue · comments

There's a problem when rendering LODs using this Outline-Effect plugin. If you have a LOD swap in the middle of an animation, the outline will encompass both LOD renderers.

I tried creating a pull request but it's denied, so the way I fixed it on my end was by adding this code to Outline.cs

private bool visible;

private void OnBecameVisible()
{
    visible = true;
}

private void OnBecameInvisible()
{
    visible = false;
}

public bool IsVisible => visible;

And then this code to OutlineEffect.cs

foreach (Outline outline in outlines)
{
    if (!outline.IsVisible)
        continue;

"I tried creating a pull request but it's denied" - Weird, what is the message?

Thanks for your contribution, I will push this.

You put the check here right?
image

Exactly. Thanks for this amazing plugin!