<div><br></div><div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Mon, 17 Jul 2023 at 11:06 Антон Шаров via gstreamer-devel <<a href="mailto:gstreamer-devel@lists.freedesktop.org">gstreamer-devel@lists.freedesktop.org</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-style:solid;padding-left:1ex;border-left-color:rgb(204,204,204)">
<div><div> </div><div><div style="font-family:Arial,Tahoma,Verdana,sans-serif;font-size:15px;font-style:normal;font-variant-caps:normal;font-variant-ligatures:normal;font-weight:400;letter-spacing:normal;text-align:start;text-decoration-color:initial;text-decoration-style:initial;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;background-color:rgb(255,255,255);color:rgb(44,45,46)">Hi.</div><div style="font-family:Arial,Tahoma,Verdana,sans-serif;font-size:15px;font-style:normal;font-variant-caps:normal;font-variant-ligatures:normal;font-weight:400;letter-spacing:normal;text-align:start;text-decoration-color:initial;text-decoration-style:initial;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;background-color:rgb(255,255,255);color:rgb(44,45,46)"> </div><div style="font-family:Arial,Tahoma,Verdana,sans-serif;font-size:15px;font-style:normal;font-variant-caps:normal;font-variant-ligatures:normal;font-weight:400;letter-spacing:normal;text-align:start;text-decoration-color:initial;text-decoration-style:initial;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;background-color:rgb(255,255,255);color:rgb(44,45,46)">I’m given rtsp stream from camera, where each frame has capturing timestamp.</div><div style="font-family:Arial,Tahoma,Verdana,sans-serif;font-size:15px;font-style:normal;font-variant-caps:normal;font-variant-ligatures:normal;font-weight:400;letter-spacing:normal;text-align:start;text-decoration-color:initial;text-decoration-style:initial;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;background-color:rgb(255,255,255);color:rgb(44,45,46)">Connection strin looks like rtsp://{usr}:{pwd{@ip_addr/onvif/media?profile=Profile1</div><div style="font-family:Arial,Tahoma,Verdana,sans-serif;font-size:15px;font-style:normal;font-variant-caps:normal;font-variant-ligatures:normal;font-weight:400;letter-spacing:normal;text-align:start;text-decoration-color:initial;text-decoration-style:initial;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;background-color:rgb(255,255,255);color:rgb(44,45,46)">I need to store this data for some time and provide search access for this data, either return closest (exact) frame for provided timestamp or return mp4 file which containts this closest frame. My first pipeline is <span style="font-family:Helvetica,Arial,sans-serif;letter-spacing:var(--vkui--font_text--letter_spacing--regular,normal)">rtsp ! h264depay ! h264parse ! splitmuxsink location=… max-time-size=10seconds (for example), when I save new file via splitmuxsink, I’m some how need to get camera timestamp</span></div><div style="font-family:Arial,Tahoma,Verdana,sans-serif;font-size:15px;font-style:normal;font-variant-caps:normal;font-variant-ligatures:normal;font-weight:400;letter-spacing:normal;text-align:start;text-decoration-color:initial;text-decoration-style:initial;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;background-color:rgb(255,255,255);color:rgb(44,45,46)"><span style="font-family:Helvetica,Arial,sans-serif;letter-spacing:var(--vkui--font_text--letter_spacing--regular,normal)">for first frame of video (or key frame) and maybe store this mp4 file as timestamp.mp4 (or save ts for later in some db, for example).</span></div><div style="font-family:Arial,Tahoma,Verdana,sans-serif;font-size:15px;font-style:normal;font-variant-caps:normal;font-variant-ligatures:normal;font-weight:400;letter-spacing:normal;text-align:start;text-decoration-color:initial;text-decoration-style:initial;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;background-color:rgb(255,255,255);color:rgb(44,45,46)"> </div><div style="font-family:Arial,Tahoma,Verdana,sans-serif;font-size:15px;font-style:normal;font-variant-caps:normal;font-variant-ligatures:normal;font-weight:400;letter-spacing:normal;text-align:start;text-decoration-color:initial;text-decoration-style:initial;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;background-color:rgb(255,255,255);color:rgb(44,45,46)">Other approach is to use jpegenc and to store each frame with it’s timestamp, but I don’t know how to obtain timestamp for jpeg buffer (rtsp ! decodebin ! jpegenc ! appsink). But I assume that this won’t be effective solution in terms of CPU and storage usage, and better to store mp4 files.</div><div style="font-family:Arial,Tahoma,Verdana,sans-serif;font-size:15px;font-style:normal;font-variant-caps:normal;font-variant-ligatures:normal;font-weight:400;letter-spacing:normal;text-align:start;text-decoration-color:initial;text-decoration-style:initial;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;background-color:rgb(255,255,255);color:rgb(44,45,46)"> </div><div style="font-family:Arial,Tahoma,Verdana,sans-serif;font-size:15px;font-style:normal;font-variant-caps:normal;font-variant-ligatures:normal;font-weight:400;letter-spacing:normal;text-align:start;text-decoration-color:initial;text-decoration-style:initial;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;background-color:rgb(255,255,255);color:rgb(44,45,46)">So, in both cases I don’t know how to get reference-timestamp-meta for needed buffer.</div><div style="font-family:Arial,Tahoma,Verdana,sans-serif;font-size:15px;font-style:normal;font-variant-caps:normal;font-variant-ligatures:normal;font-weight:400;letter-spacing:normal;text-align:start;text-decoration-color:initial;text-decoration-style:initial;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;background-color:rgb(255,255,255);color:rgb(44,45,46)"> </div><div style="font-family:Arial,Tahoma,Verdana,sans-serif;font-size:15px;font-style:normal;font-variant-caps:normal;font-variant-ligatures:normal;font-weight:400;letter-spacing:normal;text-align:start;text-decoration-color:initial;text-decoration-style:initial;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;background-color:rgb(255,255,255);color:rgb(44,45,46)">Can someone help me? </div><div style="font-family:Arial,Tahoma,Verdana,sans-serif;font-size:15px;font-style:normal;font-variant-caps:normal;font-variant-ligatures:normal;font-weight:400;letter-spacing:normal;text-align:start;text-decoration-color:initial;text-decoration-style:initial;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;background-color:rgb(255,255,255);color:rgb(44,45,46)"> </div><div style="font-family:Arial,Tahoma,Verdana,sans-serif;font-size:15px;font-style:normal;font-variant-caps:normal;font-variant-ligatures:normal;font-weight:400;letter-spacing:normal;text-align:start;text-decoration-color:initial;text-decoration-style:initial;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;background-color:rgb(255,255,255);color:rgb(44,45,46)">PS: I use C# wrapper, namely gstreamer-sharp, but I don’t think it is relevant for this problem.</div><div style="font-family:Arial,Tahoma,Verdana,sans-serif;font-size:15px;font-style:normal;font-variant-caps:normal;font-variant-ligatures:normal;font-weight:400;letter-spacing:normal;text-align:start;text-decoration-color:initial;text-decoration-style:initial;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;background-color:rgb(255,255,255);color:rgb(44,45,46)"> </div><div style="font-family:Arial,Tahoma,Verdana,sans-serif;font-size:15px;font-style:normal;font-variant-caps:normal;font-variant-ligatures:normal;font-weight:400;letter-spacing:normal;text-align:start;text-decoration-color:initial;text-decoration-style:initial;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;background-color:rgb(255,255,255);color:rgb(44,45,46)">Thanks in advance.</div></div><div> </div><div><div><div>--<br>С Уважением,<br>Шаров Антон</div></div></div></div>
</blockquote></div></div>