Skip to content

Commit

Permalink
fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
lukasIO committed Dec 20, 2024
1 parent 6f572df commit 9f6f23d
Show file tree
Hide file tree
Showing 3 changed files with 22 additions and 3 deletions.
7 changes: 7 additions & 0 deletions livekit-ffi/protocol/room.proto
Original file line number Diff line number Diff line change
Expand Up @@ -604,3 +604,10 @@ message SendStreamChunkRequest {
optional string sender_identity = 4;
}

message SendStreamHeaderResponse {
required uint64 async_id = 1;
}

message SendStreamChunkResponse {
required uint64 async_id = 1;
}
12 changes: 12 additions & 0 deletions livekit-ffi/src/livekit.proto.rs
Original file line number Diff line number Diff line change
Expand Up @@ -3146,6 +3146,18 @@ pub struct SendStreamChunkRequest {
#[prost(string, optional, tag="4")]
pub sender_identity: ::core::option::Option<::prost::alloc::string::String>,
}
#[allow(clippy::derive_partial_eq_without_eq)]
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct SendStreamHeaderResponse {
#[prost(uint64, required, tag="1")]
pub async_id: u64,
}
#[allow(clippy::derive_partial_eq_without_eq)]
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct SendStreamChunkResponse {
#[prost(uint64, required, tag="1")]
pub async_id: u64,
}
#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
#[repr(i32)]
pub enum IceTransportType {
Expand Down
6 changes: 3 additions & 3 deletions livekit-ffi/src/server/requests.rs
Original file line number Diff line number Diff line change
Expand Up @@ -244,18 +244,18 @@ fn on_send_stream_header(
.retrieve_handle::<FfiParticipant>(stream_header_message.local_participant_handle)?
.clone();

// Ok(ffi_participant.room.publish_raw_data(server, edit_chat_message))
Ok(ffi_participant.room.send_stream_header(server, stream_header_message))
}

fn on_send_stream_chunk(
server: &'static FfiServer,
stream_chunk_message: proto::SendStreamChunkRequest,
) {
let ffi_participant = server
.retrieve_handle::<FfiParticipant>(edit_chat_message.local_participant_handle)?
.retrieve_handle::<FfiParticipant>(stream_chunk_message.local_participant_handle)?
.clone();

Ok(ffi_participant.room.edit_chat_message(server, edit_chat_message))
Ok(ffi_participant.room.send_stream_chunk(server, stream_chunk_message))
}

/// Create a new video track from a source
Expand Down

0 comments on commit 9f6f23d

Please sign in to comment.