cakeslice / Outline-Effect

Outline Image Effect for Unity

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

unnecessary draw call and mistakes when submeshes use different texture

karsuszhang opened this issue · comments

I found it has many unnecessary draw calls when outline camera render. And if submeshes use different material with different texture, it causes some mistakes, especially when you use mesh to render atlas, like spine object.

It's wierd to render SharedMaterials.Length * (sharedMesh.subMeshCount - 1) times in OutlineEffect's OnPreRender(). I can't get why. So I change the render times to correspond to outline.SharedMaterials.Length
捕获
Everything works fine. Is this a bug or there's some consideration in it ?