Bug 1316211. P11 - remove empty functions.
MozReview-Commit-ID: 44blKyrVzLV
--- a/dom/media/MediaDecoderReader.cpp
+++ b/dom/media/MediaDecoderReader.cpp
@@ -66,21 +66,16 @@ MediaDecoderReader::~MediaDecoderReader(
void
MediaDecoderReader::UpdateDuration(const media::TimeUnit& aDuration)
{
MOZ_ASSERT(OnTaskQueue());
mDuration = Some(aDuration);
UpdateBuffered();
}
-nsresult MediaDecoderReader::ResetDecode(TrackSet aTracks)
-{
- return NS_OK;
-}
-
RefPtr<ShutdownPromise>
MediaDecoderReader::Shutdown()
{
MOZ_ASSERT(OnTaskQueue());
mShutdown = true;
ReleaseResources();
mBuffered.DisconnectAll();
--- a/dom/media/MediaDecoderReader.h
+++ b/dom/media/MediaDecoderReader.h
@@ -144,17 +144,17 @@ public:
// made after this should be processed as usual.
//
// Normally this call preceedes a Seek() call, or shutdown.
//
// aParam is a set of TrackInfo::TrackType enums specifying which
// queues need to be reset, defaulting to both audio and video tracks.
virtual nsresult ResetDecode(
TrackSet aTracks = TrackSet(TrackInfo::kAudioTrack,
- TrackInfo::kVideoTrack));
+ TrackInfo::kVideoTrack)) = 0;
// Requests one audio sample from the reader.
//
// The decode should be performed asynchronously, and the promise should
// be resolved when it is complete.
virtual RefPtr<AudioDataPromise> RequestAudioData() = 0;
// Requests one video sample from the reader.
@@ -177,23 +177,16 @@ public:
// ReadUpdatedMetadata will always be called once ReadMetadata has succeeded.
virtual void ReadUpdatedMetadata(MediaInfo* aInfo) = 0;
// Moves the decode head to aTime microseconds.
virtual RefPtr<SeekPromise> Seek(const SeekTarget& aTarget) = 0;
virtual void SetCDMProxy(CDMProxy* aProxy) = 0;
- // Tell the reader that the data decoded are not for direct playback, so it
- // can accept more files, in particular those which have more channels than
- // available in the audio output.
- void SetIgnoreAudioOutputFormat()
- {
- }
-
// The MediaDecoderStateMachine uses various heuristics that assume that
// raw media data is arriving sequentially from a network channel. This
// makes sense in the <video src="foo"> case, but not for more advanced use
// cases like MSE.
virtual bool UseBufferingHeuristics() const = 0;
virtual size_t SizeOfVideoQueueInFrames() = 0;
virtual size_t SizeOfAudioQueueInFrames() = 0;
--- a/dom/media/MediaFormatReader.cpp
+++ b/dom/media/MediaFormatReader.cpp
@@ -2475,17 +2475,17 @@ MediaFormatReader::ResetDecode(TrackSet
mAudio.ResetDemuxer();
mVideo.mFirstFrameTime = Some(media::TimeUnit::Zero());
Reset(TrackInfo::kAudioTrack);
if (mAudio.HasPromise()) {
mAudio.RejectPromise(NS_ERROR_DOM_MEDIA_CANCELED, __func__);
}
}
- return MediaDecoderReader::ResetDecode(aTracks);
+ return NS_OK;
}
void
MediaFormatReader::Reset(TrackType aTrack)
{
MOZ_ASSERT(OnTaskQueue());
LOG("Reset(%s) BEGIN", TrackTypeToStr(aTrack));
--- a/dom/media/webaudio/MediaBufferDecoder.cpp
+++ b/dom/media/webaudio/MediaBufferDecoder.cpp
@@ -237,21 +237,16 @@ private:
void
MediaDecodeTask::Decode()
{
MOZ_ASSERT(!NS_IsMainThread());
mBufferDecoder->BeginDecoding(mDecoderReader->OwnerThread());
- // Tell the decoder reader that we are not going to play the data directly,
- // and that we should not reject files with more channels than the audio
- // backend support.
- mDecoderReader->SetIgnoreAudioOutputFormat();
-
mDecoderReader->AsyncReadMetadata()->Then(mDecoderReader->OwnerThread(), __func__, this,
&MediaDecodeTask::OnMetadataRead,
&MediaDecodeTask::OnMetadataNotRead);
}
void
MediaDecodeTask::OnMetadataRead(MetadataHolder&& aMetadata)
{