protected MeshFile(string filePath, FileMode fileMode, MeshFileFormat meshFileFormat = MeshFileFormat.BINARY) { FilePath = filePath; FileFormat = meshFileFormat; MeshStream = new FileStream(filePath, fileMode); }
public static MeshFile CreateInstance(string filePath, FileMode fileMode, MeshFileFormat fileFormat = MeshFileFormat.BINARY) { var fileExtension = FindFileExtension(filePath); return(fileExtension?.FileFormatType.CreateInstance <MeshFile>(filePath, fileMode, fileFormat)); }