Search Unity

  1. Unity Asset Manager is now available in public beta. Try it out now and join the conversation here in the forums.
    Dismiss Notice

stats window triangle count and normal calculation bug?

Discussion in '2017.3 Beta' started by laurentlavigne, Dec 8, 2017.

  1. laurentlavigne

    laurentlavigne

    Joined:
    Aug 16, 2012
    Posts:
    6,327
    Back in the days, if I import a sphere and set the import normal smoothing angle to 0 to turn it into a faceted sphere, I'd get double the number of triangles because internally, unity would duplicate edges.
    what I'm seeing now is that if I set the smoothing angle to 180 or 0 won't change the polycount of the scene.
    Is this a bug in the stats window or a new way unity handles normal angle at import?
     
  2. markvi

    markvi

    Joined:
    Oct 31, 2016
    Posts:
    118
    Do you still get a faceted sphere? Because if not, this sounds suspiciously like a bug and should be logged. :)

    But if you still get a faceted sphere, all is good. Vertex count should increase, but not triangle count.
     
    laurentlavigne likes this.
  3. laurentlavigne

    laurentlavigne

    Joined:
    Aug 16, 2012
    Posts:
    6,327
    I was looking at polycount, thanks! yes vertex quadruple.
     
  4. laurentlavigne

    laurentlavigne

    Joined:
    Aug 16, 2012
    Posts:
    6,327
    While I have your attention, I want to do flat shaded but without the vertex cost. In the past I've used the nointerpolation keyword writing a very simple CG shader but now I need to use surface shader what's the keyword in that?

    Code (CSharp):
    1.             struct v2f
    2.             {
    3.                 float2 uv : TEXCOORD0;
    4.                 SHADOW_COORDS(1)
    5.                 nointerpolation fixed3 diff : COLOR0;
    6.                 nointerpolation fixed3 ambient : COLOR1;
    7.                 float4 pos : SV_POSITION;
    8.             };
     
  5. hippocoder

    hippocoder

    Digital Ape

    Joined:
    Apr 11, 2010
    Posts:
    29,723
    Please restrict posting in beta forums for beta issues, this is clearly spelled out in the rules. If we don't enforce some sanity, everyone else will do it.

    Hopefully someone can reply to your issue anyway.