Hidden participants (#65)
Enables hidden recording and/or forwarding participants
This commit is contained in:
@@ -39,6 +39,7 @@ type ParticipantParams struct {
|
||||
Stats *RoomStatsReporter
|
||||
ThrottleConfig config.PLIThrottleConfig
|
||||
EnabledCodecs []*livekit.Codec
|
||||
Hidden bool
|
||||
}
|
||||
|
||||
type ParticipantImpl struct {
|
||||
@@ -195,6 +196,7 @@ func (p *ParticipantImpl) ToProto() *livekit.ParticipantInfo {
|
||||
Metadata: p.metadata,
|
||||
State: p.State(),
|
||||
JoinedAt: p.ConnectedAt().Unix(),
|
||||
Hidden: p.Hidden(),
|
||||
}
|
||||
|
||||
p.lock.RLock()
|
||||
@@ -583,6 +585,10 @@ func (p *ParticipantImpl) CanSubscribe() bool {
|
||||
return p.permission == nil || p.permission.CanSubscribe
|
||||
}
|
||||
|
||||
func (p *ParticipantImpl) Hidden() bool {
|
||||
return p.params.Hidden
|
||||
}
|
||||
|
||||
func (p *ParticipantImpl) SubscriberPC() *webrtc.PeerConnection {
|
||||
return p.subscriber.pc
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user