Backed out changeset 7d6255d1c547 (bug 816664)

This commit is contained in:
Josh Matthews 2012-12-28 19:03:48 -05:00
parent abd926c8f3
commit 24b5b26242
3 changed files with 6 additions and 13 deletions

View File

@ -215,7 +215,6 @@ protected:
void AppendFromInternal(MediaSegmentBase<C, Chunk>* aSource)
{
static_cast<C*>(this)->CheckCompatible(*static_cast<C*>(aSource));
MOZ_ASSERT(aSource->mDuration >= 0);
mDuration += aSource->mDuration;
aSource->mDuration = 0;
if (!mChunks.IsEmpty() && !aSource->mChunks.IsEmpty() &&
@ -249,7 +248,6 @@ protected:
Chunk* AppendChunk(TrackTicks aDuration)
{
MOZ_ASSERT(aDuration >= 0);
Chunk* c = mChunks.AppendElement();
c->mDuration = aDuration;
mDuration += aDuration;

View File

@ -146,7 +146,7 @@ MediaEngineWebRTCAudioSource::NotifyPull(MediaStreamGraph* aGraph,
static TrackTicks mLastEndTime = 0;
TrackTicks target = TimeToTicksRoundUp(SAMPLE_FREQUENCY, aDesiredTime);
TrackTicks delta = target - mLastEndTime;
LOG(("Audio: NotifyPull: aDesiredTime %ld, target %ld, delta %ld",(int64_t) aDesiredTime, (int64_t) target, (int64_t) delta));
LOG(("Audio:NotifyPull: target %lu, delta %lu",(uint32_t) target, (uint32_t) delta));
mLastEndTime = target;
#endif
}

View File

@ -15,7 +15,6 @@ extern PRLogModuleInfo* GetMediaManagerLog();
#else
#define LOG(msg)
#endif
#define LOG_ALL_FRAMES 1
/**
* Webrtc video source.
@ -111,16 +110,12 @@ MediaEngineWebRTCVideoSource::NotifyPull(MediaStreamGraph* aGraph,
TrackTicks target = TimeToTicksRoundUp(USECS_PER_S, aDesiredTime);
TrackTicks delta = target - mLastEndTime;
#ifdef LOG_ALL_FRAMES
LOG(("NotifyPull, desired = %ld, target = %ld, delta = %ld", (int64_t) aDesiredTime, (int64_t) target, (int64_t) delta));
LOG(("NotifyPull, target = %lu, delta = %lu", (uint64_t) target, (uint64_t) delta));
#endif
// Don't append if we've already provided a frame that supposedly goes past the current aDesiredTime
// Doing so means a negative delta and thus messes up handling of the graph
if (delta > 0) {
// NULL images are allowed
segment.AppendFrame(image ? image.forget() : nullptr, delta, gfxIntSize(mWidth, mHeight));
mSource->AppendToTrack(mTrackID, &(segment));
mLastEndTime = target;
}
// NULL images are allowed
segment.AppendFrame(image ? image.forget() : nullptr, delta, gfxIntSize(mWidth, mHeight));
mSource->AppendToTrack(mTrackID, &(segment));
mLastEndTime = target;
}
void