/// <summary> /// Export the scene. /// </summary> void CadKit.Interfaces.IExportScene.export(string filename, CadKit.Interfaces.SceneExport.Option option) { CadKit.Interfaces.IExportScene export = this.Panel as CadKit.Interfaces.IExportScene; if (null == export) { throw new System.Exception(System.String.Format("Error 1824824745: Failed to export scene file '{0}', feature not supported", filename)); } export.export(filename, option); }
/// <summary> /// Export the scene. /// </summary> void CadKit.Interfaces.IExportScene.export(string filename, CadKit.Interfaces.SceneExport.Option option) { using (this.Lock.read()) { if (CadKit.Interfaces.SceneExport.Option.ENTIRE_SCENE == option) { if (false == this.Viewer.writeSceneFile(filename)) { throw new System.Exception(System.String.Format("Error 1243330417: Failed to export scene file: {0}", filename)); } } else if (CadKit.Interfaces.SceneExport.Option.MODEL_ONLY == option) { if (false == this.Viewer.writeModelFile(filename)) { throw new System.Exception(System.String.Format("Error 3455377944: Failed to export model file: {0}", filename)); } } } }