Sometimes splitmuxsink has high cpu load and prints "redistribute latency" message.

sonntex sonntex at gmail.com
Fri Nov 25 13:20:23 UTC 2016


I have one usb video camera, that works with splitmuxsink very strange.

This pipeline works well (writes data to mp4 file immediately):

# timeout -s INT 60 gst-launch-1.0 \
>       v4l2src device="/dev/video0" do-timestamp=true \
>     !     image/jpeg,width=640,height=480,framerate=30/1 \
>     ! jpegparse \
>     ! omxmjpegdec \
>     ! clockoverlay time-format="%Y-%m-%d %T" \
>     ! videoconvert \
>     ! omxh264enc target-bitrate=2097152 control-rate=variable
interval-intraframes=30 \
>     !     video/x-h264,profile=baseline \
>     ! h264parse \
>     ! mp4mux \
>     ! filesink location="video.mp4"
Setting pipeline to PAUSED ...
Pipeline is live and does not need PREROLL ...
Setting pipeline to PLAYING ...
New clock: GstSystemClock
handling interrupt.
Interrupt: Stopping pipeline ...
Execution ended after 0:00:59.751358987
Setting pipeline to PAUSED ...
Setting pipeline to READY ...
Setting pipeline to NULL ...
Freeing pipeline ...

# ls -l video.mp4
-rw-r--r-- 1 root root 733678 Jan  1 01:12 video.mp4

This pipeline loads cpu until first "redistribute latency" message (does
not write any data to mp4 file during this time) and then has strange
behavior:

# timeout -s INT 300 gst-launch-1.0 \
>       v4l2src device="/dev/video0" do-timestamp=true \
>     !     image/jpeg,width=640,height=480,framerate=30/1 \
>     ! jpegparse \
>     ! omxmjpegdec \
>     ! clockoverlay time-format="%Y-%m-%d %T" \
>     ! videoconvert \
>     ! omxh264enc target-bitrate=2097152 control-rate=variable
interval-intraframes=30 \
>     !     video/x-h264,profile=baseline \
>     ! h264parse \
>     ! splitmuxsink location="video-chunk-%02d.mp4"
max-size-time=15000000000
Setting pipeline to PAUSED ...
Pipeline is live and does not need PREROLL ...
Setting pipeline to PLAYING ...
New clock: GstSystemClock
Redistribute latency...
Redistribute latency...
Redistribute latency...
Redistribute latency...
handling interrupt.
Interrupt: Stopping pipeline ...
Execution ended after 0:04:59.739565719
Setting pipeline to PAUSED ...
Setting pipeline to READY ...
Setting pipeline to NULL ...
Freeing pipeline ...

# ls -l video-chunk-*.mp4
-rw-r--r-- 1 root root 1373643 Jan  1 01:17 video-chunk-00.mp4
-rw-r--r-- 1 root root 1339636 Jan  1 01:19 video-chunk-01.mp4
-rw-r--r-- 1 root root  378033 Jan  1 01:20 video-chunk-02.mp4

As you can see, distance between creation time of the chunks is longer than
15 seconds.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.freedesktop.org/archives/gstreamer-devel/attachments/20161125/f3945147/attachment.html>


More information about the gstreamer-devel mailing list