vasuyan

streaming code

Apr 2nd, 2021 (edited)
105
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Bash 1.09 KB | None | 0 0
  1. GST_DEBUG=3 \
  2. gst-launch-1.0 -v \
  3. \
  4. v4l2src device='/dev/video0' io-mode=2 ! image/jpeg, width=640, height=480, framerate=30/1 ! \
  5. nvjpegdec ! 'video/x-raw, width=640, height=480, framerate=30/1' ! \
  6. nvvidconv ! 'video/x-raw(memory:NVMM), width=640, height=480, framerate=30/1' ! queue max-size-bytes=0 max-size-buffers=0 ! glue. \
  7.  \
  8. rtspsrc location='rtsp://<ip-cam-adress>' protocols=tcp latency=500 ! rtph264depay ! h264parse ! nvv4l2decoder !  \
  9. nvvidconv ! 'video/x-raw(memory:NVMM), width=1920, height=1080, framerate=25/1' ! queue max-size-bytes=0 max-size-buffers=0 ! glue. \
  10. \
  11. nvcompositor name=glue sink_0::xpos=0 sink_0::ypos=252 sink_0::width=960 sink_0::height=540 \
  12. sink_1::xpos=960 sink_1::ypos=252 sink_1::width=960 sink_1::height=540 ! \
  13.  \
  14. nvvidconv ! 'video/x-raw(memory:NVMM), width=1920, height=1080, framerate=25/1' ! nvv4l2h264enc bitrate='4500000' ! \
  15. h264parse config-interval=1 disable-passthrough=true ! queue max-size-bytes=0 max-size-buffers=0 ! mux. \
  16. flvmux name=mux ! rtmpsink location='rtmp://a.rtmp.youtube.com/live2/<stream_code>'  &> debug_record_cam+screen.txt
Add Comment
Please, Sign In to add comment