Bug 1400889 - Keep constant output channels in MediaStreamGraph. r=padenot

MozReview-Commit-ID: JlQdxU0aNOf

--HG--
extra : rebase_source : 25b6f223c2158a4eb9175731cdbb8521de4ce312
This commit is contained in:
Alex Chronopoulos 2017-10-03 17:56:53 +03:00
Родитель 772b9c6088
Коммит 643923ac4c
2 изменённых файлов: 7 добавлений и 1 удалений

Просмотреть файл

@ -3437,6 +3437,7 @@ MediaStreamGraphImpl::MediaStreamGraphImpl(GraphDriverType aDriverRequested,
, mFarendObserverRef(nullptr)
#endif
, mSelfRef(this)
, mOutputChannels(std::min<uint32_t>(8, CubebUtils::MaxNumberOfChannels()))
#ifdef DEBUG
, mCanRunMessagesSynchronously(false)
#endif

Просмотреть файл

@ -422,7 +422,7 @@ public:
uint32_t AudioChannelCount() const
{
return std::min<uint32_t>(8, CubebUtils::MaxNumberOfChannels());
return mOutputChannels;
}
double MediaTimeToSeconds(GraphTime aTime) const
@ -815,6 +815,11 @@ private:
*/
nsTArray<WindowAndStream> mWindowCaptureStreams;
/**
* Number of channels on output.
*/
const uint32_t mOutputChannels;
#ifdef DEBUG
/**
* Used to assert when AppendMessage() runs ControlMessages synchronously.