diff options
author | sr55 <[email protected]> | 2011-06-22 17:31:53 +0000 |
---|---|---|
committer | sr55 <[email protected]> | 2011-06-22 17:31:53 +0000 |
commit | 18a1a18f43a9f90eaae4eb288885e5b19048454d (patch) | |
tree | 085a06997335af23a56516fb68743c6f4b9b9716 /win/CS/Functions | |
parent | f9a3d3cd8dbb41d95e4d37c4e54f7a3c3bee9edd (diff) |
WinGui: Add DTS-HD Passthru support and a bit of code tidy-up.
git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@4076 b64f7644-9d1e-0410-96f1-a4d463321fa5
Diffstat (limited to 'win/CS/Functions')
-rw-r--r-- | win/CS/Functions/QueryGenerator.cs | 66 |
1 files changed, 4 insertions, 62 deletions
diff --git a/win/CS/Functions/QueryGenerator.cs b/win/CS/Functions/QueryGenerator.cs index 1c84fa37c..7215be30e 100644 --- a/win/CS/Functions/QueryGenerator.cs +++ b/win/CS/Functions/QueryGenerator.cs @@ -409,13 +409,13 @@ namespace Handbrake.Functions // Audio Encoder (-E)
encoders += string.IsNullOrEmpty(encoders)
- ? GetAudioEncoder(EnumHelper<AudioEncoder>.GetDescription(audioTrack.Encoder))
- : string.Format(",{0}", GetAudioEncoder(EnumHelper<AudioEncoder>.GetDescription(audioTrack.Encoder)));
+ ? Converters.GetCliAudioEncoder(audioTrack.Encoder)
+ : string.Format(",{0}", Converters.GetCliAudioEncoder(audioTrack.Encoder));
// Audio Mixdowns (-6)
mixdowns += string.IsNullOrEmpty(mixdowns)
- ? GetMixDown(EnumHelper<Mixdown>.GetDescription(audioTrack.MixDown))
- : string.Format(",{0}", GetMixDown(EnumHelper<Mixdown>.GetDescription(audioTrack.MixDown)));
+ ? Converters.GetCliMixDown(audioTrack.MixDown)
+ : string.Format(",{0}", Converters.GetCliMixDown(audioTrack.MixDown));
// Audio Samplerates (-R)
string rate = audioTrack.SampleRate == 0 ? "Auto" : audioTrack.SampleRate.ToString(); // Default to "Auto"
@@ -528,64 +528,6 @@ namespace Handbrake.Functions #region Helpers
/// <summary>
- /// Return the CLI Mixdown name
- /// </summary>
- /// <param name="selectedAudio">GUI mixdown name</param>
- /// <returns>CLI mixdown name</returns>
- private static string GetMixDown(string selectedAudio)
- {
- switch (selectedAudio)
- {
- case "Automatic":
- return "auto";
- case "Mono":
- return "mono";
- case "Stereo":
- return "stereo";
- case "Dolby Surround":
- return "dpl1";
- case "Dolby Pro Logic II":
- return "dpl2";
- case "6 Channel Discrete":
- return "6ch";
- default:
- return "auto";
- }
- }
-
- /// <summary>
- /// Get the CLI Audio Encoder name
- /// </summary>
- /// <param name="selectedEncoder">
- /// String The GUI Encode name
- /// </param>
- /// <returns>
- /// String CLI encoder name
- /// </returns>
- private static string GetAudioEncoder(string selectedEncoder)
- {
- switch (selectedEncoder)
- {
- case "AAC (faac)":
- return "faac";
- case "AAC (ffmpeg)":
- return "ffaac";
- case "MP3 (lame)":
- return "lame";
- case "Vorbis (vorbis)":
- return "vorbis";
- case "AC3 Passthru":
- return "copy:ac3";
- case "DTS Passthru":
- return "copy:dts";
- case "AC3 (ffmpeg)":
- return "ac3";
- default:
- return string.Empty;
- }
- }
-
- /// <summary>
/// Create a CSV file with the data from the Main Window Chapters tab
/// </summary>
/// <param name="mainWindow">Main Window</param>
|