Exemplo n.º 1
0
    public void DeformCGAL(Vector3 direction)
    {
        Mesh mesh = MeshManager.Instance.mesh;

        float[] directionFloat = { direction.x, direction.y, direction.z };
        CGAL.DeformMesh(heart, directionFloat);
        Vector3[] newVertices = CGAL.ConvertToVector(CGAL.GetVertices(heart), CGAL.GetNumberOfVertices(heart), GameObject.Find("PartialModel").transform);
        mesh.vertices = newVertices;
    }