MythTV master
|
A simple wrapper around VDPAU functionality. More...
#include <libmythtv/decoders/mythvdpauhelper.h>
Public Types | |
enum | VDPMixerFeature : std::uint8_t { VDPMixerNone = 0x00 , VDPMixerTemporal = 0x01 , VDPMixerSpatial = 0x02 } |
Signals | |
void | DisplayPreempted (void) |
Public Member Functions | |
MythVDPAUHelper (AVVDPAUDeviceContext *Context) | |
~MythVDPAUHelper (void) override | |
bool | IsValid (void) const |
void | SetPreempted (void) |
bool | IsFeatureAvailable (uint Feature) |
bool | IsAttributeAvailable (uint Attribute) |
VdpOutputSurface | CreateOutputSurface (QSize Size) |
VdpVideoMixer | CreateMixer (QSize Size, VdpChromaType ChromaType=VDP_CHROMA_TYPE_420, MythDeintType Deinterlacer=DEINT_BASIC) |
void | MixerRender (VdpVideoMixer Mixer, VdpVideoSurface Source, VdpOutputSurface Dest, FrameScanType Scan, int TopFieldFirst, QVector< AVBufferRef * > &Frames) |
void | SetCSCMatrix (VdpVideoMixer Mixer, MythVideoColourSpace *ColourSpace) |
void | DeleteOutputSurface (VdpOutputSurface Surface) |
void | DeleteMixer (VdpVideoMixer Mixer) |
QSize | GetSurfaceParameters (VdpVideoSurface Surface, VdpChromaType &Chroma) |
Static Public Member Functions | |
static bool | HaveVDPAU (bool Reinit=false) |
static bool | CheckH264Decode (AVCodecContext *Context) |
static const VDPAUProfiles & | GetProfiles (void) |
static void | GetDecoderList (QStringList &Decoders) |
Protected Member Functions | |
MythVDPAUHelper (void) | |
bool | H264DecodeCheck (VdpDecoderProfile Profile, AVCodecContext *Context) |
bool | HEVCSupported (void) |
bool | ProfileCheck (VdpDecoderProfile Profile, uint32_t &Level, uint32_t &Macros, uint32_t &Width, uint32_t &Height) |
Private Member Functions | |
bool | InitProcs (void) |
Private Attributes | |
VdpDevice | m_device { 0 } |
MythXDisplay * | m_display { nullptr } |
VdpGetProcAddress * | m_vdpGetProcAddress { nullptr } |
VdpGetErrorString * | m_vdpGetErrorString { nullptr } |
VdpGetInformationString * | m_vdpGetInformationString { nullptr } |
VdpDeviceDestroy * | m_vdpDeviceDestroy { nullptr } |
VdpDecoderQueryCapabilities * | m_vdpDecoderQueryCapabilities { nullptr } |
VdpDecoderCreate * | m_vdpDecoderCreate { nullptr } |
VdpDecoderDestroy * | m_vdpDecoderDestroy { nullptr } |
VdpVideoMixerCreate * | m_vdpVideoMixerCreate { nullptr } |
VdpVideoMixerDestroy * | m_vdpVideoMixerDestroy { nullptr } |
VdpVideoMixerRender * | m_vdpVideoMixerRender { nullptr } |
VdpVideoMixerSetAttributeValues * | m_vdpVideoMixerSetAttributeValues { nullptr } |
VdpVideoMixerSetFeatureEnables * | m_vdpVideoMixerSetFeatureEnables { nullptr } |
VdpVideoMixerQueryFeatureSupport * | m_vdpVideoMixerQueryFeatureSupport { nullptr } |
VdpVideoMixerQueryAttributeSupport * | m_vdpVideoMixerQueryAttributeSupport { nullptr } |
VdpOutputSurfaceCreate * | m_vdpOutputSurfaceCreate { nullptr } |
VdpOutputSurfaceDestroy * | m_vdpOutputSurfaceDestroy { nullptr } |
VdpVideoSurfaceGetParameters * | m_vdpVideoSurfaceGetParameters { nullptr } |
VdpPreemptionCallbackRegister * | m_vdpPreemptionCallbackRegister { nullptr } |
bool | m_createdDevice { false } |
bool | m_valid { false } |
A simple wrapper around VDPAU functionality.
Definition at line 52 of file mythvdpauhelper.h.
enum MythVDPAUHelper::VDPMixerFeature : std::uint8_t |
Enumerator | |
---|---|
VDPMixerNone | |
VDPMixerTemporal | |
VDPMixerSpatial |
Definition at line 57 of file mythvdpauhelper.h.
|
explicit |
Definition at line 236 of file mythvdpauhelper.cpp.
|
override |
Definition at line 279 of file mythvdpauhelper.cpp.
|
protected |
Definition at line 256 of file mythvdpauhelper.cpp.
|
static |
Definition at line 348 of file mythvdpauhelper.cpp.
Referenced by MythVDPAUContext::GetSupportedCodec().
VdpVideoMixer MythVDPAUHelper::CreateMixer | ( | QSize | Size, |
VdpChromaType | ChromaType = VDP_CHROMA_TYPE_420 , |
||
MythDeintType | Deinterlacer = DEINT_BASIC |
||
) |
Definition at line 430 of file mythvdpauhelper.cpp.
Referenced by MythVDPAUInterop::InitVDPAU().
VdpOutputSurface MythVDPAUHelper::CreateOutputSurface | ( | QSize | Size | ) |
Definition at line 406 of file mythvdpauhelper.cpp.
Referenced by MythVDPAUInterop::InitVDPAU().
void MythVDPAUHelper::DeleteMixer | ( | VdpVideoMixer | Mixer | ) |
Definition at line 541 of file mythvdpauhelper.cpp.
Referenced by MythVDPAUInterop::Cleanup().
void MythVDPAUHelper::DeleteOutputSurface | ( | VdpOutputSurface | Surface | ) |
Definition at line 420 of file mythvdpauhelper.cpp.
Referenced by MythVDPAUInterop::Cleanup().
|
signal |
Referenced by MythVDPAUInterop::InitNV(), and SetPreempted().
|
static |
Definition at line 214 of file mythvdpauhelper.cpp.
Referenced by MythCodecContext::GetDecoderDescription().
|
static |
Definition at line 122 of file mythvdpauhelper.cpp.
Referenced by GetDecoderList(), MythVDPAUContext::GetSupportedCodec(), and HaveVDPAU().
QSize MythVDPAUHelper::GetSurfaceParameters | ( | VdpVideoSurface | Surface, |
VdpChromaType & | Chroma | ||
) |
Definition at line 588 of file mythvdpauhelper.cpp.
Referenced by MythVDPAUInterop::InitVDPAU().
|
protected |
Definition at line 386 of file mythvdpauhelper.cpp.
Referenced by CheckH264Decode().
Definition at line 55 of file mythvdpauhelper.cpp.
Referenced by MythCodecContext::GetDecoders(), MythVDPAUContext::GetSupportedCodec(), and MythVDPAUInterop::GetVDPAUTypes().
|
protected |
Definition at line 327 of file mythvdpauhelper.cpp.
Referenced by GetProfiles().
|
private |
Definition at line 288 of file mythvdpauhelper.cpp.
Referenced by MythVDPAUHelper().
Definition at line 576 of file mythvdpauhelper.cpp.
Referenced by MythVDPAUInterop::Acquire().
Definition at line 564 of file mythvdpauhelper.cpp.
bool MythVDPAUHelper::IsValid | ( | void | ) | const |
Definition at line 317 of file mythvdpauhelper.cpp.
Referenced by CheckH264Decode(), GetProfiles(), HaveVDPAU(), and MythVDPAUInterop::InitNV().
void MythVDPAUHelper::MixerRender | ( | VdpVideoMixer | Mixer, |
VdpVideoSurface | Source, | ||
VdpOutputSurface | Dest, | ||
FrameScanType | Scan, | ||
int | TopFieldFirst, | ||
QVector< AVBufferRef * > & | Frames | ||
) |
Definition at line 485 of file mythvdpauhelper.cpp.
Referenced by MythVDPAUInterop::Acquire().
|
protected |
Definition at line 86 of file mythvdpauhelper.cpp.
Referenced by GetProfiles().
void MythVDPAUHelper::SetCSCMatrix | ( | VdpVideoMixer | Mixer, |
MythVideoColourSpace * | ColourSpace | ||
) |
Definition at line 551 of file mythvdpauhelper.cpp.
Referenced by MythVDPAUInterop::UpdateColourSpace().
void MythVDPAUHelper::SetPreempted | ( | void | ) |
Definition at line 322 of file mythvdpauhelper.cpp.
Referenced by vdpau_preemption_callback().
Definition at line 125 of file mythvdpauhelper.h.
Referenced by ~MythVDPAUHelper().
|
private |
Definition at line 103 of file mythvdpauhelper.h.
Referenced by CreateMixer(), CreateOutputSurface(), H264DecodeCheck(), IsAttributeAvailable(), IsFeatureAvailable(), MythVDPAUHelper(), ProfileCheck(), and ~MythVDPAUHelper().
|
private |
Definition at line 104 of file mythvdpauhelper.h.
Referenced by MythVDPAUHelper(), and ~MythVDPAUHelper().
Definition at line 126 of file mythvdpauhelper.h.
Referenced by CreateMixer(), CreateOutputSurface(), H264DecodeCheck(), HEVCSupported(), IsAttributeAvailable(), IsFeatureAvailable(), IsValid(), MixerRender(), and MythVDPAUHelper().
|
private |
Definition at line 111 of file mythvdpauhelper.h.
Referenced by H264DecodeCheck(), and InitProcs().
|
private |
Definition at line 112 of file mythvdpauhelper.h.
Referenced by H264DecodeCheck(), and InitProcs().
|
private |
Definition at line 110 of file mythvdpauhelper.h.
Referenced by InitProcs(), and ProfileCheck().
|
private |
Definition at line 109 of file mythvdpauhelper.h.
Referenced by InitProcs(), and ~MythVDPAUHelper().
|
private |
Definition at line 107 of file mythvdpauhelper.h.
Referenced by InitProcs(), and MythVDPAUHelper().
|
private |
Definition at line 108 of file mythvdpauhelper.h.
Referenced by HEVCSupported(), and InitProcs().
|
private |
Definition at line 106 of file mythvdpauhelper.h.
Referenced by MythVDPAUHelper().
|
private |
Definition at line 120 of file mythvdpauhelper.h.
Referenced by CreateOutputSurface(), and InitProcs().
|
private |
Definition at line 121 of file mythvdpauhelper.h.
Referenced by DeleteOutputSurface(), and InitProcs().
|
private |
Definition at line 123 of file mythvdpauhelper.h.
Referenced by InitProcs(), MythVDPAUHelper(), and ~MythVDPAUHelper().
|
private |
Definition at line 113 of file mythvdpauhelper.h.
Referenced by CreateMixer(), and InitProcs().
|
private |
Definition at line 114 of file mythvdpauhelper.h.
Referenced by DeleteMixer(), and InitProcs().
|
private |
Definition at line 119 of file mythvdpauhelper.h.
Referenced by InitProcs(), and IsAttributeAvailable().
|
private |
Definition at line 118 of file mythvdpauhelper.h.
Referenced by InitProcs(), and IsFeatureAvailable().
|
private |
Definition at line 115 of file mythvdpauhelper.h.
Referenced by InitProcs(), and MixerRender().
|
private |
Definition at line 116 of file mythvdpauhelper.h.
Referenced by InitProcs(), and SetCSCMatrix().
|
private |
Definition at line 117 of file mythvdpauhelper.h.
Referenced by CreateMixer(), and InitProcs().
|
private |
Definition at line 122 of file mythvdpauhelper.h.
Referenced by GetSurfaceParameters(), and InitProcs().