summaryrefslogtreecommitdiffstats
path: root/win
diff options
context:
space:
mode:
authorsr55 <[email protected]>2012-05-01 00:55:30 +0000
committersr55 <[email protected]>2012-05-01 00:55:30 +0000
commit356045a1bf9dc82e108a8832674d623be17b6338 (patch)
treee3e309b755bbb170d9820654951906f370b77613 /win
parent4b99eac923d164a5a7e726370dbdb04324fea3da (diff)
WinGui: (WPF) Updates to the new Query Generator to deal with passthru tracks correctly.
git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@4615 b64f7644-9d1e-0410-96f1-a4d463321fa5
Diffstat (limited to 'win')
-rw-r--r--win/CS/HandBrake.ApplicationServices/Utilities/QueryGeneratorUtility.cs15
1 files changed, 8 insertions, 7 deletions
diff --git a/win/CS/HandBrake.ApplicationServices/Utilities/QueryGeneratorUtility.cs b/win/CS/HandBrake.ApplicationServices/Utilities/QueryGeneratorUtility.cs
index 5572f8cb2..d9f909d78 100644
--- a/win/CS/HandBrake.ApplicationServices/Utilities/QueryGeneratorUtility.cs
+++ b/win/CS/HandBrake.ApplicationServices/Utilities/QueryGeneratorUtility.cs
@@ -497,19 +497,19 @@ namespace HandBrake.ApplicationServices.Utilities
codecs.Add(track.Encoder);
// Audio Mixdown (-6)
- mixdowns.Add(track.MixDown);
+ mixdowns.Add(track.IsPassthru ? Mixdown.None : track.MixDown);
// Sample Rate (-R)
- samplerates.Add(track.SampleRate);
+ samplerates.Add(track.IsPassthru ? 0 : track.SampleRate);
// Audio Bitrate (-B)
- bitrates.Add(track.Bitrate);
+ bitrates.Add(track.IsPassthru ? 0 : track.Bitrate);
// DRC (-D)
- drcs.Add(track.DRC);
+ drcs.Add(track.IsPassthru ? 0 : track.DRC);
// Gain (--gain)
- gains.Add(track.Gain);
+ gains.Add(track.IsPassthru ? 0 : track.Gain);
}
// Audio Track (-a)
@@ -566,13 +566,14 @@ namespace HandBrake.ApplicationServices.Utilities
// Sample Rate (-R)
foreach (double item in samplerates)
{
+ string add = (item == 0.0) ? "Auto" : item.ToString();
if (firstLoop)
{
- audioItems = item.ToString();
+ audioItems = add;
firstLoop = false;
}
else
- audioItems += "," + item;
+ audioItems += "," + add;
}
if (audioItems.Trim() != String.Empty)
query += " -R " + audioItems;