Where is the opencv frame code in gstreamer?

Hello all,
I wanna ask to you all, how to consume the gstreamer frame ? in OpenCV there’s a code

cap = cv2.VideoCapture(0)
_, <b>frame </b>= cap.read()

But i’m in confuse, where is the frame in gstreamer ?

There isn’t really an equivalent in Gstreamer. Buffers are passed down a pipeline a bit like a chain of python generators or a stream of data from source to sink. Buffers can be anything, not just frames. Sometimes it might be less than a frame. Other times it might be whole batches of them.

What’s the end goal of your app? Do you want to draw bounding boxes around things or send detection/classification metadata around? You can do all that. It’s just done in a different way. What’s the idea you have for your app?

Thank you for your response mr. mdegans
I want to find a contour from the stream(like detect the colour), because all the time i use the opencv code.

Hi,
There are several posts about gstreamer + OpenCV:
https://devtalk.nvidia.com/default/topic/1064944/jetson-nano/-gstreamer-nvvidconv-bgr-as-input/post/5397143/#5397143
https://devtalk.nvidia.com/default/topic/1065637/jetson-agx-xavier/sony-camera-module-cannot-be-opened-with-opencv-on-xavier/post/5397032/#5397032
https://devtalk.nvidia.com/default/topic/1042892/jetson-agx-xavier/nvarguscamerasrc-opencv-solved-/post/5290833/#5290833
Please take a look. These posts may bring more information for your usecase.