Qt5.11 multimedia and gstreamer connection problem
-
Hello everyone.
I am writing an application to output an rtp stream sent by gstreamer.
On qt 5.15, everything starts successfully and outputs the video stream to Qwidget, but on 5.11 there is a problem, on ubuntu 16.04.
Error:
"Streamer; Unable to pause - "gst-pipeline: udpsre port=10334 caps = %22application/x-rtp,
rtph264depay ! decodebin ! videoconvert ! ximagesink name=qtvideosink"
Streamer; Unable to pause - "gst-pipeline: udpsre port=10334 caps
= %22application/x-rtp, media=(string) video, clock-rate=(int) 90000, encoding-name=(string)H 264, payload=(int)96%22 | queue ! rtpjitterbuffer latency=0 !
rtph264depay ! decodebin ! videoconvert ! ximagesink name=qtvideosink" Error:
"There is no URI handler implemented for the gst-pipeline."const auto port = 5000; auto m_mediaPlayer = new QMediaPlayer(); auto m_videoWidget = new QVideoWidget(); m_mediaPlayer->setVideoOutput(m_videoWidget); m_mediaPlayer->setMedia(QUrl("gst-pipeline: udpsrc port=" + port + " caps = \"application/x-rtp, media=(string)video, clock-rate=(int)90000, encoding-name=(string)H264, payload=(int)96\" ! queue ! rtpjitterbuffer latency=0 ! rtph264depay ! decodebin ! videoconvert ! ximagesink name=qtvideosink")); m_mediaPlayer->play();
sending pipeline
gst-launch-1.0 -v ximagesrc startx = 0 endx = 1920 ! video/x-raw,framerate=20/1 ! videoscale ! videoconvert ! x264enc tune=zerolatency bitrate=1000 speed-preset=superfast ! rtph264pay ! udpsink host=127.0.0.1 port=5000
receiving pipeline
gst-launch-1.0 -v udpsrc port=5000 caps = "application/x-rtp, media=(string)video, clock-rate=(int)90000, encoding-name=(string)H264, payload=(int)96" ! rtph264depay ! decodebin ! videoconvert ! ximagesink
I tried another approach, but unfortunately I also get an error:
"Error:The stream type could not be determined.""
code:auto process = new QProcess; auto player = new QMediaPlayer; auto video = new QVideoWidget() ; player-›setVideoOutput(video); QStringList p; QString z = "gst-launch-1.0": p « "videotestsrc" << "!" << "appsink"; process-›start(z,p) ; process-›waitForReadyRead) : player-›setMedia (QMediaContent, process) ; player-›play;
-
@Mahyar what's the point of your answer? And this is an english forum.
-
Qt 5.11 is no longer supported. No point in using it, when everything works on 5.15.
-
@Axel-Spoerl Have a nice day. I would be happy to use qt 5.15. o on my linux version, the maximum version from the package manager 5.11 and higher cannot be used.
-
Then your package manager provides EOL-software!
You can download later versions via the link in @Christian-Ehrlicher's signature.