draw_rect
- savant.deepstream.opencv_utils.draw_rect(frame, rect, color, thickness=1, stream=None)
Draw rectangle on a frame.
Usage example:
with nvds_to_gpu_mat(gst_buffer, nvds_frame_meta) as frame_mat: draw_rect(frame_mat, (400, 100, 500, 300), (255, 0, 0, 255), 4)