/frameworks/av/media/libstagefright/ |
D | MediaSync.cpp | 314 int64_t nowUs = ALooper::GetNowUs(); in updateQueuedAudioData() local 317 + getPlayedOutAudioDurationMedia_l(nowUs); in updateQueuedAudioData() 323 oldRealTime = getRealTime(mNextBufferItemMediaUs, nowUs); in updateQueuedAudioData() 326 mMediaClock->updateAnchor(nowMediaUs, nowUs, maxMediaTimeUs); in updateQueuedAudioData() 330 int64_t newRealTime = getRealTime(mNextBufferItemMediaUs, nowUs); in updateQueuedAudioData() 466 int64_t MediaSync::getRealTime(int64_t mediaTimeUs, int64_t nowUs) { in getRealTime() argument 471 return nowUs; in getRealTime() 480 int64_t MediaSync::getPlayedOutAudioDurationMedia_l(int64_t nowUs) { in getPlayedOutAudioDurationMedia_l() argument 497 numFramesPlayedAtUs = nowUs; in getPlayedOutAudioDurationMedia_l() 504 numFramesPlayedAtUs = nowUs; in getPlayedOutAudioDurationMedia_l() [all …]
|
D | ThrottledSource.cpp | 45 int64_t nowUs = ALooper::GetNowUs(); in readAt() local 48 mStartTimeUs = nowUs; in readAt() 58 if (whenUs > nowUs) { in readAt() 59 usleep(whenUs - nowUs); in readAt()
|
D | MediaClock.cpp | 99 int64_t nowUs = ALooper::GetNowUs(); in updateAnchor() local 101 anchorTimeMediaUs + (nowUs - anchorTimeRealUs) * (double)mPlaybackRate; in updateAnchor() 112 mAnchorTimeMediaUs + (nowUs - mAnchorTimeRealUs) * (double)mPlaybackRate; in updateAnchor() 118 updateAnchorTimesAndPlaybackRate_l(nowMediaUs, nowUs, mPlaybackRate); in updateAnchor() 137 int64_t nowUs = ALooper::GetNowUs(); in setPlaybackRate() local 138 int64_t nowMediaUs = mAnchorTimeMediaUs + (nowUs - mAnchorTimeRealUs) * (double)mPlaybackRate; in setPlaybackRate() 143 updateAnchorTimesAndPlaybackRate_l(nowMediaUs, nowUs, rate); in setPlaybackRate() 198 int64_t nowUs = ALooper::GetNowUs(); in getRealTimeFor() local 201 getMediaTime_l(nowUs, &nowMediaUs, true /* allowPastMaxTime */); in getRealTimeFor() 205 *outRealUs = (targetMediaUs - nowMediaUs) / (double)mPlaybackRate + nowUs; in getRealTimeFor()
|
/frameworks/av/media/libstagefright/foundation/ |
D | ALooper.cpp | 173 int64_t nowUs = GetNowUs(); in post() local 174 whenUs = (delayUs > INT64_MAX - nowUs ? INT64_MAX : nowUs + delayUs); in post() 209 int64_t nowUs = GetNowUs(); in loop() local 211 if (whenUs > nowUs) { in loop() 212 int64_t delayUs = whenUs - nowUs; in loop()
|
/frameworks/av/media/libmediaplayerservice/nuplayer/ |
D | NuPlayerRenderer.cpp | 380 int64_t nowUs = ALooper::GetNowUs(); in getCurrentPosition() local 381 int64_t playedOutDurationUs = mAudioSink->getPlayedOutDurationUs(nowUs); in getCurrentPosition() 387 mMediaClock->updateAnchor(nowMediaUs, nowUs, -1); in getCurrentPosition() 926 int64_t nowUs = ALooper::GetNowUs(); in fillAudioBuffer() local 928 mAudioFirstAnchorTimeMediaUs + mAudioSink->getPlayedOutDurationUs(nowUs); in fillAudioBuffer() 930 mMediaClock->updateAnchor(nowMediaUs, nowUs, INT64_MAX); in fillAudioBuffer() 1173 int64_t NuPlayer::Renderer::getPendingAudioPlayoutDurationUs(int64_t nowUs) { in getPendingAudioPlayoutDurationUs() argument 1176 int64_t nowUs = ALooper::GetNowUs(); in getPendingAudioPlayoutDurationUs() local 1178 if (mMediaClock->getMediaTime(nowUs, &mediaUs) != OK) { in getPendingAudioPlayoutDurationUs() 1185 const int64_t audioSinkPlayedUs = mAudioSink->getPlayedOutDurationUs(nowUs); in getPendingAudioPlayoutDurationUs() [all …]
|
D | NuPlayerRenderer.h | 225 int64_t *mediaUs, int64_t nowUs, bool allowPastQueuedVideo = false); 228 int64_t *mediaUs, int64_t nowUs, bool allowPastQueuedVideo = false); 235 int64_t getPendingAudioPlayoutDurationUs(int64_t nowUs); 244 int64_t getRealTimeUs(int64_t mediaTimeUs, int64_t nowUs);
|
/frameworks/av/media/libmediaplayer2/nuplayer2/ |
D | NuPlayer2Renderer.cpp | 371 int64_t nowUs = ALooper::GetNowUs(); in getCurrentPosition() local 372 int64_t nowMediaUs = mAudioSink->getPlayedOutDurationUs(nowUs) in getCurrentPosition() 374 mMediaClock->updateAnchor(nowMediaUs, nowUs, -1); in getCurrentPosition() 913 int64_t nowUs = ALooper::GetNowUs(); in fillAudioBuffer() local 915 mAudioFirstAnchorTimeMediaUs + mAudioSink->getPlayedOutDurationUs(nowUs); in fillAudioBuffer() 917 mMediaClock->updateAnchor(nowMediaUs, nowUs, INT64_MAX); in fillAudioBuffer() 1159 int64_t NuPlayer2::Renderer::getPendingAudioPlayoutDurationUs(int64_t nowUs) { in getPendingAudioPlayoutDurationUs() argument 1162 int64_t nowUs = ALooper::GetNowUs(); in getPendingAudioPlayoutDurationUs() local 1164 if (mMediaClock->getMediaTime(nowUs, &mediaUs) != OK) { in getPendingAudioPlayoutDurationUs() 1171 const int64_t audioSinkPlayedUs = mAudioSink->getPlayedOutDurationUs(nowUs); in getPendingAudioPlayoutDurationUs() [all …]
|
D | NuPlayer2Renderer.h | 226 int64_t *mediaUs, int64_t nowUs, bool allowPastQueuedVideo = false); 229 int64_t *mediaUs, int64_t nowUs, bool allowPastQueuedVideo = false); 236 int64_t getPendingAudioPlayoutDurationUs(int64_t nowUs); 245 int64_t getRealTimeUs(int64_t mediaTimeUs, int64_t nowUs);
|
/frameworks/av/media/extractors/mp3/ |
D | VBRISeeker.cpp | 174 int64_t nowUs = 0; in getOffsetForTime() local 177 while (segmentIndex < mSegments.size() && nowUs < *timeUs) { in getOffsetForTime() 178 nowUs += segmentDurationUs; in getOffsetForTime() 184 *timeUs = nowUs; in getOffsetForTime()
|
/frameworks/av/media/libstagefright/rtsp/ |
D | UDPPusher.cpp | 105 int64_t nowUs = ALooper::GetNowUs(); in onPush() local 106 (new AMessage(kWhatPush, this))->post(whenUs - nowUs); in onPush()
|
D | ARTPSource.cpp | 182 int64_t nowUs = ALooper::GetNowUs(); in addFIR() local 183 if (mLastFIRRequestUs >= 0 && mLastFIRRequestUs + 5000000LL > nowUs) { in addFIR() 188 mLastFIRRequestUs = nowUs; in addFIR()
|
D | ARTPWriter.cpp | 421 uint64_t nowUs = ALooper::GetNowUs(); in GetNowNTP() local 423 nowUs += ((70LL * 365 + 17) * 24) * 60 * 60 * 1000000LL; in GetNowNTP() 425 uint64_t hi = nowUs / 1000000LL; in GetNowNTP() 426 uint64_t lo = ((1LL << 32) * (nowUs % 1000000LL)) / 1000000LL; in GetNowNTP()
|
D | ARTPConnection.cpp | 308 int64_t nowUs = ALooper::GetNowUs(); in onPollStreams() local 310 || mLastReceiverReportTimeUs + 5000000LL <= nowUs) { in onPollStreams() 361 mLastReceiverReportTimeUs = nowUs; in onPollStreams()
|
D | MyTransmitter.h | 144 uint64_t nowUs = tv.tv_sec * 1000000ll + tv.tv_usec; in ntpTime() local 146 nowUs += ((70ll * 365 + 17) * 24) * 60 * 60 * 1000000ll; in ntpTime() 148 uint64_t hi = nowUs / 1000000ll; in ntpTime() 149 uint64_t lo = ((1ll << 32) * (nowUs % 1000000ll)) / 1000000ll; in ntpTime()
|
/frameworks/av/media/libstagefright/include/media/stagefright/ |
D | MediaSync.h | 236 int64_t getRealTime(int64_t mediaTimeUs, int64_t nowUs); 238 int64_t getPlayedOutAudioDurationMedia_l(int64_t nowUs);
|
/frameworks/av/media/libmediaplayer2/ |
D | MediaPlayer2AudioOutput.cpp | 182 int64_t MediaPlayer2AudioOutput::getPlayedOutDurationUs(int64_t nowUs) const { in getPlayedOutDurationUs() 201 numFramesPlayedAtUs = nowUs; in getPlayedOutDurationUs() 209 + nowUs - numFramesPlayedAtUs; in getPlayedOutDurationUs() 222 (long long)durationUs, (long long)nowUs, in getPlayedOutDurationUs()
|
/frameworks/base/media/jni/ |
D | android_media_MediaSync.cpp | 285 int64_t nowUs = ALooper::GetNowUs(); in android_media_MediaSync_native_getTimestamp() local 287 if (mediaClock->getMediaTime(nowUs, &mediaUs) != OK) { in android_media_MediaSync_native_getTimestamp() 294 (jlong)(nowUs * 1000)); in android_media_MediaSync_native_getTimestamp()
|
/frameworks/av/cmds/stagefright/ |
D | SimplePlayer.cpp | 512 int64_t nowUs = ALooper::GetNowUs(); in onDoMoreStuff() local 515 mStartTimeRealUs = nowUs + 1000000ll; in onDoMoreStuff() 525 int64_t lateByUs = nowUs - whenRealUs; in onDoMoreStuff()
|
/frameworks/av/media/libmediaplayer2/include/mediaplayer2/ |
D | MediaPlayer2AudioOutput.h | 57 virtual int64_t getPlayedOutDurationUs(int64_t nowUs) const;
|
D | MediaPlayer2Interface.h | 94 virtual int64_t getPlayedOutDurationUs(int64_t nowUs) const = 0;
|
/frameworks/base/media/java/android/media/ |
D | MediaPlayer.java | 5745 long nowUs; in notifyTimedEvent() local 5747 nowUs = getCurrentTimeUs(refreshTime, true); in notifyTimedEvent() 5752 nowUs = getCurrentTimeUs(refreshTime, true); in notifyTimedEvent() 5754 long nextTimeUs = nowUs; in notifyTimedEvent() 5764 .append(nowUs).append(") from {"); in notifyTimedEvent() 5786 } else if (mTimes[ix] <= nowUs + MAX_EARLY_CALLBACK_US) { in notifyTimedEvent() 5790 } else if (nextTimeUs == nowUs || mTimes[ix] < nextTimeUs) { in notifyTimedEvent() 5795 if (nextTimeUs > nowUs && !mPaused) { in notifyTimedEvent() 5797 if (DEBUG) Log.d(TAG, "scheduling for " + nextTimeUs + " and " + nowUs); in notifyTimedEvent() 5805 listener.onTimedEvent(nowUs); in notifyTimedEvent()
|
/frameworks/av/include/media/ |
D | MediaPlayerInterface.h | 106 virtual int64_t getPlayedOutDurationUs(int64_t nowUs) const = 0;
|
/frameworks/av/media/libmediaplayerservice/include/ |
D | MediaPlayerInterface.h | 106 virtual int64_t getPlayedOutDurationUs(int64_t nowUs) const = 0;
|
/frameworks/av/media/libmediaplayerservice/ |
D | MediaPlayerService.cpp | 1723 int64_t MediaPlayerService::AudioOutput::getPlayedOutDurationUs(int64_t nowUs) const in getPlayedOutDurationUs() 1741 numFramesPlayedAtUs = nowUs; in getPlayedOutDurationUs() 1747 numFramesPlayedAtUs = nowUs; in getPlayedOutDurationUs() 1755 + nowUs - numFramesPlayedAtUs; in getPlayedOutDurationUs() 1768 (long long)durationUs, (long long)nowUs, in getPlayedOutDurationUs()
|
D | MediaPlayerService.h | 94 virtual int64_t getPlayedOutDurationUs(int64_t nowUs) const;
|