Hardware encoding of MJPEG is impacted by h264 decoding , but softeware encoding of MJPEG isn’t impacted.
Here is my environment setup.
send h264 stream(PC) → h264 decoding and MJPEG encoding(TK1)–> MJPEG decoding and display(PC)
PC IP:192.168.8.8
TK1 IP:192.168.8.6
PC collect data from Logitech’s c920 camera and send h264 stream to TK1 .
gst-launch-1.0 -e v4l2src device=/dev/video0 ! 'video/x-h264, width=(int)1920, height=(int)1080, framerate=30/1' ! h264parse ! rtph264pay config-interval=1 ! udpsink host=192.168.8.6 port=5000 sync=false
TK1 decode h264 and use hardware encoding of MJPEG .
gst-launch-1.0 -e udpsrc port=5000 caps="application/x-rtp, media=(string)video, encoding-name=(string)H264" ! rtph264depay ! h264parse ! omxh264dec ! nvvidconv ! "video/x-raw(memory:NVMM)"! nvjpegenc ! rtpjpegpay ! udpsink host=192.168.8.8 port=5000
PC receive MJPEG and display.
gst-launch-1.0 -e udpsrc port=5000 ! application/x-rtp,encoding-name=JPEG,payload=26 ! rtpjpegdepay ! jpegdec ! videoconvert ! 'video/x-raw, format=(string)UYVY' ! fpsdisplaysink sync=false video-sink="autovideosink"
The result is PC send 30fps h264 and receive 16fps MJPEG.
when software encoding replace hardware encoding, PC will receive 30fps MJPEG.
gst-launch-1.0 -e udpsrc port=5000 caps="application/x-rtp, media=(string)video, encoding-name=(string)H264" ! rtph264depay ! h264parse ! omxh264dec ! videoconvert ! jpegenc ! rtpjpegpay ! udpsink host=192.168.8.8 port=5000
my question:
what is the cause of this issue and how to solve it.