Backed out changeset 1395d2a59698 (bug 879668) for landing without review.

This commit is contained in:
Ryan VanderMeulen 2014-01-18 23:00:52 -05:00
parent a0667c2146
commit efaee8d500
2 changed files with 8 additions and 11 deletions

View File

@ -208,15 +208,13 @@ VideoTrackEncoder::NotifyEndOfStream()
mReentrantMonitor.NotifyAll();
}
/* static */
void
VideoTrackEncoder::CreateMutedFrame(nsTArray<uint8_t>* aOutputBuffer,
int aFrameWidth, int aFrameHeight)
VideoTrackEncoder::CreateMutedFrame(nsTArray<uint8_t>* aOutputBuffer)
{
NS_ENSURE_TRUE_VOID(aOutputBuffer);
// Supports YUV420 image format only.
int yPlaneLen = aFrameWidth * aFrameHeight;
int yPlaneLen = mFrameWidth * mFrameHeight;
int cbcrPlaneLen = yPlaneLen / 2;
int frameLen = yPlaneLen + cbcrPlaneLen;

View File

@ -229,13 +229,6 @@ public:
uint32_t aTrackEvents,
const MediaSegment& aQueuedMedia) MOZ_OVERRIDE;
/**
* Create a buffer of black image in format of YUV:420. Called on the worker
* thread.
*/
static void CreateMutedFrame(nsTArray<uint8_t>* aOutputBuffer,
int aFrameWidth, int aFrameHeight);
protected:
/**
* Initialized the video encoder. In order to collect the value of width and
@ -259,6 +252,12 @@ protected:
*/
virtual void NotifyEndOfStream() MOZ_OVERRIDE;
/**
* Create a buffer of black image in format of YUV:420. Called on the worker
* thread.
*/
void CreateMutedFrame(nsTArray<uint8_t>* aOutputBuffer);
/**
* The width of source video frame, ceiled if the source width is odd.
*/