Replies: 1 comment
-
its my mistake ,i use rtp source data as h264 source data ,sorry |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
I use pion webrtc to establish a P2P session with my device, receive the audio and video data stream from the device and forward it to livekit, using track After reading the data, use track Writesample is sent to the track that implements publishing to livekit, but there is no video. The sound is stored as Ogg and can be played, but the noise is published to livekit. The following is the audio and video format of the device time= "2022-06-22t17:12:13+08:00" level=info msg= "got track audio/opus, pt=111 tbn=48000, channels=2"
time="2022-06-22T17:12:13+08:00" level=info msg="Open ogg writer file=./test_audio.ogg , tbn=48000, channels=2"
time="2022-06-22T17:12:13+08:00" level=info msg="Got track video/H264, pt=125 tbn=90000, fmtp=level-asymmetry-allowed=1;packetization-mode=1;profile-level-id=42e01f"
time="2022-06-22T17:12:13+08:00" level=info msg="Open h264 writer file=./test_video.h264"
my create peer function is:
func newPeerConnection(configuration webrtc.Configuration) (*webrtc.PeerConnection, error) {
m := &webrtc.MediaEngine{}
if err := m.RegisterDefaultCodecs(); err != nil {
return nil, err
}
}
in onTrack callback function running code as fellow:
Beta Was this translation helpful? Give feedback.
All reactions