Add sync and async support in *testsrc

Make minumum alsa latency configurable.
This commit is contained in:
Wim Taymans 2017-04-03 16:54:44 +02:00
parent 01c13adab5
commit 5c32690cc8
13 changed files with 186 additions and 153 deletions

View file

@ -51,6 +51,8 @@ pinos_spa_node_load (PinosCore *core,
SpaEnumHandleFactoryFunc enum_func;
const SpaHandleFactory *factory;
void *iface;
SpaDictItem items[1];
SpaDict dict = SPA_DICT_INIT (1, items);
if ((hnd = dlopen (lib, RTLD_NOW)) == NULL) {
pinos_log_error ("can't load %s: %s", lib, dlerror());
@ -71,10 +73,13 @@ pinos_spa_node_load (PinosCore *core,
break;
}
items[0].key = "asynchronous";
items[0].value = "1";
handle = calloc (1, factory->size);
if ((res = spa_handle_factory_init (factory,
handle,
NULL,
&dict,
core->support,
core->n_support)) < 0) {
pinos_log_error ("can't make factory instance: %d", res);