client consumes provided track
This commit is contained in:
+199
-15
@@ -230,6 +230,148 @@ func (x *Room) GetToken() string {
|
||||
return ""
|
||||
}
|
||||
|
||||
type RoomInfo struct {
|
||||
state protoimpl.MessageState
|
||||
sizeCache protoimpl.SizeCache
|
||||
unknownFields protoimpl.UnknownFields
|
||||
|
||||
RoomId string `protobuf:"bytes,1,opt,name=room_id,json=roomId,proto3" json:"room_id,omitempty"`
|
||||
NodeIp string `protobuf:"bytes,2,opt,name=node_ip,json=nodeIp,proto3" json:"node_ip,omitempty"`
|
||||
NodeRtcPort uint32 `protobuf:"varint,3,opt,name=node_rtc_port,json=nodeRtcPort,proto3" json:"node_rtc_port,omitempty"`
|
||||
CreationTime int64 `protobuf:"varint,4,opt,name=creation_time,json=creationTime,proto3" json:"creation_time,omitempty"`
|
||||
Token string `protobuf:"bytes,5,opt,name=token,proto3" json:"token,omitempty"`
|
||||
}
|
||||
|
||||
func (x *RoomInfo) Reset() {
|
||||
*x = RoomInfo{}
|
||||
if protoimpl.UnsafeEnabled {
|
||||
mi := &file_model_proto_msgTypes[3]
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
}
|
||||
|
||||
func (x *RoomInfo) String() string {
|
||||
return protoimpl.X.MessageStringOf(x)
|
||||
}
|
||||
|
||||
func (*RoomInfo) ProtoMessage() {}
|
||||
|
||||
func (x *RoomInfo) ProtoReflect() protoreflect.Message {
|
||||
mi := &file_model_proto_msgTypes[3]
|
||||
if protoimpl.UnsafeEnabled && x != nil {
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
if ms.LoadMessageInfo() == nil {
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
return ms
|
||||
}
|
||||
return mi.MessageOf(x)
|
||||
}
|
||||
|
||||
// Deprecated: Use RoomInfo.ProtoReflect.Descriptor instead.
|
||||
func (*RoomInfo) Descriptor() ([]byte, []int) {
|
||||
return file_model_proto_rawDescGZIP(), []int{3}
|
||||
}
|
||||
|
||||
func (x *RoomInfo) GetRoomId() string {
|
||||
if x != nil {
|
||||
return x.RoomId
|
||||
}
|
||||
return ""
|
||||
}
|
||||
|
||||
func (x *RoomInfo) GetNodeIp() string {
|
||||
if x != nil {
|
||||
return x.NodeIp
|
||||
}
|
||||
return ""
|
||||
}
|
||||
|
||||
func (x *RoomInfo) GetNodeRtcPort() uint32 {
|
||||
if x != nil {
|
||||
return x.NodeRtcPort
|
||||
}
|
||||
return 0
|
||||
}
|
||||
|
||||
func (x *RoomInfo) GetCreationTime() int64 {
|
||||
if x != nil {
|
||||
return x.CreationTime
|
||||
}
|
||||
return 0
|
||||
}
|
||||
|
||||
func (x *RoomInfo) GetToken() string {
|
||||
if x != nil {
|
||||
return x.Token
|
||||
}
|
||||
return ""
|
||||
}
|
||||
|
||||
type PeerInfo struct {
|
||||
state protoimpl.MessageState
|
||||
sizeCache protoimpl.SizeCache
|
||||
unknownFields protoimpl.UnknownFields
|
||||
|
||||
PeerId string `protobuf:"bytes,1,opt,name=peer_id,json=peerId,proto3" json:"peer_id,omitempty"`
|
||||
HasAudio bool `protobuf:"varint,2,opt,name=has_audio,json=hasAudio,proto3" json:"has_audio,omitempty"`
|
||||
HasVideo bool `protobuf:"varint,3,opt,name=has_video,json=hasVideo,proto3" json:"has_video,omitempty"`
|
||||
}
|
||||
|
||||
func (x *PeerInfo) Reset() {
|
||||
*x = PeerInfo{}
|
||||
if protoimpl.UnsafeEnabled {
|
||||
mi := &file_model_proto_msgTypes[4]
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
}
|
||||
|
||||
func (x *PeerInfo) String() string {
|
||||
return protoimpl.X.MessageStringOf(x)
|
||||
}
|
||||
|
||||
func (*PeerInfo) ProtoMessage() {}
|
||||
|
||||
func (x *PeerInfo) ProtoReflect() protoreflect.Message {
|
||||
mi := &file_model_proto_msgTypes[4]
|
||||
if protoimpl.UnsafeEnabled && x != nil {
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
if ms.LoadMessageInfo() == nil {
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
return ms
|
||||
}
|
||||
return mi.MessageOf(x)
|
||||
}
|
||||
|
||||
// Deprecated: Use PeerInfo.ProtoReflect.Descriptor instead.
|
||||
func (*PeerInfo) Descriptor() ([]byte, []int) {
|
||||
return file_model_proto_rawDescGZIP(), []int{4}
|
||||
}
|
||||
|
||||
func (x *PeerInfo) GetPeerId() string {
|
||||
if x != nil {
|
||||
return x.PeerId
|
||||
}
|
||||
return ""
|
||||
}
|
||||
|
||||
func (x *PeerInfo) GetHasAudio() bool {
|
||||
if x != nil {
|
||||
return x.HasAudio
|
||||
}
|
||||
return false
|
||||
}
|
||||
|
||||
func (x *PeerInfo) GetHasVideo() bool {
|
||||
if x != nil {
|
||||
return x.HasVideo
|
||||
}
|
||||
return false
|
||||
}
|
||||
|
||||
type DataChannel struct {
|
||||
state protoimpl.MessageState
|
||||
sizeCache protoimpl.SizeCache
|
||||
@@ -242,7 +384,7 @@ type DataChannel struct {
|
||||
func (x *DataChannel) Reset() {
|
||||
*x = DataChannel{}
|
||||
if protoimpl.UnsafeEnabled {
|
||||
mi := &file_model_proto_msgTypes[3]
|
||||
mi := &file_model_proto_msgTypes[5]
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
@@ -255,7 +397,7 @@ func (x *DataChannel) String() string {
|
||||
func (*DataChannel) ProtoMessage() {}
|
||||
|
||||
func (x *DataChannel) ProtoReflect() protoreflect.Message {
|
||||
mi := &file_model_proto_msgTypes[3]
|
||||
mi := &file_model_proto_msgTypes[5]
|
||||
if protoimpl.UnsafeEnabled && x != nil {
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
if ms.LoadMessageInfo() == nil {
|
||||
@@ -268,7 +410,7 @@ func (x *DataChannel) ProtoReflect() protoreflect.Message {
|
||||
|
||||
// Deprecated: Use DataChannel.ProtoReflect.Descriptor instead.
|
||||
func (*DataChannel) Descriptor() ([]byte, []int) {
|
||||
return file_model_proto_rawDescGZIP(), []int{3}
|
||||
return file_model_proto_rawDescGZIP(), []int{5}
|
||||
}
|
||||
|
||||
func (x *DataChannel) GetSessionId() string {
|
||||
@@ -311,15 +453,31 @@ var file_model_proto_rawDesc = []byte{
|
||||
0x12, 0x23, 0x0a, 0x0d, 0x63, 0x72, 0x65, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x5f, 0x74, 0x69, 0x6d,
|
||||
0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0c, 0x63, 0x72, 0x65, 0x61, 0x74, 0x69, 0x6f,
|
||||
0x6e, 0x54, 0x69, 0x6d, 0x65, 0x12, 0x14, 0x0a, 0x05, 0x74, 0x6f, 0x6b, 0x65, 0x6e, 0x18, 0x05,
|
||||
0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x74, 0x6f, 0x6b, 0x65, 0x6e, 0x22, 0x46, 0x0a, 0x0b, 0x44,
|
||||
0x61, 0x74, 0x61, 0x43, 0x68, 0x61, 0x6e, 0x6e, 0x65, 0x6c, 0x12, 0x1d, 0x0a, 0x0a, 0x73, 0x65,
|
||||
0x73, 0x73, 0x69, 0x6f, 0x6e, 0x5f, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09,
|
||||
0x73, 0x65, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x49, 0x64, 0x12, 0x18, 0x0a, 0x07, 0x70, 0x61, 0x79,
|
||||
0x6c, 0x6f, 0x61, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x07, 0x70, 0x61, 0x79, 0x6c,
|
||||
0x6f, 0x61, 0x64, 0x42, 0x31, 0x5a, 0x2f, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f,
|
||||
0x6d, 0x2f, 0x6c, 0x69, 0x76, 0x65, 0x6b, 0x69, 0x74, 0x2f, 0x6c, 0x69, 0x76, 0x65, 0x6b, 0x69,
|
||||
0x74, 0x2d, 0x73, 0x65, 0x72, 0x76, 0x65, 0x72, 0x2f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x6c,
|
||||
0x69, 0x76, 0x65, 0x6b, 0x69, 0x74, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33,
|
||||
0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x74, 0x6f, 0x6b, 0x65, 0x6e, 0x22, 0x9b, 0x01, 0x0a, 0x08,
|
||||
0x52, 0x6f, 0x6f, 0x6d, 0x49, 0x6e, 0x66, 0x6f, 0x12, 0x17, 0x0a, 0x07, 0x72, 0x6f, 0x6f, 0x6d,
|
||||
0x5f, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x72, 0x6f, 0x6f, 0x6d, 0x49,
|
||||
0x64, 0x12, 0x17, 0x0a, 0x07, 0x6e, 0x6f, 0x64, 0x65, 0x5f, 0x69, 0x70, 0x18, 0x02, 0x20, 0x01,
|
||||
0x28, 0x09, 0x52, 0x06, 0x6e, 0x6f, 0x64, 0x65, 0x49, 0x70, 0x12, 0x22, 0x0a, 0x0d, 0x6e, 0x6f,
|
||||
0x64, 0x65, 0x5f, 0x72, 0x74, 0x63, 0x5f, 0x70, 0x6f, 0x72, 0x74, 0x18, 0x03, 0x20, 0x01, 0x28,
|
||||
0x0d, 0x52, 0x0b, 0x6e, 0x6f, 0x64, 0x65, 0x52, 0x74, 0x63, 0x50, 0x6f, 0x72, 0x74, 0x12, 0x23,
|
||||
0x0a, 0x0d, 0x63, 0x72, 0x65, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x5f, 0x74, 0x69, 0x6d, 0x65, 0x18,
|
||||
0x04, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0c, 0x63, 0x72, 0x65, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x54,
|
||||
0x69, 0x6d, 0x65, 0x12, 0x14, 0x0a, 0x05, 0x74, 0x6f, 0x6b, 0x65, 0x6e, 0x18, 0x05, 0x20, 0x01,
|
||||
0x28, 0x09, 0x52, 0x05, 0x74, 0x6f, 0x6b, 0x65, 0x6e, 0x22, 0x5d, 0x0a, 0x08, 0x50, 0x65, 0x65,
|
||||
0x72, 0x49, 0x6e, 0x66, 0x6f, 0x12, 0x17, 0x0a, 0x07, 0x70, 0x65, 0x65, 0x72, 0x5f, 0x69, 0x64,
|
||||
0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x70, 0x65, 0x65, 0x72, 0x49, 0x64, 0x12, 0x1b,
|
||||
0x0a, 0x09, 0x68, 0x61, 0x73, 0x5f, 0x61, 0x75, 0x64, 0x69, 0x6f, 0x18, 0x02, 0x20, 0x01, 0x28,
|
||||
0x08, 0x52, 0x08, 0x68, 0x61, 0x73, 0x41, 0x75, 0x64, 0x69, 0x6f, 0x12, 0x1b, 0x0a, 0x09, 0x68,
|
||||
0x61, 0x73, 0x5f, 0x76, 0x69, 0x64, 0x65, 0x6f, 0x18, 0x03, 0x20, 0x01, 0x28, 0x08, 0x52, 0x08,
|
||||
0x68, 0x61, 0x73, 0x56, 0x69, 0x64, 0x65, 0x6f, 0x22, 0x46, 0x0a, 0x0b, 0x44, 0x61, 0x74, 0x61,
|
||||
0x43, 0x68, 0x61, 0x6e, 0x6e, 0x65, 0x6c, 0x12, 0x1d, 0x0a, 0x0a, 0x73, 0x65, 0x73, 0x73, 0x69,
|
||||
0x6f, 0x6e, 0x5f, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x73, 0x65, 0x73,
|
||||
0x73, 0x69, 0x6f, 0x6e, 0x49, 0x64, 0x12, 0x18, 0x0a, 0x07, 0x70, 0x61, 0x79, 0x6c, 0x6f, 0x61,
|
||||
0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x07, 0x70, 0x61, 0x79, 0x6c, 0x6f, 0x61, 0x64,
|
||||
0x42, 0x31, 0x5a, 0x2f, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x6c,
|
||||
0x69, 0x76, 0x65, 0x6b, 0x69, 0x74, 0x2f, 0x6c, 0x69, 0x76, 0x65, 0x6b, 0x69, 0x74, 0x2d, 0x73,
|
||||
0x65, 0x72, 0x76, 0x65, 0x72, 0x2f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x6c, 0x69, 0x76, 0x65,
|
||||
0x6b, 0x69, 0x74, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33,
|
||||
}
|
||||
|
||||
var (
|
||||
@@ -334,12 +492,14 @@ func file_model_proto_rawDescGZIP() []byte {
|
||||
return file_model_proto_rawDescData
|
||||
}
|
||||
|
||||
var file_model_proto_msgTypes = make([]protoimpl.MessageInfo, 4)
|
||||
var file_model_proto_msgTypes = make([]protoimpl.MessageInfo, 6)
|
||||
var file_model_proto_goTypes = []interface{}{
|
||||
(*Node)(nil), // 0: livekit.Node
|
||||
(*NodeStats)(nil), // 1: livekit.NodeStats
|
||||
(*Room)(nil), // 2: livekit.Room
|
||||
(*DataChannel)(nil), // 3: livekit.DataChannel
|
||||
(*RoomInfo)(nil), // 3: livekit.RoomInfo
|
||||
(*PeerInfo)(nil), // 4: livekit.PeerInfo
|
||||
(*DataChannel)(nil), // 5: livekit.DataChannel
|
||||
}
|
||||
var file_model_proto_depIdxs = []int32{
|
||||
1, // 0: livekit.Node.stats:type_name -> livekit.NodeStats
|
||||
@@ -393,6 +553,30 @@ func file_model_proto_init() {
|
||||
}
|
||||
}
|
||||
file_model_proto_msgTypes[3].Exporter = func(v interface{}, i int) interface{} {
|
||||
switch v := v.(*RoomInfo); i {
|
||||
case 0:
|
||||
return &v.state
|
||||
case 1:
|
||||
return &v.sizeCache
|
||||
case 2:
|
||||
return &v.unknownFields
|
||||
default:
|
||||
return nil
|
||||
}
|
||||
}
|
||||
file_model_proto_msgTypes[4].Exporter = func(v interface{}, i int) interface{} {
|
||||
switch v := v.(*PeerInfo); i {
|
||||
case 0:
|
||||
return &v.state
|
||||
case 1:
|
||||
return &v.sizeCache
|
||||
case 2:
|
||||
return &v.unknownFields
|
||||
default:
|
||||
return nil
|
||||
}
|
||||
}
|
||||
file_model_proto_msgTypes[5].Exporter = func(v interface{}, i int) interface{} {
|
||||
switch v := v.(*DataChannel); i {
|
||||
case 0:
|
||||
return &v.state
|
||||
@@ -411,7 +595,7 @@ func file_model_proto_init() {
|
||||
GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
|
||||
RawDescriptor: file_model_proto_rawDesc,
|
||||
NumEnums: 0,
|
||||
NumMessages: 4,
|
||||
NumMessages: 6,
|
||||
NumExtensions: 0,
|
||||
NumServices: 0,
|
||||
},
|
||||
|
||||
Reference in New Issue
Block a user