MPEG-TS stream shaping problem: please help

About encoding, codec settings, muxers and filter usage
STod
New Cone
New Cone
Posts: 4
Joined: 10 Sep 2018 17:59

MPEG-TS stream shaping problem: please help

Postby STod » 10 Sep 2018 19:55

Hi to all!

I need to stream video from a capture device. The original video is 1920x1080, and the image isn't very "dynamic", so my needs are:
- 10 fps
- no audio
- h264 encoding
- no B-frames
- one I-frame every 5 secs. (I have to record the stream, and this setting helps the seek...)
- no peak when the I-frames are streamed

Therefore when I set VLC I use the following settings:

MRL:

Code: Select all

v4l2:///dev/video0

Input options:

Code: Select all

:v4l2-aspect-ratio=16\:9 :v4l2-audio-input=-1 :v4l2-width=1920 :v4l2-height=1080 :live-caching=1000

sout string:

Code: Select all

:sout=#transcode{venc=x264{keyint=50,qp=0,bframes=0,b-bias=-100,bpyramid=none,ref=1},vcodec=h264,fps=10,vb=0,scale=0,acodec=none}:rtp{dst=192.168.0.150,port=50040,mux=ts{shaping=6000,use-key-frames}}

All seems work correctly, the video is showed on the destination workstation (received with VLC), but if I capture the stream with Wireshark I see a burst of packets every 5 secs, and no traffic in the meantime. This is exactly the opposite of what is described in the "VLC command-line help" about the "--sout-ts-shaping" and "--sout-ts-use-key-frames" options...

You can find a pcap file here:
https://drive.google.com/drive/folders/ ... sp=sharing

With the same sout string, but without "shaping" and "use-key-frames" options, I obtain a "smooth" stream, with peaks every 5 secs (the I-frames) and several packets in the meantime.


What is wrong in the settings I'm using?

I'm using "VLC 2.2.2 Weatherwax" on an "Ubuntu server 16.04" pc (with Lubuntu desktop).
The same settings works ok on a Windows 7 pc with "VLC 2.0.0 Twoflower".


Thanks a lot in advance for the answers!!

STod
New Cone
New Cone
Posts: 4
Joined: 10 Sep 2018 17:59

Re: MPEG-TS stream shaping problem: please help

Postby STod » 17 Sep 2018 16:00

No answers?

If my question isn't clear enough, or further informations are needed, please let me know.

Thanks!!

Rémi Denis-Courmont
Developer
Developer
Posts: 15267
Joined: 07 Jun 2004 16:01
VLC version: master
Operating System: Linux
Contact:

Re: MPEG-TS stream shaping problem: please help

Postby Rémi Denis-Courmont » 18 Sep 2018 03:32

This is a very specific question that would need somebody to investigate. And that's just not likely to happen on a free support forum... Consider getting a consultant or investigating yourself.
Rémi Denis-Courmont
https://www.remlab.net/
Private messages soliciting support will be systematically discarded

STod
New Cone
New Cone
Posts: 4
Joined: 10 Sep 2018 17:59

Re: MPEG-TS stream shaping problem: please help

Postby STod » 19 Sep 2018 19:00

Thank you for your reply!
I will consider to get a consultant...

However I thought that knowing how to correctly use two VLC's parameters ("shaping" and "use-key-frames"), and what should be the VLC behavior when using them, were of general interest.
Unless I'm the only VLC user to use these parameters ....

HiZ
New Cone
New Cone
Posts: 4
Joined: 29 Jan 2019 22:28

Re: MPEG-TS stream shaping problem: please help

Postby HiZ » 01 Feb 2019 09:18

I too see the same 5 second behaviour. Wireshark shows the bursts proceeded by an RTCP packet.

Without shaping there are bursts so was hoping this command would improve things rather than make it worse.

Did you make any further progress?


Return to “VLC stream-output (sout)”

Who is online

Users browsing this forum: No registered users and 35 guests