mirror of
https://github.com/mozilla/gecko-dev.git
synced 2025-03-02 06:22:20 +00:00
Bug 1493198 - P5. Don't restrict high bit depth images on Windows r=bryce
Both D3D11 compositor and WebRender now supports 10/12 bits images. Depends on D6688 Differential Revision: https://phabricator.services.mozilla.com/D6695 --HG-- extra : moz-landing-system : lando
This commit is contained in:
parent
a4846efef7
commit
f97bb952b9
@ -81,15 +81,10 @@ protected:
|
||||
bool SupportsColorDepth(gfx::ColorDepth aColorDepth,
|
||||
DecoderDoctorDiagnostics* aDiagnostics) const override
|
||||
{
|
||||
// We don't support bitDepth > 8 when compositor backend is D3D11.
|
||||
// But we don't have KnowsCompositor or any object
|
||||
// that we can ask for the layersbackend type.
|
||||
// We should remove this restriction until
|
||||
// we solve the D3D11 compositor backend issue.
|
||||
#if defined(XP_LINUX) || defined(XP_MACOSX)
|
||||
return true;
|
||||
#endif
|
||||
#if defined(MOZ_WIDGET_ANDROID)
|
||||
return aColorDepth == gfx::ColorDepth::COLOR_8;
|
||||
#endif
|
||||
return true;
|
||||
}
|
||||
|
||||
private:
|
||||
|
@ -237,22 +237,6 @@ FFmpegVideoDecoder<LIBAV_VER>::DoDecode(MediaRawData* aSample,
|
||||
return NS_OK;
|
||||
}
|
||||
|
||||
if ((mCodecContext->pix_fmt == AV_PIX_FMT_YUV420P10LE ||
|
||||
mCodecContext->pix_fmt == AV_PIX_FMT_YUV444P10LE
|
||||
#if LIBAVCODEC_VERSION_MAJOR >= 57
|
||||
|| mCodecContext->pix_fmt == AV_PIX_FMT_YUV444P12LE
|
||||
#endif
|
||||
) &&
|
||||
(!mImageAllocator || (mImageAllocator->GetCompositorBackendType()
|
||||
!= layers::LayersBackend::LAYERS_BASIC &&
|
||||
mImageAllocator->GetCompositorBackendType()
|
||||
!= layers::LayersBackend::LAYERS_OPENGL &&
|
||||
mImageAllocator->GetCompositorBackendType()
|
||||
!= layers::LayersBackend::LAYERS_D3D11))) {
|
||||
return MediaResult(NS_ERROR_DOM_MEDIA_FATAL_ERR,
|
||||
RESULT_DETAIL("unsupported format type (hdr)"));
|
||||
}
|
||||
|
||||
// If we've decoded a frame then we need to output it
|
||||
int64_t pts = mPtsContext.GuessCorrectPts(mFrame->pkt_pts, mFrame->pkt_dts);
|
||||
// Retrieve duration from dts.
|
||||
|
Loading…
x
Reference in New Issue
Block a user