@overwolf/ow-electron-packages-types 1.0.0-beta.3 → 1.0.0-beta.5
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/game-list.d.ts +3 -3
- package/package.json +1 -1
- package/types.d.ts +219 -56
package/game-list.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
// game list version:
|
|
1
|
+
// game list version: 40
|
|
2
2
|
|
|
3
3
|
export const enum kLaunchersIds {
|
|
4
4
|
LOLLauncher = 10902,
|
|
@@ -3249,6 +3249,7 @@ export const enum kGameIds {
|
|
|
3249
3249
|
WorldofGoo = 4274,
|
|
3250
3250
|
WorldofGoo2 = 25720,
|
|
3251
3251
|
WORLDOFHORROR = 23460,
|
|
3252
|
+
WorldOfTanks = 6365,
|
|
3252
3253
|
WorldofTanksBlitz = 10896,
|
|
3253
3254
|
WorldofWarships = 10746,
|
|
3254
3255
|
WorldofZoo = 5504,
|
|
@@ -3328,5 +3329,4 @@ export const enum kGameIds {
|
|
|
3328
3329
|
Zort = 24928,
|
|
3329
3330
|
Zortch = 25010,
|
|
3330
3331
|
Zula = 10768,
|
|
3331
|
-
}
|
|
3332
|
-
|
|
3332
|
+
}
|
package/package.json
CHANGED
package/types.d.ts
CHANGED
|
@@ -1,18 +1,18 @@
|
|
|
1
|
-
import { overwolf } from '@overwolf/ow-electron';
|
|
2
|
-
import {
|
|
3
|
-
BrowserWindow,
|
|
4
|
-
BrowserWindowConstructorOptions,
|
|
5
|
-
Size,
|
|
6
|
-
WebContents,
|
|
7
|
-
Display,
|
|
8
|
-
Rectangle
|
|
9
|
-
} from 'electron';
|
|
10
|
-
|
|
11
|
-
import { EventEmitter } from 'events';
|
|
12
|
-
|
|
13
|
-
// -----------------------------------------------------------------------------
|
|
14
|
-
|
|
15
|
-
// --- modules\utility.d.ts ---
|
|
1
|
+
import { overwolf } from '@overwolf/ow-electron';
|
|
2
|
+
import {
|
|
3
|
+
BrowserWindow,
|
|
4
|
+
BrowserWindowConstructorOptions,
|
|
5
|
+
Size,
|
|
6
|
+
WebContents,
|
|
7
|
+
Display,
|
|
8
|
+
Rectangle
|
|
9
|
+
} from 'electron';
|
|
10
|
+
|
|
11
|
+
import { EventEmitter } from 'events';
|
|
12
|
+
|
|
13
|
+
// -----------------------------------------------------------------------------
|
|
14
|
+
|
|
15
|
+
// --- modules\utility.d.ts ---
|
|
16
16
|
/**
|
|
17
17
|
* @packageDocumentation
|
|
18
18
|
*
|
|
@@ -79,9 +79,9 @@ interface IOverwolfUtilityApi {
|
|
|
79
79
|
*/
|
|
80
80
|
on(eventName: 'game-exit', listener: (gameInfo: GameInfo) => void): this;
|
|
81
81
|
}
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
// --- modules\recorder.d.ts ---
|
|
82
|
+
|
|
83
|
+
|
|
84
|
+
// --- modules\recorder.d.ts ---
|
|
85
85
|
/**
|
|
86
86
|
*
|
|
87
87
|
* The Overwolf Electron recording APIs integrate recording into the Overwolf Electron framework allowing you to record both audio and video.
|
|
@@ -1972,6 +1972,135 @@ interface AudioGeneralSettings {
|
|
|
1972
1972
|
*/
|
|
1973
1973
|
lowLatencyAudioBuffering?: boolean;
|
|
1974
1974
|
}
|
|
1975
|
+
/**
|
|
1976
|
+
* Defines the alignment options specifying a position by using [Vertical][Horizontal]
|
|
1977
|
+
* (e.g., 'TopLeft', 'Center', 'BottomRight'). Typically used for positioning
|
|
1978
|
+
* UI elements, popovers, or text blocks.
|
|
1979
|
+
*/
|
|
1980
|
+
export declare type AlignmentOptions =
|
|
1981
|
+
| 'TopLeft'
|
|
1982
|
+
| 'TopCenter'
|
|
1983
|
+
| 'TopRight'
|
|
1984
|
+
| 'CenterLeft'
|
|
1985
|
+
| 'Center'
|
|
1986
|
+
| 'CenterRight'
|
|
1987
|
+
| 'BottomLeft'
|
|
1988
|
+
| 'BottomCenter'
|
|
1989
|
+
| 'BottomRight';
|
|
1990
|
+
|
|
1991
|
+
/**
|
|
1992
|
+
* Defines the type of bounding or scaling applied to an element's dimensions
|
|
1993
|
+
* within a container.
|
|
1994
|
+
*
|
|
1995
|
+
* Typically used to control how content (like an image or video)
|
|
1996
|
+
* is resized to fit or fill a specific area.
|
|
1997
|
+
*/
|
|
1998
|
+
export declare type BoundsType =
|
|
1999
|
+
| 'None'
|
|
2000
|
+
| 'Stretch'
|
|
2001
|
+
| 'ScaleInner'
|
|
2002
|
+
| 'ScaleOuter'
|
|
2003
|
+
| 'ScaleToWidth'
|
|
2004
|
+
| 'ScaleToHeight'
|
|
2005
|
+
| 'MaxOnly';
|
|
2006
|
+
|
|
2007
|
+
/**
|
|
2008
|
+
* Options for transforming and positioning a source element (e.g. an image or video) within an output container or scene.
|
|
2009
|
+
*
|
|
2010
|
+
* Typically used to control how content is translated, scaled, rotated, aligned,
|
|
2011
|
+
* and cropped within a visual presentation area.
|
|
2012
|
+
*/
|
|
2013
|
+
export interface SourceTransformOptions {
|
|
2014
|
+
/**
|
|
2015
|
+
* Position X in pixels. Default is 0.
|
|
2016
|
+
*/
|
|
2017
|
+
positionX?: number;
|
|
2018
|
+
|
|
2019
|
+
/**
|
|
2020
|
+
* Position Y in pixels. Default is 0.
|
|
2021
|
+
*/
|
|
2022
|
+
positionY?: number;
|
|
2023
|
+
|
|
2024
|
+
/**
|
|
2025
|
+
* Rotation in degrees (-360.0 to 360.0). Default is 0.
|
|
2026
|
+
*/
|
|
2027
|
+
rotation?: number;
|
|
2028
|
+
|
|
2029
|
+
/**
|
|
2030
|
+
* Size Width in pixels.
|
|
2031
|
+
*/
|
|
2032
|
+
sizeWidth?: number;
|
|
2033
|
+
|
|
2034
|
+
/**
|
|
2035
|
+
* Size Height in pixels.
|
|
2036
|
+
*/
|
|
2037
|
+
sizeHeight?: number;
|
|
2038
|
+
|
|
2039
|
+
/**
|
|
2040
|
+
* Alignment of the source within the output.
|
|
2041
|
+
* The alignment is relative to the top-left corner of the output.
|
|
2042
|
+
*
|
|
2043
|
+
* Default is TopLeft.
|
|
2044
|
+
*/
|
|
2045
|
+
alignment?: AlignmentOptions;
|
|
2046
|
+
|
|
2047
|
+
/**
|
|
2048
|
+
* Defines a bounding box for the source within the output.
|
|
2049
|
+
*
|
|
2050
|
+
* Changing the bounds type or alignment only has an effect
|
|
2051
|
+
* if a bounds width or height is specified.
|
|
2052
|
+
*
|
|
2053
|
+
* Type of bounds to apply.
|
|
2054
|
+
* Default is None.
|
|
2055
|
+
*/
|
|
2056
|
+
boundsType?: BoundsType;
|
|
2057
|
+
|
|
2058
|
+
/**
|
|
2059
|
+
* Alignment of the source within the bounding box.
|
|
2060
|
+
*
|
|
2061
|
+
* Relevant only when bounds width or height are defined.
|
|
2062
|
+
* Default is Center.
|
|
2063
|
+
*/
|
|
2064
|
+
boundsAlignment?: AlignmentOptions;
|
|
2065
|
+
|
|
2066
|
+
/**
|
|
2067
|
+
* Bounding box width in pixels.
|
|
2068
|
+
*/
|
|
2069
|
+
boundsWidth?: number;
|
|
2070
|
+
|
|
2071
|
+
/**
|
|
2072
|
+
* Bounding box height in pixels.
|
|
2073
|
+
*/
|
|
2074
|
+
boundsHeight?: number;
|
|
2075
|
+
|
|
2076
|
+
/**
|
|
2077
|
+
* Crop to bounds. Default is False.
|
|
2078
|
+
*/
|
|
2079
|
+
cropToBounds?: boolean;
|
|
2080
|
+
|
|
2081
|
+
/**
|
|
2082
|
+
* Crop options in pixels. Default is no crop.
|
|
2083
|
+
*/
|
|
2084
|
+
cropLeft?: number;
|
|
2085
|
+
cropRight?: number;
|
|
2086
|
+
cropTop?: number;
|
|
2087
|
+
cropBottom?: number;
|
|
2088
|
+
}
|
|
2089
|
+
|
|
2090
|
+
/**
|
|
2091
|
+
* Defines a complete transformation operation to be applied to a specific source element.
|
|
2092
|
+
*
|
|
2093
|
+
* Typically used on a target source by its name with the full set of
|
|
2094
|
+
* transformation and positioning properties it should adopt.
|
|
2095
|
+
*/
|
|
2096
|
+
export interface SourceTransform {
|
|
2097
|
+
/**
|
|
2098
|
+
* Source name to update.
|
|
2099
|
+
*/
|
|
2100
|
+
readonly sourceName: string;
|
|
2101
|
+
|
|
2102
|
+
readonly transform: SourceTransformOptions;
|
|
2103
|
+
}
|
|
1975
2104
|
|
|
1976
2105
|
/**
|
|
1977
2106
|
* Configuration settings for how a capture source is rendered in the output video.
|
|
@@ -1980,15 +2109,25 @@ interface AudioGeneralSettings {
|
|
|
1980
2109
|
* content relative to the output resolution.
|
|
1981
2110
|
*/
|
|
1982
2111
|
interface CaptureSourceSettings {
|
|
2112
|
+
/**
|
|
2113
|
+
* Unique Source name (for easier identification).
|
|
2114
|
+
*/
|
|
2115
|
+
name?: string;
|
|
2116
|
+
|
|
1983
2117
|
/**
|
|
1984
2118
|
* Whether the capture source should be centered and stretched to fit the output video size.
|
|
1985
2119
|
*
|
|
1986
2120
|
* When set to `true`, the source will automatically scale and center itself to match
|
|
1987
2121
|
* the output resolution, even if it requires stretching.
|
|
1988
2122
|
*
|
|
1989
|
-
* @default true
|
|
2123
|
+
* @default true (if transform is not provided).
|
|
1990
2124
|
*/
|
|
1991
2125
|
stretchToOutputSize?: boolean;
|
|
2126
|
+
|
|
2127
|
+
/**
|
|
2128
|
+
* Transform options for the source.
|
|
2129
|
+
*/
|
|
2130
|
+
transform?: SourceTransformOptions;
|
|
1992
2131
|
}
|
|
1993
2132
|
|
|
1994
2133
|
/**
|
|
@@ -2106,8 +2245,16 @@ interface WindowCaptureSourceSettings extends CaptureSourceSettings {
|
|
|
2106
2245
|
* The name of the executable associated with the window to capture.
|
|
2107
2246
|
*
|
|
2108
2247
|
* This is typically the process name (e.g., `"notepad.exe"` or `"chrome.exe"`).
|
|
2248
|
+
*
|
|
2249
|
+
* Mandatory field when using Window Capture source.
|
|
2250
|
+
* Optional when using Browser Window source.
|
|
2109
2251
|
*/
|
|
2110
|
-
executable
|
|
2252
|
+
executable?: string;
|
|
2253
|
+
|
|
2254
|
+
/**
|
|
2255
|
+
* The window title, if multiple windows of the same executable exist.
|
|
2256
|
+
*/
|
|
2257
|
+
windowTitle?: string;
|
|
2111
2258
|
|
|
2112
2259
|
/**
|
|
2113
2260
|
* The capture method used to record the window.
|
|
@@ -2165,6 +2312,13 @@ interface CaptureSource {
|
|
|
2165
2312
|
* capture method, and more, depending on the selected source type.
|
|
2166
2313
|
*/
|
|
2167
2314
|
readonly properties: any;
|
|
2315
|
+
|
|
2316
|
+
/**
|
|
2317
|
+
* Optional name for the capture source.
|
|
2318
|
+
*
|
|
2319
|
+
* Can be used later for setting transform properties.
|
|
2320
|
+
*/
|
|
2321
|
+
readonly name?: string;
|
|
2168
2322
|
}
|
|
2169
2323
|
|
|
2170
2324
|
/**
|
|
@@ -2855,6 +3009,26 @@ interface CaptureSettingsBuilder extends CaptureSettings {
|
|
|
2855
3009
|
*/
|
|
2856
3010
|
addGameSource(settings: GameCaptureSourceSettings): CaptureSettingsBuilder;
|
|
2857
3011
|
|
|
3012
|
+
/**
|
|
3013
|
+
* Add Window video capture source
|
|
3014
|
+
* settings. Executable is mandatory.
|
|
3015
|
+
* @param settings
|
|
3016
|
+
*/
|
|
3017
|
+
addWindowSource(
|
|
3018
|
+
settings: WindowCaptureSourceSettings
|
|
3019
|
+
): CaptureSettingsBuilder;
|
|
3020
|
+
|
|
3021
|
+
/**
|
|
3022
|
+
* Add Electron window capture source
|
|
3023
|
+
* settings. Executable is optional.
|
|
3024
|
+
* @param browserWindow
|
|
3025
|
+
* @param settings
|
|
3026
|
+
*/
|
|
3027
|
+
addBrowserWindowSource(
|
|
3028
|
+
browserWindow: BrowserWindow,
|
|
3029
|
+
setting: WindowCaptureSourceSettings
|
|
3030
|
+
): CaptureSettingsBuilder;
|
|
3031
|
+
|
|
2858
3032
|
/**
|
|
2859
3033
|
* Adds an audio device for capturing input or output audio.
|
|
2860
3034
|
*
|
|
@@ -3014,24 +3188,6 @@ interface RecordingAppOptions {
|
|
|
3014
3188
|
* Can be used to troubleshoot issues during recording.
|
|
3015
3189
|
*/
|
|
3016
3190
|
enableDebugLogs?: boolean;
|
|
3017
|
-
|
|
3018
|
-
/**
|
|
3019
|
-
* Additional command-line arguments to pass when launching the recorder.
|
|
3020
|
-
* This can be used to customize the underlying OBS runtime behavior.
|
|
3021
|
-
*/
|
|
3022
|
-
customCommandLineArgs?: string[];
|
|
3023
|
-
|
|
3024
|
-
/**
|
|
3025
|
-
* Specifies a custom folder path to override the default OBS binaries used by the recorder.
|
|
3026
|
-
* Useful for testing with a modified or custom OBS build.
|
|
3027
|
-
*/
|
|
3028
|
-
overrideOBSFolder?: string;
|
|
3029
|
-
|
|
3030
|
-
/**
|
|
3031
|
-
* Interval in milliseconds for emitting 'stats' events.
|
|
3032
|
-
* Default is 2000 (2 seconds). Set to `0` to disable stats reporting.
|
|
3033
|
-
*/
|
|
3034
|
-
statsInterval?: number;
|
|
3035
3191
|
}
|
|
3036
3192
|
|
|
3037
3193
|
|
|
@@ -3609,22 +3765,22 @@ interface IOverwolfRecordingApi {
|
|
|
3609
3765
|
options: RecordingAppOptions;
|
|
3610
3766
|
|
|
3611
3767
|
/**
|
|
3612
|
-
* Overlay package version
|
|
3768
|
+
* Overlay package version.
|
|
3613
3769
|
*/
|
|
3614
3770
|
readonly version: string;
|
|
3615
3771
|
|
|
3616
3772
|
/**
|
|
3617
|
-
* Path to ffmpeg
|
|
3773
|
+
* Path to ffmpeg file.
|
|
3618
3774
|
*/
|
|
3619
3775
|
readonly ffmpegPath: string;
|
|
3620
3776
|
|
|
3621
3777
|
/**
|
|
3622
|
-
* Path to
|
|
3778
|
+
* Path to OBS binaries folder.
|
|
3623
3779
|
*/
|
|
3624
3780
|
readonly binFolderPath: string;
|
|
3625
3781
|
|
|
3626
3782
|
/**
|
|
3627
|
-
*
|
|
3783
|
+
* Checks if either recording or replays are currently active.
|
|
3628
3784
|
*/
|
|
3629
3785
|
isActive(): Promise<boolean>;
|
|
3630
3786
|
|
|
@@ -3734,7 +3890,6 @@ interface IOverwolfRecordingApi {
|
|
|
3734
3890
|
* Registers games to monitor and track for launch/exit detection.
|
|
3735
3891
|
*
|
|
3736
3892
|
* @param filter Filtering rules for which games to track.
|
|
3737
|
-
*
|
|
3738
3893
|
*/
|
|
3739
3894
|
registerGames(filter: GamesFilter): void;
|
|
3740
3895
|
|
|
@@ -3745,9 +3900,17 @@ interface IOverwolfRecordingApi {
|
|
|
3745
3900
|
* @see {@link AudioDeviceSettingsUpdateInfo}
|
|
3746
3901
|
* @since 0.32.0
|
|
3747
3902
|
*/
|
|
3748
|
-
updateAudioDevice(
|
|
3749
|
-
|
|
3750
|
-
|
|
3903
|
+
updateAudioDevice(device: AudioDeviceSettingsUpdateInfo): Promise<void>;
|
|
3904
|
+
|
|
3905
|
+
/**
|
|
3906
|
+
* Set a source to transform.
|
|
3907
|
+
*
|
|
3908
|
+
* Defines how the source will be rendered (for example, position, scale, crop, etc.).
|
|
3909
|
+
* Throws an error if the source is not found or if the transform is invalid.
|
|
3910
|
+
*
|
|
3911
|
+
* @param sourceTransform
|
|
3912
|
+
*/
|
|
3913
|
+
setSourceTransform(sourceTransform: SourceTransform): Promise<void>;
|
|
3751
3914
|
|
|
3752
3915
|
/** @event Fired when a registered game is launched. */
|
|
3753
3916
|
on(eventName: 'game-launched', listener: (gameInfo: GameInfo) => void): this;
|
|
@@ -3779,9 +3942,9 @@ interface IOverwolfRecordingApi {
|
|
|
3779
3942
|
*/
|
|
3780
3943
|
on(eventName: 'stats', listener: (args: RecorderStats) => void): this;
|
|
3781
3944
|
}
|
|
3782
|
-
|
|
3783
|
-
|
|
3784
|
-
// --- modules\packages.d.ts ---
|
|
3945
|
+
|
|
3946
|
+
|
|
3947
|
+
// --- modules\packages.d.ts ---
|
|
3785
3948
|
// -----------------------------------------------------------------------------
|
|
3786
3949
|
//
|
|
3787
3950
|
/**
|
|
@@ -3836,9 +3999,9 @@ interface OWPackages extends overwolf.packages.OverwolfPackageManager {
|
|
|
3836
3999
|
*/
|
|
3837
4000
|
crn: IOverwolfCRNApi;
|
|
3838
4001
|
}
|
|
3839
|
-
|
|
3840
|
-
|
|
3841
|
-
// --- modules\overlay.d.ts ---
|
|
4002
|
+
|
|
4003
|
+
|
|
4004
|
+
// --- modules\overlay.d.ts ---
|
|
3842
4005
|
/**
|
|
3843
4006
|
* APIs for controlling and creating overlays in games. Overlay is the ability to show windows on top of the current game window.
|
|
3844
4007
|
*
|
|
@@ -4842,9 +5005,9 @@ interface IOverwolfOverlayApi extends EventEmitter {
|
|
|
4842
5005
|
listener: (info: GameInputInterception) => void
|
|
4843
5006
|
): this;
|
|
4844
5007
|
}
|
|
4845
|
-
|
|
4846
|
-
|
|
4847
|
-
// --- modules\crn.d.ts ---
|
|
5008
|
+
|
|
5009
|
+
|
|
5010
|
+
// --- modules\crn.d.ts ---
|
|
4848
5011
|
/**
|
|
4849
5012
|
* The *Content Recommendation Notification* (CRN) APIs give you tools to help manage the content notification settings in your app.
|
|
4850
5013
|
*
|
|
@@ -4981,4 +5144,4 @@ export interface IOverwolfCRNApi {
|
|
|
4981
5144
|
eventName: 'notification-action',
|
|
4982
5145
|
listener: (event: CRNActionType) => void
|
|
4983
5146
|
): this;
|
|
4984
|
-
}
|
|
5147
|
+
}
|