星期四, 4月 25, 2019

GST rtsp server





  1. sudo apt-get install libgstrtspserver-1.0 libgstreamer1.0-dev
  2. test-launch.c @ https://github.com/GStreamer/gst-rtsp-server/blob/master/examples/test-launch.c
  3. gcc test-launch.c -o test-launch $(pkg-config --cflags --libs gstreamer-1.0 gstreamer-rtsp-server-1.0)
onboard:
  1. ./test-launch "videotestsrc ! omxh265enc ! rtph265pay name=pay0 pt=96"
  2. ./test-launch "nvcamerasrc ! video/x-raw(memory:NVMM), format=I420, framerate=30/1, width=1920, height=1080 ! omxh265enc bitrate=30000000 ! rtph265pay name=pay0 pt=96 "
  3. # H264
    1. ./test-launch "( nvcamerasrc ! video/x-raw(memory:NVMM), width=(int)1920, height=(int)1080, format=(string)I420, framerate=(fraction)30/1 ! omxh264enc bitrate=20000000 ! video/x-h264, profile=baseline ! rtph264pay name=pay0 pt=96 )"

usb:
  1. ./test-launch "v4l2src device=/dev/video1 ! video/x-raw,format=YUY2 ! nvvidconv ! video/x-raw(memory:NVMM),width=2560,height=720,format=I420 ! omxh265enc ! rtph265pay name=pay0 pt=96"



Reference:

沒有留言: