@overwolf/ow-electron-packages-types 1.1.13-beta.0 → 1.1.13-beta.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +1 -1
- package/types.d.ts +32 -3
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@overwolf/ow-electron-packages-types",
|
|
3
|
-
"version": "1.1.13-beta.
|
|
3
|
+
"version": "1.1.13-beta.2",
|
|
4
4
|
"description": "Type definition file for autocompletion and documentation purposes for ow-electron packages",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"types": "types.d.ts",
|
package/types.d.ts
CHANGED
|
@@ -5576,7 +5576,9 @@ type GpuPreference = "default" | "highPerformance";
|
|
|
5576
5576
|
* game.
|
|
5577
5577
|
* - `gpuAdapterMismatch`—The game renders on a different GPU adapter than Chromium,
|
|
5578
5578
|
* and a shared texture handle can only be opened on the adapter that created it. Fixable
|
|
5579
|
-
* with {@link IOverwolfOverlayApi.setGpuPreference} and an application restart
|
|
5579
|
+
* with {@link IOverwolfOverlayApi.setGpuPreference} and an application restart, or from
|
|
5580
|
+
* the first launch with Chromium's `force_high_performance_gpu` switch (see
|
|
5581
|
+
* {@link IOverwolfOverlayApi.setGpuPreference}).
|
|
5580
5582
|
* - `copyFailure`—The game repeatedly failed to open the shared texture handles it
|
|
5581
5583
|
* received in-game. The overlay retried, then fell back to the CPU copy path.
|
|
5582
5584
|
* {@link IOverwolfOverlayApi.setGpuPreference} may help when the root cause is
|
|
@@ -6265,6 +6267,18 @@ interface ExclusiveInputOptions {
|
|
|
6265
6267
|
* @default 'rgba(12, 12, 12, , 0.5)'
|
|
6266
6268
|
*/
|
|
6267
6269
|
backgroundColor?: string;
|
|
6270
|
+
|
|
6271
|
+
/**
|
|
6272
|
+
* Move the mouse cursor to the center of the game window when entering
|
|
6273
|
+
* exclusive mode.
|
|
6274
|
+
*
|
|
6275
|
+
* Useful when the game has no visible cursor (e.g. during gameplay), where
|
|
6276
|
+
* the cursor would otherwise appear wherever the game last left it.
|
|
6277
|
+
*
|
|
6278
|
+
* @default false
|
|
6279
|
+
* @since 2.0.17
|
|
6280
|
+
*/
|
|
6281
|
+
centerCursor?: boolean;
|
|
6268
6282
|
}
|
|
6269
6283
|
|
|
6270
6284
|
|
|
@@ -6597,6 +6611,13 @@ interface IOverwolfOverlayApi extends EventEmitter {
|
|
|
6597
6611
|
* the application is *already* aligned and therefore needs no restart; this method is
|
|
6598
6612
|
* idempotent, so calling it unconditionally is safe.
|
|
6599
6613
|
*
|
|
6614
|
+
* **Alternative with no restart.** Appending Chromium's `force_high_performance_gpu` switch
|
|
6615
|
+
* from the application's main script, **before** the `ready` event, starts the GPU process
|
|
6616
|
+
* on the high-performance adapter from the first launch. It affects only Chromium's GPU
|
|
6617
|
+
* process and writes no Windows setting, though it still keeps the discrete GPU awake while
|
|
6618
|
+
* the application runs. The overlay package loads after `ready`, so it cannot apply the
|
|
6619
|
+
* switch itself.
|
|
6620
|
+
*
|
|
6600
6621
|
* **Side effects — read before calling.** It moves the **entire application's**
|
|
6601
6622
|
* rendering to that GPU, draining laptop battery and keeping the discrete GPU awake; it is
|
|
6602
6623
|
* persistent, user-visible Windows state under
|
|
@@ -6611,6 +6632,7 @@ interface IOverwolfOverlayApi extends EventEmitter {
|
|
|
6611
6632
|
* @throws If the registry cannot be written, or on a non-Windows platform.
|
|
6612
6633
|
* @see {@link GpuPreference}.
|
|
6613
6634
|
* @see {@link https://dev.overwolf.com/ow-electron/reference/examples/overlay | Overlay examples}
|
|
6635
|
+
* @see {@link https://www.electronjs.org/docs/latest/api/command-line-switches#--force_high_performance_gpu | --force_high_performance_gpu}
|
|
6614
6636
|
*
|
|
6615
6637
|
* @example
|
|
6616
6638
|
* ```ts
|
|
@@ -6622,6 +6644,12 @@ interface IOverwolfOverlayApi extends EventEmitter {
|
|
|
6622
6644
|
* });
|
|
6623
6645
|
* ```
|
|
6624
6646
|
*
|
|
6647
|
+
* @example
|
|
6648
|
+
* ```ts
|
|
6649
|
+
* // Main script, before `app` is ready - no restart needed.
|
|
6650
|
+
* app.commandLine.appendSwitch('force_high_performance_gpu');
|
|
6651
|
+
* ```
|
|
6652
|
+
*
|
|
6625
6653
|
* @since 2.0.5
|
|
6626
6654
|
*/
|
|
6627
6655
|
setGpuPreference(preference: GpuPreference): Promise<void>;
|
|
@@ -6794,8 +6822,9 @@ interface IOverwolfOverlayApi extends EventEmitter {
|
|
|
6794
6822
|
* (D3D9 / OpenGL / Vulkan). Nothing to fix.
|
|
6795
6823
|
* - `gpuAdapterMismatch`—the game renders on a **different GPU adapter than
|
|
6796
6824
|
* Chromium**; a shared texture handle can only be opened on the adapter that created it.
|
|
6797
|
-
* Fixable with {@link IOverwolfOverlayApi.setGpuPreference} and a restart
|
|
6798
|
-
*
|
|
6825
|
+
* Fixable with {@link IOverwolfOverlayApi.setGpuPreference} and a restart, or from the
|
|
6826
|
+
* first launch with Chromium's `force_high_performance_gpu` switch; both adapters are
|
|
6827
|
+
* named in the overlay log.
|
|
6799
6828
|
* - `copyFailure`—the game **repeatedly failed to open the shared texture handles it
|
|
6800
6829
|
* received in-game**. The overlay retried, then abandoned the path for this game.
|
|
6801
6830
|
* {@link IOverwolfOverlayApi.setGpuPreference} may help when the root cause is
|