Commit c9670a0e authored by Adrien Béraud's avatar Adrien Béraud

opensl: avoid stopping record if buffer queue is empty

Change-Id: I0c2a06afd0a3c73bb64a64ece119f7ea65f54064
parent 0dfbe2c2
...@@ -27,7 +27,7 @@ namespace opensl { ...@@ -27,7 +27,7 @@ namespace opensl {
/* /*
* Sample Buffer Controls... * Sample Buffer Controls...
*/ */
#define RECORD_DEVICE_KICKSTART_BUF_COUNT 2 #define RECORD_DEVICE_KICKSTART_BUF_COUNT 4
#define PLAY_KICKSTART_BUFFER_COUNT 8 #define PLAY_KICKSTART_BUFFER_COUNT 8
#define DEVICE_SHADOW_BUFFER_QUEUE_LEN 4 #define DEVICE_SHADOW_BUFFER_QUEUE_LEN 4
#define BUF_COUNT 16 #define BUF_COUNT 16
......
...@@ -51,9 +51,9 @@ AudioRecorder::processSLCallback(SLAndroidSimpleBufferQueueItf bq) ...@@ -51,9 +51,9 @@ AudioRecorder::processSLCallback(SLAndroidSimpleBufferQueueItf bq)
} }
// should leave the device to sleep to save power if no buffers // should leave the device to sleep to save power if no buffers
if (devShadowQueue_.size() == 0) { /*if (devShadowQueue_.size() == 0) {
(*recItf_)->SetRecordState(recItf_, SL_RECORDSTATE_STOPPED); (*recItf_)->SetRecordState(recItf_, SL_RECORDSTATE_STOPPED);
} }*/
callback_(); callback_();
} catch (const std::exception& e) { } catch (const std::exception& e) {
JAMI_ERR("processSLCallback exception: %s", e.what()); JAMI_ERR("processSLCallback exception: %s", e.what());
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment