How to drop queued frames using gstCamera Jetson Utils

Instead of using an opencv videocapture device:

cap = cv2.VideoCapture("v4l2src device=/dev/video3 ! nvvidconv ! video/x-raw(memory:NVMM) ! nvvidconv ! video/x-raw,format=BGRx ! videoconvert ! video/x-raw,format=BGR ! appsink drop=1 max-buffers=2")

I’m trying to use the gstCamera instead because it captures frames faster:

self.cap = jetson.utils.gstCamera(2560,720,"/dev/video3")

however I still want to set the appsink properties that I had in my videocapture device such as setting drop=1 and max-buffers=2. How would I do that using gstCamera?

Hi @chealsie.bains, you would need to add your desired appsink settings to this line of code:

Then after you modify the code, re-build/re-install with the following commands:

cd /path/to/your/jetson-inference/build
sudo make install

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.