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

Preview last frame when external camera is removed. #707

Open
aaron23v opened this issue Jul 30, 2024 · 5 comments
Open

Preview last frame when external camera is removed. #707

aaron23v opened this issue Jul 30, 2024 · 5 comments

Comments

@aaron23v
Copy link

Just wanted to know, how can we implement this?

When the external camera is detached / removed, i want to preview the last frame and when it is attached back, it should start working as normal. Need some guidance

@Clark-caipeiyuan
Copy link

Clark-caipeiyuan commented Jul 30, 2024 via email

@fbzhong
Copy link

fbzhong commented Jul 30, 2024

I would suggest you to use ImageReader & ImageWriter as a proxy between UVCCamera and Surface.

Set ImageReader as UVCCamera set preview display. And then enqueue to ImageWriter in onImageAvailable listener. Then you could always keep the last Image (into Bitmap)

@aaron23v
Copy link
Author

I would suggest you to use ImageReader & ImageWriter as a proxy between UVCCamera and Surface.

Set ImageReader as UVCCamera set preview display. And then enqueue to ImageWriter in onImageAvailable listener. Then you could always keep the last Image (into Bitmap)

Thanks for this advice. Will check it out

@Clark-caipeiyuan
Copy link

Clark-caipeiyuan commented Jan 16, 2025 via email

@AaronDsilva97
Copy link

Hi, could you please clarify in which file or folder I should add the ImageReader and image queuing logic in the UVCCamera project?

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

4 participants