Example #1
0
 protected MeshFile(string filePath, FileMode fileMode, MeshFileFormat meshFileFormat = MeshFileFormat.BINARY)
 {
     FilePath   = filePath;
     FileFormat = meshFileFormat;
     MeshStream = new FileStream(filePath, fileMode);
 }
Example #2
0
        public static MeshFile CreateInstance(string filePath, FileMode fileMode, MeshFileFormat fileFormat = MeshFileFormat.BINARY)
        {
            var fileExtension = FindFileExtension(filePath);

            return(fileExtension?.FileFormatType.CreateInstance <MeshFile>(filePath, fileMode, fileFormat));
        }