On Unity's web site (https://docs.unity3d.com/2017.3/Documentation/Manual/SL-SurfaceShaderExamples.html), Custom data computed per-vertex Shader has a bug, when I try the shader I get correct result in Scene view but not int Game view.
The fix is normalizing the normals.Just add normalize.
void vert (inout appdata_full v, out Input o) {
UNITY_INITIALIZE_OUTPUT(Input,o);
o.customColor = normalize(abs(v.normal));
}
Then correct result is:
if debugging is the art of removing bugs, then programming must be the art of inserting them..
Subscribe to:
Post Comments (Atom)
Visual Studio Keyboard Shortcuts
Playing with keyboard shortcuts is very interesting and reduce the headache of using the mouse again and again while programming with visu...
-
A quick reference for working with AGAL, the new shader language for use with Stage3D introduced with Flash Player 11. Registers: Each r...
-
The Linux file system is the structure in which all the information on your computer is stored.Files are organized within a hierarchy of dir...
-
http://www.dgp.toronto.edu/~rms/links.html Papers Ke-Sen Huang's comprehensive and invaluable Conference Paper Link Archive Mesh Libra...


No comments:
Post a Comment