Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

rtp example problems #499

Open
G2G2G2G opened this issue May 4, 2023 · 0 comments
Open

rtp example problems #499

G2G2G2G opened this issue May 4, 2023 · 0 comments

Comments

@G2G2G2G
Copy link

G2G2G2G commented May 4, 2023

https://github.com/pion/mediadevices/tree/master/examples/rtp

gst-launch-1.0 udpsrc port=5000 caps=application/x-rtp,encode-name=H264 \
    ! rtph264depay ! avdec_h264 ! videoconvert ! autovideosink

avdec_h264 is widely replaced by openh264 now, which would be openh264dec for gstreamer.
image

Run cd mediadevices/examples/archive && go build && ./rtp localhost:5000

this is the wrong path here, it is to the archive example

example doesn't work, can't get working for mpv either

mpv -v --rtsp-transport=udp rtp://localhost:5000
gst-launch-1.0 udpsrc port=5000 caps=application/x-rtp,encode-name=H264 ! rtph264depay ! openh264dec ! videoconvert ! autovideosink
Setting pipeline to PAUSED ...
Pipeline is live and does not need PREROLL ...
Pipeline is PREROLLED ...
Setting pipeline to PLAYING ...
New clock: GstSystemClock
ERROR: from element /GstPipeline:pipeline0/GstUDPSrc:udpsrc0: Internal data stream error.
Additional debug info:
../gstreamer/subprojects/gstreamer/libs/gst/base/gstbasesrc.c(3132): gst_base_src_loop (): /GstPipeline:pipeline0/GstUDPSrc:udpsrc0:
streaming stopped, reason not-negotiated (-4)
Execution ended after 0:00:18.567873781
Setting pipeline to NULL ...
Freeing pipeline ...
x264 [info]: using cpu capabilities: MMX2 SSE2Fast SSSE3 SSE4.2 AVX FMA3 BMI2 AVX2
x264 [info]: profile High, level 3.0, 4:2:0, 8-bit
panic: write udp 127.0.0.1:47689->127.0.0.1:5000: write: connection refused

goroutine 1 [running]:
main.must(...)
	/storage/1/projects/git/mediadevices/examples/rtp/main.go:22
main.main()
	/storage/1/projects/git/mediadevices/examples/rtp/main.go:73 +0x5ba

mpv hangs and unable to see data, as far as I see it isn't sending any data streams except a broken mp3 stream which isn't even listed
Why is it such a different code than the https://github.com/pion/mediadevices/blob/master/examples/webrtc/main.go#L86
GetVideoTracks vs GetTracks
aren't both sending a stream video? are there any rtp or webrtc that just works out of the box? only one that seems to automatically work without 3rd party requirements is https://github.com/pion/mediadevices/tree/master/examples/http and streaming jpegs is 1990s

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant