Lines Matching refs:recordTrack
9089 status_t RecordThread::start(IAfRecordTrack* recordTrack, in start() argument
9098 recordTrack->clearSyncStartEvent(); in start()
9100 recordTrack->synchronizedRecordState().startRecording( in start()
9103 recordTrack->sessionId(), syncStartEventCallback, recordTrack)); in start()
9109 if (recordTrack->isInvalid()) { in start()
9110 recordTrack->clearSyncStartEvent(); in start()
9111 ALOGW("%s track %d: invalidated before startInput", __func__, recordTrack->portId()); in start()
9114 if (mActiveTracks.indexOf(recordTrack) >= 0) { in start()
9115 if (recordTrack->state() == IAfTrackBase::PAUSING) { in start()
9119 recordTrack->setState(IAfTrackBase::ACTIVE); in start()
9121 ALOGV("active record track state %d", (int)recordTrack->state()); in start()
9129 recordTrack->setState(IAfTrackBase::STARTING_1); in start()
9130 mActiveTracks.add(recordTrack); in start()
9131 if (recordTrack->isExternalTrack()) { in start()
9133 status = AudioSystem::startInput(recordTrack->portId()); in start()
9135 if (recordTrack->isInvalid()) { in start()
9136 recordTrack->clearSyncStartEvent(); in start()
9137 if (status == NO_ERROR && recordTrack->state() == IAfTrackBase::STARTING_1) { in start()
9138 recordTrack->setState(IAfTrackBase::STARTING_2); in start()
9141 ALOGW("%s track %d: invalidated after startInput", __func__, recordTrack->portId()); in start()
9144 if (recordTrack->state() != IAfTrackBase::STARTING_1) { in start()
9146 __func__, recordTrack->id(), (int)recordTrack->state()); in start()
9149 recordTrack->clearSyncStartEvent(); in start()
9155 __func__, recordTrack->id(), status); in start()
9158 mActiveTracks.remove(recordTrack); in start()
9159 recordTrack->clearSyncStartEvent(); in start()
9163 AUDIO_CLIENT_STARTED, recordTrack->creatorPid(), recordTrack->portId()); in start()
9166 recordTrack->logBeginInterval(patchSourcesToString(&mPatch)); // log to MediaMetrics in start()
9173 recordTrack->resamplerBufferProvider()->reset(); in start()
9174 if (!recordTrack->isDirect()) { in start()
9176 recordTrack->recordBufferConverter()->reset(); in start()
9178 recordTrack->setState(IAfTrackBase::STARTING_2); in start()
9199 bool RecordThread::stop(IAfRecordTrack* recordTrack) { in stop() argument
9203 if (mActiveTracks.indexOf(recordTrack) < 0 || recordTrack->state() == IAfTrackBase::PAUSING) { in stop()
9207 recordTrack->setState(IAfTrackBase::PAUSING); in stop()
9211 while (recordTrack->state() == IAfTrackBase::PAUSING && !recordTrack->isInvalid()) { in stop()
9216 if (recordTrack->state() == IAfTrackBase::PAUSED) { // successful stop in stop()
9223 __func__, recordTrack->id(), recordTrack->state()); in stop()