device: add device object

Make a device object, let the v4l2 monitor create device objects
The device object is responsible for dynamically creating nodes.
This commit is contained in:
Wim Taymans 2018-11-23 12:43:47 +01:00
parent 79253c6d46
commit e1bd12e599
43 changed files with 1784 additions and 237 deletions

View file

@ -29,6 +29,7 @@
extern const struct spa_handle_factory spa_alsa_source_factory;
extern const struct spa_handle_factory spa_alsa_sink_factory;
extern const struct spa_handle_factory spa_alsa_monitor_factory;
extern const struct spa_handle_factory spa_alsa_device_factory;
int spa_handle_factory_enum(const struct spa_handle_factory **factory, uint32_t *index)
{
@ -45,6 +46,9 @@ int spa_handle_factory_enum(const struct spa_handle_factory **factory, uint32_t
case 2:
*factory = &spa_alsa_monitor_factory;
break;
case 3:
*factory = &spa_alsa_device_factory;
break;
default:
return 0;
}