Enable HEVC RFI for CUDA, VAAPI, and VDPAU decoders
This commit is contained in:
parent
a1694ab951
commit
413ef42a34
6 changed files with 18 additions and 0 deletions
|
|
@ -57,6 +57,11 @@ bool CUDARenderer::isDirectRenderingSupported()
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
int CUDARenderer::getDecoderCapabilities()
|
||||||
|
{
|
||||||
|
return CAPABILITY_REFERENCE_FRAME_INVALIDATION_HEVC;
|
||||||
|
}
|
||||||
|
|
||||||
CUDAGLInteropHelper::CUDAGLInteropHelper(AVHWDeviceContext* context)
|
CUDAGLInteropHelper::CUDAGLInteropHelper(AVHWDeviceContext* context)
|
||||||
: m_Funcs(nullptr),
|
: m_Funcs(nullptr),
|
||||||
m_Context((AVCUDADeviceContext*)context->hwctx)
|
m_Context((AVCUDADeviceContext*)context->hwctx)
|
||||||
|
|
|
||||||
|
|
@ -17,6 +17,7 @@ public:
|
||||||
virtual void renderFrame(AVFrame* frame) override;
|
virtual void renderFrame(AVFrame* frame) override;
|
||||||
virtual bool needsTestFrame() override;
|
virtual bool needsTestFrame() override;
|
||||||
virtual bool isDirectRenderingSupported() override;
|
virtual bool isDirectRenderingSupported() override;
|
||||||
|
virtual int getDecoderCapabilities() override;
|
||||||
|
|
||||||
private:
|
private:
|
||||||
AVBufferRef* m_HwContext;
|
AVBufferRef* m_HwContext;
|
||||||
|
|
|
||||||
|
|
@ -477,6 +477,11 @@ int VAAPIRenderer::getDecoderColorspace()
|
||||||
return COLORSPACE_REC_601;
|
return COLORSPACE_REC_601;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
int VAAPIRenderer::getDecoderCapabilities()
|
||||||
|
{
|
||||||
|
return CAPABILITY_REFERENCE_FRAME_INVALIDATION_HEVC;
|
||||||
|
}
|
||||||
|
|
||||||
void VAAPIRenderer::notifyOverlayUpdated(Overlay::OverlayType type)
|
void VAAPIRenderer::notifyOverlayUpdated(Overlay::OverlayType type)
|
||||||
{
|
{
|
||||||
AVHWDeviceContext* deviceContext = (AVHWDeviceContext*)m_HwContext->data;
|
AVHWDeviceContext* deviceContext = (AVHWDeviceContext*)m_HwContext->data;
|
||||||
|
|
|
||||||
|
|
@ -42,6 +42,7 @@ public:
|
||||||
virtual bool needsTestFrame() override;
|
virtual bool needsTestFrame() override;
|
||||||
virtual bool isDirectRenderingSupported() override;
|
virtual bool isDirectRenderingSupported() override;
|
||||||
virtual int getDecoderColorspace() override;
|
virtual int getDecoderColorspace() override;
|
||||||
|
virtual int getDecoderCapabilities() override;
|
||||||
virtual void notifyOverlayUpdated(Overlay::OverlayType) override;
|
virtual void notifyOverlayUpdated(Overlay::OverlayType) override;
|
||||||
|
|
||||||
#ifdef HAVE_EGL
|
#ifdef HAVE_EGL
|
||||||
|
|
|
||||||
|
|
@ -437,6 +437,11 @@ int VDPAURenderer::getDecoderColorspace()
|
||||||
return COLORSPACE_REC_601;
|
return COLORSPACE_REC_601;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
int VDPAURenderer::getDecoderCapabilities()
|
||||||
|
{
|
||||||
|
return CAPABILITY_REFERENCE_FRAME_INVALIDATION_HEVC;
|
||||||
|
}
|
||||||
|
|
||||||
void VDPAURenderer::renderOverlay(VdpOutputSurface destination, Overlay::OverlayType type)
|
void VDPAURenderer::renderOverlay(VdpOutputSurface destination, Overlay::OverlayType type)
|
||||||
{
|
{
|
||||||
VdpStatus status;
|
VdpStatus status;
|
||||||
|
|
|
||||||
|
|
@ -20,6 +20,7 @@ public:
|
||||||
virtual void renderFrame(AVFrame* frame) override;
|
virtual void renderFrame(AVFrame* frame) override;
|
||||||
virtual bool needsTestFrame() override;
|
virtual bool needsTestFrame() override;
|
||||||
virtual int getDecoderColorspace() override;
|
virtual int getDecoderColorspace() override;
|
||||||
|
virtual int getDecoderCapabilities() override;
|
||||||
|
|
||||||
private:
|
private:
|
||||||
void renderOverlay(VdpOutputSurface destination, Overlay::OverlayType type);
|
void renderOverlay(VdpOutputSurface destination, Overlay::OverlayType type);
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue