Rotate CSI camera image

Hello,
I am working with a Jetson Nano and the DLI course.
I have the deepstream SDK v4.0.2.
In the dli_apps, I ran the deepstream-test1-csicam-in but the image is inverted.

I saw that it was possible to do video transformation with the nvvidconv flip-method but how do I modify the code to set the value to 2 to rotate the video of 180 degrees?

Otherwise, I saw it was possible to use the nvbufsurftransform but I’m yet to find an example.

Thanks in advance for your help,
Clément

Hi,
You may refer to the sample:

Hi,
I tried adding the code but there is no static gboolean create_camera_source_bin function in the code.
Do you know where I have to add the

GstPad *src_pad;
src_pad = gst_element_get_static_pad (bin->src_elem, "src");
gst_pad_add_probe (src_pad, GST_PAD_PROBE_TYPE_BUFFER,
nvargus_src_pad_buffer_probe, NULL, NULL);

Thanks for your help

Hi,
The sample is for deepstream-app
In your app, you may add the same is source pad of nvarguscamerasrc.

Hi,
It works fine.
I replaced bin->src by source.

Thanks a lot!