This repository was archived by the owner on Jun 28, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 4
/
Copy pathindex.tsx
50 lines (44 loc) · 1.8 KB
/
index.tsx
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
import { Endpoint, Metadata } from './MembraneWebRTC.types';
import { updateEndpointMetadata } from './common/metadata';
import { useEndpoints } from './hooks/useEndpoints';
export { useAudioSettings } from './hooks/useAudioSettings';
export { useBandwidthEstimation } from './hooks/useBandwidthEstimation';
export { useCamera } from './hooks/useCamera';
export { useEndpoints } from './hooks/useEndpoints';
export { useMicrophone } from './hooks/useMicrophone';
export { useRTCStatistics } from './hooks/useRTCStatistics';
export { useScreencast } from './hooks/useScreencast';
export {
updateAudioTrackMetadata,
updateEndpointMetadata,
updateVideoTrackMetadata,
} from './common/metadata';
export {
changeWebRTCLoggingSeverity,
setTargetTrackEncoding,
} from './common/webRTC';
export { default as VideoPreviewView } from './VideoPreviewView';
export { default as VideoRendererView } from './VideoRendererView';
export * from './MembraneWebRTC.types';
export * from './FishjamClientContext';
// below are aliases used by 'old' rn-client-sdk. They should be removed
export type Peer<
MetadataType extends Metadata,
VideoTrackMetadataType extends Metadata,
AudioTrackMetadataType extends Metadata,
> = Endpoint<MetadataType, VideoTrackMetadataType, AudioTrackMetadataType>;
/**
* This hook provides live updates of room peers.
* @returns An array of room peers.
*/
export const usePeers: <
MetadataType extends Metadata,
VideoTrackMetadataType extends Metadata,
AudioTrackMetadataType extends Metadata,
>() => Peer<MetadataType, VideoTrackMetadataType, AudioTrackMetadataType>[] =
useEndpoints;
/**
* Function that updates peer's metadata on the server.
* @param metadata a map `string -> any` containing user's metadata to be sent to the server.
*/
export const updatePeerMetadata = updateEndpointMetadata;