Question about nvgstcapture

HW: Jetson TX2/TX1
JetPack: 3.2

After JetPack installation , tested camera on the board with nvgstcapture.

$ nvgstcapture --image-res=3
or
$ nvgstcapture --image-res=4

Image size is changed from 1280x720 to 1920x1080, but not angles.
When we modify image resolution, we expect image angle might be changed.

To get it, any idea please?

hello nvdpx2,

suppose you’re saying field-of-view.

that’s due to image sensor’s sub-sampling.
please check sensor specification for more details.
thanks

Hello JerryChang,

5MP OV5693 might be installed on the Jetson TX1/TX2.

nvgstcapture can make only VGA images even I change various parameters.
sub-sampling is useful when I can configure sensor resolutions.

To change default image size, e.g HD or FHD, should I dig kernel drive codes?
A command is preferred.

thanks

hello nvdpx2,

did you mean output different resolution with different sensor modes?
besides nvgstcapture, there’s gst-launch which have more straightforward options to configure the output resolution.
for example,

gst-launch-1.0 nvcamerasrc sensor-id=0 ! 'video/x-raw(memory:NVMM),width=1920, height=1080, framerate=30/1, format=NV12' ! nvoverlaysink -ev

it will also show the sensor capability, and the sensor mode used for streaming,
for example,

Available Sensor modes :
2592 x 1944 FR=30.000000 CF=0x1109208a10 SensorModeType=4 CSIPixelBitDepth=10 DynPixelBitDepth=10
2592 x 1458 FR=30.000000 CF=0x1109208a10 SensorModeType=4 CSIPixelBitDepth=10 DynPixelBitDepth=10
1280 x 720 FR=120.000000 CF=0x1109208a10 SensorModeType=4 CSIPixelBitDepth=10 DynPixelBitDepth=10
Pipeline is live and does not need PREROLL ...
Setting pipeline to PLAYING ...
New clock: GstSystemClock

NvCameraSrc: Trying To Set Default Camera Resolution. Selected sensorModeIndex = 1 WxH = 2592x1458 FrameRate = 30.000000 ...

Thanks JerryChang,

I tested what you said, gst-launch-1.0, that shows same result to nvgstcapture.
It simply changes screen resolution not input resolution too.

Hello JerryChang,

I contacted an OV(OmniVision) engineer to discuss this issue.
He said that OV5693 is a simple sensor without ISP, then it only transfer raw-data to some other ISP, here X1/X2.

To modify image resolution(not same view different H x W, but wider or narrower view),
device driver to control ISP should be handled, he said.

After several test on the Linux, I think TX1/TX2 ISP might fix an image resolution(H x W) like this.
If YES, I need how to modify that to make it.

Thanks,

hello nvdpx2,

you would like to see the FOV change, right?
please capture the video file with different aspect ratios for comparison.
thanks

4:3

gst-launch-1.0 nvcamerasrc sensor-id=0 num-buffers=100 ! 'video/x-raw(memory:NVMM), width=2592, height=1944, framerate=30/1' ! nvtee ! omxh264enc bitrate=20000000 ! qtmux ! filesink location=video.mp4

-vs-
16:9

gst-launch-1.0 nvcamerasrc sensor-id=0 num-buffers=100 ! 'video/x-raw(memory:NVMM), width=1920, height=1080, framerate=30/1' ! nvtee ! omxh264enc bitrate=20000000 ! qtmux ! filesink location=video.mp4

Hello JerryChang,

I tested your advice, and confirmed FoV is varied. (I will use FoV to distinguish from resolution)
However, it’s not understandable that there are very mere gap between width 2592 and 1920 video.
Even 640 x 480 FoV, it has similar result.

I’ve got Same result from different FoV images.

Any other advices?

Thanks,

hello nvdpx2,

please check your sensor specification,
in generally, sensor vendor would provide lower resolution image with maintaining the field-of-view.
this approach will used binning-mode (or something else) to subsampling the source image.

may i know what’s your use-case?
please illustrate your FoV expectation.
thanks

Hello JerryChang,

I asked datasheet of OV5693 sensor to local distributor.
(but he/she said this camera sensor does not configuration features and have no chances to change image resolutions)

My customer wants use various resolution images from a camera module by configuration.
I attach a image what I expect.

Thanks

hello nvdpx2,

you may use the nvvidconv element to crop the source image to output the desire region,
for example,
below command would crop an 640x480 region from source image,

gst-launch-1.0 nvcamerasrc sensor-id=0 ! 'video/x-raw(memory:NVMM),width=1920, height=1080, framerate=30/1, format=NV12' ! nvvidconv left=100 right=740 top=100 bottom=580 ! nvoverlaysink -ev

Hello JerryChang,

Thanks for your help.

I’ve tested and confirmed changed FoV.

If I ask more questions,
nvgstcapture util has a ‘j’ command to capture images,
does gst-launch-1.0 have any command to do this?
(captured image should have chaged FoV)

And, nvvidconv has 4 arguments; left, right, top, bottom.
It seems like that base coordinate, here, is (100, 100), and offset is 640 to row and 480 to column, isn’t it?

Thanks,

hello nvdpx2,

  1. you would like to capture a still image while previewing, right?
  2. yes, your expression of nvvidconv were correct.

Hello JerryChang,

Pretty SURE.
Want to take shots during preview.

Thanks,

hello nvdpx2,

unfortunately, gst-launch-1.0 don’t support keyevents interrupt.
since Argus is also based on gstreamer, you could check the Argus samples in the L4T Multimedia API.
please have the implementation for your use-case,
thanks

JerryChang,

That’s unfortunate news!
Customer should work for it!

Thanks,