get data rate at eos
Kenneth Feingold via gstreamer-devel <[email protected]> Sun, 7 Jan 2024 14:45:14 -0500
| Newsgroups | gmane.comp.video.gstreamer.devel |
|---|---|
| Message-ID | <CAMF_QKsfoUfMS7N3+oUi_5t-tL1PKTAkG-fwfdAuRTkWAba4YA@mail.gmail.com> |
I am trying to grab the speed at which video is playing at the moment it
reaches the end (or start, if playing in reverse) of a video stream, I have
implemented the ability to have the stream jump to where I want it to go
(here, 1 second from the start) when it reaches the end or start of the
stream, but no matter what the playback rate is at the moment it reaches
the eos the rate resets to normal forward. I am working in C.
static void eos_cb (GstBus *bus, GstMessage *msg, CustomData *data) {
g_print ("End-Of-Stream reached.\n");
gst_element_seek_simple (data->playbin, GST_FORMAT_TIME,
GST_SEEK_FLAG_FLUSH | GST_SEEK_FLAG_KEY_UNIT, 1 * GST_SECOND);
send_seek_event (data);
}
Thanks for any advice.