summaryrefslogtreecommitdiffstats
path: root/win/CS/HandBrake.Interop
diff options
context:
space:
mode:
authorsr55 <[email protected]>2015-01-17 22:04:33 +0000
committersr55 <[email protected]>2015-01-17 22:04:33 +0000
commit7f7da739dc4485771416931aab652b6651737d69 (patch)
tree11f8d2f443d636679f0ef477f2da7d90b8dee146 /win/CS/HandBrake.Interop
parent75d7e2000d61c63e91f3e2d153be30e9db27b5e7 (diff)
WinGui: Don't set audio rate fields in the json message for passthru.
git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@6764 b64f7644-9d1e-0410-96f1-a4d463321fa5
Diffstat (limited to 'win/CS/HandBrake.Interop')
-rw-r--r--win/CS/HandBrake.Interop/HandBrakeInterop/Json/Factories/EncodeFactory.cs23
-rw-r--r--win/CS/HandBrake.Interop/HandBrakeInterop/Model/Encoding/AudioEncoding.cs5
2 files changed, 18 insertions, 10 deletions
diff --git a/win/CS/HandBrake.Interop/HandBrakeInterop/Json/Factories/EncodeFactory.cs b/win/CS/HandBrake.Interop/HandBrakeInterop/Json/Factories/EncodeFactory.cs
index 6d10b64eb..51b29533f 100644
--- a/win/CS/HandBrake.Interop/HandBrakeInterop/Json/Factories/EncodeFactory.cs
+++ b/win/CS/HandBrake.Interop/HandBrakeInterop/Json/Factories/EncodeFactory.cs
@@ -307,19 +307,22 @@ namespace HandBrake.Interop.Json.Factories
Name = item.Name,
};
- if (item.EncodeRateType == AudioEncodeRateType.Quality)
+ if (!item.IsPassthru)
{
- audioTrack.Quality = item.Quality;
- }
+ if (item.EncodeRateType == AudioEncodeRateType.Quality)
+ {
+ audioTrack.Quality = item.Quality;
+ }
- if (item.EncodeRateType == AudioEncodeRateType.Compression)
- {
- audioTrack.CompressionLevel = item.Compression;
- }
+ if (item.EncodeRateType == AudioEncodeRateType.Compression)
+ {
+ audioTrack.CompressionLevel = item.Compression;
+ }
- if (item.EncodeRateType == AudioEncodeRateType.Bitrate)
- {
- audioTrack.Bitrate = item.Bitrate;
+ if (item.EncodeRateType == AudioEncodeRateType.Bitrate)
+ {
+ audioTrack.Bitrate = item.Bitrate;
+ }
}
audio.AudioList.Add(audioTrack);
diff --git a/win/CS/HandBrake.Interop/HandBrakeInterop/Model/Encoding/AudioEncoding.cs b/win/CS/HandBrake.Interop/HandBrakeInterop/Model/Encoding/AudioEncoding.cs
index 5d76a9f5d..2f08623c1 100644
--- a/win/CS/HandBrake.Interop/HandBrakeInterop/Model/Encoding/AudioEncoding.cs
+++ b/win/CS/HandBrake.Interop/HandBrakeInterop/Model/Encoding/AudioEncoding.cs
@@ -80,5 +80,10 @@ namespace HandBrake.Interop.Model.Encoding
/// Gets or sets Name.
/// </summary>
public string Name { get; set; }
+
+ /// <summary>
+ /// Gets or sets a value indicating whether is passthru.
+ /// </summary>
+ public bool IsPassthru { get; set; }
}
}