Пример #1
0
        /// <summary>
        /// Returns a <see cref="TriangleMesh"/> object loaded from the specified OBJ file stream.
        /// </summary>
        /// <param name="stream">The stream for the OBJ to load.</param>
        /// <returns>The mesh loaded from the OBJ file stream.</returns>
        public static PolygonMesh3D FromObjStream(Stream stream)
        {
            PolygonMesh3D m = new PolygonMesh3D();

            m.LoadObjStream(stream);
            return(m);
        }
Пример #2
0
        /// <summary>
        /// Returns a <see cref="TriangleMesh"/> object loaded from the specified OBJ file.
        /// </summary>
        /// <param name="fileName">The name of the OBJ file to load.</param>
        /// <returns>The mesh loaded from the OBJ file.</returns>
        public static PolygonMesh3D FromObjFile(string fileName)
        {
            PolygonMesh3D m = new PolygonMesh3D();

            m.LoadObjFile(fileName);
            return(m);
        }