There is getStats() API available in mediasoup. But I want to use another library to avoid doing it myself. https://github.com/muaz-khan/getStats . but this library is giving error that transport is not instance RTCPerrConnection, mediasoup documentation says it returns RTCstatsReport https://mediasoup.org/documentation/v3/mediasoup-client/api/#transport-getStats
is there a way to get normal RTCPeerConnection from transport?
Obviously a mediasoup-client Transport
instance is not a RTCPeerConnection
instance.
is there a way to get normal RTCPeerConnection from transport?
Undocumented and not guaranteed to work for all browsers (now and in the future), but this gives you the RTCPeerConnection instance:
transport._handler._pc
Wow. so fast reply, never expected that, Really thanks.