livekit / client-sdk-unity

Official Unity SDK for LiveKit
https://livekit.io
40 stars 15 forks source link

Add more method for Local/Remote Track. #46

Closed cloudwebrtc closed 2 months ago

cloudwebrtc commented 4 months ago

close https://github.com/livekit/client-sdk-unity/issues/55 close https://github.com/livekit/client-sdk-unity/issues/52

Tested Platfroms:

Updated ffi to v0.9.0.

burakkaraceylan commented 4 months ago

How does muting the local track work? It seems a request is sent to the server. Does the muting happen on the server side? If so, does that mean the muted track is still being published (i.e. uploading data)?

cloudwebrtc commented 4 months ago

Actually this request will be sent to rust core, which will block data upload internally, but yes, it would be more explicit to add a muted flag inside LocalTrack to prevent data send to ffi.

Cheney1112 commented 3 months ago

After pulling the update, when calling the ‘MakeCall’ method, the following error occurs: “NullReferenceException: Object reference not set to an instance of an object LiveKit.Room.OnEventReceived (LiveKit.Proto.RoomEvent e) (at Assets/client-sdk-unity-main/Runtime/Scripts/Room.cs:344) LiveKit.Internal.FfiClient+<>c.b__47_0 (System.Object resp) (at Assets/client-sdk-unity-main/Runtime/Scripts/Internal/FFIClient.cs:236) UnityEngine.UnitySynchronizationContext+WorkRequest.Invoke () (at :0) UnityEngine.UnitySynchronizationContext.Exec () (at :0) UnityEngine.UnitySynchronizationContext.ExecuteTasks () (at :0) ” Setting a breakpoint shows that the issue occurs in the ‘Room’ script at the following lines: ”var participant = RemoteParticipants[e.TrackPublished.ParticipantIdentity]; var publication = new RemoteTrackPublication(e.TrackPublished.Publication.Info, FfiHandle.FromOwnedHandle(e.TrackPublished.Publication.Handle)); “ I hope to find a solution to this problem. Thank you.

cloudwebrtc commented 3 months ago

Thanks for finding this bug. I believe this is because the corresponding version of ffi .so/dll has not been updated yet.

Cheney1112 commented 3 months ago

Thanks for finding this bug. I believe this is because the corresponding version of ffi .so/dll has not been updated yet.

Thanks for the response :) When will the "ffi.so.dll" be updated, or is it possible that I didn't download the correct version?