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

Make camera fulfill the io.ReadCloser interface #15

Open
marcoshuck opened this issue Aug 21, 2024 · 0 comments
Open

Make camera fulfill the io.ReadCloser interface #15

marcoshuck opened this issue Aug 21, 2024 · 0 comments

Comments

@marcoshuck
Copy link

marcoshuck commented Aug 21, 2024

I recently needed to write camera input to a stream in a QUIC server. To achieve this, I had to implement a custom adapter (reference). This experience highlights a real-world use case where the Camera struct naturally benefits from implementing io.ReadCloser. Having this functionality directly within the Vidio package would help people with similar use cases.

From the top of my head, it would require to:

  1. Rename Read to CanRead
  2. Implement Read from io.Reader in Camera.
  3. Make Close return an error.

By the way, thanks for putting this package together, it was literally plug and play.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant