private void gr2BatchConvertBtn_Click(object sender, EventArgs e) { gr2BatchConvertBtn.Enabled = false; var exporter = new Exporter(); UpdateCommonExporterSettings(exporter.Options); if (gr2BatchInputFormat.SelectedIndex == 0) { exporter.Options.InputFormat = ExportFormat.GR2; } else { exporter.Options.InputFormat = ExportFormat.DAE; } if (gr2BatchOutputFormat.SelectedIndex == 0) { exporter.Options.OutputFormat = ExportFormat.GR2; } else { exporter.Options.OutputFormat = ExportFormat.DAE; } var batchConverter = new GR2Utils(); batchConverter.progressUpdate = GR2ProgressUpdate; batchConverter.conversionError = GR2ConversionError; batchConverter.ConvertModels(gr2BatchInputDir.Text, gr2BatchOutputDir.Text, exporter); gr2BatchConvertBtn.Enabled = true; MessageBox.Show("Batch export completed."); }
private void LoadFile(string inPath) { _root = GR2Utils.LoadModel(inPath); UpdateInputState(); }