예제 #1
0
 protected override void ExportCore(Scene model, Stream destination, string fileName)
 {
     if (destination is FileStream fileStream)
     {
         AssimpSceneHelper.Export(model, fileStream.Name);
     }
     else
     {
         throw new ArgumentException("Assimp scene can only be exported to file stream", nameof(destination));
     }
 }
예제 #2
0
 protected override Scene ImportCore(Stream source, string fileName)
 {
     return(source is FileStream fileStream
         ? AssimpSceneHelper.Import(fileStream.Name)
         : throw new ArgumentException("Assimp scene can only be imported from a file stream", nameof(source)));
 }