Skip to content
Snippets Groups Projects
Commit e022f93e authored by Emmanuel Milou's avatar Emmanuel Milou
Browse files

Merge branch 'conference'

parents a43578c7 0728e685
Branches
Tags
No related merge requests found
......@@ -184,11 +184,11 @@ AudioStream::createStream (pa_context* c)
// parameters are defined as number of bytes
// 2048 bytes (1024 int16) is 20 ms at 44100 Hz
if (_streamType == PLAYBACK_STREAM) {
attributes->maxlength = 16000;
attributes->tlength = 2048;
attributes->prebuf = 2048;
attributes->minreq = 1024;
attributes->fragsize = 4096;
attributes->maxlength = 32000;
attributes->tlength = 8192;
attributes->prebuf = 4096;
attributes->minreq = 512;
attributes->fragsize = (uint32_t) -1;
pa_stream_connect_playback( s , NULL , attributes, PA_STREAM_INTERPOLATE_TIMING, &_volume, NULL);
// pa_stream_connect_playback (s , NULL , attributes, PA_STREAM_START_CORKED, &_volume, NULL);
} else if (_streamType == CAPTURE_STREAM) {
......@@ -197,10 +197,10 @@ AudioStream::createStream (pa_context* c)
// attributes->fragsize = (uint32_t)-1;
attributes->maxlength = 16000;
attributes->tlength = 1024;
attributes->prebuf = 1024;
attributes->tlength = 8192;
attributes->prebuf = 4096;
attributes->minreq = 512;
attributes->fragsize = 1024;
attributes->fragsize = (uint32_t) -1;
// pa_stream_connect_record (s , NULL , attributes , PA_STREAM_START_CORKED);
pa_stream_connect_record( s , NULL , attributes , PA_STREAM_INTERPOLATE_TIMING );
......
......@@ -57,7 +57,8 @@ static void stream_moved_callback(pa_stream *s UNUSED, void *userdata UNUSED)
static void playback_underflow_callback (pa_stream* s, void* userdata UNUSED)
{
_debug ("PulseLayer::Buffer Underflow\n");
pa_stream_trigger (s, NULL, NULL);
// pa_stream_trigger (s, NULL, NULL);
}
......@@ -546,6 +547,7 @@ void PulseLayer::writeToSpeaker (void)
if((tone == 0) && (file_tone == 0)) {
// _debug("maxNbBytesToGet: %i\n", maxNbBytesToGet);
bzero (out, maxNbBytesToGet);
pa_stream_write (playback->pulseStream(), out, maxNbBytesToGet, NULL, 0, PA_SEEK_RELATIVE);
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment