<div dir="auto"><div><br><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">Le lun. 29 avr. 2019 04 h 55, Andressio <<a href="mailto:www.andreabertolaso@gmail.com">www.andreabertolaso@gmail.com</a>> a écrit :<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Dear all
I have a camera which emits a h264 stream via rtsp.
This stream follows two paths: the firts stores the stream as raw h264 (this in handled by an external application) and the second one performs some real-time video analysis operations.
The second path generates some events (like moving objecs) which should be stored in a database and later displayed in onverlay on the recorded videos coming from path one.
As the recording and the video analysis might be sligthly shifted in time (let's say that a random number of frames are dropped before the external application starts recording) I cannot rely on the frame number. Also I would like to avoid to rely on a NTP to sync the timestamps because even a difference of a bounch of milliseconds might lead to a bad user experience in terms of ovelayed info.
I am not that expert in h264 and since now I've used opencv to decode frames, but I've read that h264 streams are packed into NAL unit. Are these units numbered in some way? and if so, can these info be extracted using gstreamer? If a </blockquote></div></div><div dir="auto"><br></div><div dir="auto">Not really. In general you should avoid storing raw h264 for this purpose. Instead use a container, like streamable matroska or Mpeg ts.</div><div dir="auto"><br></div><div dir="auto"><div class="gmail_quote"><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">counter was naturally embedded in the h264 stream and it could be reached I think that would be the best synchronization option.
Before I start editing opencv's source code or change the video analysis application to use pure gstreamer I need to know if this can be achieved in some way.
Thanks in advance for your help!
<br><hr align="left" width="300">
Sent from the <a href="http://gstreamer-devel.966125.n4.nabble.com/" target="_blank" rel="noreferrer">GStreamer-devel mailing list archive</a> at Nabble.com.<br>_______________________________________________<br>
gstreamer-devel mailing list<br>
<a href="mailto:gstreamer-devel@lists.freedesktop.org" target="_blank" rel="noreferrer">gstreamer-devel@lists.freedesktop.org</a><br>
<a href="https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel" rel="noreferrer noreferrer" target="_blank">https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel</a></blockquote></div></div></div>