-
-
Notifications
You must be signed in to change notification settings - Fork 226
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Multi Planar device support #233
Conversation
I've a RK3399 board which require multi-planar support too
Test this branch locally, it runs well! |
Could you confirm this PR works for your SBC? |
yeah, it works, but latency little bit higher in 1280x720@30fps, and laggy in higher resolution, thought it's cause by the software MJPG compression |
good! on my hardware the latency is ok and yes it can be laggy for high resolutions, but i guess it depends on the hardware too, i have 3 cpu cores busy for 1920x1080x60. |
nice work! let me know if need any help, have some experience in the video processing pipeline (capturing/encoding/decoding/rendering) |
Ping me when it will be ready. |
@mdevaev i think we are good |
Signed-off-by: Artem Mamonov <artyom.mamonov@gmail.com>
I'll merge it to a separate branch and review again. |
Okay, I made some fixes and merged it to master. Please test it. |
works as expected. |
Looking forward to support for H264 |
Some devices doesn't have V4L2_BUF_TYPE_VIDEO_CAPTURE support, but they can be a multi planar devices and have a bit different api (V4L2_BUF_TYPE_VIDEO_CAPTURE_MPLANE).
I have one of this devices NanoPC-T6 based on RK3588 SoC. One of the cool features of this device is HDMI IN support.
Also Orange Pi 5 Plus, Radxa Rock 5B and other SBC on RK3588 should work with it too.
v4l2-ctl --all
output:v4l2-ctl --list-formats-ext -d /dev/video0
output:Device has 4 pixel formats: NV24, NV16, NV12, BGR3 (BGR24). By default it works in NV24 mode. Device has no any controls, you can't set pixel format or resolution or fps.
To set device in BGR3 pixel format you have to use EDID.
I tested it with this one EDID:
Lines above turn on BGR3 pixel format, which is much easier to work and convert.
Command:
Environment:
Probably some devices can have multiple planes, with different pixel format(for example), i can't test it, so i hardcode plane count to 1 (e.g. index=0).
I am not a C/C++ developer, so let me know about mistakes.