Hi:
at the struct tegra_channel_ioctl_ops which in the channel.c . I can’t found the value of .vidioc_s_crop , also the value of .vidioc_g_selection , .vidioc_g_crop .
Does it means : I can’t use V4L2’s ioctl VIDIOC_CROPCAP ,VIDIOC_S_CROP , VIDIOC_G_CROP?
version of my jetPack is 2.3.1 .
hello XuXiang,
may I have confirmation that you would like to crop the sources to produce smaller result images.
could you please upgrade your work to our latest JetPack release, thanks
hello Jerry:
I upgraded my jetPack to 3.3, and use sources_sync.sh to upgrade my kernel to tegra-l4t-r28.2.1 .
but I can't found the .vidioc_s_crop , .vidioc_g_crop in the channel.c (kernel/kernel-4.4/drivers
/media/platform/tegra/camera/vi/) .
static const struct v4l2_ioctl_ops tegra_channel_ioctl_ops = {
.vidioc_querycap = tegra_channel_querycap,
.vidioc_enum_framesizes = tegra_channel_enum_framesizes,
.vidioc_enum_frameintervals = tegra_channel_enum_frameintervals,
.vidioc_enum_fmt_vid_cap = tegra_channel_enum_format,
.vidioc_g_fmt_vid_cap = tegra_channel_get_format,
.vidioc_s_fmt_vid_cap = tegra_channel_set_format,
.vidioc_try_fmt_vid_cap = tegra_channel_try_format,
.vidioc_reqbufs = vb2_ioctl_reqbufs,
.vidioc_querybuf = vb2_ioctl_querybuf,
.vidioc_qbuf = vb2_ioctl_qbuf,
.vidioc_dqbuf = vb2_ioctl_dqbuf,
.vidioc_create_bufs = vb2_ioctl_create_bufs,
.vidioc_expbuf = vb2_ioctl_expbuf,
.vidioc_streamon = vb2_ioctl_streamon,
.vidioc_streamoff = vb2_ioctl_streamoff,
.vidioc_g_edid = tegra_channel_g_edid,
.vidioc_s_edid = tegra_channel_s_edid,
.vidioc_s_dv_timings = tegra_channel_s_dv_timings,
.vidioc_g_dv_timings = tegra_channel_g_dv_timings,
.vidioc_query_dv_timings = tegra_channel_query_dv_timings,
.vidioc_enum_dv_timings = tegra_channel_enum_dv_timings,
.vidioc_dv_timings_cap = tegra_channel_dv_timings_cap,
.vidioc_subscribe_event = tegra_channel_subscribe_event,
.vidioc_unsubscribe_event = v4l2_event_unsubscribe,
.vidioc_enum_input = tegra_channel_enum_input,
.vidioc_g_input = tegra_channel_g_input,
.vidioc_s_input = tegra_channel_s_input,
.vidioc_log_status = tegra_channel_log_status,
};
Waiting for your good news ,thanks.
hello XuXiang,
it’s standard v4l2 control, you may have implementation by yourself.
may I have your description of the use-case that you would like to crop the sources from low-level side?
you could use the nvvidconv for an alternative way,
for example.
gst-launch-1.0 nvcamerasrc sensor-id=0 ! 'video/x-raw(memory:NVMM),width=2592, height=1944, framerate=30/1, format=NV12' ! nvvidconv ! 'video/x-raw(memory:NVMM), width=1920,height=1080,format=(string)NV12' ! nvoverlaysink -ev
hello jerry:
yes,we use VIDIOC_S_CROP to crop the image.
I will send the messgae about nvcamerasrc to our application software engineer ,thanks.