Loading media/libmedia/AudioRecord.cpp +3 −3 Original line number Diff line number Diff line Loading @@ -47,9 +47,9 @@ status_t AudioRecord::getMinFrameCount( *frameCount = 0; size_t size = 0; if (AudioSystem::getInputBufferSize(sampleRate, format, channelMask, &size) != NO_ERROR) { ALOGE("AudioSystem could not query the input buffer size."); status_t status = AudioSystem::getInputBufferSize(sampleRate, format, channelMask, &size); if (status != NO_ERROR) { ALOGE("AudioSystem could not query the input buffer size; status %d", status); return NO_INIT; } Loading services/audioflinger/AudioFlinger.cpp +2 −2 Original line number Diff line number Diff line Loading @@ -464,7 +464,7 @@ sp<IAudioTrack> AudioFlinger::createTrack( PlaybackThread *thread = checkPlaybackThread_l(output); PlaybackThread *effectThread = NULL; if (thread == NULL) { ALOGE("unknown output thread"); ALOGE("no playback thread found for output handle %d", output); lStatus = BAD_VALUE; goto Exit; } Loading Loading @@ -589,7 +589,7 @@ uint32_t AudioFlinger::latency(audio_io_handle_t output) const Mutex::Autolock _l(mLock); PlaybackThread *thread = checkPlaybackThread_l(output); if (thread == NULL) { ALOGW("latency() unknown thread %d", output); ALOGW("latency(): no playback thread found for output handle %d", output); return 0; } return thread->latency(); Loading services/audioflinger/FastMixer.cpp +3 −3 Original line number Diff line number Diff line Loading @@ -388,9 +388,9 @@ bool FastMixer::threadLoop() if (ATRACE_ENABLED()) { // I wish we had formatted trace names char traceName[16]; strcpy(traceName, "framesReady"); traceName[11] = i + (i < 10 ? '0' : 'A' - 10); traceName[12] = '\0'; strcpy(traceName, "fRdy"); traceName[4] = i + (i < 10 ? '0' : 'A' - 10); traceName[5] = '\0'; ATRACE_INT(traceName, framesReady); } FastTrackDump *ftDump = &dumpState->mTracks[i]; Loading services/audioflinger/PlaybackTracks.h +3 −9 Original line number Diff line number Diff line Loading @@ -77,15 +77,9 @@ protected: virtual size_t framesReady() const; bool isPausing() const { return mState == PAUSING; } bool isPaused() const { return mState == PAUSED; } bool isResuming() const { return mState == RESUMING; } bool isPausing() const { return mState == PAUSING; } bool isPaused() const { return mState == PAUSED; } bool isResuming() const { return mState == RESUMING; } bool isReady() const; void setPaused() { mState = PAUSED; } void reset(); Loading services/audioflinger/Threads.cpp +3 −2 Original line number Diff line number Diff line Loading @@ -2795,7 +2795,7 @@ AudioFlinger::PlaybackThread::mixer_state AudioFlinger::MixerThread::prepareTrac // No buffers for this track. Give it a few chances to // fill a buffer, then remove it from active list. if (--(track->mRetryCount) <= 0) { ALOGV("BUFFER TIMEOUT: remove(%d) from active list on thread %p", name, this); ALOGI("BUFFER TIMEOUT: remove(%d) from active list on thread %p", name, this); tracksToRemove->add(track); // indicate to client process that the track was disabled because of underrun; // it will then automatically call start() when data is available Loading Loading @@ -3725,7 +3725,8 @@ bool AudioFlinger::RecordThread::threadLoop() readInto = mRsmpInBuffer; mRsmpInIndex = 0; } mBytesRead = mInput->stream->read(mInput->stream, readInto, mInputBytes); mBytesRead = mInput->stream->read(mInput->stream, readInto, mInputBytes); if (mBytesRead <= 0) { if ((mBytesRead < 0) && (mActiveTrack->mState == TrackBase::ACTIVE)) { Loading Loading
media/libmedia/AudioRecord.cpp +3 −3 Original line number Diff line number Diff line Loading @@ -47,9 +47,9 @@ status_t AudioRecord::getMinFrameCount( *frameCount = 0; size_t size = 0; if (AudioSystem::getInputBufferSize(sampleRate, format, channelMask, &size) != NO_ERROR) { ALOGE("AudioSystem could not query the input buffer size."); status_t status = AudioSystem::getInputBufferSize(sampleRate, format, channelMask, &size); if (status != NO_ERROR) { ALOGE("AudioSystem could not query the input buffer size; status %d", status); return NO_INIT; } Loading
services/audioflinger/AudioFlinger.cpp +2 −2 Original line number Diff line number Diff line Loading @@ -464,7 +464,7 @@ sp<IAudioTrack> AudioFlinger::createTrack( PlaybackThread *thread = checkPlaybackThread_l(output); PlaybackThread *effectThread = NULL; if (thread == NULL) { ALOGE("unknown output thread"); ALOGE("no playback thread found for output handle %d", output); lStatus = BAD_VALUE; goto Exit; } Loading Loading @@ -589,7 +589,7 @@ uint32_t AudioFlinger::latency(audio_io_handle_t output) const Mutex::Autolock _l(mLock); PlaybackThread *thread = checkPlaybackThread_l(output); if (thread == NULL) { ALOGW("latency() unknown thread %d", output); ALOGW("latency(): no playback thread found for output handle %d", output); return 0; } return thread->latency(); Loading
services/audioflinger/FastMixer.cpp +3 −3 Original line number Diff line number Diff line Loading @@ -388,9 +388,9 @@ bool FastMixer::threadLoop() if (ATRACE_ENABLED()) { // I wish we had formatted trace names char traceName[16]; strcpy(traceName, "framesReady"); traceName[11] = i + (i < 10 ? '0' : 'A' - 10); traceName[12] = '\0'; strcpy(traceName, "fRdy"); traceName[4] = i + (i < 10 ? '0' : 'A' - 10); traceName[5] = '\0'; ATRACE_INT(traceName, framesReady); } FastTrackDump *ftDump = &dumpState->mTracks[i]; Loading
services/audioflinger/PlaybackTracks.h +3 −9 Original line number Diff line number Diff line Loading @@ -77,15 +77,9 @@ protected: virtual size_t framesReady() const; bool isPausing() const { return mState == PAUSING; } bool isPaused() const { return mState == PAUSED; } bool isResuming() const { return mState == RESUMING; } bool isPausing() const { return mState == PAUSING; } bool isPaused() const { return mState == PAUSED; } bool isResuming() const { return mState == RESUMING; } bool isReady() const; void setPaused() { mState = PAUSED; } void reset(); Loading
services/audioflinger/Threads.cpp +3 −2 Original line number Diff line number Diff line Loading @@ -2795,7 +2795,7 @@ AudioFlinger::PlaybackThread::mixer_state AudioFlinger::MixerThread::prepareTrac // No buffers for this track. Give it a few chances to // fill a buffer, then remove it from active list. if (--(track->mRetryCount) <= 0) { ALOGV("BUFFER TIMEOUT: remove(%d) from active list on thread %p", name, this); ALOGI("BUFFER TIMEOUT: remove(%d) from active list on thread %p", name, this); tracksToRemove->add(track); // indicate to client process that the track was disabled because of underrun; // it will then automatically call start() when data is available Loading Loading @@ -3725,7 +3725,8 @@ bool AudioFlinger::RecordThread::threadLoop() readInto = mRsmpInBuffer; mRsmpInIndex = 0; } mBytesRead = mInput->stream->read(mInput->stream, readInto, mInputBytes); mBytesRead = mInput->stream->read(mInput->stream, readInto, mInputBytes); if (mBytesRead <= 0) { if ((mBytesRead < 0) && (mActiveTrack->mState == TrackBase::ACTIVE)) { Loading