@webref/idl 3.9.0 → 3.11.1
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/FedCM.idl +40 -0
- package/{mediacapture-handle-identity.idl → capture-handle-identity.idl} +0 -10
- package/conversion-measurement-api.idl +3 -22
- package/cssom-view.idl +0 -1
- package/fetch.idl +1 -0
- package/html.idl +1 -1
- package/media-source.idl +10 -6
- package/mediacapture-viewport.idl +9 -0
- package/package.json +2 -2
- package/screen-capture.idl +6 -0
- package/touch-events.idl +1 -0
- package/webaudio.idl +10 -4
- package/webgl1.idl +2 -0
- package/webgpu.idl +44 -30
- package/webnn.idl +53 -14
- package/webrtc-encoded-transform.idl +1 -1
package/FedCM.idl
ADDED
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
// GENERATED CONTENT - DO NOT EDIT
|
|
2
|
+
// Content was automatically extracted by Reffy into webref
|
|
3
|
+
// (https://github.com/w3c/webref)
|
|
4
|
+
// Source: Federated Credential Management API (https://fedidcg.github.io/FedCM/)
|
|
5
|
+
|
|
6
|
+
[Exposed=Window, SecureContext]
|
|
7
|
+
dictionary FederatedAccountLoginRequest {
|
|
8
|
+
AbortSignal signal;
|
|
9
|
+
USVString nonce;
|
|
10
|
+
};
|
|
11
|
+
|
|
12
|
+
[Exposed=Window, SecureContext]
|
|
13
|
+
partial interface FederatedCredential {
|
|
14
|
+
Promise<FederatedTokens> login(optional FederatedAccountLoginRequest request = {});
|
|
15
|
+
};
|
|
16
|
+
|
|
17
|
+
[Exposed=Window, SecureContext]
|
|
18
|
+
dictionary FederatedTokens {
|
|
19
|
+
USVString idToken;
|
|
20
|
+
};
|
|
21
|
+
|
|
22
|
+
[Exposed=Window, SecureContext]
|
|
23
|
+
partial interface FederatedCredential {
|
|
24
|
+
Promise<undefined> revoke(USVString hint);
|
|
25
|
+
};
|
|
26
|
+
|
|
27
|
+
[Exposed=Window, SecureContext]
|
|
28
|
+
partial interface FederatedCredential {
|
|
29
|
+
Promise<undefined> logout();
|
|
30
|
+
};
|
|
31
|
+
|
|
32
|
+
dictionary FederatedCredentialLogoutRpsRequest {
|
|
33
|
+
required USVString url;
|
|
34
|
+
required USVString accountId;
|
|
35
|
+
};
|
|
36
|
+
|
|
37
|
+
[Exposed=Window, SecureContext]
|
|
38
|
+
partial interface FederatedCredential {
|
|
39
|
+
static Promise<undefined> logoutRPs(sequence<FederatedCredentialLogoutRpsRequest> logoutRequests);
|
|
40
|
+
};
|
|
@@ -22,16 +22,6 @@ partial interface MediaStreamTrack {
|
|
|
22
22
|
CaptureHandle? getCaptureHandle();
|
|
23
23
|
};
|
|
24
24
|
|
|
25
|
-
[Exposed=Window]
|
|
26
|
-
interface CaptureHandleChangeEvent : Event {
|
|
27
|
-
constructor(optional CaptureHandleChangeEventInit init = {});
|
|
28
|
-
[SameObject] CaptureHandle captureHandle();
|
|
29
|
-
};
|
|
30
|
-
|
|
31
|
-
dictionary CaptureHandleChangeEventInit : EventInit {
|
|
32
|
-
CaptureHandle captureHandle;
|
|
33
|
-
};
|
|
34
|
-
|
|
35
25
|
partial interface MediaStreamTrack {
|
|
36
26
|
attribute EventHandler oncapturehandlechange;
|
|
37
27
|
};
|
|
@@ -4,28 +4,9 @@
|
|
|
4
4
|
// Source: Attribution Reporting (https://wicg.github.io/conversion-measurement-api/)
|
|
5
5
|
|
|
6
6
|
partial interface HTMLAnchorElement {
|
|
7
|
-
[CEReactions] attribute USVString
|
|
8
|
-
[CEReactions] attribute DOMString attributionSourceEventId;
|
|
9
|
-
[CEReactions] attribute USVString attributionReportTo;
|
|
10
|
-
[CEReactions] attribute long long attributionExpiry;
|
|
11
|
-
[CEReactions] attribute long long attributionSourcePriority;
|
|
12
|
-
[CEReactions] attribute boolean registerAttributionSource;
|
|
7
|
+
[CEReactions] attribute USVString attributionSrc;
|
|
13
8
|
};
|
|
14
9
|
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
required DOMString attributionSourceEventId;
|
|
18
|
-
USVString attributionReportTo;
|
|
19
|
-
long long attributionExpiry;
|
|
20
|
-
long long attributionSourcePriority;
|
|
21
|
-
};
|
|
22
|
-
|
|
23
|
-
[Exposed=Window, SecureContext]
|
|
24
|
-
interface AttributionReporting {
|
|
25
|
-
Promise<undefined> registerAttributionSource(AttributionSourceParams params);
|
|
26
|
-
};
|
|
27
|
-
|
|
28
|
-
[SecureContext]
|
|
29
|
-
partial interface Window {
|
|
30
|
-
readonly attribute AttributionReporting attributionReporting;
|
|
10
|
+
partial interface HTMLImageElement {
|
|
11
|
+
[CEReactions] attribute USVString attributionSrc;
|
|
31
12
|
};
|
package/cssom-view.idl
CHANGED
package/fetch.idl
CHANGED
|
@@ -83,6 +83,7 @@ enum RequestRedirect { "follow", "error", "manual" };
|
|
|
83
83
|
|
|
84
84
|
[NewObject] static Response error();
|
|
85
85
|
[NewObject] static Response redirect(USVString url, optional unsigned short status = 302);
|
|
86
|
+
[NewObject] static Response json(any data, optional ResponseInit init = {});
|
|
86
87
|
|
|
87
88
|
readonly attribute ResponseType type;
|
|
88
89
|
|
package/html.idl
CHANGED
|
@@ -192,7 +192,7 @@ interface HTMLLinkElement : HTMLElement {
|
|
|
192
192
|
[CEReactions] attribute USVString href;
|
|
193
193
|
[CEReactions] attribute DOMString? crossOrigin;
|
|
194
194
|
[CEReactions] attribute DOMString rel;
|
|
195
|
-
[CEReactions] attribute DOMString as;
|
|
195
|
+
[CEReactions] attribute DOMString as;
|
|
196
196
|
[SameObject, PutForwards=value] readonly attribute DOMTokenList relList;
|
|
197
197
|
[CEReactions] attribute DOMString media;
|
|
198
198
|
[CEReactions] attribute DOMString integrity;
|
package/media-source.idl
CHANGED
|
@@ -25,14 +25,18 @@ interface MediaSource : EventTarget {
|
|
|
25
25
|
attribute EventHandler onsourceended;
|
|
26
26
|
attribute EventHandler onsourceclose;
|
|
27
27
|
static readonly attribute boolean canConstructInDedicatedWorker;
|
|
28
|
-
SourceBuffer
|
|
29
|
-
undefined
|
|
30
|
-
undefined
|
|
31
|
-
undefined
|
|
32
|
-
undefined
|
|
33
|
-
|
|
28
|
+
SourceBuffer addSourceBuffer (DOMString type);
|
|
29
|
+
undefined removeSourceBuffer (SourceBuffer sourceBuffer);
|
|
30
|
+
undefined endOfStream (optional EndOfStreamError error);
|
|
31
|
+
undefined setLiveSeekableRange (double start, double end);
|
|
32
|
+
undefined clearLiveSeekableRange ();
|
|
33
|
+
MediaSourceHandle getHandle ();
|
|
34
|
+
static boolean isTypeSupported (DOMString type);
|
|
34
35
|
};
|
|
35
36
|
|
|
37
|
+
[Exposed=(Window,DedicatedWorker)]
|
|
38
|
+
interface MediaSourceHandle {};
|
|
39
|
+
|
|
36
40
|
enum AppendMode {
|
|
37
41
|
"segments",
|
|
38
42
|
"sequence"
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
// GENERATED CONTENT - DO NOT EDIT
|
|
2
|
+
// Content was automatically extracted by Reffy into webref
|
|
3
|
+
// (https://github.com/w3c/webref)
|
|
4
|
+
// Source: Viewport Capture (https://w3c.github.io/mediacapture-viewport/)
|
|
5
|
+
|
|
6
|
+
partial interface MediaDevices {
|
|
7
|
+
Promise<MediaStream> getViewportMedia(
|
|
8
|
+
optional DisplayMediaStreamConstraints constraints = {});
|
|
9
|
+
};
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@webref/idl",
|
|
3
3
|
"description": "Web IDL definitions of the web platform",
|
|
4
|
-
"version": "3.
|
|
4
|
+
"version": "3.11.1",
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|
|
7
7
|
"url": "https://github.com/w3c/webref.git"
|
|
@@ -12,6 +12,6 @@
|
|
|
12
12
|
"license": "MIT",
|
|
13
13
|
"main": "index.js",
|
|
14
14
|
"peerDependencies": {
|
|
15
|
-
"webidl2": "^24.2.
|
|
15
|
+
"webidl2": "^24.2.2"
|
|
16
16
|
}
|
|
17
17
|
}
|
package/screen-capture.idl
CHANGED
|
@@ -12,10 +12,16 @@ enum SelfCapturePreferenceEnum {
|
|
|
12
12
|
"exclude"
|
|
13
13
|
};
|
|
14
14
|
|
|
15
|
+
enum SystemAudioPreferenceEnum {
|
|
16
|
+
"include",
|
|
17
|
+
"exclude"
|
|
18
|
+
};
|
|
19
|
+
|
|
15
20
|
dictionary DisplayMediaStreamConstraints {
|
|
16
21
|
(boolean or MediaTrackConstraints) video = true;
|
|
17
22
|
(boolean or MediaTrackConstraints) audio = false;
|
|
18
23
|
SelfCapturePreferenceEnum selfBrowserSurface;
|
|
24
|
+
SystemAudioPreferenceEnum systemAudio;
|
|
19
25
|
};
|
|
20
26
|
|
|
21
27
|
partial dictionary MediaTrackSupportedConstraints {
|
package/touch-events.idl
CHANGED
|
@@ -68,6 +68,7 @@ interface TouchEvent : UIEvent {
|
|
|
68
68
|
readonly attribute boolean metaKey;
|
|
69
69
|
readonly attribute boolean ctrlKey;
|
|
70
70
|
readonly attribute boolean shiftKey;
|
|
71
|
+
getter boolean getModifierState (DOMString keyArg);
|
|
71
72
|
};
|
|
72
73
|
|
|
73
74
|
partial interface mixin GlobalEventHandlers {
|
package/webaudio.idl
CHANGED
|
@@ -92,7 +92,7 @@ dictionary AudioTimestamp {
|
|
|
92
92
|
};
|
|
93
93
|
|
|
94
94
|
[Exposed=Window]
|
|
95
|
-
interface AudioRenderCapacity {
|
|
95
|
+
interface AudioRenderCapacity : EventTarget {
|
|
96
96
|
undefined start(optional AudioRenderCapacityOptions options = {});
|
|
97
97
|
undefined stop();
|
|
98
98
|
attribute EventHandler onupdate;
|
|
@@ -103,15 +103,21 @@ dictionary AudioRenderCapacityOptions {
|
|
|
103
103
|
};
|
|
104
104
|
|
|
105
105
|
[Exposed=Window]
|
|
106
|
-
interface AudioRenderCapacityEvent {
|
|
107
|
-
constructor (DOMString type,
|
|
108
|
-
double peakLoad, double underrunRatio);
|
|
106
|
+
interface AudioRenderCapacityEvent : Event {
|
|
107
|
+
constructor (DOMString type, optional AudioRenderCapacityEventInit eventInitDict = {});
|
|
109
108
|
readonly attribute double timestamp;
|
|
110
109
|
readonly attribute double averageLoad;
|
|
111
110
|
readonly attribute double peakLoad;
|
|
112
111
|
readonly attribute double underrunRatio;
|
|
113
112
|
};
|
|
114
113
|
|
|
114
|
+
dictionary AudioRenderCapacityEventInit : EventInit {
|
|
115
|
+
double timestamp = 0;
|
|
116
|
+
double averageLoad = 0;
|
|
117
|
+
double peakLoad = 0;
|
|
118
|
+
double underrunRatio = 0;
|
|
119
|
+
};
|
|
120
|
+
|
|
115
121
|
[Exposed=Window]
|
|
116
122
|
interface OfflineAudioContext : BaseAudioContext {
|
|
117
123
|
constructor(OfflineAudioContextOptions contextOptions);
|
package/webgl1.idl
CHANGED
|
@@ -516,6 +516,8 @@ interface mixin WebGLRenderingContextBase
|
|
|
516
516
|
readonly attribute (HTMLCanvasElement or OffscreenCanvas) canvas;
|
|
517
517
|
readonly attribute GLsizei drawingBufferWidth;
|
|
518
518
|
readonly attribute GLsizei drawingBufferHeight;
|
|
519
|
+
attribute PredefinedColorSpace drawingBufferColorSpace;
|
|
520
|
+
attribute PredefinedColorSpace unpackColorSpace;
|
|
519
521
|
|
|
520
522
|
[WebGLHandlesContextLoss] WebGLContextAttributes? getContextAttributes();
|
|
521
523
|
[WebGLHandlesContextLoss] boolean isContextLost();
|
package/webgpu.idl
CHANGED
|
@@ -46,6 +46,14 @@ interface GPUSupportedFeatures {
|
|
|
46
46
|
readonly setlike<DOMString>;
|
|
47
47
|
};
|
|
48
48
|
|
|
49
|
+
[Exposed=(Window, DedicatedWorker), SecureContext]
|
|
50
|
+
interface GPUAdapterInfo {
|
|
51
|
+
readonly attribute DOMString vendor;
|
|
52
|
+
readonly attribute DOMString architecture;
|
|
53
|
+
readonly attribute DOMString device;
|
|
54
|
+
readonly attribute DOMString description;
|
|
55
|
+
};
|
|
56
|
+
|
|
49
57
|
enum GPUPredefinedColorSpace {
|
|
50
58
|
"srgb",
|
|
51
59
|
};
|
|
@@ -59,6 +67,7 @@ WorkerNavigator includes NavigatorGPU;
|
|
|
59
67
|
[Exposed=(Window, DedicatedWorker), SecureContext]
|
|
60
68
|
interface GPU {
|
|
61
69
|
Promise<GPUAdapter?> requestAdapter(optional GPURequestAdapterOptions options = {});
|
|
70
|
+
GPUTextureFormat getPreferredCanvasFormat();
|
|
62
71
|
};
|
|
63
72
|
|
|
64
73
|
dictionary GPURequestAdapterOptions {
|
|
@@ -73,12 +82,12 @@ enum GPUPowerPreference {
|
|
|
73
82
|
|
|
74
83
|
[Exposed=(Window, DedicatedWorker), SecureContext]
|
|
75
84
|
interface GPUAdapter {
|
|
76
|
-
readonly attribute DOMString name;
|
|
77
85
|
[SameObject] readonly attribute GPUSupportedFeatures features;
|
|
78
86
|
[SameObject] readonly attribute GPUSupportedLimits limits;
|
|
79
87
|
readonly attribute boolean isFallbackAdapter;
|
|
80
88
|
|
|
81
89
|
Promise<GPUDevice> requestDevice(optional GPUDeviceDescriptor descriptor = {});
|
|
90
|
+
Promise<GPUAdapterInfo> requestAdapterInfo(optional sequence<DOMString> unmaskHints = []);
|
|
82
91
|
};
|
|
83
92
|
|
|
84
93
|
dictionary GPUDeviceDescriptor : GPUObjectDescriptorBase {
|
|
@@ -97,6 +106,7 @@ enum GPUFeatureName {
|
|
|
97
106
|
"timestamp-query",
|
|
98
107
|
"indirect-first-instance",
|
|
99
108
|
"shader-f16",
|
|
109
|
+
"bgra8unorm-storage",
|
|
100
110
|
};
|
|
101
111
|
|
|
102
112
|
[Exposed=(Window, DedicatedWorker), SecureContext]
|
|
@@ -420,14 +430,6 @@ dictionary GPUBindGroupLayoutDescriptor : GPUObjectDescriptorBase {
|
|
|
420
430
|
required sequence<GPUBindGroupLayoutEntry> entries;
|
|
421
431
|
};
|
|
422
432
|
|
|
423
|
-
typedef [EnforceRange] unsigned long GPUShaderStageFlags;
|
|
424
|
-
[Exposed=(Window, DedicatedWorker)]
|
|
425
|
-
namespace GPUShaderStage {
|
|
426
|
-
const GPUFlagsConstant VERTEX = 0x1;
|
|
427
|
-
const GPUFlagsConstant FRAGMENT = 0x2;
|
|
428
|
-
const GPUFlagsConstant COMPUTE = 0x4;
|
|
429
|
-
};
|
|
430
|
-
|
|
431
433
|
dictionary GPUBindGroupLayoutEntry {
|
|
432
434
|
required GPUIndex32 binding;
|
|
433
435
|
required GPUShaderStageFlags visibility;
|
|
@@ -439,6 +441,14 @@ dictionary GPUBindGroupLayoutEntry {
|
|
|
439
441
|
GPUExternalTextureBindingLayout externalTexture;
|
|
440
442
|
};
|
|
441
443
|
|
|
444
|
+
typedef [EnforceRange] unsigned long GPUShaderStageFlags;
|
|
445
|
+
[Exposed=(Window, DedicatedWorker)]
|
|
446
|
+
namespace GPUShaderStage {
|
|
447
|
+
const GPUFlagsConstant VERTEX = 0x1;
|
|
448
|
+
const GPUFlagsConstant FRAGMENT = 0x2;
|
|
449
|
+
const GPUFlagsConstant COMPUTE = 0x4;
|
|
450
|
+
};
|
|
451
|
+
|
|
442
452
|
enum GPUBufferBindingType {
|
|
443
453
|
"uniform",
|
|
444
454
|
"storage",
|
|
@@ -526,16 +536,16 @@ interface GPUShaderModule {
|
|
|
526
536
|
};
|
|
527
537
|
GPUShaderModule includes GPUObjectBase;
|
|
528
538
|
|
|
529
|
-
dictionary GPUShaderModuleCompilationHint {
|
|
530
|
-
required GPUPipelineLayout layout;
|
|
531
|
-
};
|
|
532
|
-
|
|
533
539
|
dictionary GPUShaderModuleDescriptor : GPUObjectDescriptorBase {
|
|
534
540
|
required USVString code;
|
|
535
541
|
object sourceMap;
|
|
536
542
|
record<USVString, GPUShaderModuleCompilationHint> hints;
|
|
537
543
|
};
|
|
538
544
|
|
|
545
|
+
dictionary GPUShaderModuleCompilationHint {
|
|
546
|
+
(GPUPipelineLayout or GPUAutoLayoutMode) layout;
|
|
547
|
+
};
|
|
548
|
+
|
|
539
549
|
enum GPUCompilationMessageType {
|
|
540
550
|
"error",
|
|
541
551
|
"warning",
|
|
@@ -557,12 +567,16 @@ interface GPUCompilationInfo {
|
|
|
557
567
|
readonly attribute FrozenArray<GPUCompilationMessage> messages;
|
|
558
568
|
};
|
|
559
569
|
|
|
570
|
+
enum GPUAutoLayoutMode {
|
|
571
|
+
"auto",
|
|
572
|
+
};
|
|
573
|
+
|
|
560
574
|
dictionary GPUPipelineDescriptorBase : GPUObjectDescriptorBase {
|
|
561
|
-
GPUPipelineLayout layout;
|
|
575
|
+
required (GPUPipelineLayout or GPUAutoLayoutMode) layout;
|
|
562
576
|
};
|
|
563
577
|
|
|
564
578
|
interface mixin GPUPipelineBase {
|
|
565
|
-
GPUBindGroupLayout getBindGroupLayout(unsigned long index);
|
|
579
|
+
[NewObject] GPUBindGroupLayout getBindGroupLayout(unsigned long index);
|
|
566
580
|
};
|
|
567
581
|
|
|
568
582
|
dictionary GPUProgrammableStage {
|
|
@@ -597,14 +611,6 @@ dictionary GPURenderPipelineDescriptor : GPUPipelineDescriptorBase {
|
|
|
597
611
|
GPUFragmentState fragment;
|
|
598
612
|
};
|
|
599
613
|
|
|
600
|
-
enum GPUPrimitiveTopology {
|
|
601
|
-
"point-list",
|
|
602
|
-
"line-list",
|
|
603
|
-
"line-strip",
|
|
604
|
-
"triangle-list",
|
|
605
|
-
"triangle-strip",
|
|
606
|
-
};
|
|
607
|
-
|
|
608
614
|
dictionary GPUPrimitiveState {
|
|
609
615
|
GPUPrimitiveTopology topology = "triangle-list";
|
|
610
616
|
GPUIndexFormat stripIndexFormat;
|
|
@@ -615,6 +621,14 @@ dictionary GPUPrimitiveState {
|
|
|
615
621
|
boolean unclippedDepth = false;
|
|
616
622
|
};
|
|
617
623
|
|
|
624
|
+
enum GPUPrimitiveTopology {
|
|
625
|
+
"point-list",
|
|
626
|
+
"line-list",
|
|
627
|
+
"line-strip",
|
|
628
|
+
"triangle-list",
|
|
629
|
+
"triangle-strip",
|
|
630
|
+
};
|
|
631
|
+
|
|
618
632
|
enum GPUFrontFace {
|
|
619
633
|
"ccw",
|
|
620
634
|
"cw",
|
|
@@ -1093,7 +1107,6 @@ interface GPUCanvasContext {
|
|
|
1093
1107
|
undefined configure(GPUCanvasConfiguration configuration);
|
|
1094
1108
|
undefined unconfigure();
|
|
1095
1109
|
|
|
1096
|
-
GPUTextureFormat getPreferredFormat(GPUAdapter adapter);
|
|
1097
1110
|
GPUTexture getCurrentTexture();
|
|
1098
1111
|
};
|
|
1099
1112
|
|
|
@@ -1109,7 +1122,6 @@ dictionary GPUCanvasConfiguration {
|
|
|
1109
1122
|
sequence<GPUTextureFormat> viewFormats = [];
|
|
1110
1123
|
GPUPredefinedColorSpace colorSpace = "srgb";
|
|
1111
1124
|
GPUCanvasCompositingAlphaMode compositingAlphaMode = "opaque";
|
|
1112
|
-
GPUExtent3D size;
|
|
1113
1125
|
};
|
|
1114
1126
|
|
|
1115
1127
|
enum GPUDeviceLostReason {
|
|
@@ -1132,17 +1144,19 @@ enum GPUErrorFilter {
|
|
|
1132
1144
|
};
|
|
1133
1145
|
|
|
1134
1146
|
[Exposed=(Window, DedicatedWorker), SecureContext]
|
|
1135
|
-
interface
|
|
1136
|
-
|
|
1147
|
+
interface GPUError {
|
|
1148
|
+
readonly attribute DOMString message;
|
|
1137
1149
|
};
|
|
1138
1150
|
|
|
1139
1151
|
[Exposed=(Window, DedicatedWorker), SecureContext]
|
|
1140
|
-
interface
|
|
1152
|
+
interface GPUOutOfMemoryError : GPUError {
|
|
1141
1153
|
constructor(DOMString message);
|
|
1142
|
-
readonly attribute DOMString message;
|
|
1143
1154
|
};
|
|
1144
1155
|
|
|
1145
|
-
|
|
1156
|
+
[Exposed=(Window, DedicatedWorker), SecureContext]
|
|
1157
|
+
interface GPUValidationError : GPUError {
|
|
1158
|
+
constructor(DOMString message);
|
|
1159
|
+
};
|
|
1146
1160
|
|
|
1147
1161
|
partial interface GPUDevice {
|
|
1148
1162
|
undefined pushErrorScope(GPUErrorFilter filter);
|
package/webnn.idl
CHANGED
|
@@ -9,10 +9,9 @@ interface mixin NavigatorML {
|
|
|
9
9
|
Navigator includes NavigatorML;
|
|
10
10
|
WorkerNavigator includes NavigatorML;
|
|
11
11
|
|
|
12
|
-
enum
|
|
13
|
-
"
|
|
14
|
-
"gpu"
|
|
15
|
-
"cpu"
|
|
12
|
+
enum MLDeviceType {
|
|
13
|
+
"cpu",
|
|
14
|
+
"gpu"
|
|
16
15
|
};
|
|
17
16
|
|
|
18
17
|
enum MLPowerPreference {
|
|
@@ -22,20 +21,43 @@ enum MLPowerPreference {
|
|
|
22
21
|
};
|
|
23
22
|
|
|
24
23
|
dictionary MLContextOptions {
|
|
25
|
-
|
|
24
|
+
MLDeviceType deviceType = "cpu";
|
|
26
25
|
MLPowerPreference powerPreference = "default";
|
|
27
26
|
};
|
|
28
27
|
|
|
29
28
|
[SecureContext, Exposed=(Window, DedicatedWorker)]
|
|
30
29
|
interface ML {
|
|
31
30
|
MLContext createContext(optional MLContextOptions options = {});
|
|
32
|
-
MLContext createContext(WebGLRenderingContext glContext);
|
|
33
31
|
MLContext createContext(GPUDevice gpuDevice);
|
|
32
|
+
MLContext createContext(WebGLRenderingContext glContext);
|
|
33
|
+
};
|
|
34
|
+
|
|
35
|
+
dictionary MLArrayInput {
|
|
36
|
+
required ArrayBufferView resource;
|
|
37
|
+
required sequence<long> dimensions;
|
|
34
38
|
};
|
|
35
39
|
|
|
40
|
+
typedef record<DOMString, (ArrayBufferView or MLArrayInput)> MLNamedArrayInputs;
|
|
41
|
+
typedef record<DOMString, ArrayBufferView> MLNamedArrayOutputs;
|
|
42
|
+
|
|
36
43
|
[SecureContext, Exposed=(Window, DedicatedWorker)]
|
|
37
44
|
interface MLContext {};
|
|
38
45
|
|
|
46
|
+
partial interface MLContext {
|
|
47
|
+
[Exposed=(DedicatedWorker)]
|
|
48
|
+
undefined compute(MLGraph graph, MLNamedArrayInputs inputs, MLNamedArrayOutputs outputs);
|
|
49
|
+
};
|
|
50
|
+
|
|
51
|
+
partial interface MLContext {
|
|
52
|
+
Promise<undefined> computeAsync(MLGraph graph, MLNamedArrayInputs inputs,
|
|
53
|
+
|
|
54
|
+
MLNamedArrayOutputs outputs);
|
|
55
|
+
};
|
|
56
|
+
|
|
57
|
+
partial interface MLContext {
|
|
58
|
+
MLCommandEncoder createCommandEncoder();
|
|
59
|
+
};
|
|
60
|
+
|
|
39
61
|
enum MLInputOperandLayout {
|
|
40
62
|
"nchw",
|
|
41
63
|
"nhwc"
|
|
@@ -89,8 +111,12 @@ interface MLGraphBuilder {
|
|
|
89
111
|
// Create a single-value operand from the specified number of the specified type.
|
|
90
112
|
MLOperand constant(double value, optional MLOperandType type = "float32");
|
|
91
113
|
|
|
92
|
-
// Compile the graph up to the specified output operands
|
|
114
|
+
// Compile the graph up to the specified output operands synchronously.
|
|
115
|
+
[Exposed=(DedicatedWorker)]
|
|
93
116
|
MLGraph build(MLNamedOperands outputs);
|
|
117
|
+
|
|
118
|
+
// Compile the graph up to the specified output operands asynchronously.
|
|
119
|
+
Promise<MLGraph> buildAsync(MLNamedOperands outputs);
|
|
94
120
|
};
|
|
95
121
|
|
|
96
122
|
dictionary MLBatchNormalizationOptions {
|
|
@@ -454,17 +480,30 @@ partial interface MLGraphBuilder {
|
|
|
454
480
|
MLOperand transpose(MLOperand input, optional MLTransposeOptions options = {});
|
|
455
481
|
};
|
|
456
482
|
|
|
457
|
-
|
|
483
|
+
[SecureContext, Exposed=(Window, DedicatedWorker)]
|
|
484
|
+
interface MLGraph {};
|
|
485
|
+
|
|
486
|
+
typedef (GPUBuffer or GPUTexture) MLGPUResource;
|
|
458
487
|
|
|
459
|
-
dictionary
|
|
460
|
-
required
|
|
488
|
+
dictionary MLGPUInput {
|
|
489
|
+
required MLGPUResource resource;
|
|
461
490
|
required sequence<long> dimensions;
|
|
462
491
|
};
|
|
463
492
|
|
|
464
|
-
typedef record<DOMString, (
|
|
465
|
-
typedef record<DOMString,
|
|
493
|
+
typedef record<DOMString, (MLGPUResource or MLGPUInput)> MLNamedGPUInputs;
|
|
494
|
+
typedef record<DOMString, MLGPUResource> MLNamedGPUOutputs;
|
|
466
495
|
|
|
467
496
|
[SecureContext, Exposed=(Window, DedicatedWorker)]
|
|
468
|
-
interface
|
|
469
|
-
|
|
497
|
+
interface MLCommandEncoder {};
|
|
498
|
+
|
|
499
|
+
partial interface MLCommandEncoder {
|
|
500
|
+
undefined initializeGraph(MLGraph graph);
|
|
501
|
+
};
|
|
502
|
+
|
|
503
|
+
partial interface MLCommandEncoder {
|
|
504
|
+
undefined dispatch(MLGraph graph, MLNamedGPUInputs inputs, MLNamedGPUOutputs outputs);
|
|
505
|
+
};
|
|
506
|
+
|
|
507
|
+
partial interface MLCommandEncoder {
|
|
508
|
+
GPUCommandBuffer finish(optional GPUCommandBufferDescriptor descriptor = {});
|
|
470
509
|
};
|
|
@@ -120,7 +120,7 @@ interface RTCRtpScriptTransformer {
|
|
|
120
120
|
readonly attribute ReadableStream readable;
|
|
121
121
|
readonly attribute WritableStream writable;
|
|
122
122
|
readonly attribute any options;
|
|
123
|
-
Promise<
|
|
123
|
+
Promise<unsigned long long> generateKeyFrame(optional DOMString rid);
|
|
124
124
|
Promise<undefined> sendKeyFrameRequest();
|
|
125
125
|
};
|
|
126
126
|
|