grandi 1.3.1 → 2.0.0
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/NOTICE +1 -1
- package/README.md +39 -446
- package/dist/index.d.mts +189 -217
- package/dist/index.mjs +252 -145
- package/dist/index.mjs.map +1 -1
- package/package.json +37 -27
package/dist/index.mjs
CHANGED
|
@@ -2,89 +2,190 @@ import { createRequire } from "node:module";
|
|
|
2
2
|
import path from "node:path";
|
|
3
3
|
import { fileURLToPath } from "node:url";
|
|
4
4
|
import nodeGypBuild from "node-gyp-build";
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
var __require = /* @__PURE__ */ createRequire(import.meta.url);
|
|
8
|
-
|
|
5
|
+
//#region \0rolldown/runtime.js
|
|
6
|
+
var __require = /* #__PURE__ */ (() => createRequire(import.meta.url))();
|
|
9
7
|
//#endregion
|
|
10
8
|
//#region node_modules/tsdown/esm-shims.js
|
|
11
9
|
const getFilename = () => fileURLToPath(import.meta.url);
|
|
12
10
|
const getDirname = () => path.dirname(getFilename());
|
|
13
11
|
const __dirname = /* @__PURE__ */ getDirname();
|
|
14
|
-
|
|
12
|
+
//#endregion
|
|
13
|
+
//#region src/platforms.json
|
|
14
|
+
var platforms_default = [
|
|
15
|
+
{
|
|
16
|
+
"key": "linux-x64",
|
|
17
|
+
"platform": "linux",
|
|
18
|
+
"arch": "x64",
|
|
19
|
+
"gypArch": "x64",
|
|
20
|
+
"packageName": "@grandi/linux-x64",
|
|
21
|
+
"packageDir": "packages/linux-x64",
|
|
22
|
+
"sources": [
|
|
23
|
+
"ndi/lib/lnx-x64/libndi.so.6",
|
|
24
|
+
"ndi/lib/LICENSE",
|
|
25
|
+
"ndi/lib/libndi_licenses.txt"
|
|
26
|
+
]
|
|
27
|
+
},
|
|
28
|
+
{
|
|
29
|
+
"key": "linux-arm64",
|
|
30
|
+
"platform": "linux",
|
|
31
|
+
"arch": "arm64",
|
|
32
|
+
"gypArch": "arm64",
|
|
33
|
+
"packageName": "@grandi/linux-arm64",
|
|
34
|
+
"packageDir": "packages/linux-arm64",
|
|
35
|
+
"sources": [
|
|
36
|
+
"ndi/lib/lnx-arm64/libndi.so.6",
|
|
37
|
+
"ndi/lib/LICENSE",
|
|
38
|
+
"ndi/lib/libndi_licenses.txt"
|
|
39
|
+
]
|
|
40
|
+
},
|
|
41
|
+
{
|
|
42
|
+
"key": "linux-arm",
|
|
43
|
+
"platform": "linux",
|
|
44
|
+
"arch": "arm",
|
|
45
|
+
"gypArch": "arm",
|
|
46
|
+
"packageName": "@grandi/linux-armv7l",
|
|
47
|
+
"packageDir": "packages/linux-armv7l",
|
|
48
|
+
"sources": [
|
|
49
|
+
"ndi/lib/lnx-armv7l/libndi.so.6",
|
|
50
|
+
"ndi/lib/LICENSE",
|
|
51
|
+
"ndi/lib/libndi_licenses.txt"
|
|
52
|
+
]
|
|
53
|
+
},
|
|
54
|
+
{
|
|
55
|
+
"key": "win32-x64",
|
|
56
|
+
"platform": "win32",
|
|
57
|
+
"arch": "x64",
|
|
58
|
+
"gypArch": "x64",
|
|
59
|
+
"packageName": "@grandi/win32-x64",
|
|
60
|
+
"packageDir": "packages/win32-x64",
|
|
61
|
+
"sources": [
|
|
62
|
+
"ndi/lib/win-x64/Processing.NDI.Lib.x64.dll",
|
|
63
|
+
"ndi/lib/win-x64/Processing.NDI.Lib.x64.lib",
|
|
64
|
+
"ndi/lib/LICENSE.pdf",
|
|
65
|
+
"ndi/lib/libndi_licenses.txt"
|
|
66
|
+
]
|
|
67
|
+
},
|
|
68
|
+
{
|
|
69
|
+
"key": "win32-ia32",
|
|
70
|
+
"platform": "win32",
|
|
71
|
+
"arch": "ia32",
|
|
72
|
+
"gypArch": "ia32",
|
|
73
|
+
"nodeTarget": "20.20.2",
|
|
74
|
+
"packageName": "@grandi/win32-ia32",
|
|
75
|
+
"packageDir": "packages/win32-ia32",
|
|
76
|
+
"sources": [
|
|
77
|
+
"ndi/lib/win-x86/Processing.NDI.Lib.x86.dll",
|
|
78
|
+
"ndi/lib/win-x86/Processing.NDI.Lib.x86.lib",
|
|
79
|
+
"ndi/lib/LICENSE.pdf",
|
|
80
|
+
"ndi/lib/libndi_licenses.txt"
|
|
81
|
+
]
|
|
82
|
+
},
|
|
83
|
+
{
|
|
84
|
+
"key": "darwin-arm64",
|
|
85
|
+
"platform": "darwin",
|
|
86
|
+
"arch": "arm64",
|
|
87
|
+
"gypArch": "arm64",
|
|
88
|
+
"packageName": "@grandi/darwin-arm64",
|
|
89
|
+
"packageDir": "packages/darwin-arm64",
|
|
90
|
+
"sources": [
|
|
91
|
+
"ndi/lib/macOS/libndi.dylib",
|
|
92
|
+
"ndi/lib/LICENSE.pdf",
|
|
93
|
+
"ndi/lib/libndi_licenses.txt"
|
|
94
|
+
]
|
|
95
|
+
},
|
|
96
|
+
{
|
|
97
|
+
"key": "darwin-x64",
|
|
98
|
+
"platform": "darwin",
|
|
99
|
+
"arch": "x64",
|
|
100
|
+
"gypArch": "x64",
|
|
101
|
+
"packageName": "@grandi/darwin-x64",
|
|
102
|
+
"packageDir": "packages/darwin-x64",
|
|
103
|
+
"sources": [
|
|
104
|
+
"ndi/lib/macOS/libndi.dylib",
|
|
105
|
+
"ndi/lib/LICENSE.pdf",
|
|
106
|
+
"ndi/lib/libndi_licenses.txt"
|
|
107
|
+
]
|
|
108
|
+
}
|
|
109
|
+
];
|
|
15
110
|
//#endregion
|
|
16
111
|
//#region src/types.ts
|
|
17
|
-
let FrameType = /* @__PURE__ */ function(FrameType
|
|
18
|
-
FrameType
|
|
19
|
-
FrameType
|
|
20
|
-
FrameType
|
|
21
|
-
FrameType
|
|
22
|
-
return FrameType
|
|
112
|
+
let FrameType = /* @__PURE__ */ function(FrameType) {
|
|
113
|
+
FrameType[FrameType["Interlaced"] = 0] = "Interlaced";
|
|
114
|
+
FrameType[FrameType["Progressive"] = 1] = "Progressive";
|
|
115
|
+
FrameType[FrameType["Field0"] = 2] = "Field0";
|
|
116
|
+
FrameType[FrameType["Field1"] = 3] = "Field1";
|
|
117
|
+
return FrameType;
|
|
23
118
|
}({});
|
|
24
|
-
let ColorFormat = /* @__PURE__ */ function(ColorFormat
|
|
25
|
-
ColorFormat
|
|
26
|
-
ColorFormat
|
|
27
|
-
ColorFormat
|
|
28
|
-
ColorFormat
|
|
29
|
-
ColorFormat
|
|
30
|
-
ColorFormat
|
|
31
|
-
ColorFormat
|
|
32
|
-
return ColorFormat
|
|
119
|
+
let ColorFormat = /* @__PURE__ */ function(ColorFormat) {
|
|
120
|
+
ColorFormat[ColorFormat["BGRX_BGRA"] = 0] = "BGRX_BGRA";
|
|
121
|
+
ColorFormat[ColorFormat["UYVY_BGRA"] = 1] = "UYVY_BGRA";
|
|
122
|
+
ColorFormat[ColorFormat["RGBX_RGBA"] = 2] = "RGBX_RGBA";
|
|
123
|
+
ColorFormat[ColorFormat["UYVY_RGBA"] = 3] = "UYVY_RGBA";
|
|
124
|
+
ColorFormat[ColorFormat["Fastest"] = 100] = "Fastest";
|
|
125
|
+
ColorFormat[ColorFormat["Best"] = 101] = "Best";
|
|
126
|
+
ColorFormat[ColorFormat["BGRX_BGRA_FLIPPED"] = 1e3] = "BGRX_BGRA_FLIPPED";
|
|
127
|
+
return ColorFormat;
|
|
33
128
|
}({});
|
|
34
|
-
let AudioFormat = /* @__PURE__ */ function(AudioFormat
|
|
35
|
-
AudioFormat
|
|
36
|
-
AudioFormat
|
|
37
|
-
AudioFormat
|
|
38
|
-
return AudioFormat
|
|
129
|
+
let AudioFormat = /* @__PURE__ */ function(AudioFormat) {
|
|
130
|
+
AudioFormat[AudioFormat["Float32Separate"] = 0] = "Float32Separate";
|
|
131
|
+
AudioFormat[AudioFormat["Float32Interleaved"] = 1] = "Float32Interleaved";
|
|
132
|
+
AudioFormat[AudioFormat["Int16Interleaved"] = 2] = "Int16Interleaved";
|
|
133
|
+
return AudioFormat;
|
|
39
134
|
}({});
|
|
40
|
-
let Bandwidth = /* @__PURE__ */ function(Bandwidth
|
|
41
|
-
Bandwidth
|
|
42
|
-
Bandwidth
|
|
43
|
-
Bandwidth
|
|
44
|
-
Bandwidth
|
|
45
|
-
return Bandwidth
|
|
135
|
+
let Bandwidth = /* @__PURE__ */ function(Bandwidth) {
|
|
136
|
+
Bandwidth[Bandwidth["MetadataOnly"] = -10] = "MetadataOnly";
|
|
137
|
+
Bandwidth[Bandwidth["AudioOnly"] = 10] = "AudioOnly";
|
|
138
|
+
Bandwidth[Bandwidth["Lowest"] = 0] = "Lowest";
|
|
139
|
+
Bandwidth[Bandwidth["Highest"] = 100] = "Highest";
|
|
140
|
+
return Bandwidth;
|
|
46
141
|
}({});
|
|
47
|
-
let FourCC = /* @__PURE__ */ function(FourCC
|
|
48
|
-
FourCC
|
|
49
|
-
FourCC
|
|
50
|
-
FourCC
|
|
51
|
-
FourCC
|
|
52
|
-
FourCC
|
|
53
|
-
FourCC
|
|
54
|
-
FourCC
|
|
55
|
-
FourCC
|
|
56
|
-
FourCC
|
|
57
|
-
FourCC
|
|
58
|
-
FourCC
|
|
59
|
-
FourCC
|
|
60
|
-
return FourCC
|
|
142
|
+
let FourCC = /* @__PURE__ */ function(FourCC) {
|
|
143
|
+
FourCC[FourCC["UYVY"] = 1498831189] = "UYVY";
|
|
144
|
+
FourCC[FourCC["UYVA"] = 1096178005] = "UYVA";
|
|
145
|
+
FourCC[FourCC["P216"] = 909193808] = "P216";
|
|
146
|
+
FourCC[FourCC["PA16"] = 909197648] = "PA16";
|
|
147
|
+
FourCC[FourCC["YV12"] = 842094169] = "YV12";
|
|
148
|
+
FourCC[FourCC["I420"] = 808596553] = "I420";
|
|
149
|
+
FourCC[FourCC["NV12"] = 842094158] = "NV12";
|
|
150
|
+
FourCC[FourCC["BGRA"] = 1095911234] = "BGRA";
|
|
151
|
+
FourCC[FourCC["BGRX"] = 1481787202] = "BGRX";
|
|
152
|
+
FourCC[FourCC["RGBA"] = 1094862674] = "RGBA";
|
|
153
|
+
FourCC[FourCC["RGBX"] = 1480738642] = "RGBX";
|
|
154
|
+
FourCC[FourCC["FLTp"] = 1884572742] = "FLTp";
|
|
155
|
+
return FourCC;
|
|
61
156
|
}({});
|
|
62
|
-
|
|
157
|
+
/**
|
|
158
|
+
* NDI sentinel that asks the SDK to generate synthesized timecode.
|
|
159
|
+
*
|
|
160
|
+
* @see [Synthesized timecode in the NDI SDK documentation](https://docs.ndi.video/all/getting-started/white-paper/time-timecode-and-sync-for-ndi#synthesized-timecode)
|
|
161
|
+
*/
|
|
162
|
+
const TIMECODE_SYNTHESIZE = 9223372036854775807n;
|
|
63
163
|
//#endregion
|
|
64
164
|
//#region src/index.ts
|
|
165
|
+
function currentPlatformTarget() {
|
|
166
|
+
return platforms_default.find((target) => target.platform === process.platform && target.arch === process.arch);
|
|
167
|
+
}
|
|
65
168
|
/**
|
|
66
169
|
* Checks if the current platform and architecture are supported by NDI.
|
|
67
|
-
* @returns {boolean} True if the platform
|
|
170
|
+
* @returns {boolean} True if the platform and architecture are supported, false otherwise.
|
|
68
171
|
*/
|
|
69
172
|
function isSupportedPlatform() {
|
|
70
|
-
return
|
|
173
|
+
return currentPlatformTarget() !== void 0;
|
|
71
174
|
}
|
|
72
175
|
function tryRequireArchPackage() {
|
|
73
176
|
const archKey = `${process.platform}-${process.arch}`;
|
|
74
|
-
const
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
"linux-arm": "@grandi/linux-armv7l",
|
|
78
|
-
"win32-x64": "@grandi/win32-x64",
|
|
79
|
-
"win32-ia32": "@grandi/win32-ia32",
|
|
80
|
-
"darwin-x64": "@grandi/darwin-x64",
|
|
81
|
-
"darwin-arm64": "@grandi/darwin-arm64"
|
|
82
|
-
}[archKey];
|
|
83
|
-
if (!pkg) throw new Error(`Unsupported platform or architecture: ${archKey}`);
|
|
177
|
+
const target = currentPlatformTarget();
|
|
178
|
+
if (!target) throw new Error(`Unsupported platform or architecture: ${archKey}`);
|
|
179
|
+
const pkg = target.packageName;
|
|
84
180
|
try {
|
|
85
181
|
return __require(pkg);
|
|
86
|
-
} catch {
|
|
87
|
-
|
|
182
|
+
} catch (cause) {
|
|
183
|
+
const packageError = /* @__PURE__ */ new Error(`Failed to find prebuilt package for ${archKey}. Please ensure that the package "${pkg}" is installed`);
|
|
184
|
+
Object.defineProperty(packageError, "cause", {
|
|
185
|
+
configurable: true,
|
|
186
|
+
value: cause
|
|
187
|
+
});
|
|
188
|
+
throw packageError;
|
|
88
189
|
}
|
|
89
190
|
}
|
|
90
191
|
function loadAddon() {
|
|
@@ -102,14 +203,16 @@ function loadAddon() {
|
|
|
102
203
|
try {
|
|
103
204
|
const archAddon = tryRequireArchPackage();
|
|
104
205
|
if (archAddon) return archAddon;
|
|
206
|
+
loadErrors.push(/* @__PURE__ */ new Error(`Prebuilt package for ${process.platform}-${process.arch} did not provide an addon`));
|
|
105
207
|
} catch (err) {
|
|
106
208
|
loadErrors.push(err);
|
|
107
209
|
}
|
|
108
210
|
if (loadErrors.length > 0) {
|
|
109
|
-
const
|
|
110
|
-
|
|
211
|
+
const message = "Failed to load native addon:\n" + loadErrors.map((e, i) => ` [${i + 1}] ${e.message}`).join("\n");
|
|
212
|
+
const AggregateErrorConstructor = globalThis.AggregateError;
|
|
213
|
+
throw AggregateErrorConstructor ? new AggregateErrorConstructor(loadErrors, message) : Object.assign(new Error(message), { errors: loadErrors });
|
|
111
214
|
}
|
|
112
|
-
|
|
215
|
+
throw new Error("Failed to load native addon");
|
|
113
216
|
}
|
|
114
217
|
const noopAddon = {
|
|
115
218
|
version() {
|
|
@@ -143,7 +246,7 @@ const noopAddon = {
|
|
|
143
246
|
const addon = loadAddon();
|
|
144
247
|
/**
|
|
145
248
|
* Creates a finder to discover NDI sources on the network.
|
|
146
|
-
* @param {FindOptions}
|
|
249
|
+
* @param {FindOptions} params - Options for finding sources.
|
|
147
250
|
* @param {boolean} [params.showLocalSources] - Whether to show local sources.
|
|
148
251
|
* @param {string} [params.groups] - Multicast groups to search in.
|
|
149
252
|
* @param {string} [params.extraIPs] - Additional IP addresses to search.
|
|
@@ -155,13 +258,18 @@ const addon = loadAddon();
|
|
|
155
258
|
* import { find, initialize } from "grandi";
|
|
156
259
|
* initialize();
|
|
157
260
|
* const finder = await find({ showLocalSources: true });
|
|
158
|
-
* finder.wait(1000);
|
|
261
|
+
* await finder.wait(1000);
|
|
159
262
|
* console.log(finder.sources());
|
|
160
263
|
* finder.destroy();
|
|
161
264
|
* ```
|
|
162
265
|
*/
|
|
163
266
|
function find(params = {}) {
|
|
164
|
-
|
|
267
|
+
const { extraIPs, extraIps, ...options } = params;
|
|
268
|
+
const normalizedExtraIps = extraIPs ?? extraIps;
|
|
269
|
+
return addon.find(normalizedExtraIps === void 0 ? options : {
|
|
270
|
+
...options,
|
|
271
|
+
extraIPs: normalizedExtraIps
|
|
272
|
+
});
|
|
165
273
|
}
|
|
166
274
|
/**
|
|
167
275
|
* Gets the version of the NDI SDK.
|
|
@@ -174,8 +282,9 @@ const version = addon.version;
|
|
|
174
282
|
*/
|
|
175
283
|
const isSupportedCPU = addon.isSupportedCPU;
|
|
176
284
|
/**
|
|
177
|
-
*
|
|
178
|
-
*
|
|
285
|
+
* Optionally initializes the process-global NDI library. The SDK does not require
|
|
286
|
+
* this call, but eager initialization is recommended for explicit lifecycle management.
|
|
287
|
+
* @returns {boolean} True if initialization was successful and the CPU is supported.
|
|
179
288
|
*
|
|
180
289
|
* @example
|
|
181
290
|
* ```js
|
|
@@ -185,9 +294,9 @@ const isSupportedCPU = addon.isSupportedCPU;
|
|
|
185
294
|
*/
|
|
186
295
|
const initialize = addon.initialize;
|
|
187
296
|
/**
|
|
188
|
-
*
|
|
189
|
-
*
|
|
190
|
-
* @returns {boolean} True
|
|
297
|
+
* Optionally shuts down the process-global NDI library.
|
|
298
|
+
* When managing the lifecycle explicitly, destroy all native objects before calling this.
|
|
299
|
+
* @returns {boolean} True after requesting shutdown.
|
|
191
300
|
*
|
|
192
301
|
* @example
|
|
193
302
|
* ```js
|
|
@@ -215,7 +324,33 @@ const destroy = addon.destroy;
|
|
|
215
324
|
* sender.destroy();
|
|
216
325
|
* ```
|
|
217
326
|
*/
|
|
218
|
-
|
|
327
|
+
async function send(params) {
|
|
328
|
+
const native = await addon.send(params);
|
|
329
|
+
Object.defineProperty(native, "sourceName", {
|
|
330
|
+
configurable: true,
|
|
331
|
+
value: native.sourcename
|
|
332
|
+
});
|
|
333
|
+
const origTally = native.tally;
|
|
334
|
+
native.tally = () => {
|
|
335
|
+
const result = origTally.call(native);
|
|
336
|
+
Object.defineProperties(result, {
|
|
337
|
+
onProgram: {
|
|
338
|
+
configurable: true,
|
|
339
|
+
get() {
|
|
340
|
+
return this.on_program;
|
|
341
|
+
}
|
|
342
|
+
},
|
|
343
|
+
onPreview: {
|
|
344
|
+
configurable: true,
|
|
345
|
+
get() {
|
|
346
|
+
return this.on_preview;
|
|
347
|
+
}
|
|
348
|
+
}
|
|
349
|
+
});
|
|
350
|
+
return result;
|
|
351
|
+
};
|
|
352
|
+
return native;
|
|
353
|
+
}
|
|
219
354
|
/**
|
|
220
355
|
* Creates an NDI receiver for receiving video and audio from an NDI source.
|
|
221
356
|
* @param {ReceiveOptions} params - Options for creating the receiver.
|
|
@@ -232,7 +367,7 @@ const send = addon.send;
|
|
|
232
367
|
* import { find, initialize, receive } from "grandi";
|
|
233
368
|
* initialize();
|
|
234
369
|
* const finder = await find({ showLocalSources: true });
|
|
235
|
-
* finder.wait(1000);
|
|
370
|
+
* await finder.wait(1000);
|
|
236
371
|
* const source = finder.sources()[0];
|
|
237
372
|
* finder.destroy();
|
|
238
373
|
* const receiver = await receive({ source });
|
|
@@ -241,45 +376,17 @@ const send = addon.send;
|
|
|
241
376
|
* ```
|
|
242
377
|
*/
|
|
243
378
|
const receive = addon.receive;
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
* Use this when you want smooth playback clocked to your own render/audio loop.
|
|
247
|
-
*
|
|
248
|
-
* Note: destroy the frame-sync before destroying the receiver.
|
|
249
|
-
* @param {Receiver} receiver - The receiver instance to frame-sync.
|
|
250
|
-
* @returns {Promise<FrameSync>} A promise that resolves to a FrameSync instance.
|
|
251
|
-
* @throws {Error} Promise rejects on unsupported platform/CPU or if framesync creation fails.
|
|
252
|
-
*
|
|
253
|
-
* @example
|
|
254
|
-
* ```js
|
|
255
|
-
* import grandi from "grandi";
|
|
256
|
-
* grandi.initialize();
|
|
257
|
-
* const receiver = await grandi.receive({ source });
|
|
258
|
-
* const fs = await grandi.framesync(receiver);
|
|
259
|
-
* const frame = await fs.video(grandi.FrameType.Progressive);
|
|
260
|
-
* fs.destroy();
|
|
261
|
-
* receiver.destroy();
|
|
262
|
-
* ```
|
|
263
|
-
*/
|
|
379
|
+
const frameSync = addon.framesync;
|
|
380
|
+
/** @deprecated Use `frameSync` instead. */
|
|
264
381
|
const framesync = addon.framesync;
|
|
265
|
-
|
|
266
|
-
|
|
267
|
-
|
|
268
|
-
|
|
269
|
-
|
|
270
|
-
|
|
271
|
-
|
|
272
|
-
|
|
273
|
-
* @example
|
|
274
|
-
* ```js
|
|
275
|
-
* import { initialize, routing } from "grandi";
|
|
276
|
-
* initialize();
|
|
277
|
-
* const router = await routing({ name: "My Router" });
|
|
278
|
-
* // router.change(source)
|
|
279
|
-
* router.destroy();
|
|
280
|
-
* ```
|
|
281
|
-
*/
|
|
282
|
-
const routing = addon.routing;
|
|
382
|
+
async function routing(params) {
|
|
383
|
+
const native = await addon.routing(params);
|
|
384
|
+
Object.defineProperty(native, "sourceName", {
|
|
385
|
+
configurable: true,
|
|
386
|
+
value: native.sourcename
|
|
387
|
+
});
|
|
388
|
+
return native;
|
|
389
|
+
}
|
|
283
390
|
const grandi = {
|
|
284
391
|
version,
|
|
285
392
|
isSupportedCPU,
|
|
@@ -287,7 +394,7 @@ const grandi = {
|
|
|
287
394
|
destroy,
|
|
288
395
|
send,
|
|
289
396
|
receive,
|
|
290
|
-
|
|
397
|
+
frameSync,
|
|
291
398
|
routing,
|
|
292
399
|
find,
|
|
293
400
|
ColorFormat,
|
|
@@ -295,39 +402,39 @@ const grandi = {
|
|
|
295
402
|
Bandwidth,
|
|
296
403
|
FrameType,
|
|
297
404
|
FourCC,
|
|
298
|
-
COLOR_FORMAT_BGRX_BGRA:
|
|
299
|
-
COLOR_FORMAT_UYVY_BGRA:
|
|
300
|
-
COLOR_FORMAT_RGBX_RGBA:
|
|
301
|
-
COLOR_FORMAT_UYVY_RGBA:
|
|
302
|
-
COLOR_FORMAT_FASTEST:
|
|
303
|
-
COLOR_FORMAT_BEST:
|
|
304
|
-
COLOR_FORMAT_BGRX_BGRA_FLIPPED:
|
|
305
|
-
|
|
306
|
-
|
|
307
|
-
|
|
308
|
-
|
|
309
|
-
|
|
310
|
-
|
|
311
|
-
|
|
312
|
-
|
|
313
|
-
|
|
314
|
-
|
|
315
|
-
|
|
316
|
-
FOURCC_UYVY:
|
|
317
|
-
FOURCC_UYVA:
|
|
318
|
-
FOURCC_P216:
|
|
319
|
-
FOURCC_PA16:
|
|
320
|
-
FOURCC_YV12:
|
|
321
|
-
FOURCC_I420:
|
|
322
|
-
FOURCC_NV12:
|
|
323
|
-
FOURCC_BGRA:
|
|
324
|
-
FOURCC_BGRX:
|
|
325
|
-
FOURCC_RGBA:
|
|
326
|
-
FOURCC_RGBX:
|
|
327
|
-
FOURCC_FLTp:
|
|
405
|
+
COLOR_FORMAT_BGRX_BGRA: 0,
|
|
406
|
+
COLOR_FORMAT_UYVY_BGRA: 1,
|
|
407
|
+
COLOR_FORMAT_RGBX_RGBA: 2,
|
|
408
|
+
COLOR_FORMAT_UYVY_RGBA: 3,
|
|
409
|
+
COLOR_FORMAT_FASTEST: 100,
|
|
410
|
+
COLOR_FORMAT_BEST: 101,
|
|
411
|
+
COLOR_FORMAT_BGRX_BGRA_FLIPPED: 1e3,
|
|
412
|
+
AUDIO_FORMAT_FLOAT_32_SEPARATE: 0,
|
|
413
|
+
AUDIO_FORMAT_FLOAT_32_INTERLEAVED: 1,
|
|
414
|
+
AUDIO_FORMAT_INT_16_INTERLEAVED: 2,
|
|
415
|
+
BANDWIDTH_METADATA_ONLY: -10,
|
|
416
|
+
BANDWIDTH_AUDIO_ONLY: 10,
|
|
417
|
+
BANDWIDTH_LOWEST: 0,
|
|
418
|
+
BANDWIDTH_HIGHEST: 100,
|
|
419
|
+
FORMAT_TYPE_PROGRESSIVE: 1,
|
|
420
|
+
FORMAT_TYPE_INTERLACED: 0,
|
|
421
|
+
FORMAT_TYPE_FIELD_0: 2,
|
|
422
|
+
FORMAT_TYPE_FIELD_1: 3,
|
|
423
|
+
FOURCC_UYVY: 1498831189,
|
|
424
|
+
FOURCC_UYVA: 1096178005,
|
|
425
|
+
FOURCC_P216: 909193808,
|
|
426
|
+
FOURCC_PA16: 909197648,
|
|
427
|
+
FOURCC_YV12: 842094169,
|
|
428
|
+
FOURCC_I420: 808596553,
|
|
429
|
+
FOURCC_NV12: 842094158,
|
|
430
|
+
FOURCC_BGRA: 1095911234,
|
|
431
|
+
FOURCC_BGRX: 1481787202,
|
|
432
|
+
FOURCC_RGBA: 1094862674,
|
|
433
|
+
FOURCC_RGBX: 1480738642,
|
|
434
|
+
FOURCC_FLTp: 1884572742,
|
|
435
|
+
TIMECODE_SYNTHESIZE
|
|
328
436
|
};
|
|
329
|
-
var src_default = grandi;
|
|
330
|
-
|
|
331
437
|
//#endregion
|
|
332
|
-
export { AudioFormat, Bandwidth, ColorFormat, FourCC, FrameType,
|
|
438
|
+
export { AudioFormat, Bandwidth, ColorFormat, FourCC, FrameType, TIMECODE_SYNTHESIZE, grandi as default, destroy, find, frameSync, framesync, initialize, isSupportedCPU, receive, routing, send, version };
|
|
439
|
+
|
|
333
440
|
//# sourceMappingURL=index.mjs.map
|