MythTV master
mythdrmprimeinterop.h
Go to the documentation of this file.
1#ifndef MYTHDRMPRIMEINTEROP_H
2#define MYTHDRMPRIMEINTEROP_H
3
4// MythTV
5#include "libmythbase/mythconfig.h"
6#include "mythegldmabuf.h"
7#include "mythopenglinterop.h"
8
9#if CONFIG_DRM_VIDEO
10#include "drm/mythvideodrm.h"
11#endif
12
13struct AVDRMFrameDescriptor;
14
16{
17 public:
18 static void GetDRMTypes(MythRenderOpenGL* Render, MythInteropGPU::InteropMap& Types);
20 void DeleteTextures(void) override;
21 std::vector<MythVideoTextureOpenGL*>
23 MythVideoColourSpace *ColourSpace,
24 MythVideoFrame *Frame, FrameScanType Scan) override;
25
26 protected:
28 ~MythDRMPRIMEInterop() override;
29
30 private:
31 AVDRMFrameDescriptor* VerifyBuffer(MythRenderOpenGL *Context, MythVideoFrame *Frame);
32 bool m_deinterlacing { false };
33 bool m_composable { true };
34
35#if CONFIG_DRM_VIDEO
36 bool HandleDRMVideo(MythVideoColourSpace* ColourSpace, MythVideoFrame* Frame,
37 AVDRMFrameDescriptor* DRMDesc);
38 MythVideoDRM* m_drm { nullptr };
39 bool m_drmTriedAndFailed { false };
40#endif
41};
42
43#endif
std::vector< MythVideoTextureOpenGL * > Acquire(MythRenderOpenGL *Context, MythVideoColourSpace *ColourSpace, MythVideoFrame *Frame, FrameScanType Scan) override
MythDRMPRIMEInterop(MythRenderOpenGL *Context, MythPlayerUI *Player, InteropType Type)
AVDRMFrameDescriptor * VerifyBuffer(MythRenderOpenGL *Context, MythVideoFrame *Frame)
void DeleteTextures(void) override
static MythDRMPRIMEInterop * CreateDRM(MythRenderOpenGL *Context, MythPlayerUI *Player)
Create a DRM PRIME interop instance.
static void GetDRMTypes(MythRenderOpenGL *Render, MythInteropGPU::InteropMap &Types)
std::map< VideoFrameType, InteropTypes > InteropMap
MythVideoColourSpace contains a QMatrix4x4 that can convert YCbCr data to RGB.
FrameScanType
Definition: videoouttypes.h:95