Exemplo n.º 1
0
        public void AreaWeightedNormals(Vector3[] vertices, ref Vector3[] normals)
        {
            if (!initialized)
            {
                return;
            }

            GCHandle normalsHandle  = Oni.PinMemory(normals);
            GCHandle verticesHandle = Oni.PinMemory(vertices);

            Oni.AreaWeightedNormals(halfEdgeMesh, verticesHandle.AddrOfPinnedObject(), normalsHandle.AddrOfPinnedObject());

            Oni.UnpinMemory(normalsHandle);
            Oni.UnpinMemory(verticesHandle);
        }