summaryrefslogtreecommitdiffstats
path: root/win/CS/HandBrakeWPF/Views/VideoView.xaml.cs
diff options
context:
space:
mode:
authorRodeo <[email protected]>2013-11-08 23:04:44 +0000
committerRodeo <[email protected]>2013-11-08 23:04:44 +0000
commit2068e877b79fb5513704a6a0c12764e55e65af6e (patch)
tree7420f1cd9a7d467ad29355df39f2723573f99720 /win/CS/HandBrakeWPF/Views/VideoView.xaml.cs
parent6b27b0d868d030992cf50d2c0f9369ecfd8916d2 (diff)
WinGui: use libhb presets for QSV.
This replaces the built-in QSV presets. git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@5889 b64f7644-9d1e-0410-96f1-a4d463321fa5
Diffstat (limited to 'win/CS/HandBrakeWPF/Views/VideoView.xaml.cs')
-rw-r--r--win/CS/HandBrakeWPF/Views/VideoView.xaml.cs42
1 files changed, 8 insertions, 34 deletions
diff --git a/win/CS/HandBrakeWPF/Views/VideoView.xaml.cs b/win/CS/HandBrakeWPF/Views/VideoView.xaml.cs
index a285e490b..e9d54d4ce 100644
--- a/win/CS/HandBrakeWPF/Views/VideoView.xaml.cs
+++ b/win/CS/HandBrakeWPF/Views/VideoView.xaml.cs
@@ -43,40 +43,14 @@ namespace HandBrakeWPF.Views
private void qsv_preset_ValueChanged(object sender, RoutedPropertyChangedEventArgs<double> e)
{
- VideoViewModel mvm = ((VideoViewModel)this.DataContext);
- EncodeTask task = mvm.Task;
-
- string addon = "";
-
- if (SystemInfo.IsHswOrNewer)
- {
- if (task.VideoEncodeRateType == VideoEncodeRateType.ConstantQuality)
- {
- if (task.QsvPreset == QsvPreset.Balanced ||
- task.QsvPreset == QsvPreset.Speed)
- addon = "num-ref-frame=1";
- }
- if (task.VideoEncodeRateType == VideoEncodeRateType.AverageBitrate)
- {
- if (task.QsvPreset == QsvPreset.Quality)
- addon = "lookahead=1:gop-ref-dist=3";
- else
- if (task.QsvPreset == QsvPreset.Balanced)
- {
- addon = "num-ref-frame=1:gop-ref-dist=1";
- }
- else
- if (task.QsvPreset == QsvPreset.Speed)
- addon = "gop-ref-dist=1";
- }
- }
-
-
- string full_string = addon + ":";
-
- IDictionary<string, string> newOptions = new Dictionary<string, string>();
- string[] existingSegments = full_string.Split(':');
- foreach (string existingSegment in existingSegments)
+ VideoViewModel mvm = ((VideoViewModel)this.DataContext);
+ EncodeTask task = mvm.Task;
+
+ string full_string = "";
+
+ IDictionary<string, string> newOptions = new Dictionary<string, string>();
+ string[] existingSegments = full_string.Split(':');
+ foreach (string existingSegment in existingSegments)
{
string optionName = existingSegment;
string optionValue = string.Empty;