Prerecording Data using Gstreamer / Circular Buffer in Gstreamer

What I want is to record last n seconds before trigger occurs , means suppose i have set n as 30 sec so the data would be continuously storing in a circular buffers which will have last n secons and when trigger occurs first this circular buffer would be store and then incoming data .

You may see this example using circular buffer from std::chrono for the same purpose (using opencv with gstreamer backend).

1 Like

Sorry for the confusion, the circular buffer in the example above was from boost (std::chrono was unrelated, just messed up when posting).

You can find an example for this here (in C): H.264 backlog recording example ($1760) · Snippets · freedesktop.org / Snippets · GitLab

1 Like