Skip to content
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

[PEN-164] feat(v4l2): add support for v4l2loopback dummy device #87

Draft
wants to merge 1 commit into
base: master
Choose a base branch
from
Draft
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 3 additions & 1 deletion actfw_core/v4l2/video.py
Original file line number Diff line number Diff line change
Expand Up @@ -811,7 +811,7 @@ def requeue_buffer(self, video_buf):
raise RuntimeError("ioctl(VIDIOC_QBUF): {}".format(errno.errorcode[get_errno()]))


VideoPort = enum.Enum("VideoPort", "CSI USB")
VideoPort = enum.Enum("VideoPort", "CSI USB DUMMY")


class VideoConfig(object):
Expand Down Expand Up @@ -863,6 +863,8 @@ def query_capability(self):
return VideoPort.CSI
elif driver[: len("uvcvideo")] == "uvcvideo":
return VideoPort.USB
elif driver == "v4l2 loopback":
return VideoPort.DUMMY
else:
raise RuntimeError("unknown driver '{}'".format(driver))

Expand Down