|
MythTV master
|
#include <libmythui/mythrender_d3d9.h>
Public Member Functions | |
| MythRenderD3D9 () | |
| bool | Create (QSize size, HWND window) |
| bool | Test (bool &reset) |
| bool | ClearBuffer (void) |
| bool | Begin (void) |
| bool | End (void) |
| void | CopyFrame (void *surface, D3D9Image *img) |
| bool | StretchRect (IDirect3DTexture9 *texture, IDirect3DSurface9 *surface, bool known_surface=true) |
| bool | DrawTexturedQuad (IDirect3DVertexBuffer9 *vertexbuffer) |
| void | DrawRect (const QRect &rect, const QColor &color, int alpha) |
| bool | Present (HWND win) |
| bool | HardwareYUVConversion (void) |
| QRect | GetRect (IDirect3DVertexBuffer9 *vertexbuffer) |
| bool | SetRenderTarget (IDirect3DTexture9 *texture) |
| IDirect3DTexture9 * | CreateTexture (const QSize &size) |
| void | DeleteTexture (IDirect3DTexture9 *texture) |
| IDirect3DVertexBuffer9 * | CreateVertexBuffer (IDirect3DTexture9 *texture=nullptr) |
| bool | UpdateVertexBuffer (IDirect3DVertexBuffer9 *vertexbuffer, const QRect &dvr, const QRect &vr, int alpha=255, bool video=false) |
| void | DeleteVertexBuffer (IDirect3DVertexBuffer9 *vertexbuffer) |
| IDirect3DSurface9 * | CreateSurface (const QSize &size, bool video=false) |
| bool | UpdateSurface (IDirect3DSurface9 *surface, const MythImage *image) |
| void | DeleteSurface (IDirect3DSurface9 *surface) |
| uint8_t * | GetBuffer (IDirect3DSurface9 *surface, uint &pitch) |
| void | ReleaseBuffer (IDirect3DSurface9 *surface) |
| IDirect3DDevice9 * | AcquireDevice (void) |
| void | ReleaseDevice (void) |
| IDirect3DDeviceManager9 * | GetDeviceManager (void) |
Public Member Functions inherited from MythRender | |
| MythRender (RenderType type) | |
| bool | IsShared (void) const |
| Warning: The reference count can be decremented between the call to this function and the use of it's value. More... | |
| RenderType | Type (void) const |
| bool | IsErrored (void) const |
| QSize | GetSize (void) const |
| virtual QStringList | GetDescription () |
| virtual void | SetViewPort (const QRect, bool=false) |
Public Member Functions inherited from ReferenceCounter | |
| ReferenceCounter (const QString &debugName, bool logDebug=true) | |
| Creates reference counter with an initial value of 1. More... | |
| virtual int | IncrRef (void) |
| Increments reference count. More... | |
| virtual int | DecrRef (void) |
| Decrements reference count and deletes on 0. More... | |
Static Public Member Functions | |
| static void * | ResolveAddress (const char *lib, const char *proc) |
Static Public Member Functions inherited from ReferenceCounter | |
| static void | PrintDebug (void) |
| Print out any leaks if that level of debugging is enabled. More... | |
Private Member Functions | |
| virtual | ~MythRenderD3D9 () |
| bool | SetTexture (IDirect3DDevice9 *dev, IDirect3DTexture9 *texture, int num=0) |
| void | DeleteTextures (void) |
| void | DeleteVertexBuffers (void) |
| void | DeleteSurfaces (void) |
| void | Init2DState (void) |
| void | EnableBlending (IDirect3DDevice9 *dev, bool enable) |
| void | MultiTexturing (IDirect3DDevice9 *dev, bool enable, IDirect3DTexture9 *texture=nullptr) |
| void | SetTextureVertices (IDirect3DDevice9 *dev, bool enable) |
| void | CreateDeviceManager (void) |
| void | DestroyDeviceManager (void) |
Private Attributes | |
| QMap< IDirect3DTexture9 *, QSize > | m_textures |
| QMap< IDirect3DVertexBuffer9 *, MythD3DVertexBuffer > | m_vertexbuffers |
| QMap< IDirect3DSurface9 *, MythD3DSurface > | m_surfaces |
| IDirect3D9 * | m_d3d {nullptr} |
| IDirect3DDevice9 * | m_rootD3DDevice {nullptr} |
| D3DFORMAT | m_adaptor_fmt {D3DFMT_UNKNOWN} |
| D3DFORMAT | m_videosurface_fmt {D3DFMT_UNKNOWN} |
| D3DFORMAT | m_surface_fmt {D3DFMT_UNKNOWN} |
| D3DFORMAT | m_texture_fmt {D3DFMT_UNKNOWN} |
| IDirect3DVertexBuffer9 * | m_rect_vertexbuffer {nullptr} |
| IDirect3DSurface9 * | m_default_surface {nullptr} |
| IDirect3DSurface9 * | m_current_surface {nullptr} |
| QRecursiveMutex | m_lock |
| bool | m_blend {true} |
| bool | m_multi_texturing {true} |
| bool | m_texture_vertices {true} |
| IDirect3DDeviceManager9 * | m_deviceManager {nullptr} |
| HANDLE | m_deviceHandle {nullptr} |
| uint | m_deviceManagerToken {0} |
Additional Inherited Members | |
Protected Member Functions inherited from MythRender | |
| ~MythRender () override=default | |
| virtual void | ReleaseResources (void) |
Protected Member Functions inherited from ReferenceCounter | |
| virtual | ~ReferenceCounter (void) |
| Called on destruction, will warn if object deleted with references in place. More... | |
Protected Attributes inherited from MythRender | |
| RenderType | m_type |
| QSize | m_size |
| bool | m_errored |
Protected Attributes inherited from ReferenceCounter | |
| bool | m_logDebug |
| This is used to suppress creating LoggingItem classes for LoggingItem reference count changes. More... | |
| QAtomicInt | m_referenceCount {1} |
Definition at line 92 of file mythrender_d3d9.h.
|
inline |
Definition at line 97 of file mythrender_d3d9.h.
|
privatevirtual |
Definition at line 157 of file mythrender_d3d9.cpp.
| IDirect3DDevice9 * MythRenderD3D9::AcquireDevice | ( | void | ) |
Definition at line 1116 of file mythrender_d3d9.cpp.
Referenced by D3D9Locker::Acquire(), and Init2DState().
| bool MythRenderD3D9::Begin | ( | void | ) |
Definition at line 439 of file mythrender_d3d9.cpp.
Referenced by MythD3D9Painter::Begin(), and VideoOutputD3D::RenderFrame().
| bool MythRenderD3D9::ClearBuffer | ( | void | ) |
Definition at line 422 of file mythrender_d3d9.cpp.
Referenced by MythD3D9Painter::Begin(), and VideoOutputD3D::RenderFrame().
| void MythRenderD3D9::CopyFrame | ( | void * | surface, |
| D3D9Image * | img | ||
| ) |
Definition at line 471 of file mythrender_d3d9.cpp.
Referenced by VideoOutputD3D::PrepareFrame().
| bool MythRenderD3D9::Create | ( | QSize | size, |
| HWND | window | ||
| ) |
Definition at line 221 of file mythrender_d3d9.cpp.
Referenced by MythD3D9Painter::InitD3D9(), and VideoOutputD3D::SetupContext().
|
private |
Definition at line 1166 of file mythrender_d3d9.cpp.
Referenced by Create().
Definition at line 799 of file mythrender_d3d9.cpp.
Referenced by D3D9Image::D3D9Image().
| IDirect3DTexture9 * MythRenderD3D9::CreateTexture | ( | const QSize & | size | ) |
Definition at line 758 of file mythrender_d3d9.cpp.
Referenced by D3D9Image::D3D9Image().
| IDirect3DVertexBuffer9 * MythRenderD3D9::CreateVertexBuffer | ( | IDirect3DTexture9 * | texture = nullptr | ) |
Definition at line 921 of file mythrender_d3d9.cpp.
Referenced by D3D9Image::D3D9Image().
| void MythRenderD3D9::DeleteSurface | ( | IDirect3DSurface9 * | surface | ) |
Definition at line 880 of file mythrender_d3d9.cpp.
Referenced by D3D9Image::~D3D9Image().
|
private |
Definition at line 872 of file mythrender_d3d9.cpp.
Referenced by ~MythRenderD3D9().
| void MythRenderD3D9::DeleteTexture | ( | IDirect3DTexture9 * | texture | ) |
Definition at line 789 of file mythrender_d3d9.cpp.
Referenced by D3D9Image::~D3D9Image().
|
private |
Definition at line 781 of file mythrender_d3d9.cpp.
Referenced by ~MythRenderD3D9().
| void MythRenderD3D9::DeleteVertexBuffer | ( | IDirect3DVertexBuffer9 * | vertexbuffer | ) |
Definition at line 958 of file mythrender_d3d9.cpp.
Referenced by D3D9Image::~D3D9Image().
|
private |
Definition at line 947 of file mythrender_d3d9.cpp.
Referenced by ~MythRenderD3D9().
|
private |
Definition at line 1209 of file mythrender_d3d9.cpp.
Referenced by ~MythRenderD3D9().
| void MythRenderD3D9::DrawRect | ( | const QRect & | rect, |
| const QColor & | color, | ||
| int | alpha | ||
| ) |
Definition at line 546 of file mythrender_d3d9.cpp.
Referenced by MythD3D9Painter::DrawRect().
| bool MythRenderD3D9::DrawTexturedQuad | ( | IDirect3DVertexBuffer9 * | vertexbuffer | ) |
Definition at line 509 of file mythrender_d3d9.cpp.
Referenced by D3D9Image::Draw().
|
private |
Definition at line 1096 of file mythrender_d3d9.cpp.
Referenced by DrawRect(), DrawTexturedQuad(), and Init2DState().
| bool MythRenderD3D9::End | ( | void | ) |
Definition at line 455 of file mythrender_d3d9.cpp.
Referenced by MythD3D9Painter::End(), and VideoOutputD3D::RenderEnd().
| uint8_t * MythRenderD3D9::GetBuffer | ( | IDirect3DSurface9 * | surface, |
| uint & | pitch | ||
| ) |
Definition at line 890 of file mythrender_d3d9.cpp.
Referenced by D3D9Image::GetBuffer(), and UpdateSurface().
|
inline |
Definition at line 168 of file mythrender_d3d9.h.
Referenced by DXVA2Decoder::CreateVideoService().
| QRect MythRenderD3D9::GetRect | ( | IDirect3DVertexBuffer9 * | vertexbuffer | ) |
Definition at line 681 of file mythrender_d3d9.cpp.
Referenced by D3D9Image::GetRect().
| bool MythRenderD3D9::HardwareYUVConversion | ( | void | ) |
Definition at line 374 of file mythrender_d3d9.cpp.
Referenced by D3D9Image::GetBuffer().
|
private |
Definition at line 1066 of file mythrender_d3d9.cpp.
Referenced by Create().
|
private |
Definition at line 628 of file mythrender_d3d9.cpp.
Referenced by DrawRect(), DrawTexturedQuad(), and Init2DState().
| bool MythRenderD3D9::Present | ( | HWND | win | ) |
Definition at line 664 of file mythrender_d3d9.cpp.
Referenced by MythD3D9Painter::End(), and VideoOutputD3D::EndFrame().
| void MythRenderD3D9::ReleaseBuffer | ( | IDirect3DSurface9 * | surface | ) |
Definition at line 910 of file mythrender_d3d9.cpp.
Referenced by D3D9Image::ReleaseBuffer(), and UpdateSurface().
| void MythRenderD3D9::ReleaseDevice | ( | void | ) |
Definition at line 1148 of file mythrender_d3d9.cpp.
Referenced by Init2DState(), and D3D9Locker::~D3D9Locker().
|
static |
Definition at line 152 of file mythrender_d3d9.cpp.
Referenced by Create(), CreateDeviceManager(), and DXVA2Decoder::CreateVideoService().
| bool MythRenderD3D9::SetRenderTarget | ( | IDirect3DTexture9 * | texture | ) |
Definition at line 688 of file mythrender_d3d9.cpp.
Referenced by MythD3D9Painter::End(), and D3D9Image::SetAsRenderTarget().
|
private |
Definition at line 743 of file mythrender_d3d9.cpp.
Referenced by DrawRect(), DrawTexturedQuad(), and MultiTexturing().
|
private |
Definition at line 1106 of file mythrender_d3d9.cpp.
Referenced by DrawRect(), DrawTexturedQuad(), and Init2DState().
| bool MythRenderD3D9::StretchRect | ( | IDirect3DTexture9 * | texture, |
| IDirect3DSurface9 * | surface, | ||
| bool | known_surface = true |
||
| ) |
Definition at line 477 of file mythrender_d3d9.cpp.
Referenced by D3D9Image::ReleaseBuffer(), and D3D9Image::UpdateImage().
Definition at line 379 of file mythrender_d3d9.cpp.
Referenced by MythD3D9Painter::Begin(), VideoOutputD3D::EndFrame(), VideoOutputD3D::PrepareFrame(), and VideoOutputD3D::RenderFrame().
Definition at line 826 of file mythrender_d3d9.cpp.
Referenced by D3D9Image::UpdateImage().
| bool MythRenderD3D9::UpdateVertexBuffer | ( | IDirect3DVertexBuffer9 * | vertexbuffer, |
| const QRect & | dvr, | ||
| const QRect & | vr, | ||
| int | alpha = 255, |
||
| bool | video = false |
||
| ) |
Definition at line 968 of file mythrender_d3d9.cpp.
Referenced by D3D9Image::UpdateVertices().
|
private |
Definition at line 152 of file mythrender_d3d9.h.
Referenced by Create().
Definition at line 161 of file mythrender_d3d9.h.
Referenced by EnableBlending().
|
private |
Definition at line 158 of file mythrender_d3d9.h.
Referenced by SetRenderTarget(), and ~MythRenderD3D9().
|
private |
Definition at line 150 of file mythrender_d3d9.h.
Referenced by Create(), and ~MythRenderD3D9().
|
private |
Definition at line 157 of file mythrender_d3d9.h.
Referenced by SetRenderTarget(), and ~MythRenderD3D9().
|
private |
Definition at line 176 of file mythrender_d3d9.h.
Referenced by AcquireDevice(), CreateDeviceManager(), DestroyDeviceManager(), and ReleaseDevice().
|
private |
Definition at line 175 of file mythrender_d3d9.h.
Referenced by AcquireDevice(), CreateDeviceManager(), DestroyDeviceManager(), and ReleaseDevice().
|
private |
Definition at line 177 of file mythrender_d3d9.h.
Referenced by CreateDeviceManager().
|
private |
Definition at line 160 of file mythrender_d3d9.h.
Referenced by AcquireDevice(), Create(), DeleteSurface(), DeleteTexture(), DeleteVertexBuffer(), GetBuffer(), ReleaseBuffer(), ReleaseDevice(), UpdateVertexBuffer(), and ~MythRenderD3D9().
Definition at line 162 of file mythrender_d3d9.h.
Referenced by MultiTexturing().
|
private |
Definition at line 156 of file mythrender_d3d9.h.
Referenced by DrawRect(), and ~MythRenderD3D9().
|
private |
Definition at line 151 of file mythrender_d3d9.h.
Referenced by AcquireDevice(), Create(), CreateDeviceManager(), and ~MythRenderD3D9().
|
private |
Definition at line 154 of file mythrender_d3d9.h.
Referenced by Create(), and CreateSurface().
|
private |
Definition at line 148 of file mythrender_d3d9.h.
Referenced by CreateSurface(), DeleteSurface(), DeleteSurfaces(), GetBuffer(), ReleaseBuffer(), StretchRect(), and UpdateSurface().
|
private |
Definition at line 155 of file mythrender_d3d9.h.
Referenced by Create(), and CreateTexture().
Definition at line 163 of file mythrender_d3d9.h.
Referenced by SetTextureVertices().
|
private |
Definition at line 146 of file mythrender_d3d9.h.
Referenced by CreateTexture(), CreateVertexBuffer(), DeleteTexture(), DeleteTextures(), SetRenderTarget(), StretchRect(), and UpdateVertexBuffer().
|
private |
Definition at line 147 of file mythrender_d3d9.h.
Referenced by CreateVertexBuffer(), DeleteVertexBuffer(), DeleteVertexBuffers(), DrawTexturedQuad(), GetRect(), and UpdateVertexBuffer().
|
private |
Definition at line 153 of file mythrender_d3d9.h.
Referenced by Create(), CreateSurface(), and HardwareYUVConversion().