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

FR: Add support for USB cameras #23

Closed
roamingthings opened this issue Feb 5, 2023 · 5 comments
Closed

FR: Add support for USB cameras #23

roamingthings opened this issue Feb 5, 2023 · 5 comments
Assignees
Labels
enhancement New feature or request

Comments

@roamingthings
Copy link
Collaborator

The use-case we are targeting with spyglass my include setups where Raspberry Pi cameras are used along with general USB cameras.

It's important to note that spyglass will only allow to use one camera at a time (e.g. if there is more than one camera you have to start spyglass multiple times).

Spyglass should be able to use USB cameras to capture images and videos.

Questions

  • Why do we need to support USB cameras
  • Are there any other projects that suite this use-case better than wie can/will do?
  • If there are other projects does this imply performance issues on the system that we aim to support (Raspberry Pi with restricted resources)
@mryel00
Copy link
Owner

mryel00 commented Feb 5, 2023

One of the goals of this project is to support camera module v3 with crowsnest.
As @KwadFan reported previously there might be some issues with USB cameras and ustreamer on Raspberry Pi if you disable the legacy camera stack.
The support of USB cameras with spyglass would solve this issue without the need of installing/building other projects or installing extra dependencies for them.
One positive thing about the direct implementation would be that USB cameras can be controlled like CSI cameras without the need of an interface for another tool.
We only grab the frames directly from the camera without encoding anything, so there won't be much performance gains from another library.

@roamingthings
Copy link
Collaborator Author

Sounds good. Thanks for clarification.

@stijnb1234
Copy link

Is it currently already possible to use USB camera's with Spyglass in combination with other software?

@mryel00
Copy link
Owner

mryel00 commented Aug 27, 2023

@stijnb1234 The problem isn't and never will be spyglass directly. The only problem would be about libcamera, but it seems like it was just a configuration error that lead to this conclusion iirc.
So there shouldn't be any problems if you use an USB camera, relying on the normal UVC driver of linux.
As #10 is already a long time on stale and I recently looked into the USB camera support of picamera2 again, I might work on it so that you can use USB cameras directly with spyglass, as this FR intends.

@mryel00
Copy link
Owner

mryel00 commented Aug 14, 2024

Merged with #10

@mryel00 mryel00 closed this as completed Aug 14, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

3 participants