Add option to toggle envvar compatibility mode

This commit is contained in:
Yukino Song
2025-05-07 04:29:38 +08:00
parent 91467d50b6
commit 69e999d245
7 changed files with 27 additions and 3 deletions

View File

@@ -381,8 +381,13 @@
<td>{{ $t('apps.env_client_audio_config') }}</td>
</tr>
</table>
<div class="form-text" v-if="platform === 'windows'"><b>{{ $t('apps.env_qres_example') }}</b>
<pre>cmd /C &lt;{{ $t('apps.env_qres_path') }}&gt;\QRes.exe /X:%APOLLO_CLIENT_WIDTH% /Y:%APOLLO_CLIENT_HEIGHT% /R:%APOLLO_CLIENT_FPS%</pre>
<div class="alert alert-info">
<i class="fa-solid fa-xl fa-circle-info"></i> {{ $t('apps.env_sunshine_compatibility') }}
</div>
<div class="form-text" v-if="platform === 'windows'"><b>{{ $t('apps.env_rtss_cli_example') }}</b>
<pre>cmd /C \path\to\rtss-cli.exe limit:set %APOLLO_CLIENT_FPS%</pre>
</div>
<div class="form-text" v-else-if="platform === 'linux'"><b>{{ $t('apps.env_xrandr_example') }}</b>
<pre>sh -c "xrandr --output HDMI-1 --mode \"${APOLLO_CLIENT_WIDTH}x${APOLLO_CLIENT_HEIGHT}\" --rate ${APOLLO_CLIENT_FPS}"</pre>

View File

@@ -43,6 +43,14 @@ const config = ref(props.config)
default="true"
></Checkbox>
<!-- ENVVAR compatibility mode -->
<Checkbox class="mb-3"
id="envvar_compatibility_mode"
locale-prefix="config"
v-model="config.envvar_compatibility_mode"
default="false"
></Checkbox>
<!-- HEVC Support -->
<div class="mb-3">
<label for="hevc_mode" class="form-label">{{ $t('config.hevc_mode') }}</label>

View File

@@ -71,6 +71,8 @@
"env_displayplacer_example": "Example - displayplacer for Resolution Automation:",
"env_qres_example": "Example - QRes for Resolution Automation:",
"env_qres_path": "qres path",
"env_rtss_cli_example": "Example - rtss-cli for FPS Limitation:",
"env_sunshine_compatibility": "Environment variables starting with \"SUNSHINE_\" are deprecated but still kept for compatibility with Sunshine related tools. The SUNSHINE_CLIENT_FPS variable is modified to FLOAT for fractional refresh rate support(especially for Special-K), if your script/tool can't take floating number input, go to Advanced tab to enable \"ENVVAR compatibility mode\". APOLLO_CLIENT_FPS is always FLOAT type.",
"env_var_name": "Var Name",
"env_vars_about": "About Environment Variables",
"env_vars_desc": "All commands get these environment variables by default:",
@@ -238,6 +240,8 @@
"encoder": "Force a Specific Encoder",
"encoder_desc": "Force a specific encoder, otherwise Apollo will select the best available option. Note: If you specify a hardware encoder on Windows, it must match the GPU where the display is connected.",
"encoder_software": "Software",
"envvar_compatibility_mode": "ENVVAR compatibility mode",
"envvar_compatibility_mode_desc": "Enable compatibility mode for environment variables. This will modify the behavior of certain environment variables to be more compatible with older tools.",
"external_ip": "External IP",
"external_ip_desc": "If no external IP address is given, Apollo will automatically detect external IP",
"fallback_mode": "Fallback Display Mode",

View File

@@ -69,6 +69,8 @@
"env_displayplacer_example": "示例 - 使用 displayplacer 自动更改分辨率:",
"env_qres_example": "示例 - 使用 QRes 自动更改分辨率:",
"env_qres_path": "QRes 路径",
"env_rtss_cli_example": "示例 - 使用 rtss-cli 限制 FPS",
"env_sunshine_compatibility": "以 \"SUNSHINE_\" 开头的环境变量已弃用,但仍保留它们以确保对 Sunshine 相关工具的兼容。SUNSHINE_CLIENT_FPS 变量已修改为 FLOAT 以支持小数刷新率(特别适用于 Special-K如果您的脚本/工具无法接受浮点数输入,请前往 Advanced 选项卡启用 \"环境变量兼容模式\"。APOLLO_CLIENT_FPS 则始终为 FLOAT 类型。",
"env_var_name": "变量名称",
"env_vars_about": "关于环境变量",
"env_vars_desc": "默认情况下,所有命令都会得到这些环境变量:",
@@ -233,6 +235,8 @@
"encoder": "强制指定编码器",
"encoder_desc": "强制指定一个特定编码器,否则 Apollo 将选择最佳可用选项。注意:如果您在 Windows 上指定了硬件编码器,它必须匹配连接显示器的 GPU。",
"encoder_software": "软件",
"envvar_compatibility_mode": "环境变量兼容模式",
"envvar_compatibility_mode_desc": "启用环境变量兼容模式。这将修改某些环境变量的行为,以更好地与旧工具兼容。",
"external_ip": "外部 IP",
"external_ip_desc": "如果没有指定外部 IP 地址Apollo 将自动检测外部 IP",
"fallback_mode": "备用显示参数",