OnTrack only fired once #2906
Unanswered
yangxingyu
asked this question in
Q&A
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hello, I am working on achieving audio and video transmission between two Pion processes (a WebRTC framework) in order to support more participants in my application. However, I have encountered a strange behavior. When User A sends video and audio to Pion A, Pion A receives its OnTrack event twice: once for the video track and once for the audio track, as expected.
The issue arises when I try to forward these tracks to Pion B. If I immediately add both tracks to a new peer connection that connects to Pion B, Pion B's OnTrack event only fires once. However, if I add the video and audio tracks to the connection after a short delay(1 to 3 seconds), Pion B's OnTrack event will fire twice.
This inconsistency has me puzzled. How can I diagnose why Pion B's OnTrack event behaves differently depending on the timing of track addition? Are there any known issues or best practices related to handling multiple tracks in this manner? I would greatly appreciate any insights or suggestions you may have on how to address this issue.
Beta Was this translation helpful? Give feedback.
All reactions