-
Notifications
You must be signed in to change notification settings - Fork 197
Viewport resolution scale parameter 2 #759
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from 3 commits
13cefae
a485192
014daf7
12ccc2f
a568f6a
1d0d804
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change | ||||
|---|---|---|---|---|---|---|
|
|
@@ -31,6 +31,7 @@ This page will be updated with new features and commands as they become availabl | |||||
| | **Setting** | **Description** | | ||||||
| | --- | --- | | ||||||
| | **Match viewport resolution** | Resizes the Unreal Engine application resolution to match the browser's video element size.| | ||||||
| | **Viewport Resolution Scale** | Scale factor for viewport resolution when Match Viewport Resolution is enabled. Range: 0.1-10.0, Default: 1.0. Values above 1.0 (e.g., 1.5, 2.0) can improve visual quality on small screens by requesting higher resolution streams. | | ||||||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Suggested change
|
||||||
| | **Control scheme** | If the scheme is `locked mouse` the browser will use `pointerlock` to capture your mouse, whereas if the scheme is `hovering mouse` you will retain your OS/browser cursor. | | ||||||
| | **Color scheme** | Allows you to switch between light mode and dark mode. | | ||||||
|
|
||||||
|
|
||||||
| Original file line number | Diff line number | Diff line change | ||||
|---|---|---|---|---|---|---|
|
|
@@ -65,6 +65,7 @@ export class NumericParameters { | |||||
| static MaxReconnectAttempts = 'MaxReconnectAttempts' as const; | ||||||
| static StreamerAutoJoinInterval = 'StreamerAutoJoinInterval' as const; | ||||||
| static KeepaliveDelay = 'KeepaliveDelay' as const; | ||||||
| static ViewportResolutionScale = 'ViewportResScale' as const; | ||||||
| } | ||||||
|
|
||||||
| export type NumericParametersKeys = Exclude<keyof typeof NumericParameters, 'prototype'>; | ||||||
|
|
@@ -821,6 +822,22 @@ export class Config { | |||||
| useUrlParams | ||||||
| ) | ||||||
| ); | ||||||
|
|
||||||
| this.numericParameters.set( | ||||||
| NumericParameters.ViewportResolutionScale, | ||||||
| new SettingNumber( | ||||||
| NumericParameters.ViewportResolutionScale, | ||||||
| 'Viewport Resolution Scale', | ||||||
| 'Scale factor for viewport resolution when MatchViewportResolution is enabled. 1.0 = 100%, 0.5 = 50%, 2.0 = 200%.', | ||||||
| 0.1 /*min*/, | ||||||
| 10.0 /*max*/, | ||||||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. We did some QA on this and we think 3x is a sane maximum. Values above that will commonly cause the encoder to fail as this will exceed the maximum encoding size on our H.264 settings - e.g. 4096x4096.
Suggested change
|
||||||
| settings && | ||||||
| Object.prototype.hasOwnProperty.call(settings, NumericParameters.ViewportResolutionScale) | ||||||
| ? settings[NumericParameters.ViewportResolutionScale] | ||||||
| : 1.0 /*value*/, | ||||||
| useUrlParams | ||||||
| ) | ||||||
| ); | ||||||
| } | ||||||
|
|
||||||
| /** | ||||||
|
|
||||||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.