Bug 1403622 - Allow VP8 HW decoder where known not to crash. r?cpearce
Windows 10 Falls Creator Update build 16287 is known to have the fix to the problem that made
bug 1403063 necessary.
MozReview-Commit-ID: 5m3ZWMes1yl
--- a/dom/media/platforms/wmf/WMFDecoderModule.cpp
+++ b/dom/media/platforms/wmf/WMFDecoderModule.cpp
@@ -210,16 +210,22 @@ WMFDecoderModule::Supports(const TrackIn
if (MP4Decoder::IsH264(aTrackInfo.mMimeType) && WMFDecoderModule::HasH264()) {
return true;
}
if (aTrackInfo.mMimeType.EqualsLiteral("audio/mpeg") &&
CanCreateWMFDecoder<CLSID_CMP3DecMediaObject>()) {
return true;
}
if (MediaPrefs::PDMWMFVP9DecoderEnabled()) {
+ static const uint32_t VP8_USABLE_BUILD = 16287;
+ if (VPXDecoder::IsVP8(aTrackInfo.mMimeType) &&
+ IsWindowsBuildOrLater(VP8_USABLE_BUILD) &&
+ CanCreateWMFDecoder<CLSID_WebmMfVpxDec>()) {
+ return true;
+ }
if (VPXDecoder::IsVP9(aTrackInfo.mMimeType) &&
((gfxPrefs::PDMWMFAMDVP9DecoderEnabled() &&
CanCreateWMFDecoder<CLSID_AMDWebmMfVp9Dec>()) ||
CanCreateWMFDecoder<CLSID_WebmMfVpxDec>())) {
return true;
}
}