-
Notifications
You must be signed in to change notification settings - Fork 59
Expand file tree
/
Copy pathHostSettingsPage.xaml
More file actions
124 lines (116 loc) · 7.98 KB
/
Copy pathHostSettingsPage.xaml
File metadata and controls
124 lines (116 loc) · 7.98 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
<Page
x:Class="moonlight_xbox_dx.HostSettingsPage"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:local="using:moonlight_xbox_dx"
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
mc:Ignorable="d"
Background="{ThemeResource ApplicationPageBackgroundThemeBrush}">
<ScrollViewer>
<StackPanel Padding="8,16,8,8">
<StackPanel Orientation="Horizontal">
<Button Margin="0 0 0 16" Name="backButton" Click="backButton_Click">
<Button.Content>
<SymbolIcon Symbol="Back" />
</Button.Content>
</Button>
<StackPanel Margin="16 0 0 0">
<TextBlock Text="{x:Bind Host.ComputerName}"></TextBlock>
<TextBlock Text="{x:Bind Host.LastHostname}"></TextBlock>
</StackPanel>
</StackPanel>
<Grid RowSpacing="8">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="200"></ColumnDefinition>
<ColumnDefinition Width="150"></ColumnDefinition>
<ColumnDefinition Width="*"></ColumnDefinition>
</Grid.ColumnDefinitions>
<Grid.RowDefinitions>
<RowDefinition Height="auto"></RowDefinition>
<RowDefinition Height="auto"></RowDefinition>
<RowDefinition Height="auto"></RowDefinition>
<RowDefinition Height="auto"></RowDefinition>
<RowDefinition Height="auto"></RowDefinition>
<RowDefinition Height="auto"></RowDefinition>
<RowDefinition Height="auto"></RowDefinition>
<RowDefinition Height="auto"></RowDefinition>
<RowDefinition Height="auto"></RowDefinition>
<RowDefinition Height="auto"></RowDefinition>
<RowDefinition Height="auto"></RowDefinition>
<RowDefinition Height="auto"></RowDefinition>
<RowDefinition Height="auto"></RowDefinition>
<RowDefinition Height="auto"></RowDefinition>
<RowDefinition Height="auto"></RowDefinition>
</Grid.RowDefinitions>
<TextBlock Grid.Row="0" Grid.Column="0">Resolution</TextBlock>
<ComboBox x:Name="ResolutionSelector" SelectionChanged="ResolutionSelector_SelectionChanged" SelectedIndex="{x:Bind CurrentResolutionIndex,Mode=TwoWay}" Grid.Row="0" Grid.Column="1" ItemsSource="{x:Bind AvailableResolutions}">
<ComboBox.ItemTemplate>
<DataTemplate x:DataType="local:ScreenResolution">
<StackPanel Orientation="Horizontal">
<TextBlock Text="{x:Bind Width}"></TextBlock>
<TextBlock Text="x"></TextBlock>
<TextBlock Text="{x:Bind Height}"></TextBlock>
</StackPanel>
</DataTemplate>
</ComboBox.ItemTemplate>
</ComboBox>
<TextBlock Grid.Row="1" Grid.Column="0">FPS</TextBlock>
<ComboBox x:Name="FPSSelector" SelectionChanged="FPSSelector_SelectionChanged" SelectedItem="{x:Bind Host.FPS,Mode=OneWay}" Grid.Row="1" Grid.Column="1" ItemsSource="{x:Bind AvailableFPS}"></ComboBox>
<TextBlock Grid.Row="2" Grid.Column="0">Bitrate (Kbps)</TextBlock>
<Slider Grid.Row="2" Grid.Column="1" Grid.ColumnSpan="2" Value="{x:Bind Host.Bitrate}" x:DefaultBindMode="TwoWay" Minimum="5000" Maximum="500000" SmallChange="10000" TickFrequency="50000" StepFrequency="50000" />
<TextBlock Grid.Row="3" Grid.Column="0">Audio Configuration</TextBlock>
<ComboBox ItemsSource="{x:Bind AvailableAudioConfigs}" SelectedItem="{x:Bind Host.AudioConfig,Mode=TwoWay}" Grid.Row="3" Grid.Column="1"></ComboBox>
<TextBlock Grid.Row="4" Grid.Column="0">Play Audio on Host PC</TextBlock>
<CheckBox Grid.Row="4" Grid.Column="1" IsChecked="{x:Bind Host.PlayAudioOnPC, Mode=TwoWay}"></CheckBox>
<TextBlock Grid.Row="5" Grid.Column="0">Autostart</TextBlock>
<ComboBox Grid.Row="5" Grid.Column="1" SelectedIndex="{x:Bind CurrentAppIndex,Mode=TwoWay}" Name="AutoStartSelector" SelectionChanged="AutoStartSelector_SelectionChanged">
</ComboBox>
<TextBlock Grid.Row="6" Grid.Column="0">Video Codecs</TextBlock>
<ComboBox Name="CodecComboBox" ItemsSource="{x:Bind AvailableVideoCodecs}" SelectedItem="{x:Bind Host.VideoCodec,Mode=TwoWay}" Grid.Row="6" Grid.Column="1"></ComboBox>
<TextBlock Grid.Row="7" Grid.Column="0" >Enable HDR:</TextBlock>
<CheckBox
Name="EnableHDRCheckbox" Grid.Row="7" Grid.Column="1"
IsChecked="{x:Bind Host.EnableHDR,Mode=TwoWay}" />
<TextBlock
Name="HDR4KNote" Grid.Row="7" Grid.Column="1" Grid.ColumnSpan="2" Visibility="Collapsed">
HDR requires Xbox system resolution set to 4K.
</TextBlock>
<TextBlock Grid.Row="8" Grid.Column="0" >Optimize host resolution:</TextBlock>
<CheckBox Name="EnableSOPSCheckbox" Grid.Row="8" Grid.Column="1" IsChecked="{x:Bind Host.EnableSOPS,Mode=TwoWay}"></CheckBox>
<TextBlock Grid.Row="9" Grid.Column="0">Frame Pacing:</TextBlock>
<ComboBox Name="FramePacingComboBox" ItemsSource="{x:Bind AvailableFramePacing}" SelectedItem="{x:Bind Host.FramePacing,Mode=TwoWay}" SelectionChanged="FramePacing_SelectionChanged" Grid.Row="9" Grid.Column="1"></ComboBox>
<TextBlock
Name="FramePacingImmediateDesc" Grid.Row="9" Grid.Column="2" Visibility="Collapsed">
Best for Xbox Series. Lowest latency. Renders frames at the incoming frame rate.
</TextBlock>
<TextBlock
Name="FramePacingDisplayLockedDesc" Grid.Row="9" Grid.Column="2" Visibility="Collapsed">
Best for Xbox One. Locks rendering frame rate to refresh rate and evenly spaces frames.
</TextBlock>
<TextBlock Grid.Row="10" Grid.Column="0" >Periodic decoder refresh:</TextBlock>
<CheckBox Name="EnableIdrIntervalCheckbox" Grid.Row="10" Grid.Column="1" Checked="EnableIdrIntervalCheckbox_Checked" Unchecked="EnableIdrIntervalCheckbox_Unchecked"></CheckBox>
<TextBlock Grid.Row="10" Grid.Column="2" >Mitigates HEVC corruption. Refreshes every (Target FPS)*(Interval) frames.</TextBlock>
<TextBlock Grid.Row="11" Grid.Column="0" >Refresh interval (Seconds)</TextBlock>
<Slider Name ="IdrIntervalSlider" Grid.Row="11" Grid.Column="1" Grid.ColumnSpan="2" Value="{x:Bind Host.IdrInterval}" IsEnabled="False" x:DefaultBindMode="TwoWay" Minimum="2" Maximum="60" SmallChange="1" TickFrequency="2" StepFrequency="2" />
<TextBlock Grid.Row="12" Grid.Column="0">Show performance stats:</TextBlock>
<CheckBox
Grid.Row="12" Grid.Column="1"
x:Name="EnableStatsCheckbox"
IsChecked="{x:Bind Host.EnableStats, Mode=TwoWay}" />
<TextBlock Grid.Row="13" Grid.Column="0" >Show performance graphs:</TextBlock>
<CheckBox
Grid.Row="13" Grid.Column="1"
x:Name="EnableGraphsCheckbox"
IsEnabled="{x:Bind Host.EnableStats, Mode=OneWay}"
IsChecked="{x:Bind Host.EnableGraphs, Mode=TwoWay}" />
<TextBlock
Name="XboxOneGraphsNote" Grid.Row="13" Grid.Column="1" Grid.ColumnSpan="2" Visibility="Collapsed">
Graphs are unavailable on Xbox One when system resolution is set to 4K.
</TextBlock>
<TextBlock Grid.Row="14" Grid.Column="0">Other:</TextBlock>
<Button Grid.Row="14" Grid.Column="1" x:Name="GlobalSettingsOption" Click="GlobalSettingsOption_Click">Open Global Settings</Button>
</Grid>
</StackPanel>
</ScrollViewer>
</Page>