aravis icon indicating copy to clipboard operation
aravis copied to clipboard

Add Device Removal Callback

Open Dennis10231 opened this issue 3 years ago • 1 comments

Is your feature request related to a problem? Please describe. It would be nice if Aravis would support a callback in case a camera gets removed (unplugged, ...).

Describe the solution you'd like Libusb supports libusb_hotplug_register_callback() with the event type LIBUSB_HOTPLUG_EVENT_DEVICE_LEFT. This can be used to directly detect the USB event. For GigE, a missed heartbeat could trigger the same. Similar to the StreamGrabber callback, a user pointer would be nice.

Additional context This is a common feature in several camera SDKs and Aravis should support it as well.

Dennis10231 avatar Oct 27 '22 06:10 Dennis10231

Like control-lost signal ?

https://github.com/AravisProject/aravis/blob/0df6d6aa9eb54454ac821c8db5e58a02a5e5f2a4/src/arvcameratest.c#L655-L656

This signal is not documented yet, and we should provide a ArvCamera helper.

EmmanuelP avatar Oct 27 '22 06:10 EmmanuelP