зеркало из https://github.com/mozilla/cubeb.git
Update sndio backend.
This commit is contained in:
Родитель
ae44ce98f8
Коммит
098b9f21bf
|
@ -177,7 +177,7 @@ sndio_stream_init(cubeb * context,
|
|||
cubeb_stream_params * input_stream_params,
|
||||
cubeb_devid output_device,
|
||||
cubeb_stream_params * output_stream_params,
|
||||
unsigned int latency,
|
||||
unsigned int latency_frames,
|
||||
cubeb_data_callback data_callback,
|
||||
cubeb_state_callback state_callback,
|
||||
void *user_ptr)
|
||||
|
@ -222,7 +222,7 @@ sndio_stream_init(cubeb * context,
|
|||
}
|
||||
wpar.rate = output_stream_params->rate;
|
||||
wpar.pchan = output_stream_params->channels;
|
||||
wpar.appbufsz = latency * wpar.rate / 1000;
|
||||
wpar.appbufsz = latency_frames;
|
||||
if (!sio_setpar(s->hdl, &wpar) || !sio_getpar(s->hdl, &rpar)) {
|
||||
sio_close(s->hdl);
|
||||
free(s);
|
||||
|
@ -290,7 +290,7 @@ static int
|
|||
sndio_get_min_latency(cubeb * ctx, cubeb_stream_params params, uint32_t * latency_ms)
|
||||
{
|
||||
// XXX Not yet implemented.
|
||||
*latency_ms = 40;
|
||||
*latency = 2048;
|
||||
|
||||
return CUBEB_OK;
|
||||
}
|
||||
|
|
Загрузка…
Ссылка в новой задаче