From 6c645787743810cc41ce0349eddae136d3d5c43d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Th=C3=A9o=20Monnom?= Date: Mon, 2 Oct 2023 11:35:06 -0700 Subject: [PATCH] feat: handle metadata (#69) --- .gitmodules | 4 +- client-sdk-rust | 1 - generate_proto.sh | 2 +- livekit/_proto/ffi_pb2.py | 32 +++---- livekit/_proto/ffi_pb2.pyi | 42 +++++++-- livekit/_proto/room_pb2.py | 176 ++++++++++++++++++++---------------- livekit/_proto/room_pb2.pyi | 171 ++++++++++++++++++++++++++++++++++- livekit/participant.py | 32 ++++++- livekit/room.py | 33 +++++-- rust-sdks | 1 + setup.py | 2 +- 11 files changed, 372 insertions(+), 124 deletions(-) delete mode 160000 client-sdk-rust create mode 160000 rust-sdks diff --git a/.gitmodules b/.gitmodules index cbbd96d2..7bd5abd1 100644 --- a/.gitmodules +++ b/.gitmodules @@ -1,3 +1,3 @@ [submodule "client-sdk-rust"] - path = client-sdk-rust - url = https://github.com/livekit/client-sdk-rust + path = rust-sdks + url = https://github.com/livekit/rust-sdks diff --git a/client-sdk-rust b/client-sdk-rust deleted file mode 160000 index b968d3bb..00000000 --- a/client-sdk-rust +++ /dev/null @@ -1 +0,0 @@ -Subproject commit b968d3bb1edd30ad3331a7f174c958d4d0346077 diff --git a/generate_proto.sh b/generate_proto.sh index 29a02fad..342bc2ec 100755 --- a/generate_proto.sh +++ b/generate_proto.sh @@ -16,7 +16,7 @@ # This script requires protobuf-compiler and https://github.com/nipunn1313/mypy-protobuf -FFI_PROTOCOL=./client-sdk-rust/livekit-ffi/protocol +FFI_PROTOCOL=./rust-sdks/livekit-ffi/protocol OUT_PYTHON=./livekit/_proto protoc \ diff --git a/livekit/_proto/ffi_pb2.py b/livekit/_proto/ffi_pb2.py index db99db60..c65708a8 100644 --- a/livekit/_proto/ffi_pb2.py +++ b/livekit/_proto/ffi_pb2.py @@ -18,7 +18,7 @@ from . import audio_frame_pb2 as audio__frame__pb2 -DESCRIPTOR = _descriptor_pool.Default().AddSerializedFile(b'\n\tffi.proto\x12\rlivekit.proto\x1a\ne2ee.proto\x1a\x0btrack.proto\x1a\nroom.proto\x1a\x11video_frame.proto\x1a\x11\x61udio_frame.proto\"\xaf\x0b\n\nFfiRequest\x12\x36\n\ninitialize\x18\x01 \x01(\x0b\x32 .livekit.proto.InitializeRequestH\x00\x12\x30\n\x07\x64ispose\x18\x02 \x01(\x0b\x32\x1d.livekit.proto.DisposeRequestH\x00\x12\x30\n\x07\x63onnect\x18\x03 \x01(\x0b\x32\x1d.livekit.proto.ConnectRequestH\x00\x12\x36\n\ndisconnect\x18\x04 \x01(\x0b\x32 .livekit.proto.DisconnectRequestH\x00\x12;\n\rpublish_track\x18\x05 \x01(\x0b\x32\".livekit.proto.PublishTrackRequestH\x00\x12?\n\x0funpublish_track\x18\x06 \x01(\x0b\x32$.livekit.proto.UnpublishTrackRequestH\x00\x12\x39\n\x0cpublish_data\x18\x07 \x01(\x0b\x32!.livekit.proto.PublishDataRequestH\x00\x12=\n\x0eset_subscribed\x18\x08 \x01(\x0b\x32#.livekit.proto.SetSubscribedRequestH\x00\x12\x44\n\x12\x63reate_video_track\x18\t \x01(\x0b\x32&.livekit.proto.CreateVideoTrackRequestH\x00\x12\x44\n\x12\x63reate_audio_track\x18\n \x01(\x0b\x32&.livekit.proto.CreateAudioTrackRequestH\x00\x12\x44\n\x12\x61lloc_video_buffer\x18\x0b \x01(\x0b\x32&.livekit.proto.AllocVideoBufferRequestH\x00\x12@\n\x10new_video_stream\x18\x0c \x01(\x0b\x32$.livekit.proto.NewVideoStreamRequestH\x00\x12@\n\x10new_video_source\x18\r \x01(\x0b\x32$.livekit.proto.NewVideoSourceRequestH\x00\x12\x46\n\x13\x63\x61pture_video_frame\x18\x0e \x01(\x0b\x32\'.livekit.proto.CaptureVideoFrameRequestH\x00\x12/\n\x07to_i420\x18\x0f \x01(\x0b\x32\x1c.livekit.proto.ToI420RequestH\x00\x12/\n\x07to_argb\x18\x10 \x01(\x0b\x32\x1c.livekit.proto.ToArgbRequestH\x00\x12\x44\n\x12\x61lloc_audio_buffer\x18\x11 \x01(\x0b\x32&.livekit.proto.AllocAudioBufferRequestH\x00\x12@\n\x10new_audio_stream\x18\x12 \x01(\x0b\x32$.livekit.proto.NewAudioStreamRequestH\x00\x12@\n\x10new_audio_source\x18\x13 \x01(\x0b\x32$.livekit.proto.NewAudioSourceRequestH\x00\x12\x46\n\x13\x63\x61pture_audio_frame\x18\x14 \x01(\x0b\x32\'.livekit.proto.CaptureAudioFrameRequestH\x00\x12\x46\n\x13new_audio_resampler\x18\x15 \x01(\x0b\x32\'.livekit.proto.NewAudioResamplerRequestH\x00\x12\x44\n\x12remix_and_resample\x18\x16 \x01(\x0b\x32&.livekit.proto.RemixAndResampleRequestH\x00\x12*\n\x04\x65\x32\x65\x65\x18\x17 \x01(\x0b\x32\x1a.livekit.proto.E2eeRequestH\x00\x42\t\n\x07message\"\xc7\x0b\n\x0b\x46\x66iResponse\x12\x37\n\ninitialize\x18\x01 \x01(\x0b\x32!.livekit.proto.InitializeResponseH\x00\x12\x31\n\x07\x64ispose\x18\x02 \x01(\x0b\x32\x1e.livekit.proto.DisposeResponseH\x00\x12\x31\n\x07\x63onnect\x18\x03 \x01(\x0b\x32\x1e.livekit.proto.ConnectResponseH\x00\x12\x37\n\ndisconnect\x18\x04 \x01(\x0b\x32!.livekit.proto.DisconnectResponseH\x00\x12<\n\rpublish_track\x18\x05 \x01(\x0b\x32#.livekit.proto.PublishTrackResponseH\x00\x12@\n\x0funpublish_track\x18\x06 \x01(\x0b\x32%.livekit.proto.UnpublishTrackResponseH\x00\x12:\n\x0cpublish_data\x18\x07 \x01(\x0b\x32\".livekit.proto.PublishDataResponseH\x00\x12>\n\x0eset_subscribed\x18\x08 \x01(\x0b\x32$.livekit.proto.SetSubscribedResponseH\x00\x12\x45\n\x12\x63reate_video_track\x18\t \x01(\x0b\x32\'.livekit.proto.CreateVideoTrackResponseH\x00\x12\x45\n\x12\x63reate_audio_track\x18\n \x01(\x0b\x32\'.livekit.proto.CreateAudioTrackResponseH\x00\x12\x45\n\x12\x61lloc_video_buffer\x18\x0b \x01(\x0b\x32\'.livekit.proto.AllocVideoBufferResponseH\x00\x12\x41\n\x10new_video_stream\x18\x0c \x01(\x0b\x32%.livekit.proto.NewVideoStreamResponseH\x00\x12\x41\n\x10new_video_source\x18\r \x01(\x0b\x32%.livekit.proto.NewVideoSourceResponseH\x00\x12G\n\x13\x63\x61pture_video_frame\x18\x0e \x01(\x0b\x32(.livekit.proto.CaptureVideoFrameResponseH\x00\x12\x30\n\x07to_i420\x18\x0f \x01(\x0b\x32\x1d.livekit.proto.ToI420ResponseH\x00\x12\x30\n\x07to_argb\x18\x10 \x01(\x0b\x32\x1d.livekit.proto.ToArgbResponseH\x00\x12\x45\n\x12\x61lloc_audio_buffer\x18\x11 \x01(\x0b\x32\'.livekit.proto.AllocAudioBufferResponseH\x00\x12\x41\n\x10new_audio_stream\x18\x12 \x01(\x0b\x32%.livekit.proto.NewAudioStreamResponseH\x00\x12\x41\n\x10new_audio_source\x18\x13 \x01(\x0b\x32%.livekit.proto.NewAudioSourceResponseH\x00\x12G\n\x13\x63\x61pture_audio_frame\x18\x14 \x01(\x0b\x32(.livekit.proto.CaptureAudioFrameResponseH\x00\x12G\n\x13new_audio_resampler\x18\x15 \x01(\x0b\x32(.livekit.proto.NewAudioResamplerResponseH\x00\x12\x45\n\x12remix_and_resample\x18\x16 \x01(\x0b\x32\'.livekit.proto.RemixAndResampleResponseH\x00\x12+\n\x04\x65\x32\x65\x65\x18\x17 \x01(\x0b\x32\x1b.livekit.proto.E2eeResponseH\x00\x42\t\n\x07message\"\x99\x05\n\x08\x46\x66iEvent\x12.\n\nroom_event\x18\x01 \x01(\x0b\x32\x18.livekit.proto.RoomEventH\x00\x12\x30\n\x0btrack_event\x18\x02 \x01(\x0b\x32\x19.livekit.proto.TrackEventH\x00\x12=\n\x12video_stream_event\x18\x03 \x01(\x0b\x32\x1f.livekit.proto.VideoStreamEventH\x00\x12=\n\x12\x61udio_stream_event\x18\x04 \x01(\x0b\x32\x1f.livekit.proto.AudioStreamEventH\x00\x12\x31\n\x07\x63onnect\x18\x05 \x01(\x0b\x32\x1e.livekit.proto.ConnectCallbackH\x00\x12\x37\n\ndisconnect\x18\x06 \x01(\x0b\x32!.livekit.proto.DisconnectCallbackH\x00\x12\x31\n\x07\x64ispose\x18\x07 \x01(\x0b\x32\x1e.livekit.proto.DisposeCallbackH\x00\x12<\n\rpublish_track\x18\x08 \x01(\x0b\x32#.livekit.proto.PublishTrackCallbackH\x00\x12@\n\x0funpublish_track\x18\t \x01(\x0b\x32%.livekit.proto.UnpublishTrackCallbackH\x00\x12:\n\x0cpublish_data\x18\n \x01(\x0b\x32\".livekit.proto.PublishDataCallbackH\x00\x12G\n\x13\x63\x61pture_audio_frame\x18\x0b \x01(\x0b\x32(.livekit.proto.CaptureAudioFrameCallbackH\x00\x42\t\n\x07message\"/\n\x11InitializeRequest\x12\x1a\n\x12\x65vent_callback_ptr\x18\x01 \x01(\x04\"\x14\n\x12InitializeResponse\"\x1f\n\x0e\x44isposeRequest\x12\r\n\x05\x61sync\x18\x01 \x01(\x08\"5\n\x0f\x44isposeResponse\x12\x15\n\x08\x61sync_id\x18\x01 \x01(\x04H\x00\x88\x01\x01\x42\x0b\n\t_async_id\"#\n\x0f\x44isposeCallback\x12\x10\n\x08\x61sync_id\x18\x01 \x01(\x04\x42\x10\xaa\x02\rLiveKit.Protob\x06proto3') +DESCRIPTOR = _descriptor_pool.Default().AddSerializedFile(b'\n\tffi.proto\x12\rlivekit.proto\x1a\ne2ee.proto\x1a\x0btrack.proto\x1a\nroom.proto\x1a\x11video_frame.proto\x1a\x11\x61udio_frame.proto\"\xbf\x0c\n\nFfiRequest\x12\x36\n\ninitialize\x18\x01 \x01(\x0b\x32 .livekit.proto.InitializeRequestH\x00\x12\x30\n\x07\x64ispose\x18\x02 \x01(\x0b\x32\x1d.livekit.proto.DisposeRequestH\x00\x12\x30\n\x07\x63onnect\x18\x03 \x01(\x0b\x32\x1d.livekit.proto.ConnectRequestH\x00\x12\x36\n\ndisconnect\x18\x04 \x01(\x0b\x32 .livekit.proto.DisconnectRequestH\x00\x12;\n\rpublish_track\x18\x05 \x01(\x0b\x32\".livekit.proto.PublishTrackRequestH\x00\x12?\n\x0funpublish_track\x18\x06 \x01(\x0b\x32$.livekit.proto.UnpublishTrackRequestH\x00\x12\x39\n\x0cpublish_data\x18\x07 \x01(\x0b\x32!.livekit.proto.PublishDataRequestH\x00\x12=\n\x0eset_subscribed\x18\x08 \x01(\x0b\x32#.livekit.proto.SetSubscribedRequestH\x00\x12J\n\x15update_local_metadata\x18\t \x01(\x0b\x32).livekit.proto.UpdateLocalMetadataRequestH\x00\x12\x42\n\x11update_local_name\x18\n \x01(\x0b\x32%.livekit.proto.UpdateLocalNameRequestH\x00\x12\x44\n\x12\x63reate_video_track\x18\x0b \x01(\x0b\x32&.livekit.proto.CreateVideoTrackRequestH\x00\x12\x44\n\x12\x63reate_audio_track\x18\x0c \x01(\x0b\x32&.livekit.proto.CreateAudioTrackRequestH\x00\x12\x44\n\x12\x61lloc_video_buffer\x18\r \x01(\x0b\x32&.livekit.proto.AllocVideoBufferRequestH\x00\x12@\n\x10new_video_stream\x18\x0e \x01(\x0b\x32$.livekit.proto.NewVideoStreamRequestH\x00\x12@\n\x10new_video_source\x18\x0f \x01(\x0b\x32$.livekit.proto.NewVideoSourceRequestH\x00\x12\x46\n\x13\x63\x61pture_video_frame\x18\x10 \x01(\x0b\x32\'.livekit.proto.CaptureVideoFrameRequestH\x00\x12/\n\x07to_i420\x18\x11 \x01(\x0b\x32\x1c.livekit.proto.ToI420RequestH\x00\x12/\n\x07to_argb\x18\x12 \x01(\x0b\x32\x1c.livekit.proto.ToArgbRequestH\x00\x12\x44\n\x12\x61lloc_audio_buffer\x18\x13 \x01(\x0b\x32&.livekit.proto.AllocAudioBufferRequestH\x00\x12@\n\x10new_audio_stream\x18\x14 \x01(\x0b\x32$.livekit.proto.NewAudioStreamRequestH\x00\x12@\n\x10new_audio_source\x18\x15 \x01(\x0b\x32$.livekit.proto.NewAudioSourceRequestH\x00\x12\x46\n\x13\x63\x61pture_audio_frame\x18\x16 \x01(\x0b\x32\'.livekit.proto.CaptureAudioFrameRequestH\x00\x12\x46\n\x13new_audio_resampler\x18\x17 \x01(\x0b\x32\'.livekit.proto.NewAudioResamplerRequestH\x00\x12\x44\n\x12remix_and_resample\x18\x18 \x01(\x0b\x32&.livekit.proto.RemixAndResampleRequestH\x00\x12*\n\x04\x65\x32\x65\x65\x18\x19 \x01(\x0b\x32\x1a.livekit.proto.E2eeRequestH\x00\x42\t\n\x07message\"\xd9\x0c\n\x0b\x46\x66iResponse\x12\x37\n\ninitialize\x18\x01 \x01(\x0b\x32!.livekit.proto.InitializeResponseH\x00\x12\x31\n\x07\x64ispose\x18\x02 \x01(\x0b\x32\x1e.livekit.proto.DisposeResponseH\x00\x12\x31\n\x07\x63onnect\x18\x03 \x01(\x0b\x32\x1e.livekit.proto.ConnectResponseH\x00\x12\x37\n\ndisconnect\x18\x04 \x01(\x0b\x32!.livekit.proto.DisconnectResponseH\x00\x12<\n\rpublish_track\x18\x05 \x01(\x0b\x32#.livekit.proto.PublishTrackResponseH\x00\x12@\n\x0funpublish_track\x18\x06 \x01(\x0b\x32%.livekit.proto.UnpublishTrackResponseH\x00\x12:\n\x0cpublish_data\x18\x07 \x01(\x0b\x32\".livekit.proto.PublishDataResponseH\x00\x12>\n\x0eset_subscribed\x18\x08 \x01(\x0b\x32$.livekit.proto.SetSubscribedResponseH\x00\x12K\n\x15update_local_metadata\x18\t \x01(\x0b\x32*.livekit.proto.UpdateLocalMetadataResponseH\x00\x12\x43\n\x11update_local_name\x18\n \x01(\x0b\x32&.livekit.proto.UpdateLocalNameResponseH\x00\x12\x45\n\x12\x63reate_video_track\x18\x0b \x01(\x0b\x32\'.livekit.proto.CreateVideoTrackResponseH\x00\x12\x45\n\x12\x63reate_audio_track\x18\x0c \x01(\x0b\x32\'.livekit.proto.CreateAudioTrackResponseH\x00\x12\x45\n\x12\x61lloc_video_buffer\x18\r \x01(\x0b\x32\'.livekit.proto.AllocVideoBufferResponseH\x00\x12\x41\n\x10new_video_stream\x18\x0e \x01(\x0b\x32%.livekit.proto.NewVideoStreamResponseH\x00\x12\x41\n\x10new_video_source\x18\x0f \x01(\x0b\x32%.livekit.proto.NewVideoSourceResponseH\x00\x12G\n\x13\x63\x61pture_video_frame\x18\x10 \x01(\x0b\x32(.livekit.proto.CaptureVideoFrameResponseH\x00\x12\x30\n\x07to_i420\x18\x11 \x01(\x0b\x32\x1d.livekit.proto.ToI420ResponseH\x00\x12\x30\n\x07to_argb\x18\x12 \x01(\x0b\x32\x1d.livekit.proto.ToArgbResponseH\x00\x12\x45\n\x12\x61lloc_audio_buffer\x18\x13 \x01(\x0b\x32\'.livekit.proto.AllocAudioBufferResponseH\x00\x12\x41\n\x10new_audio_stream\x18\x14 \x01(\x0b\x32%.livekit.proto.NewAudioStreamResponseH\x00\x12\x41\n\x10new_audio_source\x18\x15 \x01(\x0b\x32%.livekit.proto.NewAudioSourceResponseH\x00\x12G\n\x13\x63\x61pture_audio_frame\x18\x16 \x01(\x0b\x32(.livekit.proto.CaptureAudioFrameResponseH\x00\x12G\n\x13new_audio_resampler\x18\x17 \x01(\x0b\x32(.livekit.proto.NewAudioResamplerResponseH\x00\x12\x45\n\x12remix_and_resample\x18\x18 \x01(\x0b\x32\'.livekit.proto.RemixAndResampleResponseH\x00\x12+\n\x04\x65\x32\x65\x65\x18\x19 \x01(\x0b\x32\x1b.livekit.proto.E2eeResponseH\x00\x42\t\n\x07message\"\xab\x06\n\x08\x46\x66iEvent\x12.\n\nroom_event\x18\x01 \x01(\x0b\x32\x18.livekit.proto.RoomEventH\x00\x12\x30\n\x0btrack_event\x18\x02 \x01(\x0b\x32\x19.livekit.proto.TrackEventH\x00\x12=\n\x12video_stream_event\x18\x03 \x01(\x0b\x32\x1f.livekit.proto.VideoStreamEventH\x00\x12=\n\x12\x61udio_stream_event\x18\x04 \x01(\x0b\x32\x1f.livekit.proto.AudioStreamEventH\x00\x12\x31\n\x07\x63onnect\x18\x05 \x01(\x0b\x32\x1e.livekit.proto.ConnectCallbackH\x00\x12\x37\n\ndisconnect\x18\x06 \x01(\x0b\x32!.livekit.proto.DisconnectCallbackH\x00\x12\x31\n\x07\x64ispose\x18\x07 \x01(\x0b\x32\x1e.livekit.proto.DisposeCallbackH\x00\x12<\n\rpublish_track\x18\x08 \x01(\x0b\x32#.livekit.proto.PublishTrackCallbackH\x00\x12@\n\x0funpublish_track\x18\t \x01(\x0b\x32%.livekit.proto.UnpublishTrackCallbackH\x00\x12:\n\x0cpublish_data\x18\n \x01(\x0b\x32\".livekit.proto.PublishDataCallbackH\x00\x12G\n\x13\x63\x61pture_audio_frame\x18\x0b \x01(\x0b\x32(.livekit.proto.CaptureAudioFrameCallbackH\x00\x12K\n\x15update_local_metadata\x18\x0c \x01(\x0b\x32*.livekit.proto.UpdateLocalMetadataCallbackH\x00\x12\x43\n\x11update_local_name\x18\r \x01(\x0b\x32&.livekit.proto.UpdateLocalNameCallbackH\x00\x42\t\n\x07message\"/\n\x11InitializeRequest\x12\x1a\n\x12\x65vent_callback_ptr\x18\x01 \x01(\x04\"\x14\n\x12InitializeResponse\"\x1f\n\x0e\x44isposeRequest\x12\r\n\x05\x61sync\x18\x01 \x01(\x08\"5\n\x0f\x44isposeResponse\x12\x15\n\x08\x61sync_id\x18\x01 \x01(\x04H\x00\x88\x01\x01\x42\x0b\n\t_async_id\"#\n\x0f\x44isposeCallback\x12\x10\n\x08\x61sync_id\x18\x01 \x01(\x04\x42\x10\xaa\x02\rLiveKit.Protob\x06proto3') _globals = globals() _builder.BuildMessageAndEnumDescriptors(DESCRIPTOR, _globals) @@ -28,19 +28,19 @@ DESCRIPTOR._options = None DESCRIPTOR._serialized_options = b'\252\002\rLiveKit.Proto' _globals['_FFIREQUEST']._serialized_start=104 - _globals['_FFIREQUEST']._serialized_end=1559 - _globals['_FFIRESPONSE']._serialized_start=1562 - _globals['_FFIRESPONSE']._serialized_end=3041 - _globals['_FFIEVENT']._serialized_start=3044 - _globals['_FFIEVENT']._serialized_end=3709 - _globals['_INITIALIZEREQUEST']._serialized_start=3711 - _globals['_INITIALIZEREQUEST']._serialized_end=3758 - _globals['_INITIALIZERESPONSE']._serialized_start=3760 - _globals['_INITIALIZERESPONSE']._serialized_end=3780 - _globals['_DISPOSEREQUEST']._serialized_start=3782 - _globals['_DISPOSEREQUEST']._serialized_end=3813 - _globals['_DISPOSERESPONSE']._serialized_start=3815 - _globals['_DISPOSERESPONSE']._serialized_end=3868 - _globals['_DISPOSECALLBACK']._serialized_start=3870 - _globals['_DISPOSECALLBACK']._serialized_end=3905 + _globals['_FFIREQUEST']._serialized_end=1703 + _globals['_FFIRESPONSE']._serialized_start=1706 + _globals['_FFIRESPONSE']._serialized_end=3331 + _globals['_FFIEVENT']._serialized_start=3334 + _globals['_FFIEVENT']._serialized_end=4145 + _globals['_INITIALIZEREQUEST']._serialized_start=4147 + _globals['_INITIALIZEREQUEST']._serialized_end=4194 + _globals['_INITIALIZERESPONSE']._serialized_start=4196 + _globals['_INITIALIZERESPONSE']._serialized_end=4216 + _globals['_DISPOSEREQUEST']._serialized_start=4218 + _globals['_DISPOSEREQUEST']._serialized_end=4249 + _globals['_DISPOSERESPONSE']._serialized_start=4251 + _globals['_DISPOSERESPONSE']._serialized_end=4304 + _globals['_DISPOSECALLBACK']._serialized_start=4306 + _globals['_DISPOSECALLBACK']._serialized_end=4341 # @@protoc_insertion_point(module_scope) diff --git a/livekit/_proto/ffi_pb2.pyi b/livekit/_proto/ffi_pb2.pyi index c7c9d7ba..542a139b 100644 --- a/livekit/_proto/ffi_pb2.pyi +++ b/livekit/_proto/ffi_pb2.pyi @@ -74,6 +74,8 @@ class FfiRequest(google.protobuf.message.Message): UNPUBLISH_TRACK_FIELD_NUMBER: builtins.int PUBLISH_DATA_FIELD_NUMBER: builtins.int SET_SUBSCRIBED_FIELD_NUMBER: builtins.int + UPDATE_LOCAL_METADATA_FIELD_NUMBER: builtins.int + UPDATE_LOCAL_NAME_FIELD_NUMBER: builtins.int CREATE_VIDEO_TRACK_FIELD_NUMBER: builtins.int CREATE_AUDIO_TRACK_FIELD_NUMBER: builtins.int ALLOC_VIDEO_BUFFER_FIELD_NUMBER: builtins.int @@ -107,6 +109,10 @@ class FfiRequest(google.protobuf.message.Message): @property def set_subscribed(self) -> room_pb2.SetSubscribedRequest: ... @property + def update_local_metadata(self) -> room_pb2.UpdateLocalMetadataRequest: ... + @property + def update_local_name(self) -> room_pb2.UpdateLocalNameRequest: ... + @property def create_video_track(self) -> track_pb2.CreateVideoTrackRequest: """Track""" @property @@ -150,6 +156,8 @@ class FfiRequest(google.protobuf.message.Message): unpublish_track: room_pb2.UnpublishTrackRequest | None = ..., publish_data: room_pb2.PublishDataRequest | None = ..., set_subscribed: room_pb2.SetSubscribedRequest | None = ..., + update_local_metadata: room_pb2.UpdateLocalMetadataRequest | None = ..., + update_local_name: room_pb2.UpdateLocalNameRequest | None = ..., create_video_track: track_pb2.CreateVideoTrackRequest | None = ..., create_audio_track: track_pb2.CreateAudioTrackRequest | None = ..., alloc_video_buffer: video_frame_pb2.AllocVideoBufferRequest | None = ..., @@ -166,9 +174,9 @@ class FfiRequest(google.protobuf.message.Message): remix_and_resample: audio_frame_pb2.RemixAndResampleRequest | None = ..., e2ee: e2ee_pb2.E2eeRequest | None = ..., ) -> None: ... - def HasField(self, field_name: typing_extensions.Literal["alloc_audio_buffer", b"alloc_audio_buffer", "alloc_video_buffer", b"alloc_video_buffer", "capture_audio_frame", b"capture_audio_frame", "capture_video_frame", b"capture_video_frame", "connect", b"connect", "create_audio_track", b"create_audio_track", "create_video_track", b"create_video_track", "disconnect", b"disconnect", "dispose", b"dispose", "e2ee", b"e2ee", "initialize", b"initialize", "message", b"message", "new_audio_resampler", b"new_audio_resampler", "new_audio_source", b"new_audio_source", "new_audio_stream", b"new_audio_stream", "new_video_source", b"new_video_source", "new_video_stream", b"new_video_stream", "publish_data", b"publish_data", "publish_track", b"publish_track", "remix_and_resample", b"remix_and_resample", "set_subscribed", b"set_subscribed", "to_argb", b"to_argb", "to_i420", b"to_i420", "unpublish_track", b"unpublish_track"]) -> builtins.bool: ... - def ClearField(self, field_name: typing_extensions.Literal["alloc_audio_buffer", b"alloc_audio_buffer", "alloc_video_buffer", b"alloc_video_buffer", "capture_audio_frame", b"capture_audio_frame", "capture_video_frame", b"capture_video_frame", "connect", b"connect", "create_audio_track", b"create_audio_track", "create_video_track", b"create_video_track", "disconnect", b"disconnect", "dispose", b"dispose", "e2ee", b"e2ee", "initialize", b"initialize", "message", b"message", "new_audio_resampler", b"new_audio_resampler", "new_audio_source", b"new_audio_source", "new_audio_stream", b"new_audio_stream", "new_video_source", b"new_video_source", "new_video_stream", b"new_video_stream", "publish_data", b"publish_data", "publish_track", b"publish_track", "remix_and_resample", b"remix_and_resample", "set_subscribed", b"set_subscribed", "to_argb", b"to_argb", "to_i420", b"to_i420", "unpublish_track", b"unpublish_track"]) -> None: ... - def WhichOneof(self, oneof_group: typing_extensions.Literal["message", b"message"]) -> typing_extensions.Literal["initialize", "dispose", "connect", "disconnect", "publish_track", "unpublish_track", "publish_data", "set_subscribed", "create_video_track", "create_audio_track", "alloc_video_buffer", "new_video_stream", "new_video_source", "capture_video_frame", "to_i420", "to_argb", "alloc_audio_buffer", "new_audio_stream", "new_audio_source", "capture_audio_frame", "new_audio_resampler", "remix_and_resample", "e2ee"] | None: ... + def HasField(self, field_name: typing_extensions.Literal["alloc_audio_buffer", b"alloc_audio_buffer", "alloc_video_buffer", b"alloc_video_buffer", "capture_audio_frame", b"capture_audio_frame", "capture_video_frame", b"capture_video_frame", "connect", b"connect", "create_audio_track", b"create_audio_track", "create_video_track", b"create_video_track", "disconnect", b"disconnect", "dispose", b"dispose", "e2ee", b"e2ee", "initialize", b"initialize", "message", b"message", "new_audio_resampler", b"new_audio_resampler", "new_audio_source", b"new_audio_source", "new_audio_stream", b"new_audio_stream", "new_video_source", b"new_video_source", "new_video_stream", b"new_video_stream", "publish_data", b"publish_data", "publish_track", b"publish_track", "remix_and_resample", b"remix_and_resample", "set_subscribed", b"set_subscribed", "to_argb", b"to_argb", "to_i420", b"to_i420", "unpublish_track", b"unpublish_track", "update_local_metadata", b"update_local_metadata", "update_local_name", b"update_local_name"]) -> builtins.bool: ... + def ClearField(self, field_name: typing_extensions.Literal["alloc_audio_buffer", b"alloc_audio_buffer", "alloc_video_buffer", b"alloc_video_buffer", "capture_audio_frame", b"capture_audio_frame", "capture_video_frame", b"capture_video_frame", "connect", b"connect", "create_audio_track", b"create_audio_track", "create_video_track", b"create_video_track", "disconnect", b"disconnect", "dispose", b"dispose", "e2ee", b"e2ee", "initialize", b"initialize", "message", b"message", "new_audio_resampler", b"new_audio_resampler", "new_audio_source", b"new_audio_source", "new_audio_stream", b"new_audio_stream", "new_video_source", b"new_video_source", "new_video_stream", b"new_video_stream", "publish_data", b"publish_data", "publish_track", b"publish_track", "remix_and_resample", b"remix_and_resample", "set_subscribed", b"set_subscribed", "to_argb", b"to_argb", "to_i420", b"to_i420", "unpublish_track", b"unpublish_track", "update_local_metadata", b"update_local_metadata", "update_local_name", b"update_local_name"]) -> None: ... + def WhichOneof(self, oneof_group: typing_extensions.Literal["message", b"message"]) -> typing_extensions.Literal["initialize", "dispose", "connect", "disconnect", "publish_track", "unpublish_track", "publish_data", "set_subscribed", "update_local_metadata", "update_local_name", "create_video_track", "create_audio_track", "alloc_video_buffer", "new_video_stream", "new_video_source", "capture_video_frame", "to_i420", "to_argb", "alloc_audio_buffer", "new_audio_stream", "new_audio_source", "capture_audio_frame", "new_audio_resampler", "remix_and_resample", "e2ee"] | None: ... global___FfiRequest = FfiRequest @@ -186,6 +194,8 @@ class FfiResponse(google.protobuf.message.Message): UNPUBLISH_TRACK_FIELD_NUMBER: builtins.int PUBLISH_DATA_FIELD_NUMBER: builtins.int SET_SUBSCRIBED_FIELD_NUMBER: builtins.int + UPDATE_LOCAL_METADATA_FIELD_NUMBER: builtins.int + UPDATE_LOCAL_NAME_FIELD_NUMBER: builtins.int CREATE_VIDEO_TRACK_FIELD_NUMBER: builtins.int CREATE_AUDIO_TRACK_FIELD_NUMBER: builtins.int ALLOC_VIDEO_BUFFER_FIELD_NUMBER: builtins.int @@ -219,6 +229,10 @@ class FfiResponse(google.protobuf.message.Message): @property def set_subscribed(self) -> room_pb2.SetSubscribedResponse: ... @property + def update_local_metadata(self) -> room_pb2.UpdateLocalMetadataResponse: ... + @property + def update_local_name(self) -> room_pb2.UpdateLocalNameResponse: ... + @property def create_video_track(self) -> track_pb2.CreateVideoTrackResponse: """Track""" @property @@ -262,6 +276,8 @@ class FfiResponse(google.protobuf.message.Message): unpublish_track: room_pb2.UnpublishTrackResponse | None = ..., publish_data: room_pb2.PublishDataResponse | None = ..., set_subscribed: room_pb2.SetSubscribedResponse | None = ..., + update_local_metadata: room_pb2.UpdateLocalMetadataResponse | None = ..., + update_local_name: room_pb2.UpdateLocalNameResponse | None = ..., create_video_track: track_pb2.CreateVideoTrackResponse | None = ..., create_audio_track: track_pb2.CreateAudioTrackResponse | None = ..., alloc_video_buffer: video_frame_pb2.AllocVideoBufferResponse | None = ..., @@ -278,9 +294,9 @@ class FfiResponse(google.protobuf.message.Message): remix_and_resample: audio_frame_pb2.RemixAndResampleResponse | None = ..., e2ee: e2ee_pb2.E2eeResponse | None = ..., ) -> None: ... - def HasField(self, field_name: typing_extensions.Literal["alloc_audio_buffer", b"alloc_audio_buffer", "alloc_video_buffer", b"alloc_video_buffer", "capture_audio_frame", b"capture_audio_frame", "capture_video_frame", b"capture_video_frame", "connect", b"connect", "create_audio_track", b"create_audio_track", "create_video_track", b"create_video_track", "disconnect", b"disconnect", "dispose", b"dispose", "e2ee", b"e2ee", "initialize", b"initialize", "message", b"message", "new_audio_resampler", b"new_audio_resampler", "new_audio_source", b"new_audio_source", "new_audio_stream", b"new_audio_stream", "new_video_source", b"new_video_source", "new_video_stream", b"new_video_stream", "publish_data", b"publish_data", "publish_track", b"publish_track", "remix_and_resample", b"remix_and_resample", "set_subscribed", b"set_subscribed", "to_argb", b"to_argb", "to_i420", b"to_i420", "unpublish_track", b"unpublish_track"]) -> builtins.bool: ... - def ClearField(self, field_name: typing_extensions.Literal["alloc_audio_buffer", b"alloc_audio_buffer", "alloc_video_buffer", b"alloc_video_buffer", "capture_audio_frame", b"capture_audio_frame", "capture_video_frame", b"capture_video_frame", "connect", b"connect", "create_audio_track", b"create_audio_track", "create_video_track", b"create_video_track", "disconnect", b"disconnect", "dispose", b"dispose", "e2ee", b"e2ee", "initialize", b"initialize", "message", b"message", "new_audio_resampler", b"new_audio_resampler", "new_audio_source", b"new_audio_source", "new_audio_stream", b"new_audio_stream", "new_video_source", b"new_video_source", "new_video_stream", b"new_video_stream", "publish_data", b"publish_data", "publish_track", b"publish_track", "remix_and_resample", b"remix_and_resample", "set_subscribed", b"set_subscribed", "to_argb", b"to_argb", "to_i420", b"to_i420", "unpublish_track", b"unpublish_track"]) -> None: ... - def WhichOneof(self, oneof_group: typing_extensions.Literal["message", b"message"]) -> typing_extensions.Literal["initialize", "dispose", "connect", "disconnect", "publish_track", "unpublish_track", "publish_data", "set_subscribed", "create_video_track", "create_audio_track", "alloc_video_buffer", "new_video_stream", "new_video_source", "capture_video_frame", "to_i420", "to_argb", "alloc_audio_buffer", "new_audio_stream", "new_audio_source", "capture_audio_frame", "new_audio_resampler", "remix_and_resample", "e2ee"] | None: ... + def HasField(self, field_name: typing_extensions.Literal["alloc_audio_buffer", b"alloc_audio_buffer", "alloc_video_buffer", b"alloc_video_buffer", "capture_audio_frame", b"capture_audio_frame", "capture_video_frame", b"capture_video_frame", "connect", b"connect", "create_audio_track", b"create_audio_track", "create_video_track", b"create_video_track", "disconnect", b"disconnect", "dispose", b"dispose", "e2ee", b"e2ee", "initialize", b"initialize", "message", b"message", "new_audio_resampler", b"new_audio_resampler", "new_audio_source", b"new_audio_source", "new_audio_stream", b"new_audio_stream", "new_video_source", b"new_video_source", "new_video_stream", b"new_video_stream", "publish_data", b"publish_data", "publish_track", b"publish_track", "remix_and_resample", b"remix_and_resample", "set_subscribed", b"set_subscribed", "to_argb", b"to_argb", "to_i420", b"to_i420", "unpublish_track", b"unpublish_track", "update_local_metadata", b"update_local_metadata", "update_local_name", b"update_local_name"]) -> builtins.bool: ... + def ClearField(self, field_name: typing_extensions.Literal["alloc_audio_buffer", b"alloc_audio_buffer", "alloc_video_buffer", b"alloc_video_buffer", "capture_audio_frame", b"capture_audio_frame", "capture_video_frame", b"capture_video_frame", "connect", b"connect", "create_audio_track", b"create_audio_track", "create_video_track", b"create_video_track", "disconnect", b"disconnect", "dispose", b"dispose", "e2ee", b"e2ee", "initialize", b"initialize", "message", b"message", "new_audio_resampler", b"new_audio_resampler", "new_audio_source", b"new_audio_source", "new_audio_stream", b"new_audio_stream", "new_video_source", b"new_video_source", "new_video_stream", b"new_video_stream", "publish_data", b"publish_data", "publish_track", b"publish_track", "remix_and_resample", b"remix_and_resample", "set_subscribed", b"set_subscribed", "to_argb", b"to_argb", "to_i420", b"to_i420", "unpublish_track", b"unpublish_track", "update_local_metadata", b"update_local_metadata", "update_local_name", b"update_local_name"]) -> None: ... + def WhichOneof(self, oneof_group: typing_extensions.Literal["message", b"message"]) -> typing_extensions.Literal["initialize", "dispose", "connect", "disconnect", "publish_track", "unpublish_track", "publish_data", "set_subscribed", "update_local_metadata", "update_local_name", "create_video_track", "create_audio_track", "alloc_video_buffer", "new_video_stream", "new_video_source", "capture_video_frame", "to_i420", "to_argb", "alloc_audio_buffer", "new_audio_stream", "new_audio_source", "capture_audio_frame", "new_audio_resampler", "remix_and_resample", "e2ee"] | None: ... global___FfiResponse = FfiResponse @@ -304,6 +320,8 @@ class FfiEvent(google.protobuf.message.Message): UNPUBLISH_TRACK_FIELD_NUMBER: builtins.int PUBLISH_DATA_FIELD_NUMBER: builtins.int CAPTURE_AUDIO_FRAME_FIELD_NUMBER: builtins.int + UPDATE_LOCAL_METADATA_FIELD_NUMBER: builtins.int + UPDATE_LOCAL_NAME_FIELD_NUMBER: builtins.int @property def room_event(self) -> room_pb2.RoomEvent: ... @property @@ -326,6 +344,10 @@ class FfiEvent(google.protobuf.message.Message): def publish_data(self) -> room_pb2.PublishDataCallback: ... @property def capture_audio_frame(self) -> audio_frame_pb2.CaptureAudioFrameCallback: ... + @property + def update_local_metadata(self) -> room_pb2.UpdateLocalMetadataCallback: ... + @property + def update_local_name(self) -> room_pb2.UpdateLocalNameCallback: ... def __init__( self, *, @@ -340,10 +362,12 @@ class FfiEvent(google.protobuf.message.Message): unpublish_track: room_pb2.UnpublishTrackCallback | None = ..., publish_data: room_pb2.PublishDataCallback | None = ..., capture_audio_frame: audio_frame_pb2.CaptureAudioFrameCallback | None = ..., + update_local_metadata: room_pb2.UpdateLocalMetadataCallback | None = ..., + update_local_name: room_pb2.UpdateLocalNameCallback | None = ..., ) -> None: ... - def HasField(self, field_name: typing_extensions.Literal["audio_stream_event", b"audio_stream_event", "capture_audio_frame", b"capture_audio_frame", "connect", b"connect", "disconnect", b"disconnect", "dispose", b"dispose", "message", b"message", "publish_data", b"publish_data", "publish_track", b"publish_track", "room_event", b"room_event", "track_event", b"track_event", "unpublish_track", b"unpublish_track", "video_stream_event", b"video_stream_event"]) -> builtins.bool: ... - def ClearField(self, field_name: typing_extensions.Literal["audio_stream_event", b"audio_stream_event", "capture_audio_frame", b"capture_audio_frame", "connect", b"connect", "disconnect", b"disconnect", "dispose", b"dispose", "message", b"message", "publish_data", b"publish_data", "publish_track", b"publish_track", "room_event", b"room_event", "track_event", b"track_event", "unpublish_track", b"unpublish_track", "video_stream_event", b"video_stream_event"]) -> None: ... - def WhichOneof(self, oneof_group: typing_extensions.Literal["message", b"message"]) -> typing_extensions.Literal["room_event", "track_event", "video_stream_event", "audio_stream_event", "connect", "disconnect", "dispose", "publish_track", "unpublish_track", "publish_data", "capture_audio_frame"] | None: ... + def HasField(self, field_name: typing_extensions.Literal["audio_stream_event", b"audio_stream_event", "capture_audio_frame", b"capture_audio_frame", "connect", b"connect", "disconnect", b"disconnect", "dispose", b"dispose", "message", b"message", "publish_data", b"publish_data", "publish_track", b"publish_track", "room_event", b"room_event", "track_event", b"track_event", "unpublish_track", b"unpublish_track", "update_local_metadata", b"update_local_metadata", "update_local_name", b"update_local_name", "video_stream_event", b"video_stream_event"]) -> builtins.bool: ... + def ClearField(self, field_name: typing_extensions.Literal["audio_stream_event", b"audio_stream_event", "capture_audio_frame", b"capture_audio_frame", "connect", b"connect", "disconnect", b"disconnect", "dispose", b"dispose", "message", b"message", "publish_data", b"publish_data", "publish_track", b"publish_track", "room_event", b"room_event", "track_event", b"track_event", "unpublish_track", b"unpublish_track", "update_local_metadata", b"update_local_metadata", "update_local_name", b"update_local_name", "video_stream_event", b"video_stream_event"]) -> None: ... + def WhichOneof(self, oneof_group: typing_extensions.Literal["message", b"message"]) -> typing_extensions.Literal["room_event", "track_event", "video_stream_event", "audio_stream_event", "connect", "disconnect", "dispose", "publish_track", "unpublish_track", "publish_data", "capture_audio_frame", "update_local_metadata", "update_local_name"] | None: ... global___FfiEvent = FfiEvent diff --git a/livekit/_proto/room_pb2.py b/livekit/_proto/room_pb2.py index 04b52bd6..b974b273 100644 --- a/livekit/_proto/room_pb2.py +++ b/livekit/_proto/room_pb2.py @@ -18,7 +18,7 @@ from . import video_frame_pb2 as video__frame__pb2 -DESCRIPTOR = _descriptor_pool.Default().AddSerializedFile(b'\n\nroom.proto\x12\rlivekit.proto\x1a\ne2ee.proto\x1a\x0chandle.proto\x1a\x11participant.proto\x1a\x0btrack.proto\x1a\x11video_frame.proto\"Y\n\x0e\x43onnectRequest\x12\x0b\n\x03url\x18\x01 \x01(\t\x12\r\n\x05token\x18\x02 \x01(\t\x12+\n\x07options\x18\x03 \x01(\x0b\x32\x1a.livekit.proto.RoomOptions\"#\n\x0f\x43onnectResponse\x12\x10\n\x08\x61sync_id\x18\x01 \x01(\x04\"\xfd\x02\n\x0f\x43onnectCallback\x12\x10\n\x08\x61sync_id\x18\x01 \x01(\x04\x12\x12\n\x05\x65rror\x18\x02 \x01(\tH\x00\x88\x01\x01\x12&\n\x04room\x18\x03 \x01(\x0b\x32\x18.livekit.proto.OwnedRoom\x12:\n\x11local_participant\x18\x04 \x01(\x0b\x32\x1f.livekit.proto.OwnedParticipant\x12J\n\x0cparticipants\x18\x05 \x03(\x0b\x32\x34.livekit.proto.ConnectCallback.ParticipantWithTracks\x1a\x89\x01\n\x15ParticipantWithTracks\x12\x34\n\x0bparticipant\x18\x01 \x01(\x0b\x32\x1f.livekit.proto.OwnedParticipant\x12:\n\x0cpublications\x18\x02 \x03(\x0b\x32$.livekit.proto.OwnedTrackPublicationB\x08\n\x06_error\"(\n\x11\x44isconnectRequest\x12\x13\n\x0broom_handle\x18\x01 \x01(\x04\"&\n\x12\x44isconnectResponse\x12\x10\n\x08\x61sync_id\x18\x01 \x01(\x04\"&\n\x12\x44isconnectCallback\x12\x10\n\x08\x61sync_id\x18\x01 \x01(\x04\"\x82\x01\n\x13PublishTrackRequest\x12 \n\x18local_participant_handle\x18\x01 \x01(\x04\x12\x14\n\x0ctrack_handle\x18\x02 \x01(\x04\x12\x33\n\x07options\x18\x03 \x01(\x0b\x32\".livekit.proto.TrackPublishOptions\"(\n\x14PublishTrackResponse\x12\x10\n\x08\x61sync_id\x18\x01 \x01(\x04\"\x81\x01\n\x14PublishTrackCallback\x12\x10\n\x08\x61sync_id\x18\x01 \x01(\x04\x12\x12\n\x05\x65rror\x18\x02 \x01(\tH\x00\x88\x01\x01\x12\x39\n\x0bpublication\x18\x03 \x01(\x0b\x32$.livekit.proto.OwnedTrackPublicationB\x08\n\x06_error\"g\n\x15UnpublishTrackRequest\x12 \n\x18local_participant_handle\x18\x01 \x01(\x04\x12\x11\n\ttrack_sid\x18\x02 \x01(\t\x12\x19\n\x11stop_on_unpublish\x18\x03 \x01(\x08\"*\n\x16UnpublishTrackResponse\x12\x10\n\x08\x61sync_id\x18\x01 \x01(\x04\"H\n\x16UnpublishTrackCallback\x12\x10\n\x08\x61sync_id\x18\x01 \x01(\x04\x12\x12\n\x05\x65rror\x18\x02 \x01(\tH\x00\x88\x01\x01\x42\x08\n\x06_error\"\xa1\x01\n\x12PublishDataRequest\x12 \n\x18local_participant_handle\x18\x01 \x01(\x04\x12\x10\n\x08\x64\x61ta_ptr\x18\x02 \x01(\x04\x12\x10\n\x08\x64\x61ta_len\x18\x03 \x01(\x04\x12+\n\x04kind\x18\x04 \x01(\x0e\x32\x1d.livekit.proto.DataPacketKind\x12\x18\n\x10\x64\x65stination_sids\x18\x05 \x03(\t\"\'\n\x13PublishDataResponse\x12\x10\n\x08\x61sync_id\x18\x01 \x01(\x04\"E\n\x13PublishDataCallback\x12\x10\n\x08\x61sync_id\x18\x01 \x01(\x04\x12\x12\n\x05\x65rror\x18\x02 \x01(\tH\x00\x88\x01\x01\x42\x08\n\x06_error\"E\n\x14SetSubscribedRequest\x12\x11\n\tsubscribe\x18\x01 \x01(\x08\x12\x1a\n\x12publication_handle\x18\x02 \x01(\x04\"\x17\n\x15SetSubscribedResponse\";\n\rVideoEncoding\x12\x13\n\x0bmax_bitrate\x18\x01 \x01(\x04\x12\x15\n\rmax_framerate\x18\x02 \x01(\x01\"$\n\rAudioEncoding\x12\x13\n\x0bmax_bitrate\x18\x01 \x01(\x04\"\x8a\x02\n\x13TrackPublishOptions\x12\x34\n\x0evideo_encoding\x18\x01 \x01(\x0b\x32\x1c.livekit.proto.VideoEncoding\x12\x34\n\x0e\x61udio_encoding\x18\x02 \x01(\x0b\x32\x1c.livekit.proto.AudioEncoding\x12.\n\x0bvideo_codec\x18\x03 \x01(\x0e\x32\x19.livekit.proto.VideoCodec\x12\x0b\n\x03\x64tx\x18\x04 \x01(\x08\x12\x0b\n\x03red\x18\x05 \x01(\x08\x12\x11\n\tsimulcast\x18\x06 \x01(\x08\x12*\n\x06source\x18\x07 \x01(\x0e\x32\x1a.livekit.proto.TrackSource\"=\n\tIceServer\x12\x0c\n\x04urls\x18\x01 \x03(\t\x12\x10\n\x08username\x18\x02 \x01(\t\x12\x10\n\x08password\x18\x03 \x01(\t\"\x84\x02\n\tRtcConfig\x12@\n\x12ice_transport_type\x18\x01 \x01(\x0e\x32\x1f.livekit.proto.IceTransportTypeH\x00\x88\x01\x01\x12P\n\x1a\x63ontinual_gathering_policy\x18\x02 \x01(\x0e\x32\'.livekit.proto.ContinualGatheringPolicyH\x01\x88\x01\x01\x12-\n\x0bice_servers\x18\x03 \x03(\x0b\x32\x18.livekit.proto.IceServerB\x15\n\x13_ice_transport_typeB\x1d\n\x1b_continual_gathering_policy\"\xca\x01\n\x0bRoomOptions\x12\x16\n\x0e\x61uto_subscribe\x18\x01 \x01(\x08\x12\x17\n\x0f\x61\x64\x61ptive_stream\x18\x02 \x01(\x08\x12\x10\n\x08\x64ynacast\x18\x03 \x01(\x08\x12-\n\x04\x65\x32\x65\x65\x18\x04 \x01(\x0b\x32\x1a.livekit.proto.E2eeOptionsH\x00\x88\x01\x01\x12\x31\n\nrtc_config\x18\x05 \x01(\x0b\x32\x18.livekit.proto.RtcConfigH\x01\x88\x01\x01\x42\x07\n\x05_e2eeB\r\n\x0b_rtc_config\"0\n\nBufferInfo\x12\x10\n\x08\x64\x61ta_ptr\x18\x01 \x01(\x04\x12\x10\n\x08\x64\x61ta_len\x18\x02 \x01(\x04\"e\n\x0bOwnedBuffer\x12-\n\x06handle\x18\x01 \x01(\x0b\x32\x1d.livekit.proto.FfiOwnedHandle\x12\'\n\x04\x64\x61ta\x18\x02 \x01(\x0b\x32\x19.livekit.proto.BufferInfo\"\x90\n\n\tRoomEvent\x12\x13\n\x0broom_handle\x18\x01 \x01(\x04\x12\x44\n\x15participant_connected\x18\x02 \x01(\x0b\x32#.livekit.proto.ParticipantConnectedH\x00\x12J\n\x18participant_disconnected\x18\x03 \x01(\x0b\x32&.livekit.proto.ParticipantDisconnectedH\x00\x12\x43\n\x15local_track_published\x18\x04 \x01(\x0b\x32\".livekit.proto.LocalTrackPublishedH\x00\x12G\n\x17local_track_unpublished\x18\x05 \x01(\x0b\x32$.livekit.proto.LocalTrackUnpublishedH\x00\x12\x38\n\x0ftrack_published\x18\x06 \x01(\x0b\x32\x1d.livekit.proto.TrackPublishedH\x00\x12<\n\x11track_unpublished\x18\x07 \x01(\x0b\x32\x1f.livekit.proto.TrackUnpublishedH\x00\x12:\n\x10track_subscribed\x18\x08 \x01(\x0b\x32\x1e.livekit.proto.TrackSubscribedH\x00\x12>\n\x12track_unsubscribed\x18\t \x01(\x0b\x32 .livekit.proto.TrackUnsubscribedH\x00\x12K\n\x19track_subscription_failed\x18\n \x01(\x0b\x32&.livekit.proto.TrackSubscriptionFailedH\x00\x12\x30\n\x0btrack_muted\x18\x0b \x01(\x0b\x32\x19.livekit.proto.TrackMutedH\x00\x12\x34\n\rtrack_unmuted\x18\x0c \x01(\x0b\x32\x1b.livekit.proto.TrackUnmutedH\x00\x12G\n\x17\x61\x63tive_speakers_changed\x18\r \x01(\x0b\x32$.livekit.proto.ActiveSpeakersChangedH\x00\x12M\n\x1a\x63onnection_quality_changed\x18\x0e \x01(\x0b\x32\'.livekit.proto.ConnectionQualityChangedH\x00\x12\x34\n\rdata_received\x18\x0f \x01(\x0b\x32\x1b.livekit.proto.DataReceivedH\x00\x12I\n\x18\x63onnection_state_changed\x18\x10 \x01(\x0b\x32%.livekit.proto.ConnectionStateChangedH\x00\x12\x33\n\x0c\x64isconnected\x18\x12 \x01(\x0b\x32\x1b.livekit.proto.DisconnectedH\x00\x12\x33\n\x0creconnecting\x18\x13 \x01(\x0b\x32\x1b.livekit.proto.ReconnectingH\x00\x12\x31\n\x0breconnected\x18\x14 \x01(\x0b\x32\x1a.livekit.proto.ReconnectedH\x00\x12=\n\x12\x65\x32\x65\x65_state_changed\x18\x15 \x01(\x0b\x32\x1f.livekit.proto.E2eeStateChangedH\x00\x12%\n\x03\x65os\x18\x16 \x01(\x0b\x32\x16.livekit.proto.RoomEOSH\x00\x42\t\n\x07message\"7\n\x08RoomInfo\x12\x0b\n\x03sid\x18\x01 \x01(\t\x12\x0c\n\x04name\x18\x02 \x01(\t\x12\x10\n\x08metadata\x18\x03 \x01(\t\"a\n\tOwnedRoom\x12-\n\x06handle\x18\x01 \x01(\x0b\x32\x1d.livekit.proto.FfiOwnedHandle\x12%\n\x04info\x18\x02 \x01(\x0b\x32\x17.livekit.proto.RoomInfo\"E\n\x14ParticipantConnected\x12-\n\x04info\x18\x01 \x01(\x0b\x32\x1f.livekit.proto.OwnedParticipant\"2\n\x17ParticipantDisconnected\x12\x17\n\x0fparticipant_sid\x18\x01 \x01(\t\"(\n\x13LocalTrackPublished\x12\x11\n\ttrack_sid\x18\x01 \x01(\t\"0\n\x15LocalTrackUnpublished\x12\x17\n\x0fpublication_sid\x18\x01 \x01(\t\"d\n\x0eTrackPublished\x12\x17\n\x0fparticipant_sid\x18\x01 \x01(\t\x12\x39\n\x0bpublication\x18\x02 \x01(\x0b\x32$.livekit.proto.OwnedTrackPublication\"D\n\x10TrackUnpublished\x12\x17\n\x0fparticipant_sid\x18\x01 \x01(\t\x12\x17\n\x0fpublication_sid\x18\x02 \x01(\t\"T\n\x0fTrackSubscribed\x12\x17\n\x0fparticipant_sid\x18\x01 \x01(\t\x12(\n\x05track\x18\x02 \x01(\x0b\x32\x19.livekit.proto.OwnedTrack\"?\n\x11TrackUnsubscribed\x12\x17\n\x0fparticipant_sid\x18\x01 \x01(\t\x12\x11\n\ttrack_sid\x18\x02 \x01(\t\"T\n\x17TrackSubscriptionFailed\x12\x17\n\x0fparticipant_sid\x18\x01 \x01(\t\x12\x11\n\ttrack_sid\x18\x02 \x01(\t\x12\r\n\x05\x65rror\x18\x03 \x01(\t\"8\n\nTrackMuted\x12\x17\n\x0fparticipant_sid\x18\x01 \x01(\t\x12\x11\n\ttrack_sid\x18\x02 \x01(\t\":\n\x0cTrackUnmuted\x12\x17\n\x0fparticipant_sid\x18\x01 \x01(\t\x12\x11\n\ttrack_sid\x18\x02 \x01(\t\"Z\n\x10\x45\x32\x65\x65StateChanged\x12\x17\n\x0fparticipant_sid\x18\x01 \x01(\t\x12-\n\x05state\x18\x02 \x01(\x0e\x32\x1e.livekit.proto.EncryptionState\"1\n\x15\x41\x63tiveSpeakersChanged\x12\x18\n\x10participant_sids\x18\x01 \x03(\t\"f\n\x18\x43onnectionQualityChanged\x12\x17\n\x0fparticipant_sid\x18\x01 \x01(\t\x12\x31\n\x07quality\x18\x02 \x01(\x0e\x32 .livekit.proto.ConnectionQuality\"\x97\x01\n\x0c\x44\x61taReceived\x12(\n\x04\x64\x61ta\x18\x01 \x01(\x0b\x32\x1a.livekit.proto.OwnedBuffer\x12\x1c\n\x0fparticipant_sid\x18\x02 \x01(\tH\x00\x88\x01\x01\x12+\n\x04kind\x18\x03 \x01(\x0e\x32\x1d.livekit.proto.DataPacketKindB\x12\n\x10_participant_sid\"G\n\x16\x43onnectionStateChanged\x12-\n\x05state\x18\x01 \x01(\x0e\x32\x1e.livekit.proto.ConnectionState\"\x0b\n\tConnected\"\x0e\n\x0c\x44isconnected\"\x0e\n\x0cReconnecting\"\r\n\x0bReconnected\"\t\n\x07RoomEOS*P\n\x10IceTransportType\x12\x13\n\x0fTRANSPORT_RELAY\x10\x00\x12\x14\n\x10TRANSPORT_NOHOST\x10\x01\x12\x11\n\rTRANSPORT_ALL\x10\x02*C\n\x18\x43ontinualGatheringPolicy\x12\x0f\n\x0bGATHER_ONCE\x10\x00\x12\x16\n\x12GATHER_CONTINUALLY\x10\x01*N\n\x11\x43onnectionQuality\x12\x10\n\x0cQUALITY_POOR\x10\x00\x12\x10\n\x0cQUALITY_GOOD\x10\x01\x12\x15\n\x11QUALITY_EXCELLENT\x10\x02*S\n\x0f\x43onnectionState\x12\x15\n\x11\x43ONN_DISCONNECTED\x10\x00\x12\x12\n\x0e\x43ONN_CONNECTED\x10\x01\x12\x15\n\x11\x43ONN_RECONNECTING\x10\x02*3\n\x0e\x44\x61taPacketKind\x12\x0e\n\nKIND_LOSSY\x10\x00\x12\x11\n\rKIND_RELIABLE\x10\x01\x42\x10\xaa\x02\rLiveKit.Protob\x06proto3') +DESCRIPTOR = _descriptor_pool.Default().AddSerializedFile(b'\n\nroom.proto\x12\rlivekit.proto\x1a\ne2ee.proto\x1a\x0chandle.proto\x1a\x11participant.proto\x1a\x0btrack.proto\x1a\x11video_frame.proto\"Y\n\x0e\x43onnectRequest\x12\x0b\n\x03url\x18\x01 \x01(\t\x12\r\n\x05token\x18\x02 \x01(\t\x12+\n\x07options\x18\x03 \x01(\x0b\x32\x1a.livekit.proto.RoomOptions\"#\n\x0f\x43onnectResponse\x12\x10\n\x08\x61sync_id\x18\x01 \x01(\x04\"\xfd\x02\n\x0f\x43onnectCallback\x12\x10\n\x08\x61sync_id\x18\x01 \x01(\x04\x12\x12\n\x05\x65rror\x18\x02 \x01(\tH\x00\x88\x01\x01\x12&\n\x04room\x18\x03 \x01(\x0b\x32\x18.livekit.proto.OwnedRoom\x12:\n\x11local_participant\x18\x04 \x01(\x0b\x32\x1f.livekit.proto.OwnedParticipant\x12J\n\x0cparticipants\x18\x05 \x03(\x0b\x32\x34.livekit.proto.ConnectCallback.ParticipantWithTracks\x1a\x89\x01\n\x15ParticipantWithTracks\x12\x34\n\x0bparticipant\x18\x01 \x01(\x0b\x32\x1f.livekit.proto.OwnedParticipant\x12:\n\x0cpublications\x18\x02 \x03(\x0b\x32$.livekit.proto.OwnedTrackPublicationB\x08\n\x06_error\"(\n\x11\x44isconnectRequest\x12\x13\n\x0broom_handle\x18\x01 \x01(\x04\"&\n\x12\x44isconnectResponse\x12\x10\n\x08\x61sync_id\x18\x01 \x01(\x04\"&\n\x12\x44isconnectCallback\x12\x10\n\x08\x61sync_id\x18\x01 \x01(\x04\"\x82\x01\n\x13PublishTrackRequest\x12 \n\x18local_participant_handle\x18\x01 \x01(\x04\x12\x14\n\x0ctrack_handle\x18\x02 \x01(\x04\x12\x33\n\x07options\x18\x03 \x01(\x0b\x32\".livekit.proto.TrackPublishOptions\"(\n\x14PublishTrackResponse\x12\x10\n\x08\x61sync_id\x18\x01 \x01(\x04\"\x81\x01\n\x14PublishTrackCallback\x12\x10\n\x08\x61sync_id\x18\x01 \x01(\x04\x12\x12\n\x05\x65rror\x18\x02 \x01(\tH\x00\x88\x01\x01\x12\x39\n\x0bpublication\x18\x03 \x01(\x0b\x32$.livekit.proto.OwnedTrackPublicationB\x08\n\x06_error\"g\n\x15UnpublishTrackRequest\x12 \n\x18local_participant_handle\x18\x01 \x01(\x04\x12\x11\n\ttrack_sid\x18\x02 \x01(\t\x12\x19\n\x11stop_on_unpublish\x18\x03 \x01(\x08\"*\n\x16UnpublishTrackResponse\x12\x10\n\x08\x61sync_id\x18\x01 \x01(\x04\"H\n\x16UnpublishTrackCallback\x12\x10\n\x08\x61sync_id\x18\x01 \x01(\x04\x12\x12\n\x05\x65rror\x18\x02 \x01(\tH\x00\x88\x01\x01\x42\x08\n\x06_error\"\xa1\x01\n\x12PublishDataRequest\x12 \n\x18local_participant_handle\x18\x01 \x01(\x04\x12\x10\n\x08\x64\x61ta_ptr\x18\x02 \x01(\x04\x12\x10\n\x08\x64\x61ta_len\x18\x03 \x01(\x04\x12+\n\x04kind\x18\x04 \x01(\x0e\x32\x1d.livekit.proto.DataPacketKind\x12\x18\n\x10\x64\x65stination_sids\x18\x05 \x03(\t\"\'\n\x13PublishDataResponse\x12\x10\n\x08\x61sync_id\x18\x01 \x01(\x04\"E\n\x13PublishDataCallback\x12\x10\n\x08\x61sync_id\x18\x01 \x01(\x04\x12\x12\n\x05\x65rror\x18\x02 \x01(\tH\x00\x88\x01\x01\x42\x08\n\x06_error\"P\n\x1aUpdateLocalMetadataRequest\x12 \n\x18local_participant_handle\x18\x01 \x01(\x04\x12\x10\n\x08metadata\x18\x02 \x01(\t\"/\n\x1bUpdateLocalMetadataResponse\x12\x10\n\x08\x61sync_id\x18\x01 \x01(\x04\"/\n\x1bUpdateLocalMetadataCallback\x12\x10\n\x08\x61sync_id\x18\x01 \x01(\x04\"H\n\x16UpdateLocalNameRequest\x12 \n\x18local_participant_handle\x18\x01 \x01(\x04\x12\x0c\n\x04name\x18\x02 \x01(\t\"+\n\x17UpdateLocalNameResponse\x12\x10\n\x08\x61sync_id\x18\x01 \x01(\x04\"+\n\x17UpdateLocalNameCallback\x12\x10\n\x08\x61sync_id\x18\x01 \x01(\x04\"E\n\x14SetSubscribedRequest\x12\x11\n\tsubscribe\x18\x01 \x01(\x08\x12\x1a\n\x12publication_handle\x18\x02 \x01(\x04\"\x17\n\x15SetSubscribedResponse\";\n\rVideoEncoding\x12\x13\n\x0bmax_bitrate\x18\x01 \x01(\x04\x12\x15\n\rmax_framerate\x18\x02 \x01(\x01\"$\n\rAudioEncoding\x12\x13\n\x0bmax_bitrate\x18\x01 \x01(\x04\"\x8a\x02\n\x13TrackPublishOptions\x12\x34\n\x0evideo_encoding\x18\x01 \x01(\x0b\x32\x1c.livekit.proto.VideoEncoding\x12\x34\n\x0e\x61udio_encoding\x18\x02 \x01(\x0b\x32\x1c.livekit.proto.AudioEncoding\x12.\n\x0bvideo_codec\x18\x03 \x01(\x0e\x32\x19.livekit.proto.VideoCodec\x12\x0b\n\x03\x64tx\x18\x04 \x01(\x08\x12\x0b\n\x03red\x18\x05 \x01(\x08\x12\x11\n\tsimulcast\x18\x06 \x01(\x08\x12*\n\x06source\x18\x07 \x01(\x0e\x32\x1a.livekit.proto.TrackSource\"=\n\tIceServer\x12\x0c\n\x04urls\x18\x01 \x03(\t\x12\x10\n\x08username\x18\x02 \x01(\t\x12\x10\n\x08password\x18\x03 \x01(\t\"\x84\x02\n\tRtcConfig\x12@\n\x12ice_transport_type\x18\x01 \x01(\x0e\x32\x1f.livekit.proto.IceTransportTypeH\x00\x88\x01\x01\x12P\n\x1a\x63ontinual_gathering_policy\x18\x02 \x01(\x0e\x32\'.livekit.proto.ContinualGatheringPolicyH\x01\x88\x01\x01\x12-\n\x0bice_servers\x18\x03 \x03(\x0b\x32\x18.livekit.proto.IceServerB\x15\n\x13_ice_transport_typeB\x1d\n\x1b_continual_gathering_policy\"\xca\x01\n\x0bRoomOptions\x12\x16\n\x0e\x61uto_subscribe\x18\x01 \x01(\x08\x12\x17\n\x0f\x61\x64\x61ptive_stream\x18\x02 \x01(\x08\x12\x10\n\x08\x64ynacast\x18\x03 \x01(\x08\x12-\n\x04\x65\x32\x65\x65\x18\x04 \x01(\x0b\x32\x1a.livekit.proto.E2eeOptionsH\x00\x88\x01\x01\x12\x31\n\nrtc_config\x18\x05 \x01(\x0b\x32\x18.livekit.proto.RtcConfigH\x01\x88\x01\x01\x42\x07\n\x05_e2eeB\r\n\x0b_rtc_config\"0\n\nBufferInfo\x12\x10\n\x08\x64\x61ta_ptr\x18\x01 \x01(\x04\x12\x10\n\x08\x64\x61ta_len\x18\x02 \x01(\x04\"e\n\x0bOwnedBuffer\x12-\n\x06handle\x18\x01 \x01(\x0b\x32\x1d.livekit.proto.FfiOwnedHandle\x12\'\n\x04\x64\x61ta\x18\x02 \x01(\x0b\x32\x19.livekit.proto.BufferInfo\"\xf3\x0b\n\tRoomEvent\x12\x13\n\x0broom_handle\x18\x01 \x01(\x04\x12\x44\n\x15participant_connected\x18\x02 \x01(\x0b\x32#.livekit.proto.ParticipantConnectedH\x00\x12J\n\x18participant_disconnected\x18\x03 \x01(\x0b\x32&.livekit.proto.ParticipantDisconnectedH\x00\x12\x43\n\x15local_track_published\x18\x04 \x01(\x0b\x32\".livekit.proto.LocalTrackPublishedH\x00\x12G\n\x17local_track_unpublished\x18\x05 \x01(\x0b\x32$.livekit.proto.LocalTrackUnpublishedH\x00\x12\x38\n\x0ftrack_published\x18\x06 \x01(\x0b\x32\x1d.livekit.proto.TrackPublishedH\x00\x12<\n\x11track_unpublished\x18\x07 \x01(\x0b\x32\x1f.livekit.proto.TrackUnpublishedH\x00\x12:\n\x10track_subscribed\x18\x08 \x01(\x0b\x32\x1e.livekit.proto.TrackSubscribedH\x00\x12>\n\x12track_unsubscribed\x18\t \x01(\x0b\x32 .livekit.proto.TrackUnsubscribedH\x00\x12K\n\x19track_subscription_failed\x18\n \x01(\x0b\x32&.livekit.proto.TrackSubscriptionFailedH\x00\x12\x30\n\x0btrack_muted\x18\x0b \x01(\x0b\x32\x19.livekit.proto.TrackMutedH\x00\x12\x34\n\rtrack_unmuted\x18\x0c \x01(\x0b\x32\x1b.livekit.proto.TrackUnmutedH\x00\x12G\n\x17\x61\x63tive_speakers_changed\x18\r \x01(\x0b\x32$.livekit.proto.ActiveSpeakersChangedH\x00\x12\x43\n\x15room_metadata_changed\x18\x0e \x01(\x0b\x32\".livekit.proto.RoomMetadataChangedH\x00\x12Q\n\x1cparticipant_metadata_changed\x18\x0f \x01(\x0b\x32).livekit.proto.ParticipantMetadataChangedH\x00\x12I\n\x18participant_name_changed\x18\x10 \x01(\x0b\x32%.livekit.proto.ParticipantNameChangedH\x00\x12M\n\x1a\x63onnection_quality_changed\x18\x11 \x01(\x0b\x32\'.livekit.proto.ConnectionQualityChangedH\x00\x12\x34\n\rdata_received\x18\x12 \x01(\x0b\x32\x1b.livekit.proto.DataReceivedH\x00\x12I\n\x18\x63onnection_state_changed\x18\x13 \x01(\x0b\x32%.livekit.proto.ConnectionStateChangedH\x00\x12\x33\n\x0c\x64isconnected\x18\x15 \x01(\x0b\x32\x1b.livekit.proto.DisconnectedH\x00\x12\x33\n\x0creconnecting\x18\x16 \x01(\x0b\x32\x1b.livekit.proto.ReconnectingH\x00\x12\x31\n\x0breconnected\x18\x17 \x01(\x0b\x32\x1a.livekit.proto.ReconnectedH\x00\x12=\n\x12\x65\x32\x65\x65_state_changed\x18\x18 \x01(\x0b\x32\x1f.livekit.proto.E2eeStateChangedH\x00\x12%\n\x03\x65os\x18\x19 \x01(\x0b\x32\x16.livekit.proto.RoomEOSH\x00\x42\t\n\x07message\"7\n\x08RoomInfo\x12\x0b\n\x03sid\x18\x01 \x01(\t\x12\x0c\n\x04name\x18\x02 \x01(\t\x12\x10\n\x08metadata\x18\x03 \x01(\t\"a\n\tOwnedRoom\x12-\n\x06handle\x18\x01 \x01(\x0b\x32\x1d.livekit.proto.FfiOwnedHandle\x12%\n\x04info\x18\x02 \x01(\x0b\x32\x17.livekit.proto.RoomInfo\"E\n\x14ParticipantConnected\x12-\n\x04info\x18\x01 \x01(\x0b\x32\x1f.livekit.proto.OwnedParticipant\"2\n\x17ParticipantDisconnected\x12\x17\n\x0fparticipant_sid\x18\x01 \x01(\t\"(\n\x13LocalTrackPublished\x12\x11\n\ttrack_sid\x18\x01 \x01(\t\"0\n\x15LocalTrackUnpublished\x12\x17\n\x0fpublication_sid\x18\x01 \x01(\t\"d\n\x0eTrackPublished\x12\x17\n\x0fparticipant_sid\x18\x01 \x01(\t\x12\x39\n\x0bpublication\x18\x02 \x01(\x0b\x32$.livekit.proto.OwnedTrackPublication\"D\n\x10TrackUnpublished\x12\x17\n\x0fparticipant_sid\x18\x01 \x01(\t\x12\x17\n\x0fpublication_sid\x18\x02 \x01(\t\"T\n\x0fTrackSubscribed\x12\x17\n\x0fparticipant_sid\x18\x01 \x01(\t\x12(\n\x05track\x18\x02 \x01(\x0b\x32\x19.livekit.proto.OwnedTrack\"?\n\x11TrackUnsubscribed\x12\x17\n\x0fparticipant_sid\x18\x01 \x01(\t\x12\x11\n\ttrack_sid\x18\x02 \x01(\t\"T\n\x17TrackSubscriptionFailed\x12\x17\n\x0fparticipant_sid\x18\x01 \x01(\t\x12\x11\n\ttrack_sid\x18\x02 \x01(\t\x12\r\n\x05\x65rror\x18\x03 \x01(\t\"8\n\nTrackMuted\x12\x17\n\x0fparticipant_sid\x18\x01 \x01(\t\x12\x11\n\ttrack_sid\x18\x02 \x01(\t\":\n\x0cTrackUnmuted\x12\x17\n\x0fparticipant_sid\x18\x01 \x01(\t\x12\x11\n\ttrack_sid\x18\x02 \x01(\t\"Z\n\x10\x45\x32\x65\x65StateChanged\x12\x17\n\x0fparticipant_sid\x18\x01 \x01(\t\x12-\n\x05state\x18\x02 \x01(\x0e\x32\x1e.livekit.proto.EncryptionState\"1\n\x15\x41\x63tiveSpeakersChanged\x12\x18\n\x10participant_sids\x18\x01 \x03(\t\"\'\n\x13RoomMetadataChanged\x12\x10\n\x08metadata\x18\x01 \x01(\t\"G\n\x1aParticipantMetadataChanged\x12\x17\n\x0fparticipant_sid\x18\x01 \x01(\t\x12\x10\n\x08metadata\x18\x02 \x01(\t\"?\n\x16ParticipantNameChanged\x12\x17\n\x0fparticipant_sid\x18\x01 \x01(\t\x12\x0c\n\x04name\x18\x02 \x01(\t\"f\n\x18\x43onnectionQualityChanged\x12\x17\n\x0fparticipant_sid\x18\x01 \x01(\t\x12\x31\n\x07quality\x18\x02 \x01(\x0e\x32 .livekit.proto.ConnectionQuality\"\x97\x01\n\x0c\x44\x61taReceived\x12(\n\x04\x64\x61ta\x18\x01 \x01(\x0b\x32\x1a.livekit.proto.OwnedBuffer\x12\x1c\n\x0fparticipant_sid\x18\x02 \x01(\tH\x00\x88\x01\x01\x12+\n\x04kind\x18\x03 \x01(\x0e\x32\x1d.livekit.proto.DataPacketKindB\x12\n\x10_participant_sid\"G\n\x16\x43onnectionStateChanged\x12-\n\x05state\x18\x01 \x01(\x0e\x32\x1e.livekit.proto.ConnectionState\"\x0b\n\tConnected\"\x0e\n\x0c\x44isconnected\"\x0e\n\x0cReconnecting\"\r\n\x0bReconnected\"\t\n\x07RoomEOS*P\n\x10IceTransportType\x12\x13\n\x0fTRANSPORT_RELAY\x10\x00\x12\x14\n\x10TRANSPORT_NOHOST\x10\x01\x12\x11\n\rTRANSPORT_ALL\x10\x02*C\n\x18\x43ontinualGatheringPolicy\x12\x0f\n\x0bGATHER_ONCE\x10\x00\x12\x16\n\x12GATHER_CONTINUALLY\x10\x01*N\n\x11\x43onnectionQuality\x12\x10\n\x0cQUALITY_POOR\x10\x00\x12\x10\n\x0cQUALITY_GOOD\x10\x01\x12\x15\n\x11QUALITY_EXCELLENT\x10\x02*S\n\x0f\x43onnectionState\x12\x15\n\x11\x43ONN_DISCONNECTED\x10\x00\x12\x12\n\x0e\x43ONN_CONNECTED\x10\x01\x12\x15\n\x11\x43ONN_RECONNECTING\x10\x02*3\n\x0e\x44\x61taPacketKind\x12\x0e\n\nKIND_LOSSY\x10\x00\x12\x11\n\rKIND_RELIABLE\x10\x01\x42\x10\xaa\x02\rLiveKit.Protob\x06proto3') _globals = globals() _builder.BuildMessageAndEnumDescriptors(DESCRIPTOR, _globals) @@ -27,16 +27,16 @@ DESCRIPTOR._options = None DESCRIPTOR._serialized_options = b'\252\002\rLiveKit.Proto' - _globals['_ICETRANSPORTTYPE']._serialized_start=5436 - _globals['_ICETRANSPORTTYPE']._serialized_end=5516 - _globals['_CONTINUALGATHERINGPOLICY']._serialized_start=5518 - _globals['_CONTINUALGATHERINGPOLICY']._serialized_end=5585 - _globals['_CONNECTIONQUALITY']._serialized_start=5587 - _globals['_CONNECTIONQUALITY']._serialized_end=5665 - _globals['_CONNECTIONSTATE']._serialized_start=5667 - _globals['_CONNECTIONSTATE']._serialized_end=5750 - _globals['_DATAPACKETKIND']._serialized_start=5752 - _globals['_DATAPACKETKIND']._serialized_end=5803 + _globals['_ICETRANSPORTTYPE']._serialized_start=6186 + _globals['_ICETRANSPORTTYPE']._serialized_end=6266 + _globals['_CONTINUALGATHERINGPOLICY']._serialized_start=6268 + _globals['_CONTINUALGATHERINGPOLICY']._serialized_end=6335 + _globals['_CONNECTIONQUALITY']._serialized_start=6337 + _globals['_CONNECTIONQUALITY']._serialized_end=6415 + _globals['_CONNECTIONSTATE']._serialized_start=6417 + _globals['_CONNECTIONSTATE']._serialized_end=6500 + _globals['_DATAPACKETKIND']._serialized_start=6502 + _globals['_DATAPACKETKIND']._serialized_end=6553 _globals['_CONNECTREQUEST']._serialized_start=106 _globals['_CONNECTREQUEST']._serialized_end=195 _globals['_CONNECTRESPONSE']._serialized_start=197 @@ -69,72 +69,90 @@ _globals['_PUBLISHDATARESPONSE']._serialized_end=1473 _globals['_PUBLISHDATACALLBACK']._serialized_start=1475 _globals['_PUBLISHDATACALLBACK']._serialized_end=1544 - _globals['_SETSUBSCRIBEDREQUEST']._serialized_start=1546 - _globals['_SETSUBSCRIBEDREQUEST']._serialized_end=1615 - _globals['_SETSUBSCRIBEDRESPONSE']._serialized_start=1617 - _globals['_SETSUBSCRIBEDRESPONSE']._serialized_end=1640 - _globals['_VIDEOENCODING']._serialized_start=1642 - _globals['_VIDEOENCODING']._serialized_end=1701 - _globals['_AUDIOENCODING']._serialized_start=1703 - _globals['_AUDIOENCODING']._serialized_end=1739 - _globals['_TRACKPUBLISHOPTIONS']._serialized_start=1742 - _globals['_TRACKPUBLISHOPTIONS']._serialized_end=2008 - _globals['_ICESERVER']._serialized_start=2010 - _globals['_ICESERVER']._serialized_end=2071 - _globals['_RTCCONFIG']._serialized_start=2074 - _globals['_RTCCONFIG']._serialized_end=2334 - _globals['_ROOMOPTIONS']._serialized_start=2337 - _globals['_ROOMOPTIONS']._serialized_end=2539 - _globals['_BUFFERINFO']._serialized_start=2541 - _globals['_BUFFERINFO']._serialized_end=2589 - _globals['_OWNEDBUFFER']._serialized_start=2591 - _globals['_OWNEDBUFFER']._serialized_end=2692 - _globals['_ROOMEVENT']._serialized_start=2695 - _globals['_ROOMEVENT']._serialized_end=3991 - _globals['_ROOMINFO']._serialized_start=3993 - _globals['_ROOMINFO']._serialized_end=4048 - _globals['_OWNEDROOM']._serialized_start=4050 - _globals['_OWNEDROOM']._serialized_end=4147 - _globals['_PARTICIPANTCONNECTED']._serialized_start=4149 - _globals['_PARTICIPANTCONNECTED']._serialized_end=4218 - _globals['_PARTICIPANTDISCONNECTED']._serialized_start=4220 - _globals['_PARTICIPANTDISCONNECTED']._serialized_end=4270 - _globals['_LOCALTRACKPUBLISHED']._serialized_start=4272 - _globals['_LOCALTRACKPUBLISHED']._serialized_end=4312 - _globals['_LOCALTRACKUNPUBLISHED']._serialized_start=4314 - _globals['_LOCALTRACKUNPUBLISHED']._serialized_end=4362 - _globals['_TRACKPUBLISHED']._serialized_start=4364 - _globals['_TRACKPUBLISHED']._serialized_end=4464 - _globals['_TRACKUNPUBLISHED']._serialized_start=4466 - _globals['_TRACKUNPUBLISHED']._serialized_end=4534 - _globals['_TRACKSUBSCRIBED']._serialized_start=4536 - _globals['_TRACKSUBSCRIBED']._serialized_end=4620 - _globals['_TRACKUNSUBSCRIBED']._serialized_start=4622 - _globals['_TRACKUNSUBSCRIBED']._serialized_end=4685 - _globals['_TRACKSUBSCRIPTIONFAILED']._serialized_start=4687 - _globals['_TRACKSUBSCRIPTIONFAILED']._serialized_end=4771 - _globals['_TRACKMUTED']._serialized_start=4773 - _globals['_TRACKMUTED']._serialized_end=4829 - _globals['_TRACKUNMUTED']._serialized_start=4831 - _globals['_TRACKUNMUTED']._serialized_end=4889 - _globals['_E2EESTATECHANGED']._serialized_start=4891 - _globals['_E2EESTATECHANGED']._serialized_end=4981 - _globals['_ACTIVESPEAKERSCHANGED']._serialized_start=4983 - _globals['_ACTIVESPEAKERSCHANGED']._serialized_end=5032 - _globals['_CONNECTIONQUALITYCHANGED']._serialized_start=5034 - _globals['_CONNECTIONQUALITYCHANGED']._serialized_end=5136 - _globals['_DATARECEIVED']._serialized_start=5139 - _globals['_DATARECEIVED']._serialized_end=5290 - _globals['_CONNECTIONSTATECHANGED']._serialized_start=5292 - _globals['_CONNECTIONSTATECHANGED']._serialized_end=5363 - _globals['_CONNECTED']._serialized_start=5365 - _globals['_CONNECTED']._serialized_end=5376 - _globals['_DISCONNECTED']._serialized_start=5378 - _globals['_DISCONNECTED']._serialized_end=5392 - _globals['_RECONNECTING']._serialized_start=5394 - _globals['_RECONNECTING']._serialized_end=5408 - _globals['_RECONNECTED']._serialized_start=5410 - _globals['_RECONNECTED']._serialized_end=5423 - _globals['_ROOMEOS']._serialized_start=5425 - _globals['_ROOMEOS']._serialized_end=5434 + _globals['_UPDATELOCALMETADATAREQUEST']._serialized_start=1546 + _globals['_UPDATELOCALMETADATAREQUEST']._serialized_end=1626 + _globals['_UPDATELOCALMETADATARESPONSE']._serialized_start=1628 + _globals['_UPDATELOCALMETADATARESPONSE']._serialized_end=1675 + _globals['_UPDATELOCALMETADATACALLBACK']._serialized_start=1677 + _globals['_UPDATELOCALMETADATACALLBACK']._serialized_end=1724 + _globals['_UPDATELOCALNAMEREQUEST']._serialized_start=1726 + _globals['_UPDATELOCALNAMEREQUEST']._serialized_end=1798 + _globals['_UPDATELOCALNAMERESPONSE']._serialized_start=1800 + _globals['_UPDATELOCALNAMERESPONSE']._serialized_end=1843 + _globals['_UPDATELOCALNAMECALLBACK']._serialized_start=1845 + _globals['_UPDATELOCALNAMECALLBACK']._serialized_end=1888 + _globals['_SETSUBSCRIBEDREQUEST']._serialized_start=1890 + _globals['_SETSUBSCRIBEDREQUEST']._serialized_end=1959 + _globals['_SETSUBSCRIBEDRESPONSE']._serialized_start=1961 + _globals['_SETSUBSCRIBEDRESPONSE']._serialized_end=1984 + _globals['_VIDEOENCODING']._serialized_start=1986 + _globals['_VIDEOENCODING']._serialized_end=2045 + _globals['_AUDIOENCODING']._serialized_start=2047 + _globals['_AUDIOENCODING']._serialized_end=2083 + _globals['_TRACKPUBLISHOPTIONS']._serialized_start=2086 + _globals['_TRACKPUBLISHOPTIONS']._serialized_end=2352 + _globals['_ICESERVER']._serialized_start=2354 + _globals['_ICESERVER']._serialized_end=2415 + _globals['_RTCCONFIG']._serialized_start=2418 + _globals['_RTCCONFIG']._serialized_end=2678 + _globals['_ROOMOPTIONS']._serialized_start=2681 + _globals['_ROOMOPTIONS']._serialized_end=2883 + _globals['_BUFFERINFO']._serialized_start=2885 + _globals['_BUFFERINFO']._serialized_end=2933 + _globals['_OWNEDBUFFER']._serialized_start=2935 + _globals['_OWNEDBUFFER']._serialized_end=3036 + _globals['_ROOMEVENT']._serialized_start=3039 + _globals['_ROOMEVENT']._serialized_end=4562 + _globals['_ROOMINFO']._serialized_start=4564 + _globals['_ROOMINFO']._serialized_end=4619 + _globals['_OWNEDROOM']._serialized_start=4621 + _globals['_OWNEDROOM']._serialized_end=4718 + _globals['_PARTICIPANTCONNECTED']._serialized_start=4720 + _globals['_PARTICIPANTCONNECTED']._serialized_end=4789 + _globals['_PARTICIPANTDISCONNECTED']._serialized_start=4791 + _globals['_PARTICIPANTDISCONNECTED']._serialized_end=4841 + _globals['_LOCALTRACKPUBLISHED']._serialized_start=4843 + _globals['_LOCALTRACKPUBLISHED']._serialized_end=4883 + _globals['_LOCALTRACKUNPUBLISHED']._serialized_start=4885 + _globals['_LOCALTRACKUNPUBLISHED']._serialized_end=4933 + _globals['_TRACKPUBLISHED']._serialized_start=4935 + _globals['_TRACKPUBLISHED']._serialized_end=5035 + _globals['_TRACKUNPUBLISHED']._serialized_start=5037 + _globals['_TRACKUNPUBLISHED']._serialized_end=5105 + _globals['_TRACKSUBSCRIBED']._serialized_start=5107 + _globals['_TRACKSUBSCRIBED']._serialized_end=5191 + _globals['_TRACKUNSUBSCRIBED']._serialized_start=5193 + _globals['_TRACKUNSUBSCRIBED']._serialized_end=5256 + _globals['_TRACKSUBSCRIPTIONFAILED']._serialized_start=5258 + _globals['_TRACKSUBSCRIPTIONFAILED']._serialized_end=5342 + _globals['_TRACKMUTED']._serialized_start=5344 + _globals['_TRACKMUTED']._serialized_end=5400 + _globals['_TRACKUNMUTED']._serialized_start=5402 + _globals['_TRACKUNMUTED']._serialized_end=5460 + _globals['_E2EESTATECHANGED']._serialized_start=5462 + _globals['_E2EESTATECHANGED']._serialized_end=5552 + _globals['_ACTIVESPEAKERSCHANGED']._serialized_start=5554 + _globals['_ACTIVESPEAKERSCHANGED']._serialized_end=5603 + _globals['_ROOMMETADATACHANGED']._serialized_start=5605 + _globals['_ROOMMETADATACHANGED']._serialized_end=5644 + _globals['_PARTICIPANTMETADATACHANGED']._serialized_start=5646 + _globals['_PARTICIPANTMETADATACHANGED']._serialized_end=5717 + _globals['_PARTICIPANTNAMECHANGED']._serialized_start=5719 + _globals['_PARTICIPANTNAMECHANGED']._serialized_end=5782 + _globals['_CONNECTIONQUALITYCHANGED']._serialized_start=5784 + _globals['_CONNECTIONQUALITYCHANGED']._serialized_end=5886 + _globals['_DATARECEIVED']._serialized_start=5889 + _globals['_DATARECEIVED']._serialized_end=6040 + _globals['_CONNECTIONSTATECHANGED']._serialized_start=6042 + _globals['_CONNECTIONSTATECHANGED']._serialized_end=6113 + _globals['_CONNECTED']._serialized_start=6115 + _globals['_CONNECTED']._serialized_end=6126 + _globals['_DISCONNECTED']._serialized_start=6128 + _globals['_DISCONNECTED']._serialized_end=6142 + _globals['_RECONNECTING']._serialized_start=6144 + _globals['_RECONNECTING']._serialized_end=6158 + _globals['_RECONNECTED']._serialized_start=6160 + _globals['_RECONNECTED']._serialized_end=6173 + _globals['_ROOMEOS']._serialized_start=6175 + _globals['_ROOMEOS']._serialized_end=6184 # @@protoc_insertion_point(module_scope) diff --git a/livekit/_proto/room_pb2.pyi b/livekit/_proto/room_pb2.pyi index fb632972..f7777fb0 100644 --- a/livekit/_proto/room_pb2.pyi +++ b/livekit/_proto/room_pb2.pyi @@ -449,6 +449,106 @@ class PublishDataCallback(google.protobuf.message.Message): global___PublishDataCallback = PublishDataCallback +@typing_extensions.final +class UpdateLocalMetadataRequest(google.protobuf.message.Message): + """Change the local participant's metadata""" + + DESCRIPTOR: google.protobuf.descriptor.Descriptor + + LOCAL_PARTICIPANT_HANDLE_FIELD_NUMBER: builtins.int + METADATA_FIELD_NUMBER: builtins.int + local_participant_handle: builtins.int + metadata: builtins.str + def __init__( + self, + *, + local_participant_handle: builtins.int = ..., + metadata: builtins.str = ..., + ) -> None: ... + def ClearField(self, field_name: typing_extensions.Literal["local_participant_handle", b"local_participant_handle", "metadata", b"metadata"]) -> None: ... + +global___UpdateLocalMetadataRequest = UpdateLocalMetadataRequest + +@typing_extensions.final +class UpdateLocalMetadataResponse(google.protobuf.message.Message): + DESCRIPTOR: google.protobuf.descriptor.Descriptor + + ASYNC_ID_FIELD_NUMBER: builtins.int + async_id: builtins.int + def __init__( + self, + *, + async_id: builtins.int = ..., + ) -> None: ... + def ClearField(self, field_name: typing_extensions.Literal["async_id", b"async_id"]) -> None: ... + +global___UpdateLocalMetadataResponse = UpdateLocalMetadataResponse + +@typing_extensions.final +class UpdateLocalMetadataCallback(google.protobuf.message.Message): + DESCRIPTOR: google.protobuf.descriptor.Descriptor + + ASYNC_ID_FIELD_NUMBER: builtins.int + async_id: builtins.int + def __init__( + self, + *, + async_id: builtins.int = ..., + ) -> None: ... + def ClearField(self, field_name: typing_extensions.Literal["async_id", b"async_id"]) -> None: ... + +global___UpdateLocalMetadataCallback = UpdateLocalMetadataCallback + +@typing_extensions.final +class UpdateLocalNameRequest(google.protobuf.message.Message): + """Change the local participant's name""" + + DESCRIPTOR: google.protobuf.descriptor.Descriptor + + LOCAL_PARTICIPANT_HANDLE_FIELD_NUMBER: builtins.int + NAME_FIELD_NUMBER: builtins.int + local_participant_handle: builtins.int + name: builtins.str + def __init__( + self, + *, + local_participant_handle: builtins.int = ..., + name: builtins.str = ..., + ) -> None: ... + def ClearField(self, field_name: typing_extensions.Literal["local_participant_handle", b"local_participant_handle", "name", b"name"]) -> None: ... + +global___UpdateLocalNameRequest = UpdateLocalNameRequest + +@typing_extensions.final +class UpdateLocalNameResponse(google.protobuf.message.Message): + DESCRIPTOR: google.protobuf.descriptor.Descriptor + + ASYNC_ID_FIELD_NUMBER: builtins.int + async_id: builtins.int + def __init__( + self, + *, + async_id: builtins.int = ..., + ) -> None: ... + def ClearField(self, field_name: typing_extensions.Literal["async_id", b"async_id"]) -> None: ... + +global___UpdateLocalNameResponse = UpdateLocalNameResponse + +@typing_extensions.final +class UpdateLocalNameCallback(google.protobuf.message.Message): + DESCRIPTOR: google.protobuf.descriptor.Descriptor + + ASYNC_ID_FIELD_NUMBER: builtins.int + async_id: builtins.int + def __init__( + self, + *, + async_id: builtins.int = ..., + ) -> None: ... + def ClearField(self, field_name: typing_extensions.Literal["async_id", b"async_id"]) -> None: ... + +global___UpdateLocalNameCallback = UpdateLocalNameCallback + @typing_extensions.final class SetSubscribedRequest(google.protobuf.message.Message): """Change the "desire" to subs2ribe to a track""" @@ -694,6 +794,9 @@ class RoomEvent(google.protobuf.message.Message): TRACK_MUTED_FIELD_NUMBER: builtins.int TRACK_UNMUTED_FIELD_NUMBER: builtins.int ACTIVE_SPEAKERS_CHANGED_FIELD_NUMBER: builtins.int + ROOM_METADATA_CHANGED_FIELD_NUMBER: builtins.int + PARTICIPANT_METADATA_CHANGED_FIELD_NUMBER: builtins.int + PARTICIPANT_NAME_CHANGED_FIELD_NUMBER: builtins.int CONNECTION_QUALITY_CHANGED_FIELD_NUMBER: builtins.int DATA_RECEIVED_FIELD_NUMBER: builtins.int CONNECTION_STATE_CHANGED_FIELD_NUMBER: builtins.int @@ -728,6 +831,12 @@ class RoomEvent(google.protobuf.message.Message): @property def active_speakers_changed(self) -> global___ActiveSpeakersChanged: ... @property + def room_metadata_changed(self) -> global___RoomMetadataChanged: ... + @property + def participant_metadata_changed(self) -> global___ParticipantMetadataChanged: ... + @property + def participant_name_changed(self) -> global___ParticipantNameChanged: ... + @property def connection_quality_changed(self) -> global___ConnectionQualityChanged: ... @property def data_received(self) -> global___DataReceived: ... @@ -735,7 +844,7 @@ class RoomEvent(google.protobuf.message.Message): def connection_state_changed(self) -> global___ConnectionStateChanged: ... @property def disconnected(self) -> global___Disconnected: - """Connected connected = 17;""" + """Connected connected = 20;""" @property def reconnecting(self) -> global___Reconnecting: ... @property @@ -761,6 +870,9 @@ class RoomEvent(google.protobuf.message.Message): track_muted: global___TrackMuted | None = ..., track_unmuted: global___TrackUnmuted | None = ..., active_speakers_changed: global___ActiveSpeakersChanged | None = ..., + room_metadata_changed: global___RoomMetadataChanged | None = ..., + participant_metadata_changed: global___ParticipantMetadataChanged | None = ..., + participant_name_changed: global___ParticipantNameChanged | None = ..., connection_quality_changed: global___ConnectionQualityChanged | None = ..., data_received: global___DataReceived | None = ..., connection_state_changed: global___ConnectionStateChanged | None = ..., @@ -770,9 +882,9 @@ class RoomEvent(google.protobuf.message.Message): e2ee_state_changed: global___E2eeStateChanged | None = ..., eos: global___RoomEOS | None = ..., ) -> None: ... - def HasField(self, field_name: typing_extensions.Literal["active_speakers_changed", b"active_speakers_changed", "connection_quality_changed", b"connection_quality_changed", "connection_state_changed", b"connection_state_changed", "data_received", b"data_received", "disconnected", b"disconnected", "e2ee_state_changed", b"e2ee_state_changed", "eos", b"eos", "local_track_published", b"local_track_published", "local_track_unpublished", b"local_track_unpublished", "message", b"message", "participant_connected", b"participant_connected", "participant_disconnected", b"participant_disconnected", "reconnected", b"reconnected", "reconnecting", b"reconnecting", "track_muted", b"track_muted", "track_published", b"track_published", "track_subscribed", b"track_subscribed", "track_subscription_failed", b"track_subscription_failed", "track_unmuted", b"track_unmuted", "track_unpublished", b"track_unpublished", "track_unsubscribed", b"track_unsubscribed"]) -> builtins.bool: ... - def ClearField(self, field_name: typing_extensions.Literal["active_speakers_changed", b"active_speakers_changed", "connection_quality_changed", b"connection_quality_changed", "connection_state_changed", b"connection_state_changed", "data_received", b"data_received", "disconnected", b"disconnected", "e2ee_state_changed", b"e2ee_state_changed", "eos", b"eos", "local_track_published", b"local_track_published", "local_track_unpublished", b"local_track_unpublished", "message", b"message", "participant_connected", b"participant_connected", "participant_disconnected", b"participant_disconnected", "reconnected", b"reconnected", "reconnecting", b"reconnecting", "room_handle", b"room_handle", "track_muted", b"track_muted", "track_published", b"track_published", "track_subscribed", b"track_subscribed", "track_subscription_failed", b"track_subscription_failed", "track_unmuted", b"track_unmuted", "track_unpublished", b"track_unpublished", "track_unsubscribed", b"track_unsubscribed"]) -> None: ... - def WhichOneof(self, oneof_group: typing_extensions.Literal["message", b"message"]) -> typing_extensions.Literal["participant_connected", "participant_disconnected", "local_track_published", "local_track_unpublished", "track_published", "track_unpublished", "track_subscribed", "track_unsubscribed", "track_subscription_failed", "track_muted", "track_unmuted", "active_speakers_changed", "connection_quality_changed", "data_received", "connection_state_changed", "disconnected", "reconnecting", "reconnected", "e2ee_state_changed", "eos"] | None: ... + def HasField(self, field_name: typing_extensions.Literal["active_speakers_changed", b"active_speakers_changed", "connection_quality_changed", b"connection_quality_changed", "connection_state_changed", b"connection_state_changed", "data_received", b"data_received", "disconnected", b"disconnected", "e2ee_state_changed", b"e2ee_state_changed", "eos", b"eos", "local_track_published", b"local_track_published", "local_track_unpublished", b"local_track_unpublished", "message", b"message", "participant_connected", b"participant_connected", "participant_disconnected", b"participant_disconnected", "participant_metadata_changed", b"participant_metadata_changed", "participant_name_changed", b"participant_name_changed", "reconnected", b"reconnected", "reconnecting", b"reconnecting", "room_metadata_changed", b"room_metadata_changed", "track_muted", b"track_muted", "track_published", b"track_published", "track_subscribed", b"track_subscribed", "track_subscription_failed", b"track_subscription_failed", "track_unmuted", b"track_unmuted", "track_unpublished", b"track_unpublished", "track_unsubscribed", b"track_unsubscribed"]) -> builtins.bool: ... + def ClearField(self, field_name: typing_extensions.Literal["active_speakers_changed", b"active_speakers_changed", "connection_quality_changed", b"connection_quality_changed", "connection_state_changed", b"connection_state_changed", "data_received", b"data_received", "disconnected", b"disconnected", "e2ee_state_changed", b"e2ee_state_changed", "eos", b"eos", "local_track_published", b"local_track_published", "local_track_unpublished", b"local_track_unpublished", "message", b"message", "participant_connected", b"participant_connected", "participant_disconnected", b"participant_disconnected", "participant_metadata_changed", b"participant_metadata_changed", "participant_name_changed", b"participant_name_changed", "reconnected", b"reconnected", "reconnecting", b"reconnecting", "room_handle", b"room_handle", "room_metadata_changed", b"room_metadata_changed", "track_muted", b"track_muted", "track_published", b"track_published", "track_subscribed", b"track_subscribed", "track_subscription_failed", b"track_subscription_failed", "track_unmuted", b"track_unmuted", "track_unpublished", b"track_unpublished", "track_unsubscribed", b"track_unsubscribed"]) -> None: ... + def WhichOneof(self, oneof_group: typing_extensions.Literal["message", b"message"]) -> typing_extensions.Literal["participant_connected", "participant_disconnected", "local_track_published", "local_track_unpublished", "track_published", "track_unpublished", "track_subscribed", "track_unsubscribed", "track_subscription_failed", "track_muted", "track_unmuted", "active_speakers_changed", "room_metadata_changed", "participant_metadata_changed", "participant_name_changed", "connection_quality_changed", "data_received", "connection_state_changed", "disconnected", "reconnecting", "reconnected", "e2ee_state_changed", "eos"] | None: ... global___RoomEvent = RoomEvent @@ -1056,6 +1168,57 @@ class ActiveSpeakersChanged(google.protobuf.message.Message): global___ActiveSpeakersChanged = ActiveSpeakersChanged +@typing_extensions.final +class RoomMetadataChanged(google.protobuf.message.Message): + DESCRIPTOR: google.protobuf.descriptor.Descriptor + + METADATA_FIELD_NUMBER: builtins.int + metadata: builtins.str + def __init__( + self, + *, + metadata: builtins.str = ..., + ) -> None: ... + def ClearField(self, field_name: typing_extensions.Literal["metadata", b"metadata"]) -> None: ... + +global___RoomMetadataChanged = RoomMetadataChanged + +@typing_extensions.final +class ParticipantMetadataChanged(google.protobuf.message.Message): + DESCRIPTOR: google.protobuf.descriptor.Descriptor + + PARTICIPANT_SID_FIELD_NUMBER: builtins.int + METADATA_FIELD_NUMBER: builtins.int + participant_sid: builtins.str + metadata: builtins.str + def __init__( + self, + *, + participant_sid: builtins.str = ..., + metadata: builtins.str = ..., + ) -> None: ... + def ClearField(self, field_name: typing_extensions.Literal["metadata", b"metadata", "participant_sid", b"participant_sid"]) -> None: ... + +global___ParticipantMetadataChanged = ParticipantMetadataChanged + +@typing_extensions.final +class ParticipantNameChanged(google.protobuf.message.Message): + DESCRIPTOR: google.protobuf.descriptor.Descriptor + + PARTICIPANT_SID_FIELD_NUMBER: builtins.int + NAME_FIELD_NUMBER: builtins.int + participant_sid: builtins.str + name: builtins.str + def __init__( + self, + *, + participant_sid: builtins.str = ..., + name: builtins.str = ..., + ) -> None: ... + def ClearField(self, field_name: typing_extensions.Literal["name", b"name", "participant_sid", b"participant_sid"]) -> None: ... + +global___ParticipantNameChanged = ParticipantNameChanged + @typing_extensions.final class ConnectionQualityChanged(google.protobuf.message.Message): DESCRIPTOR: google.protobuf.descriptor.Descriptor diff --git a/livekit/participant.py b/livekit/participant.py index feb64925..7ef4b2be 100644 --- a/livekit/participant.py +++ b/livekit/participant.py @@ -103,17 +103,43 @@ async def publish_data(self, req.publish_data.destination_sids.extend(sids) try: - queue = self._room_queue.subscribe() + queue = ffi_client.queue.subscribe() resp = ffi_client.request(req) cb = await queue.wait_for(lambda e: e.publish_data.async_id == resp.publish_data.async_id) - queue.task_done() finally: - self._room_queue.unsubscribe(queue) + ffi_client.queue.unsubscribe(queue) if cb.publish_data.error: raise PublishDataError(cb.publish_data.error) + async def update_metadata(self, metadata: str) -> None: + req = proto_ffi.FfiRequest() + req.update_local_metadata.local_participant_handle = self._ffi_handle.handle + req.update_local_metadata.metadata = metadata + + try: + queue = ffi_client.queue.subscribe() + resp = ffi_client.request(req) + cb = await queue.wait_for(lambda e: e.update_local_metadata.async_id == + resp.update_local_metadata.async_id) + finally: + ffi_client.queue.unsubscribe(queue) + + async def update_name(self, name: str) -> None: + req = proto_ffi.FfiRequest() + req.update_local_name.local_participant_handle = self._ffi_handle.handle + req.update_local_name.name = name + + try: + queue = ffi_client.queue.subscribe() + resp = ffi_client.request(req) + cb = await queue.wait_for(lambda e: e.update_local_name.async_id == + resp.update_local_name.async_id) + finally: + ffi_client.queue.unsubscribe(queue) + + async def publish_track(self, track: Track, options: TrackPublishOptions) \ -> TrackPublication: if not isinstance(track, LocalAudioTrack) \ diff --git a/livekit/room.py b/livekit/room.py index fd7962b0..1eec8a05 100644 --- a/livekit/room.py +++ b/livekit/room.py @@ -35,9 +35,9 @@ @dataclass class RtcConfiguration: - ice_transport_type: proto_room.IceTransportType = \ + ice_transport_type: proto_room.IceTransportType.ValueType = \ proto_room.IceTransportType.TRANSPORT_ALL - continual_gathering_policy: proto_room.ContinualGatheringPolicy = \ + continual_gathering_policy: proto_room.ContinualGatheringPolicy.ValueType = \ proto_room.ContinualGatheringPolicy.GATHER_CONTINUALLY ice_servers: list[proto_room.IceServer] = field(default_factory=list) @@ -180,10 +180,10 @@ async def _listen_task(self) -> None: try: self._on_room_event(event.room_event) - except Exception as e: - logging.error( + except Exception: + logging.exception( 'error running user callback for %s: %s', - event.room_event.WhichOneof('message'), e) + event.room_event.WhichOneof('message'), event.room_event) # wait for the subscribers to process the event # before processing the next one @@ -274,12 +274,29 @@ def _on_room_event(self, event: proto_room.RoomEvent): speakers.append(self._retrieve_participant(sid)) self.emit('active_speakers_changed', speakers) + elif which == 'room_metadata_changed': + old_metadata = self.metadata + self._info.metadata = event.room_metadata_changed.metadata + self.emit('room_metadata_changed', old_metadata, self.metadata) + elif which == 'participant_metadata_changed': + sid = event.participant_metadata_changed.participant_sid + participant = self._retrieve_participant(sid) + old_metadata = participant.metadata + participant._info.metadata = event.participant_metadata_changed.metadata + self.emit('participant_metadata_changed', + participant, old_metadata, participant.metadata) + elif which == 'participant_name_changed': + sid = event.participant_name_changed.participant_sid + participant = self._retrieve_participant(sid) + old_name = participant.name + participant._info.name = event.participant_name_changed.name + self.emit('participant_name_changed', + participant, old_name, participant.name) elif which == 'connection_quality_changed': sid = event.connection_quality_changed.participant_sid - p = self._retrieve_participant(sid) - + participant = self._retrieve_participant(sid) self.emit('connection_quality_changed', - p, event.connection_quality_changed.quality) + participant, event.connection_quality_changed.quality) elif which == 'data_received': rparticipant = self.participants[event.data_received.participant_sid] owned_buffer_info = event.data_received.data diff --git a/rust-sdks b/rust-sdks new file mode 160000 index 00000000..ee6e159c --- /dev/null +++ b/rust-sdks @@ -0,0 +1 @@ +Subproject commit ee6e159cbb4c6189c97046f2cc8c74be0eef4184 diff --git a/setup.py b/setup.py index 974be95b..b1831c1c 100644 --- a/setup.py +++ b/setup.py @@ -39,7 +39,7 @@ class BuildPyCommand(setuptools.command.build_py.build_py): def run(self): - download_script = here / 'client-sdk-rust' / 'download_ffi.py' + download_script = here / 'rust-sdks' / 'download_ffi.py' cmd = ['python3', download_script.absolute(), '--output', 'livekit/resources']