fix(home:vesktop): update vesktop patch
This commit is contained in:
		
							parent
							
								
									5c055252ea
								
							
						
					
					
						commit
						1ab7a9de11
					
				
					 1 changed files with 39 additions and 15 deletions
				
			
		|  | @ -1,24 +1,26 @@ | ||||||
| diff --git a/src/main/index.ts b/src/main/index.ts
 | 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
 | --- a/src/main/index.ts
 | ||||||
| +++ b/src/main/index.ts
 | +++ b/src/main/index.ts
 | ||||||
| @@ -33,13 +33,29 @@ function init() {
 | @@ -35,7 +35,7 @@ function init() {
 | ||||||
|      if (hardwareAcceleration === false) { |      if (hardwareAcceleration === false) { | ||||||
|          app.disableHardwareAcceleration(); |          app.disableHardwareAcceleration(); | ||||||
|      } else { |      } else { | ||||||
| -        enabledFeatures.push("VaapiVideoDecodeLinuxGL", "VaapiVideoEncoder", "VaapiVideoDecoder");
 | -        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) { |      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-renderer-backgrounding");
 | ||||||
| +    app.commandLine.appendSwitch("disable-background-timer-throttling");
 | +    app.commandLine.appendSwitch("disable-background-timer-throttling");
 | ||||||
| +    app.commandLine.appendSwitch("disable-backgrounding-occluded-windows");
 | +    app.commandLine.appendSwitch("disable-backgrounding-occluded-windows");
 | ||||||
| +    app.commandLine.appendSwitch("enable-zero-copy");
 | +    app.commandLine.appendSwitch("enable-zero-copy");
 | ||||||
| +    app.commandLine.appendSwitch("use-gl=angle");
 | +    app.commandLine.appendSwitch("use-gl=angle");
 | ||||||
|  | +    app.commandLine.appendSwitch("use-angle=gl");
 | ||||||
| +    app.commandLine.appendSwitch("use-vulkan");
 | +    app.commandLine.appendSwitch("use-vulkan");
 | ||||||
| +    app.commandLine.appendSwitch("enable-oop-rasterization");
 | +    app.commandLine.appendSwitch("enable-oop-rasterization");
 | ||||||
| +    app.commandLine.appendSwitch("enable-raw-draw");
 | +    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-video-decode");
 | ||||||
| +    app.commandLine.appendSwitch("enable-accelerated-mjpeg-decode");
 | +    app.commandLine.appendSwitch("enable-accelerated-mjpeg-decode");
 | ||||||
| +    app.commandLine.appendSwitch("disable-gpu-vsync");
 | +    app.commandLine.appendSwitch("disable-gpu-vsync");
 | ||||||
| +
 | +    app.commandLine.appendSwitch("disable-frame-rate-limit");
 | ||||||
|      // work around chrome 66 disabling autoplay by default | +    app.commandLine.appendSwitch("ozone-platform-hint=auto");
 | ||||||
|      app.commandLine.appendSwitch("autoplay-policy", "no-user-gesture-required"); | +    app.commandLine.appendSwitch("enable-webrtc-pipewire-capturer");
 | ||||||
|      // WinRetrieveSuggestionsOnlyOnDemand: Work around electron 13 bug w/ async spellchecking on Windows. | +    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
 | 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
 | --- a/src/renderer/components/ScreenSharePicker.tsx
 | ||||||
| +++ b/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)); |          const width = Math.round(height * (16 / 9)); | ||||||
|   |   | ||||||
|          Object.assign(opts, { |          Object.assign(opts, { | ||||||
| -            bitrateMin: 500000,
 | -            bitrateMin: 500000,
 | ||||||
| -            bitrateMax: 8000000,
 | -            bitrateMax: 8000000,
 | ||||||
| -            bitrateTarget: 600000
 | -            bitrateTarget: 600000
 | ||||||
| +            bitrateMin: 8000000,
 | +            bitrateMin: 10000000,
 | ||||||
| +            bitrateMax: 30000000,
 | +            bitrateMax: 60000000,
 | ||||||
| +            bitrateTarget: 16000000
 | +            bitrateTarget: 32000000
 | ||||||
|          }); |          }); | ||||||
|          if (opts?.encode) { |          if (opts?.encode) { | ||||||
|              Object.assign(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; | ||||||
|  |  | ||||||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue