gst: deviceprodiver: Add fd property / camera portal support

Add a `fd` property to `GstPipeWireDeviceProvider` so it can be used
with fds obtained from e.g. the camera xdg-desktop-portal.

This is needed so apps like Cheese or Camera can easily implement the
camera portal.
This commit is contained in:
Robert Mader 2022-12-27 23:27:52 +01:00
parent 2bc3e0ca10
commit be99aa1eba
2 changed files with 39 additions and 5 deletions

View file

@ -58,6 +58,7 @@ struct _GstPipeWireDevice {
GstPipeWireDeviceType type;
uint32_t id;
uint64_t serial;
int fd;
const gchar *element;
};
@ -82,6 +83,7 @@ struct _GstPipeWireDeviceProvider {
GstDeviceProvider parent;
gchar *client_name;
int fd;
GstPipeWireCore *core;
struct spa_hook core_listener;