GeneratePerTriangleUV() public static method

Will generate per-triangle uv (3 UVs for each triangle) with default settings.

public static GeneratePerTriangleUV ( Mesh src ) : Vector2[]
src UnityEngine.Mesh The source mesh to generate UVs for.
return Vector2[]
Example #1
0
        public static Vector2[] GeneratePerTriangleUV(Mesh src)
        {
            UnwrapParam settings = default(UnwrapParam);

            UnwrapParam.SetDefaults(out settings);
            return(Unwrapping.GeneratePerTriangleUV(src, settings));
        }
Example #2
0
 public static void GenerateSecondaryUVSet(Mesh src, UnwrapParam settings)
 {
     MeshUtility.SetPerTriangleUV2(src, Unwrapping.GeneratePerTriangleUV(src, settings));
 }