@3dsource/angular-unreal-module 0.0.197 → 0.0.199
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
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import * as i0 from "@angular/core";
|
|
2
2
|
import { DestroyRef, ElementRef, PipeTransform, Signal, TemplateRef } from "@angular/core";
|
|
3
3
|
import { UNREAL_CONFIG, UnrealInitialConfig, UnrealMode } from "@3dsource/angular-unreal-module/config";
|
|
4
|
-
import { Observable, OperatorFunction, Subject, Subscription } from "rxjs";
|
|
4
|
+
import { BehaviorSubject, Observable, OperatorFunction, Subject, Subscription } from "rxjs";
|
|
5
5
|
import { Store } from "@ngrx/store";
|
|
6
6
|
import { Actions } from "@ngrx/effects";
|
|
7
7
|
import { FCameraChangedCallback, FOnChangeSequenceChangedCallback, FOnFinishSequenceChangedCallback, FOnFocusObjectCallback, FOnObjectTransformChangedCallback, FOnSceneStateCallback, MetaBoxCallbackList, MetaBoxCommandList, MetaBoxCommandPacket } from "@3dsource/types-unreal";
|
|
@@ -2157,7 +2157,10 @@ export declare class UnrealCommunicatorService extends SubService {
|
|
|
2157
2157
|
}
|
|
2158
2158
|
export declare class VideoService extends SubService {
|
|
2159
2159
|
private readonly isVideoPlaying;
|
|
2160
|
-
video
|
|
2160
|
+
/** The current streaming `<video>`; replays the latest one to late subscribers. */
|
|
2161
|
+
readonly video$: BehaviorSubject<HTMLVideoElement | null>;
|
|
2162
|
+
get video(): HTMLVideoElement | null;
|
|
2163
|
+
set video(video: HTMLVideoElement | null);
|
|
2161
2164
|
audio: HTMLAudioElement | null;
|
|
2162
2165
|
private container;
|
|
2163
2166
|
private latencyTestTimings;
|
|
@@ -2232,26 +2235,6 @@ export declare class VideoService extends SubService {
|
|
|
2232
2235
|
static ɵfac: i0.ɵɵFactoryDeclaration<VideoService, never>;
|
|
2233
2236
|
static ɵprov: i0.ɵɵInjectableDeclaration<any>;
|
|
2234
2237
|
}
|
|
2235
|
-
declare function finite(value: unknown): number | undefined;
|
|
2236
|
-
/** The `local-candidate` / `remote-candidate` fields read here — the DOM lib
|
|
2237
|
-
* in use does not declare RTCIceCandidateStats. */
|
|
2238
|
-
interface IceCandidateStats {
|
|
2239
|
-
candidateType?: string;
|
|
2240
|
-
protocol?: string;
|
|
2241
|
-
address?: string | null;
|
|
2242
|
-
port?: number;
|
|
2243
|
-
url?: string;
|
|
2244
|
-
relayProtocol?: string;
|
|
2245
|
-
}
|
|
2246
|
-
/**
|
|
2247
|
-
* The route-relevant fields of one candidate. The address is uploaded for a
|
|
2248
|
-
* relay candidate only — host / srflx addresses identify the user, a relay
|
|
2249
|
-
* address identifies the TURN provider's region.
|
|
2250
|
-
*/
|
|
2251
|
-
declare function candidateInfo(candidate: IceCandidateStats | undefined, isLocal: boolean): IceCandidateInfo;
|
|
2252
|
-
/** Id of the selected candidate pair: the transport's pick, or Firefox's
|
|
2253
|
-
* pre-standard `selected` flag when there is no `transport` report. */
|
|
2254
|
-
declare function selectedPairId(stats: RTCStatsReport): string | undefined;
|
|
2255
2238
|
/** Candidates per side by type, pairs by check state, and the selected pair. */
|
|
2256
2239
|
interface IceSnapshot {
|
|
2257
2240
|
readonly local: Readonly<Record<string, number>>;
|
|
@@ -2260,7 +2243,6 @@ interface IceSnapshot {
|
|
|
2260
2243
|
readonly selected: IceRoute | null;
|
|
2261
2244
|
readonly selectedRttMs?: number;
|
|
2262
2245
|
}
|
|
2263
|
-
declare function iceSnapshot(stats: RTCStatsReport): IceSnapshot;
|
|
2264
2246
|
export declare class WebRtcPlayerService extends SubService {
|
|
2265
2247
|
onDataChannelMessage$: Subject<ArrayBuffer>;
|
|
2266
2248
|
/** ICE connection / gathering state changes of the current peer connection. */
|
|
@@ -2308,6 +2290,8 @@ export declare class WebRtcPlayerService extends SubService {
|
|
|
2308
2290
|
* them at the correct point depending on the negotiation flow.
|
|
2309
2291
|
*/
|
|
2310
2292
|
private setupPeerConnection;
|
|
2293
|
+
/** Takes a peer connection over — a freshly created one or an adopted one. */
|
|
2294
|
+
private ownPeerConnection;
|
|
2311
2295
|
private createDataChannel;
|
|
2312
2296
|
private handleCandidateFromServer;
|
|
2313
2297
|
/**
|
|
@@ -2384,15 +2368,21 @@ export declare class WebRtcPlayerService extends SubService {
|
|
|
2384
2368
|
* of running the handshake. The head-script attached property-based handlers
|
|
2385
2369
|
* (`pc.onicecandidate`, `dc.onmessage`, …) and buffered inbound DC messages;
|
|
2386
2370
|
* here we detach those, wire our own (addEventListener-based) handlers, replay
|
|
2387
|
-
* the buffer in order, then
|
|
2388
|
-
*
|
|
2389
|
-
* adopted channel deliberately does not subscribe to it.
|
|
2371
|
+
* the buffer in order, then wire the channel through the same
|
|
2372
|
+
* `ownDataChannel` as the live path, which announces it.
|
|
2390
2373
|
*/
|
|
2391
2374
|
adopt(pc: RTCPeerConnection, dc: RTCDataChannel, stream: MediaStream, config: RTCConfiguration, dcBuffer: ArrayBuffer[]): void;
|
|
2392
2375
|
private setConfig;
|
|
2393
2376
|
private handlePeerConnectionEvents;
|
|
2394
2377
|
private setupTransceiversAsync;
|
|
2395
|
-
|
|
2378
|
+
/**
|
|
2379
|
+
* Takes a DataChannel over — created, server-sent or adopted. Ownership
|
|
2380
|
+
* comes first: the announcement below can run synchronously (an already
|
|
2381
|
+
* open channel with a <video> in place) and its listeners send through
|
|
2382
|
+
* `canSend()` in the same dispatch. `replay` is delivered after the
|
|
2383
|
+
* listeners are wired and before the announcement.
|
|
2384
|
+
*/
|
|
2385
|
+
private ownDataChannel;
|
|
2396
2386
|
private onDataChannelConnected;
|
|
2397
2387
|
/**
|
|
2398
2388
|
* Creates an SDP offer, applies SDP munging, sets it as a local description,
|