Jatson Xaiver VI video format issue

Dear nvidia team.

we made product through xavier platform,

clear most of problems, but we have a problem recently.

we were using 1280x720 and 1024x769 video format,(no problem)

that is no problem, but we change the video format 1026x769 recently for customer,

system is as below

‘camera output mipi csi(1026x769/YUV422) -> Xavier AGX 16G’

we change another format 1028x769, 1032x769, 1040x769 etc(Word count is 2056, 2064, 2080) There is also a problem too, (problem is occurs jagging image)

finally we found some problem cause, we change the 1056x769(word count 2112) format and we can see the normal image(it is OK).

we guess VI memory write 64byte system, so occurs problem,

Could you help me solve problem? we want to make 1026x769 video format,

thanks

(Below is a problem image)
,

Try to set below in …/kernel/nvidia/include/media/tegra_camera_core.h

#define TEGRA_STRIDE_ALIGNMENT 4096

Aslo try below patch

thank your support,

we change alignment value.

#define TEGRA_STRIDE_ALIGNMENT 64’

we can see the image,

and I want to know next step :)

how to capturing(crop) 1026x769 format? or any other suggestion?

attached file is result of image.

Sorry, Not really understanding your question here.

sorry, insufficient explanation.

ours equipment is logging system for SIL

this image(attached image) is 1052x769 format, so we have to crop(or something) 1026 x 769 format,

detail system is as below

camera 1026x769 -> command ‘./camera_v4l2_cuda -s 1026x769 -f UYVY -d /dev/video0 -n 30’ -> camera.UYVY(result of image) -> we could see the image ‘1056x769 UYVY’

we hope to use 1026x769 image only,

thanks,

Wow, do you mean the sensor output 1026x769 but you get 1052x769 from the APP?

sensor output is 1026x769(Word count 2052) but we don’t want 1052x769 image

we want to get the 1026x769 format only,

but v4l2 is not support this format so we change this command (#define TEGRA_STRIDE_ALIGNMENT 64)

and then we can get the picture 1052x769 image, (1052 is 64byte format)

how to get image 1026x769 format.

  1. Could you try TEGRA_STRIDE_ALIGNMENT 4096
  2. Apply the patch from below and tune the --–set-ctrl preferred_stride=256
    Jatson Xaiver VI video format issue

thanks your reply,

  1. We changed command TEGRA_STRIDE_ALIGNMENT 4096 but we couldn’t get the image,

  2. Apply --–set-ctrl preferred_stride=256
    Ours kernel version is L4T r31, we use JetPack 4.1.1 so We couldn’t set this value.

Have adjust below value to try. If still can’t figure out a solution you may need to use nvvidconv API to crop it.
#define TEGRA_WIDTH_ALIGNMENT
#define TEGRA_STRIDE_ALIGNMENT