"Buffer has no PTS" with this H264 IP Camera
Mandar Joshi
emailmandar at gmail.com
Sat Apr 8 16:37:50 UTC 2017
Hello everyone,
I am facing this weird problem with an H264 IP camera.
While trying to record the stream, mp4mux gives an errror "Buffer has no PTS".
This doesn't happen every time. Most of the time, restarting the
pipeline solves the problem.
The problem is similar to what an user has mentioned here
https://stackoverflow.com/questions/42874691/gstreamer-for-android-buffer-has-no-pts
but I am facing this on Fedora 25 x86_64 with GStreamer 1.10.4.
The pipeline I am using is somewhat complex but essentialls this is what it does
gst-launch-1.0 -e rtspsrc location=rtsp://127.0.0.1:8556/vstarcam !
rtph264depay ! h264parse ! mp4mux ! filesink location=1.mp4
Things I have tried
1. Adding a timestamp using appsink appsrc and then feeding the output
to shmsink and streaming the camera from there. What I do is
-----------------------------------------------------------------------------------------
GST_BUFFER_PTS (app_buffer) = camera->appsrc_timestamp;
GST_BUFFER_DURATION (app_buffer) = gst_util_uint64_scale_int (1,
GST_SECOND, camera->fps);
camera->appsrc_timestamp += GST_BUFFER_DURATION (app_buffer);
-----------------------------------------------------------------------------------------
Can I do the above with pad probes?
2. The problem doesn't present itself while using the mkv container.
But for some reason the recorded video in mkv isn't seekable
correctly.
3. Setting h264parse properties
g_object_set (parser, "disable-passthrough", TRUE, "config-interval", 1, NULL);
This didn't make any difference.
What else can I try?
I would appreciate any inputs.
Thanks and Regards
Mandar Joshi
More information about the gstreamer-devel
mailing list