Commit e95c461c authored by Alexandre Bourget's avatar Alexandre Bourget
Browse files

Comments and cleanups.

parent 86343ef2
...@@ -261,14 +261,14 @@ AudioRtpRTX::sendSessionFromMic(int timestamp) ...@@ -261,14 +261,14 @@ AudioRtpRTX::sendSessionFromMic(int timestamp)
// available bytes inside ringbuffer // available bytes inside ringbuffer
int availBytesFromMic = audiolayer->canGetMic(); int availBytesFromMic = audiolayer->canGetMic();
// take the lower // take the lowest
int bytesAvail = (availBytesFromMic < maxBytesToGet) ? availBytesFromMic : maxBytesToGet; int bytesAvail = (availBytesFromMic < maxBytesToGet) ? availBytesFromMic : maxBytesToGet;
//_debug("available = %d, maxBytesToGet = %d\n", availBytesFromMic, maxBytesToGet); //_debug("available = %d, maxBytesToGet = %d\n", availBytesFromMic, maxBytesToGet);
// Get bytes from micRingBuffer to data_from_mic // Get bytes from micRingBuffer to data_from_mic
int nbSample = audiolayer->getMic(_dataAudioLayer, bytesAvail) / sizeof(SFLDataFormat); int nbSample = audiolayer->getMic(_dataAudioLayer, bytesAvail) / sizeof(SFLDataFormat);
int16* toSIP = 0; int16* toSIP = NULL;
if (audiolayer->getSampleRate() != audiocodec->getClockRate() && nbSample) { if (audiolayer->getSampleRate() != audiocodec->getClockRate() && nbSample) {
SRC_DATA src_data; SRC_DATA src_data;
#ifdef DATAFORMAT_IS_FLOAT #ifdef DATAFORMAT_IS_FLOAT
...@@ -331,7 +331,7 @@ AudioRtpRTX::sendSessionFromMic(int timestamp) ...@@ -331,7 +331,7 @@ AudioRtpRTX::sendSessionFromMic(int timestamp)
} else { } else {
_session->putData(timestamp, _sendDataEncoded, compSize); _session->putData(timestamp, _sendDataEncoded, compSize);
} }
toSIP = 0; toSIP = NULL;
} catch(...) { } catch(...) {
_debugException("! ARTP: sending failed"); _debugException("! ARTP: sending failed");
throw; throw;
......
...@@ -51,7 +51,9 @@ public: ...@@ -51,7 +51,9 @@ public:
void setFormat(int format); void setFormat(int format);
/** /**
* Get format * Get format for the voice codec used
*
* Bitmask for codecs defined in iax/frame.h
*/ */
int getFormat() { return _format; } int getFormat() { return _format; }
......
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