/// <summary> /// Creates a new triangle mesh in this scene. /// </summary> /// <returns>The newly created geometry.</returns> /// <param name="desc">The geometry's description.</param> public TriangleMesh NewTriangleMesh(TriangleMeshDescription desc) { CheckDisposed(); var geometry = new TriangleMesh(this, desc); geometryMapping[geometry.ID] = geometry; geometryInverse[geometry] = geometry.ID; return(geometry); }
internal TriangleMesh(Scene parent, TriangleMeshDescription desc) { this.parent = parent; this.description = desc; this.id = RTC.NewTriangleMesh(Parent.NativePtr, Description.Flags, Description.NumTriangles, Description.NumVertices, Description.LinearMotion ? 2 : 1); }