summaryrefslogtreecommitdiffstats
path: root/win/CS/HandBrake.Interop/HandBrakeInterop/Converters.cs
diff options
context:
space:
mode:
authorrandomengy <[email protected]>2011-07-24 19:04:13 +0000
committerrandomengy <[email protected]>2011-07-24 19:04:13 +0000
commitd03140dd43594dafbf6f7f474ee06b45afc1b903 (patch)
tree700ad66da60f01e9d1b399dbead00f91f1d8c039 /win/CS/HandBrake.Interop/HandBrakeInterop/Converters.cs
parent2f8559933d48333e463a548152197db4cb926971 (diff)
Add DTS-HD and DRC to HandBrakeInterop. Update libhb audio structures. Fix test project build failures.
git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@4138 b64f7644-9d1e-0410-96f1-a4d463321fa5
Diffstat (limited to 'win/CS/HandBrake.Interop/HandBrakeInterop/Converters.cs')
-rw-r--r--win/CS/HandBrake.Interop/HandBrakeInterop/Converters.cs11
1 files changed, 8 insertions, 3 deletions
diff --git a/win/CS/HandBrake.Interop/HandBrakeInterop/Converters.cs b/win/CS/HandBrake.Interop/HandBrakeInterop/Converters.cs
index cbe3cce9f..ee49c5802 100644
--- a/win/CS/HandBrake.Interop/HandBrakeInterop/Converters.cs
+++ b/win/CS/HandBrake.Interop/HandBrakeInterop/Converters.cs
@@ -16,7 +16,7 @@ namespace HandBrake.Interop
using HandBrake.Interop.Model.Encoding;
using HandBrake.Interop.SourceData;
- public static class Converters
+ public static class Converters
{
private static Dictionary<double, int> vrates = new Dictionary<double, int>
{
@@ -83,14 +83,17 @@ namespace HandBrake.Interop
throw new ArgumentException("Unrecognized mixdown: " + mixdown, "mixdown");
}
+ /// <summary>
+ /// Gets the native code for the given encoder.
+ /// </summary>
+ /// <param name="encoder">The audio encoder to convert. Cannot be AudioEncoder.Passthrough.</param>
+ /// <returns>The native code for the encoder.</returns>
public static uint AudioEncoderToNative(AudioEncoder encoder)
{
switch (encoder)
{
case AudioEncoder.Ac3Passthrough:
return NativeConstants.HB_ACODEC_AC3_PASS;
- case AudioEncoder.DtsPassthrough:
- return NativeConstants.HB_ACODEC_DCA_PASS;
case AudioEncoder.Faac:
return NativeConstants.HB_ACODEC_FAAC;
case AudioEncoder.Lame:
@@ -112,6 +115,8 @@ namespace HandBrake.Interop
return AudioCodec.Ac3;
case NativeConstants.HB_ACODEC_DCA:
return AudioCodec.Dts;
+ case NativeConstants.HB_ACODEC_DCA_HD:
+ return AudioCodec.DtsHD;
default:
return AudioCodec.Other;
}