fix(home:vesktop): update vesktop patch

This commit is contained in:
ooks-io 2024-07-21 20:29:38 +12:00
parent 5c055252ea
commit 1ab7a9de11

View file

@ -1,24 +1,26 @@
diff --git a/src/main/index.ts b/src/main/index.ts
index 2f8191c..a1e697b 100644
index 2e0d6f7..70dabba 100644
--- a/src/main/index.ts
+++ b/src/main/index.ts
@@ -33,13 +33,29 @@ function init() {
@@ -35,7 +35,7 @@ function init() {
if (hardwareAcceleration === false) {
app.disableHardwareAcceleration();
} else {
- enabledFeatures.push("VaapiVideoDecodeLinuxGL", "VaapiVideoEncoder", "VaapiVideoDecoder");
+ enabledFeatures.push("VaapiVideoDecodeLinuxGL", "VaapiVideoEncoder", "VaapiVideoDecoder", "VulkanFromANGLE", "DefaultANGLEVulkan", "VaapiIgnoreDriverChecks", "PlatformHEVCDecoderSupport", "VaapiVP8Encoder", "VaapiVP9Encoder", "VaapiAV1Encoder");
+ enabledFeatures.push("VaapiVideoDecodeLinuxGL", "VaapiVideoEncoder", "VaapiVideoDecoder", "VulkanFromANGLE", "DefaultANGLEVulkan", "VaapiIgnoreDriverChecks", "PlatformHEVCDecoderSupport", "VaapiVP8Encoder", "VaapiVP9Encoder", "VaapiAV1Encoder", "WaylandWindowDecorations", "UseOzonePlatform", "WebRTCPipeWireCapturer");
}
if (disableSmoothScroll) {
app.commandLine.appendSwitch("disable-smooth-scrolling");
}
@@ -48,6 +48,26 @@ function init() {
app.commandLine.appendSwitch("disable-renderer-backgrounding");
app.commandLine.appendSwitch("disable-background-timer-throttling");
app.commandLine.appendSwitch("disable-backgrounding-occluded-windows");
+ app.commandLine.appendSwitch("disable-renderer-backgrounding");
+ app.commandLine.appendSwitch("disable-background-timer-throttling");
+ app.commandLine.appendSwitch("disable-backgrounding-occluded-windows");
+ app.commandLine.appendSwitch("enable-zero-copy");
+ app.commandLine.appendSwitch("use-gl=angle");
+ app.commandLine.appendSwitch("use-angle=gl");
+ app.commandLine.appendSwitch("use-vulkan");
+ app.commandLine.appendSwitch("enable-oop-rasterization");
+ app.commandLine.appendSwitch("enable-raw-draw");
@ -29,24 +31,46 @@ index 2f8191c..a1e697b 100644
+ app.commandLine.appendSwitch("enable-accelerated-video-decode");
+ app.commandLine.appendSwitch("enable-accelerated-mjpeg-decode");
+ app.commandLine.appendSwitch("disable-gpu-vsync");
+
// work around chrome 66 disabling autoplay by default
app.commandLine.appendSwitch("autoplay-policy", "no-user-gesture-required");
// WinRetrieveSuggestionsOnlyOnDemand: Work around electron 13 bug w/ async spellchecking on Windows.
+ app.commandLine.appendSwitch("disable-frame-rate-limit");
+ app.commandLine.appendSwitch("ozone-platform-hint=auto");
+ app.commandLine.appendSwitch("enable-webrtc-pipewire-capturer");
+ app.commandLine.appendSwitch("ozone-platform=wayland");
if (process.platform === "win32") {
disabledFeatures.push("CalculateNativeWinOcclusion");
}
diff --git a/src/renderer/components/ScreenSharePicker.tsx b/src/renderer/components/ScreenSharePicker.tsx
index 1c53b63..f6ea297 100644
index c7403b9..9b454e6 100644
--- a/src/renderer/components/ScreenSharePicker.tsx
+++ b/src/renderer/components/ScreenSharePicker.tsx
@@ -87,9 +87,9 @@ addPatch({
@@ -84,9 +84,9 @@ addPatch({
const width = Math.round(height * (16 / 9));
Object.assign(opts, {
- bitrateMin: 500000,
- bitrateMax: 8000000,
- bitrateTarget: 600000
+ bitrateMin: 8000000,
+ bitrateMax: 30000000,
+ bitrateTarget: 16000000
+ bitrateMin: 10000000,
+ bitrateMax: 60000000,
+ bitrateTarget: 32000000
});
if (opts?.encode) {
Object.assign(opts.encode, {
diff --git a/src/main/settings.ts b/src/main/settings.ts
index 6fad97f..dfc64e3 100644
--- a/src/main/settings.ts
+++ b/src/main/settings.ts
@@ -26,8 +26,10 @@ function loadSettings<T extends object = any>(file: string, name: string) {
const store = new SettingsStore(settings);
store.addGlobalChangeListener(o => {
- mkdirSync(dirname(file), { recursive: true });
- writeFileSync(file, JSON.stringify(o, null, 4));
+ try {
+ mkdirSync(dirname(file), { recursive: true });
+ writeFileSync(file, JSON.stringify(o, null, 4));
+ } catch {}
});
return store;