Author Topic: Just a minor fix to a wrong shader log error  (Read 4775 times)

BGL

  • Newbie
  • *
  • Thank You
  • -Given: 0
  • -Receive: 0
  • Posts: 9
    • View Profile
Just a minor fix to a wrong shader log error
« on: November 20, 2013, 03:22:05 AM »
Hi, I I had an issue with a shader and due to that the log
"Unlit/Transparent doesn't have a clipped shader version for NONE"
show up, but the correct message should be
"Unlit/Transparent doesn't have a clipped shader version for AlphaClip"
The problem is that you reset the clipping to None before the log in UIDrawCall.UpdateMaterials, so the code
  1.                                 mClipping = Clipping.None;
  2.                                 Debug.LogError(shaderName + " doesn't have a clipped shader version for " + mClipping);
  3.  
should be
  1.                                 Debug.LogError(shaderName + " doesn't have a clipped shader version for " + mClipping);
  2.                                 mClipping = Clipping.None;
  3.  

If you want the message to be a better hint on how to fix the issue, I think the material name should be logged too.
Thanks

ArenMook

  • Administrator
  • Hero Member
  • *****
  • Thank You
  • -Given: 337
  • -Receive: 1171
  • Posts: 22,128
  • Toronto, Canada
    • View Profile
Re: Just a minor fix to a wrong shader log error
« Reply #1 on: November 20, 2013, 03:57:32 AM »
Thanks, I actually found this myself and fixed it about 2 hours ago. :)