summaryrefslogtreecommitdiff
path: root/src/components/UsageInstructions.tsx
diff options
context:
space:
mode:
authorKurt Himebauch <136133082+xXJSONDeruloXx@users.noreply.github.com>2025-07-16 16:35:34 -0400
committerGitHub <noreply@github.com>2025-07-16 16:35:34 -0400
commit44393f6e126c3dff196283a2079162e3eb9245a2 (patch)
tree46fdc7e70e272ac6a33259d1228233496b54371b /src/components/UsageInstructions.tsx
parent80247f76332d2704e21361192b774f31b1520e57 (diff)
parent7c8f336196c215d90588f1994fa1556c7790dba8 (diff)
downloaddecky-lsfg-vk-44393f6e126c3dff196283a2079162e3eb9245a2.tar.gz
decky-lsfg-vk-44393f6e126c3dff196283a2079162e3eb9245a2.zip
Merge pull request #30 from xXJSONDeruloXx/fps-limit
Fps limit
Diffstat (limited to 'src/components/UsageInstructions.tsx')
-rw-r--r--src/components/UsageInstructions.tsx29
1 files changed, 12 insertions, 17 deletions
diff --git a/src/components/UsageInstructions.tsx b/src/components/UsageInstructions.tsx
index bf80630..727a0ab 100644
--- a/src/components/UsageInstructions.tsx
+++ b/src/components/UsageInstructions.tsx
@@ -1,17 +1,8 @@
import { PanelSectionRow } from "@decky/ui";
-
-interface ConfigType {
- enableLsfg: boolean;
- multiplier: number;
- flowScale: number;
- hdr: boolean;
- perfMode: boolean;
- immediateMode: boolean;
- disableVkbasalt: boolean;
-}
+import { ConfigurationData } from "../config/configSchema";
interface UsageInstructionsProps {
- config: ConfigType;
+ config: ConfigurationData;
}
export function UsageInstructions({ config }: UsageInstructionsProps) {
@@ -19,32 +10,36 @@ export function UsageInstructions({ config }: UsageInstructionsProps) {
const buildManualEnvVars = (): string => {
const envVars: string[] = [];
- if (config.enableLsfg) {
+ if (config.enable_lsfg) {
envVars.push("ENABLE_LSFG=1");
}
// Always include multiplier and flow_scale if LSFG is enabled, as they have defaults
- if (config.enableLsfg) {
+ if (config.enable_lsfg) {
envVars.push(`LSFG_MULTIPLIER=${config.multiplier}`);
- envVars.push(`LSFG_FLOW_SCALE=${config.flowScale}`);
+ envVars.push(`LSFG_FLOW_SCALE=${config.flow_scale}`);
}
if (config.hdr) {
envVars.push("LSFG_HDR=1");
}
- if (config.perfMode) {
+ if (config.perf_mode) {
envVars.push("LSFG_PERF_MODE=1");
}
- if (config.immediateMode) {
+ if (config.immediate_mode) {
envVars.push("MESA_VK_WSI_PRESENT_MODE=immediate");
}
- if (config.disableVkbasalt) {
+ if (config.disable_vkbasalt) {
envVars.push("DISABLE_VKBASALT=1");
}
+ if (config.frame_cap > 0) {
+ envVars.push(`DXVK_FRAME_RATE=${config.frame_cap}`);
+ }
+
return envVars.length > 0 ? `${envVars.join(" ")} %command%` : "%command%";
};