예제 #1
0
        // TODO: it seems to me that the DocumentBuilder should track the "IMesh" as it is added.
        // However I have to take into account the fact that the DocumentBUilder is aware of GeometryBuilder but not IMesh
        public static int AddNode(this DocumentBuilder db, Matrix4x4 transform, IMesh mesh, IndexedSet <IMesh> meshes)
        {
            var gid = mesh != null?meshes.GetOrAdd(mesh) : -1;

            db.AddNode(transform, gid, -1, -1);
            return(db.Nodes.Count - 1);
        }