private void MixdownAudio_Click( object sender, EventArgs e ) {
if( !File.Exists( blendFilePathTextBox.Text ) ) {
return;
}
if( !Directory.Exists( outFolderPathTextBox.Text ) ) {
Directory.CreateDirectory( outFolderPathTextBox.Text );
}
Process p = new Process();
p.StartInfo.FileName = "blender";
p.StartInfo.RedirectStandardOutput = true;
p.StartInfo.UseShellExecute = false;
//Using minimized instead so we get feedback
//p.StartInfo.CreateNoWindow = true;
p.StartInfo.WindowStyle = ProcessWindowStyle.Minimized;
p.StartInfo.Arguments = String.Format("-b \"{0}\" -P \"{1}\"",
blendFilePathTextBox.Text,
Path.Combine(ScriptsPath, "mixdown_audio.py")
);
p.Start();
p.WaitForExit((int)TimeSpan.FromMinutes(5).TotalMilliseconds);
Trace.WriteLine("MixDown Completed");
}