Commit abc1863b authored by GitLab CI's avatar GitLab CI

Merge remote-tracking branch 'upstream/master' into master-build

* upstream/master:
  WinGui: Fix fast decode tune with x264 vs x265. #2083
parents e0ec70d5 465d9f76
Pipeline #60397843 passed with stages
in 69 minutes and 51 seconds
......@@ -610,6 +610,8 @@ namespace HandBrakeWPF.ViewModels
}
}
public bool DisplayFastDecode { get; set; }
/// <summary>
/// Gets or sets a value indicating whether display level control.
/// </summary>
......@@ -661,10 +663,6 @@ namespace HandBrakeWPF.ViewModels
}
set
{
if (value.Equals(this.fastDecode))
{
return;
}
this.fastDecode = value;
// Update the encode task
......@@ -1366,10 +1364,12 @@ namespace HandBrakeWPF.ViewModels
this.VideoTunes.Add(VideoTune.None);
foreach (var item in encoder.Tunes)
{
if (item != VideoTune.FastDecode.ShortName)
if (item == VideoTune.FastDecode.ShortName && (selectedEncoder == VideoEncoder.X264 || selectedEncoder == VideoEncoder.X264_10))
{
this.VideoTunes.Add(new VideoTune(item, item));
continue;
}
this.VideoTunes.Add(new VideoTune(item, item));
}
this.FastDecode = false;
this.VideoTune = VideoTune.None;
......@@ -1443,6 +1443,9 @@ namespace HandBrakeWPF.ViewModels
this.SelectedVideoEncoder == VideoEncoder.VceH264 || this.SelectedVideoEncoder == VideoEncoder.VceH265 ||
this.SelectedVideoEncoder == VideoEncoder.NvencH264 || this.SelectedVideoEncoder == VideoEncoder.NvencH265;
this.DisplayFastDecode = this.SelectedVideoEncoder == VideoEncoder.X264 || this.SelectedVideoEncoder == VideoEncoder.X264_10;
this.NotifyOfPropertyChange(() => this.DisplayFastDecode);
this.DisplayProfileControl = this.SelectedVideoEncoder == VideoEncoder.X264
|| this.SelectedVideoEncoder == VideoEncoder.X264_10
|| this.SelectedVideoEncoder == VideoEncoder.X265
......
......@@ -159,17 +159,17 @@
<TextBlock Text="{x:Static Properties:Resources.VideoView_EncodeTune}" Grid.Row="2" Grid.Column="0" VerticalAlignment="Center" Margin="0,5,0,0"
Visibility="{Binding DisplayTuneControls, Converter={StaticResource boolToVisConverter}}"/>
<ComboBox Width="100" Grid.Row="2" Grid.Column="1" Margin="5,5,5,0" Height="22" AutomationProperties.Name="{x:Static Properties:Resources.VideoView_EncodeTune}"
ItemsSource="{Binding VideoTunes}" DisplayMemberPath="DisplayName" SelectedItem="{Binding VideoTune}"
ItemsSource="{Binding VideoTunes}" DisplayMemberPath="DisplayName" SelectedItem="{Binding VideoTune}" HorizontalAlignment="Left"
ToolTip="{x:Static Properties:ResourcesTooltips.Video_EncoderTune}" Visibility="{Binding DisplayTuneControls, Converter={StaticResource boolToVisConverter}}"
Style="{StaticResource LongToolTipHolder}" />
<CheckBox IsChecked="{Binding FastDecode}" Content="{x:Static Properties:Resources.VideoView_FastDecode}" Grid.Row="2" Grid.Column="2" Margin="10,5,10,0" VerticalAlignment="Center" VerticalContentAlignment="Center"
ToolTip="{x:Static Properties:ResourcesTooltips.Video_FastDecode}" Visibility="{Binding DisplayTuneControls, Converter={StaticResource boolToVisConverter}}"/>
ToolTip="{x:Static Properties:ResourcesTooltips.Video_FastDecode}" Visibility="{Binding DisplayFastDecode, Converter={StaticResource boolToVisConverter}}"/>
<!-- Row 2-->
<TextBlock Text="{x:Static Properties:Resources.VideoView_EncoderProfile}" Grid.Row="3" Grid.Column="0" Margin="0,5,0,0" VerticalAlignment="Center" Visibility="{Binding DisplayProfileControl, Converter={StaticResource boolToVisConverter}}"/>
<ComboBox Width="100" Grid.Row="3" Grid.Column="1" Margin="5,5,5,0" Height="22" VerticalAlignment="Center" Visibility="{Binding DisplayProfileControl, Converter={StaticResource boolToVisConverter}}"
ItemsSource="{Binding VideoProfiles}" DisplayMemberPath="DisplayName" SelectedItem="{Binding VideoProfile}"
ItemsSource="{Binding VideoProfiles}" DisplayMemberPath="DisplayName" SelectedItem="{Binding VideoProfile}" HorizontalAlignment="Left"
Style="{StaticResource LongToolTipHolder}" ToolTip="{x:Static Properties:ResourcesTooltips.Video_Profile}"
AutomationProperties.Name="{x:Static Properties:Resources.VideoView_EncoderProfile}" />
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment