When we use HEVC + RTSP, ffmpeg works fine. The stream is captured by webcam.
ffmpeg -f dshow -rtbufsize 100M -f vfwcap -i "0" -strict experimental -c:v hevc_qsv -f rtsp -rtsp_transport tcp rtsp://127.0.0.1/live/test
The output is like:
frame= 355 fps= 37 q=-0.0 size=N/A time=00:00:11.27 bitrate=N/A dup=159 drop=0 speed=1.18x
Then we switch to VP9 + RTSP.
ffmpeg -f dshow -rtbufsize 100M -f vfwcap -i "0" -strict experimental -c:v libvpx-vp9 -f rtsp -rtsp_transport tcp rtsp://127.0.0.1/live/test
The fps and speed looks too slow:
frame= 263 fps=9.5 q=0.0 size=N/A time=00:00:07.94 bitrate=N/A dup=119 drop=0 speed=0.288x
Then we use ffplay to play the stream. There are a lot of error messages and the video seems frozen.
[vp9 @ 000001c3da86c200] Not all references are available
[vp9 @ 000001c3dffd5700] Not all references are available
[vp9 @ 000001c3da8477c0] Not all references are available
[vp9 @ 000001c3da848240] Not all references are available
[vp9 @ 000001c3da848e40] Not all references are available
[vp9 @ 000001c3e01d2fc0] Not all references are available
[vp9 @ 000001c3e01dd280] Not all references are available
[vp9 @ 000001c3e01e8980] Not all references are available
[vp9 @ 000001c3e01f1880] Not all references are available
[vp9 @ 000001c3da86c200] Not all references are available
[vp9 @ 000001c3dffd5700] Not all references are available
[vp9 @ 000001c3da8477c0] Not all references are available
[vp9 @ 000001c3da848240] Not all references are available
[vp9 @ 000001c3da848e40] Not all references are available
[vp9 @ 000001c3e01d2fc0] Not all references are available
[vp9 @ 000001c3e01dd280] Not all references are available0B f=0/0
[vp9 @ 000001c3e01e8980] Not all references are available
[vp9 @ 000001c3e01f1880] Not all references are available
[vp9 @ 000001c3da86c200] Not all references are available
[vp9 @ 000001c3dffd5700] Not all references are available
[vp9 @ 000001c3da8477c0] Not all references are available
[vp9 @ 000001c3da848240] Not all references are available
[vp9 @ 000001c3da848e40] Not all references are available
[vp9 @ 000001c3e01d2fc0] Not all references are available
[vp9 @ 000001c3e01dd280] Not all references are available
[vp9 @ 000001c3e01e8980] Not all references are available
[vp9 @ 000001c3e01f1880] Not all references are available
Finally, we try hardware VP9 encoder.
ffmpeg -f dshow -rtbufsize 100M -f vfwcap -i "0" -strict experimental -c:v vp9_qsv -f rtsp -rtsp_transport tcp rtsp://127.0.0.1/live/test
It can't work.
[swscaler @ 0000021e88df9fc0] deprecated pixel format used, make sure you did set range correctly
[vp9_qsv @ 0000021e8687df80] Selected ratecontrol mode is unsupported
[vp9_qsv @ 0000021e8687df80] Low power mode is unsupported
[vp9_qsv @ 0000021e8687df80] Current frame rate is unsupported
[vp9_qsv @ 0000021e8687df80] Current picture structure is unsupported
[vp9_qsv @ 0000021e8687df80] Current resolution is unsupported
[vp9_qsv @ 0000021e8687df80] Current pixel format is unsupported
[vp9_qsv @ 0000021e8687df80] some encoding parameters are not supported by the QSV runtime. Please double check the input parameters.
Error initializing output stream 0:0 -- Error while opening encoder for output stream #0:0 - maybe incorrect parameters such as bit_rate, rate, width or height
Conversion failed!
So, how can we deal with VP9 + RTSP successfully?