@ikonai/sdk 1.0.42 → 1.0.44
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/client/ikon-client-config.d.ts +2 -0
- package/connection/authenticator.d.ts +5 -10
- package/index.d.ts +1 -1
- package/index.js +1924 -1920
- package/media/ikon-image-capture.d.ts +5 -0
- package/media/ikon-video-capture.d.ts +4 -0
- package/package.json +1 -1
- package/utils/query-params.d.ts +0 -3
- package/webrtc/index.d.ts +1 -1
- package/webrtc/webrtc-config.d.ts +0 -1
- package/webrtc/webrtc-connection.d.ts +1 -0
- package/webrtc/webrtc-signaling.d.ts +5 -0
|
@@ -13,6 +13,11 @@ export interface IkonImageCaptureResult {
|
|
|
13
13
|
data: Uint8Array;
|
|
14
14
|
}
|
|
15
15
|
export declare class IkonImageCapture {
|
|
16
|
+
/**
|
|
17
|
+
* Capture a single frame from an existing MediaStream (e.g., from an active screen share).
|
|
18
|
+
* The caller is responsible for managing the stream lifecycle.
|
|
19
|
+
*/
|
|
20
|
+
captureFromStream(stream: MediaStream, request?: IkonImageCaptureRequest): Promise<IkonImageCaptureResult>;
|
|
16
21
|
private acquireCameraStream;
|
|
17
22
|
captureFromCamera(request?: IkonImageCaptureRequest): Promise<IkonImageCaptureResult>;
|
|
18
23
|
}
|
|
@@ -35,5 +35,9 @@ export declare class IkonVideoCapture {
|
|
|
35
35
|
startCamera(options?: Omit<IkonVideoCaptureRequest, 'sourceType'>): Promise<IkonVideoCaptureHandle>;
|
|
36
36
|
startScreen(options?: Omit<IkonVideoCaptureRequest, 'sourceType'>): Promise<IkonVideoCaptureHandle>;
|
|
37
37
|
stop(captureId: string): Promise<boolean>;
|
|
38
|
+
/**
|
|
39
|
+
* Returns the MediaStream of an active screen capture, if any.
|
|
40
|
+
*/
|
|
41
|
+
getActiveScreenStream(): MediaStream | null;
|
|
38
42
|
dispose(): void;
|
|
39
43
|
}
|
package/package.json
CHANGED
package/utils/query-params.d.ts
CHANGED
|
@@ -18,7 +18,6 @@
|
|
|
18
18
|
* - ikon-video Force video on (true) or off (false)
|
|
19
19
|
* - ikon-webrtc Force WebRTC on (true) or off (false)
|
|
20
20
|
* - ikon-inspect Enable element inspection overlay (true)
|
|
21
|
-
* - ikon-init Enable optimized channel init flow (true)
|
|
22
21
|
*/
|
|
23
22
|
export declare const IKON_PARAM_PROXY = "ikon-proxy";
|
|
24
23
|
export declare const IKON_PARAM_WEBSOCKET = "ikon-websocket";
|
|
@@ -32,7 +31,6 @@ export declare const IKON_PARAM_AUDIO = "ikon-audio";
|
|
|
32
31
|
export declare const IKON_PARAM_VIDEO = "ikon-video";
|
|
33
32
|
export declare const IKON_PARAM_WEBRTC = "ikon-webrtc";
|
|
34
33
|
export declare const IKON_PARAM_INSPECT = "ikon-inspect";
|
|
35
|
-
export declare const IKON_PARAM_INIT = "ikon-init";
|
|
36
34
|
/**
|
|
37
35
|
* Set an SDK query parameter in the URL via history.replaceState.
|
|
38
36
|
*/
|
|
@@ -47,4 +45,3 @@ export declare function getAudioParam(): boolean | null;
|
|
|
47
45
|
export declare function getVideoParam(): boolean | null;
|
|
48
46
|
export declare function getWebRtcParam(): boolean | null;
|
|
49
47
|
export declare function getInspectParam(): boolean;
|
|
50
|
-
export declare function getInitParam(): boolean;
|
package/webrtc/index.d.ts
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
export { WebRTCConnection, type WebRTCConnectionConfig, type WebRTCConnectionState } from './webrtc-connection';
|
|
2
2
|
export { WebRTCSignaling, type WebRTCSignalingConfig } from './webrtc-signaling';
|
|
3
|
-
export { WEBRTC_AUDIO_CODEC, WEBRTC_AUDIO_SAMPLE_RATE, WEBRTC_AUDIO_CHANNELS, WEBRTC_AUDIO_BITRATE, WEBRTC_AUDIO_JITTER_BUFFER_TARGET_MS, WEBRTC_VIDEO_CODEC, WEBRTC_VIDEO_MAX_BITRATE, WEBRTC_VIDEO_MAX_FRAMERATE, WEBRTC_MAX_AUDIO_TRACKS, WEBRTC_MAX_VIDEO_TRACKS, WEBRTC_BUNDLE_POLICY, WEBRTC_RTCP_MUX_POLICY,
|
|
3
|
+
export { WEBRTC_AUDIO_CODEC, WEBRTC_AUDIO_SAMPLE_RATE, WEBRTC_AUDIO_CHANNELS, WEBRTC_AUDIO_BITRATE, WEBRTC_AUDIO_JITTER_BUFFER_TARGET_MS, WEBRTC_VIDEO_CODEC, WEBRTC_VIDEO_MAX_BITRATE, WEBRTC_VIDEO_MAX_FRAMERATE, WEBRTC_MAX_AUDIO_TRACKS, WEBRTC_MAX_VIDEO_TRACKS, WEBRTC_BUNDLE_POLICY, WEBRTC_RTCP_MUX_POLICY, WEBRTC_DATA_CHANNEL_LABEL, WEBRTC_DATA_CHANNEL_ORDERED, WEBRTC_DATA_CHANNEL_MAX_RETRANSMITS, } from './webrtc-config';
|
|
@@ -9,7 +9,6 @@ export declare const WEBRTC_VIDEO_MAX_FRAMERATE = 30;
|
|
|
9
9
|
export declare const WEBRTC_VIDEO_PLAYOUT_DELAY_HINT_S = 0.05;
|
|
10
10
|
export declare const WEBRTC_BUNDLE_POLICY: RTCBundlePolicy;
|
|
11
11
|
export declare const WEBRTC_RTCP_MUX_POLICY: RTCRtcpMuxPolicy;
|
|
12
|
-
export declare const WEBRTC_ICE_SERVERS: RTCIceServer[];
|
|
13
12
|
export declare const WEBRTC_MAX_AUDIO_TRACKS = 16;
|
|
14
13
|
export declare const WEBRTC_MAX_VIDEO_TRACKS = 16;
|
|
15
14
|
export declare const WEBRTC_DATA_CHANNEL_LABEL = "ikon-data";
|
|
@@ -3,6 +3,7 @@ export interface WebRTCConnectionConfig {
|
|
|
3
3
|
useAudioTrack: boolean;
|
|
4
4
|
useVideoTrack: boolean;
|
|
5
5
|
useDataChannel: boolean;
|
|
6
|
+
iceServers?: RTCIceServer[];
|
|
6
7
|
onIceCandidate?: (candidate: RTCIceCandidate | null) => void;
|
|
7
8
|
onStateChange?: (state: WebRTCConnectionState) => void;
|
|
8
9
|
onDataChannelMessage?: (data: ArrayBuffer) => void;
|
|
@@ -7,6 +7,7 @@ export interface WebRTCSignalingConfig {
|
|
|
7
7
|
useAudioTrack: boolean;
|
|
8
8
|
useVideoTrack: boolean;
|
|
9
9
|
useDataChannel: boolean;
|
|
10
|
+
iceServers?: RTCIceServer[];
|
|
10
11
|
onStateChange?: (state: WebRTCConnectionState) => void;
|
|
11
12
|
onDataChannelMessage?: (data: ArrayBuffer) => void;
|
|
12
13
|
onDataChannelOpen?: () => void;
|
|
@@ -32,6 +33,10 @@ export declare class WebRTCSignaling {
|
|
|
32
33
|
sendDataChannelMessage(data: ArrayBuffer): void;
|
|
33
34
|
private audioCaptureStream;
|
|
34
35
|
private videoCaptureStreams;
|
|
36
|
+
/**
|
|
37
|
+
* Returns the first active video capture MediaStream, if any.
|
|
38
|
+
*/
|
|
39
|
+
getActiveVideoCaptureStream(): MediaStream | null;
|
|
35
40
|
startAudioCapture(constraints?: MediaTrackConstraints): Promise<void>;
|
|
36
41
|
startAudioSegment(): void;
|
|
37
42
|
endAudioSegment(): void;
|