rust-sdks icon indicating copy to clipboard operation
rust-sdks copied to clipboard

ffi setMute dont work

Open xwxctjpkfc-bit opened this issue 2 months ago • 1 comments

after send FfiRequest::LocalTrackMuteRequest, remote participants don't receive TrackMuted/TrackUnmuted room event

xwxctjpkfc-bit avatar Oct 30 '25 08:10 xwxctjpkfc-bit

Hi @xwxctjpkfc-bit, thank you for reporting this—we will investigate the issue.

ladvoc avatar Nov 04 '25 23:11 ladvoc

fn on_local_track_mute(
    server: &'static FfiServer,
    request: proto::LocalTrackMuteRequest,
) -> FfiResult<proto::LocalTrackMuteResponse> {
    let ffi_pub = server.retrieve_handle::<FfiPublication>(request.track_handle)?.clone();
    let TrackPublication::Local(publication) = &ffi_pub.publication else {
        return Err(FfiError::InvalidRequest("publication is not a LoclPublication".into()));
    };
    let mut muted = false;
    if(request.mute){
        publication.mute();
    }else{
        publication.unmute();
    }
    muted = publication.is_muted();

    Ok(proto::LocalTrackMuteResponse { muted: muted })
}

Its work for me after change on_local_track_mute in requests.rs

asok00000 avatar Dec 01 '25 02:12 asok00000

I believe this PR can fix this issue. https://github.com/livekit/rust-sdks/pull/799

cloudwebrtc avatar Dec 01 '25 09:12 cloudwebrtc