2 * Copyright (C) 2007-2018 Team Kodi
3 * This file is part of Kodi - https://kodi.tv
5 * SPDX-License-Identifier: GPL-2.0-or-later
6 * See LICENSES/README.md for more information.
11 #include "DRMPRIMEEGL.h"
12 #include "cores/VideoPlayer/VideoRenderers/BaseRenderer.h"
27 class CRendererDRMPRIMEGLES
: public CBaseRenderer
30 CRendererDRMPRIMEGLES() = default;
31 ~CRendererDRMPRIMEGLES() override
;
34 static CBaseRenderer
* Create(CVideoBuffer
* buffer
);
35 static void Register();
38 bool Configure(const VideoPicture
& picture
, float fps
, unsigned int orientation
) override
;
39 bool IsConfigured() override
{ return m_configured
; }
40 void AddVideoPicture(const VideoPicture
& picture
, int index
) override
;
41 void UnInit() override
{}
42 bool Flush(bool saveBuffers
) override
;
43 void ReleaseBuffer(int idx
) override
;
44 bool NeedBuffer(int idx
) override
;
45 CRenderInfo
GetRenderInfo() override
;
46 void Update() override
;
48 int index
, int index2
, bool clear
, unsigned int flags
, unsigned int alpha
) override
;
49 bool RenderCapture(int index
, CRenderCapture
* capture
) override
;
50 bool ConfigChanged(const VideoPicture
& picture
) override
;
53 bool SupportsMultiPassRendering() override
{ return false; }
54 bool Supports(ERENDERFEATURE feature
) const override
;
55 bool Supports(ESCALINGMETHOD method
) const override
;
59 void Render(unsigned int flags
, int index
);
61 bool m_configured
= false;
62 float m_clearColour
{0.0f
};
66 CVideoBuffer
* videoBuffer
= nullptr;
67 std::unique_ptr
<KODI::UTILS::EGL::CEGLFence
> fence
;
68 CDRMPRIMETexture texture
;
69 } m_buffers
[NUM_BUFFERS
];