I'm working on a program that is migrating from OpenCV to Gstreamer, currently I have the pipeline and the frames obtained from a RTSP stream in Gstreamer. This frames are displayed in a window using OpenCV and I'm working in C++ on Windows.
My question is the following, which is the best approach to obtain the number of processed frames via Gstreamer ? How can I get that value and store it in a local variable ?
EDIT: I'm obtaining the buffer data from an RTSP stream and dumping it into a cv::Mat, after that I process and display this Mat in screen using the imshow(). At the same time, I'm doing this process in a loop, so in my screen the imshow is being updated constantly with the real time images extracted from the RTSP stream. I'm displaying the obtained frames in my screen as a media format/real-time video.
My question is, how do I extract the framerate at which Gstreamer is sending the info ?