3588修改行对齐
-
@veye_xumm 为什么用python预览图像就没有黑边,自己采集保存出来图像就有黑边了,我的图像分辨率为1920*1200,v4l2-ctl -all查看bytes per line 参数是2048,有办法去掉黑边吗?
-
@lin
试试下面这个脚本export WIDTH=1920 export HEIGHT=1200 export FPS=60 v4l2-ctl -d /dev/v4l-subdev2 --set-ctrl roi_x=0 v4l2-ctl -d /dev/v4l-subdev2 --set-ctrl roi_y=0 media-ctl -d /dev/media0 --set-v4l2 '"m00_b_mvcam 7-003b":0[fmt:Y8_1X8/'"$WIDTH"'x'"$HEIGHT"'@1/'"$FPS"']' v4l2-ctl -d /dev/video0 --set-fmt-video=width=$WIDTH,height=$HEIGHT,pixelformat=GREY --stream-mmap --stream-count=1 --stream-to=y8-${WIDTH}x${HEIGHT}.raw -
@veye_xumm还是有黑边呀?
-
@lin 文件大小是多少?
-
@veye_xumm 2.34M
-
@lin 你可以看看具体的大小,精确到字节。 1920*1200=2304000bytes
-
@veye_xumm 2457600字节,我算过1200行,每行是2048
-
@lin 确实有这个现象。回头我研究一下是怎么回事。
-
@lin 我理解这个Bytes per Line是rkcif驱动里面,自动根据camera的分辨率计算的,没有留v4l-ctl进行配置的接口。如果要改动,需要修改一下rockchip的rkcif源码。rk这么做的目的应该是出于整个系统一些硬件模块操作的方便性。
暂时建议你保留这个状况,你的程序处理的时候忽略掉多余的部分。 -
@veye_xumm 好的,谢谢
Hello! It looks like you're interested in this conversation, but you don't have an account yet.
Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.
With your input, this post could be even better 💗
Register Login