File tree Expand file tree Collapse file tree 1 file changed +4
-6
lines changed
Sources/LiveKitComponents/UI/Participant Expand file tree Collapse file tree 1 file changed +4
-6
lines changed Original file line number Diff line number Diff line change @@ -29,19 +29,16 @@ public struct ParticipantView: View {
29
29
30
30
public var body : some View {
31
31
ZStack ( alignment: . topLeading) {
32
- let cameraReference = TrackReference ( participant: _participant. avatarWorker ?? _participant, source: . camera)
32
+ // let cameraReference = TrackReference(participant: _participant.avatarWorker ?? _participant, source: .camera)
33
33
let microphoneReference = TrackReference ( participant: _participant. avatarWorker ?? _participant, source: . microphone)
34
34
35
- if let cameraTrack = cameraReference . resolve ( ) , !cameraTrack . isMuted {
36
- VideoTrackView ( trackReference : cameraReference )
35
+ if let cameraTrack = _participant . firstCameraVideoTrack {
36
+ SwiftUIVideoView ( cameraTrack )
37
37
} else if let microphoneTrack = microphoneReference. resolve ( ) , !microphoneTrack. isMuted,
38
38
let audioTrack = microphoneTrack. track as? AudioTrack
39
39
{
40
40
BarAudioVisualizer ( audioTrack: audioTrack, agentState: _participant. agentState) . id ( _participant. agentState)
41
- } else {
42
- _ui. noTrackView ( )
43
41
}
44
-
45
42
if _showInformation {
46
43
ParticipantInformationView ( )
47
44
. padding ( 5 )
@@ -51,6 +48,7 @@ public struct ParticipantView: View {
51
48
}
52
49
}
53
50
. animation ( . easeOut, value: _participant. trackPublications)
51
+ . transition ( . identity)
54
52
. frame ( maxWidth: . infinity, maxHeight: . infinity)
55
53
}
56
54
}
You can’t perform that action at this time.
0 commit comments