Rise
The Vieneo Province
Loading...
Searching...
No Matches
Rendering::RenderDevice Class Reference

#include <ClientRenderer11.h>

Collaboration diagram for Rendering::RenderDevice:
[legend]

Classes

struct  Saved

Public Member Functions

 RenderDevice (DrawContext11 &draws)
void Reset ()
DrawContext11 & Draws ()
Device11 & Owner ()
ID3D11Device * Native ()
ID3D11DeviceContext * Context ()
HRESULT CreateVertexBuffer (UINT bytes, DWORD usage, DWORD format, ResourcePool pool, RenderBuffer **result, void *shared)
HRESULT CreateIndexBuffer (UINT bytes, DWORD usage, ImageFormat format, ResourcePool pool, RenderBuffer **result, void *shared)
HRESULT CreateQuery (UINT type, RenderQuery **result)
HRESULT CreateStateBlock (UINT type, RenderStateSnapshot **result)
HRESULT SetStreamSource (UINT stream, RenderBuffer *buffer, UINT offset, UINT stride)
HRESULT SetIndices (RenderBuffer *buffer)
HRESULT SetFVF (DWORD value)
HRESULT GetFVF (DWORD *value) const
HRESULT SetRenderState (DWORD state, DWORD value)
HRESULT GetRenderState (DWORD state, DWORD *value) const
HRESULT SetSamplerState (DWORD sampler, DWORD state, DWORD value)
HRESULT SetTextureStageState (DWORD stage, DWORD state, DWORD value)
HRESULT SetTexture (DWORD stage, RenderTexture *texture)
HRESULT SetTransform (DWORD slot, const RiseMath::Matrix *value)
HRESULT GetTransform (DWORD slot, RiseMath::Matrix *value) const
HRESULT SetLight (DWORD index, const Light *value)
HRESULT LightEnable (DWORD index, BOOL enabled)
HRESULT SetMaterial (const Material *value)
HRESULT SetScissorRect (const RECT *value)
HRESULT GetScissorRect (RECT *value) const
HRESULT SetViewport (const Viewport *value)
HRESULT GetViewport (Viewport *value) const
HRESULT SetClipPlane (DWORD index, const float *value)
HRESULT SetVertexShader (std::nullptr_t)
HRESULT SetPixelShader (std::nullptr_t)
HRESULT DrawPrimitive (Primitive type, UINT first, UINT count)
HRESULT DrawIndexedPrimitive (Primitive type, INT baseVertex, UINT minimum, UINT vertices, UINT startIndex, UINT count)
HRESULT DrawPrimitiveUP (Primitive type, UINT count, const void *vertices, UINT stride)
HRESULT Clear (DWORD count, const RECT *rectangles, DWORD flags, PackedColor color, float depth, DWORD stencil)
HRESULT BeginScene ()
HRESULT EndScene ()
HRESULT GetBackBuffer (UINT chain, UINT buffer, UINT type, RenderSurface **result)
UINT GetAvailableTextureMem () const
bool InScene () const
Saved Capture () const
HRESULT Restore (const Saved &value)

Private Member Functions

HRESULT Layout (VertexLayout11 &result, UINT stride) const
void UpdateBlend ()

Private Attributes

RenderSprite * activeSprite =nullptr
DrawContext11 & draws
std::map< DWORD, DWORD > states
Microsoft::WRL::ComPtr< RenderBuffer > vertices
Microsoft::WRL::ComPtr< RenderBuffer > indices
DWORD vertexFormat =0
UINT offset =0
UINT stride =0
std::array< Light, 8 > lights
std::array< bool, 8 > enabled {}
std::array< std::array< DWORD, 3 >, 8 > filters {}
bool inScene =false

Friends

class RenderSprite

Detailed Description

Definition at line 91 of file ClientRenderer11.h.

Constructor & Destructor Documentation

◆ RenderDevice()

Rendering::RenderDevice::RenderDevice ( DrawContext11 & draws)
inlineexplicit

Definition at line 94 of file ClientRenderer11.h.

Here is the call graph for this function:

Member Function Documentation

◆ BeginScene()

HRESULT Rendering::RenderDevice::BeginScene ( )
inline

Definition at line 129 of file ClientRenderer11.h.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ Capture()

RenderDevice::Saved Rendering::RenderDevice::Capture ( ) const

Definition at line 373 of file ClientRenderer11.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ Clear()

HRESULT Rendering::RenderDevice::Clear ( DWORD count,
const RECT * rectangles,
DWORD flags,
PackedColor color,
float depth,
DWORD stencil )

Definition at line 324 of file ClientRenderer11.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ Context()

ID3D11DeviceContext * Rendering::RenderDevice::Context ( )
inline

Definition at line 99 of file ClientRenderer11.h.

Here is the call graph for this function:

◆ CreateIndexBuffer()

HRESULT Rendering::RenderDevice::CreateIndexBuffer ( UINT bytes,
DWORD usage,
ImageFormat format,
ResourcePool pool,
RenderBuffer ** result,
void * shared )

Definition at line 75 of file ClientRenderer11.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ CreateQuery()

HRESULT Rendering::RenderDevice::CreateQuery ( UINT type,
RenderQuery ** result )

Definition at line 81 of file ClientRenderer11.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ CreateStateBlock()

HRESULT Rendering::RenderDevice::CreateStateBlock ( UINT type,
RenderStateSnapshot ** result )

Definition at line 86 of file ClientRenderer11.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ CreateVertexBuffer()

HRESULT Rendering::RenderDevice::CreateVertexBuffer ( UINT bytes,
DWORD usage,
DWORD format,
ResourcePool pool,
RenderBuffer ** result,
void * shared )

Definition at line 70 of file ClientRenderer11.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ DrawIndexedPrimitive()

HRESULT Rendering::RenderDevice::DrawIndexedPrimitive ( Primitive type,
INT baseVertex,
UINT minimum,
UINT vertices,
UINT startIndex,
UINT count )

Definition at line 310 of file ClientRenderer11.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ DrawPrimitive()

HRESULT Rendering::RenderDevice::DrawPrimitive ( Primitive type,
UINT first,
UINT count )

Definition at line 298 of file ClientRenderer11.cpp.

Here is the call graph for this function:

◆ DrawPrimitiveUP()

HRESULT Rendering::RenderDevice::DrawPrimitiveUP ( Primitive type,
UINT count,
const void * vertices,
UINT stride )

Definition at line 315 of file ClientRenderer11.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ Draws()

DrawContext11 & Rendering::RenderDevice::Draws ( )
inline

Definition at line 96 of file ClientRenderer11.h.

◆ EndScene()

HRESULT Rendering::RenderDevice::EndScene ( )
inline

Definition at line 130 of file ClientRenderer11.h.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ GetAvailableTextureMem()

UINT Rendering::RenderDevice::GetAvailableTextureMem ( ) const

Definition at line 365 of file ClientRenderer11.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ GetBackBuffer()

HRESULT Rendering::RenderDevice::GetBackBuffer ( UINT chain,
UINT buffer,
UINT type,
RenderSurface ** result )

Definition at line 360 of file ClientRenderer11.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ GetFVF()

HRESULT Rendering::RenderDevice::GetFVF ( DWORD * value) const
inline

Definition at line 107 of file ClientRenderer11.h.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ GetRenderState()

HRESULT Rendering::RenderDevice::GetRenderState ( DWORD state,
DWORD * value ) const

Definition at line 113 of file ClientRenderer11.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ GetScissorRect()

HRESULT Rendering::RenderDevice::GetScissorRect ( RECT * value) const
inline

Definition at line 119 of file ClientRenderer11.h.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ GetTransform()

HRESULT Rendering::RenderDevice::GetTransform ( DWORD slot,
RiseMath::Matrix * value ) const

Definition at line 261 of file ClientRenderer11.cpp.

Here is the call graph for this function:

◆ GetViewport()

HRESULT Rendering::RenderDevice::GetViewport ( Viewport * value) const

Definition at line 292 of file ClientRenderer11.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ InScene()

bool Rendering::RenderDevice::InScene ( ) const
inline

Definition at line 133 of file ClientRenderer11.h.

◆ Layout()

HRESULT Rendering::RenderDevice::Layout ( VertexLayout11 & result,
UINT stride ) const
private

Definition at line 93 of file ClientRenderer11.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ LightEnable()

HRESULT Rendering::RenderDevice::LightEnable ( DWORD index,
BOOL enabled )

Definition at line 273 of file ClientRenderer11.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ Native()

ID3D11Device * Rendering::RenderDevice::Native ( )
inline

Definition at line 98 of file ClientRenderer11.h.

Here is the call graph for this function:

◆ Owner()

Device11 & Rendering::RenderDevice::Owner ( )
inline

Definition at line 97 of file ClientRenderer11.h.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ Reset()

void Rendering::RenderDevice::Reset ( )

Definition at line 50 of file ClientRenderer11.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ Restore()

HRESULT Rendering::RenderDevice::Restore ( const Saved & value)

Definition at line 374 of file ClientRenderer11.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ SetClipPlane()

HRESULT Rendering::RenderDevice::SetClipPlane ( DWORD index,
const float * value )

Definition at line 296 of file ClientRenderer11.cpp.

Here is the call graph for this function:

◆ SetFVF()

HRESULT Rendering::RenderDevice::SetFVF ( DWORD value)

Definition at line 112 of file ClientRenderer11.cpp.

Here is the call graph for this function:

◆ SetIndices()

HRESULT Rendering::RenderDevice::SetIndices ( RenderBuffer * buffer)
inline

Definition at line 105 of file ClientRenderer11.h.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ SetLight()

HRESULT Rendering::RenderDevice::SetLight ( DWORD index,
const Light * value )

Definition at line 269 of file ClientRenderer11.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ SetMaterial()

HRESULT Rendering::RenderDevice::SetMaterial ( const Material * value)

Definition at line 282 of file ClientRenderer11.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ SetPixelShader()

HRESULT Rendering::RenderDevice::SetPixelShader ( std::nullptr_t )
inline

Definition at line 124 of file ClientRenderer11.h.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ SetRenderState()

HRESULT Rendering::RenderDevice::SetRenderState ( DWORD state,
DWORD value )

Definition at line 127 of file ClientRenderer11.cpp.

Here is the call graph for this function:

◆ SetSamplerState()

HRESULT Rendering::RenderDevice::SetSamplerState ( DWORD sampler,
DWORD state,
DWORD value )

Definition at line 225 of file ClientRenderer11.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ SetScissorRect()

HRESULT Rendering::RenderDevice::SetScissorRect ( const RECT * value)
inline

Definition at line 118 of file ClientRenderer11.h.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ SetStreamSource()

HRESULT Rendering::RenderDevice::SetStreamSource ( UINT stream,
RenderBuffer * buffer,
UINT offset,
UINT stride )

Definition at line 88 of file ClientRenderer11.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ SetTexture()

HRESULT Rendering::RenderDevice::SetTexture ( DWORD stage,
RenderTexture * texture )

Definition at line 251 of file ClientRenderer11.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ SetTextureStageState()

HRESULT Rendering::RenderDevice::SetTextureStageState ( DWORD stage,
DWORD state,
DWORD value )

Definition at line 234 of file ClientRenderer11.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ SetTransform()

HRESULT Rendering::RenderDevice::SetTransform ( DWORD slot,
const RiseMath::Matrix * value )

Definition at line 253 of file ClientRenderer11.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ SetVertexShader()

HRESULT Rendering::RenderDevice::SetVertexShader ( std::nullptr_t )
inline

Definition at line 123 of file ClientRenderer11.h.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ SetViewport()

HRESULT Rendering::RenderDevice::SetViewport ( const Viewport * value)

Definition at line 287 of file ClientRenderer11.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ UpdateBlend()

void Rendering::RenderDevice::UpdateBlend ( )
private

Definition at line 115 of file ClientRenderer11.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ RenderSprite

friend class RenderSprite
friend

Definition at line 148 of file ClientRenderer11.h.

Member Data Documentation

◆ activeSprite

RenderSprite* Rendering::RenderDevice::activeSprite =nullptr
private

Definition at line 149 of file ClientRenderer11.h.

◆ draws

DrawContext11& Rendering::RenderDevice::draws
private

Definition at line 152 of file ClientRenderer11.h.

◆ enabled

std::array<bool,8> Rendering::RenderDevice::enabled {}
private

Definition at line 158 of file ClientRenderer11.h.

◆ filters

std::array<std::array<DWORD,3>,8> Rendering::RenderDevice::filters {}
private

Definition at line 159 of file ClientRenderer11.h.

◆ indices

Microsoft::WRL::ComPtr<RenderBuffer> Rendering::RenderDevice::indices
private

Definition at line 154 of file ClientRenderer11.h.

◆ inScene

bool Rendering::RenderDevice::inScene =false
private

Definition at line 160 of file ClientRenderer11.h.

◆ lights

std::array<Light,8> Rendering::RenderDevice::lights
private

Definition at line 157 of file ClientRenderer11.h.

◆ offset

UINT Rendering::RenderDevice::offset =0
private

Definition at line 156 of file ClientRenderer11.h.

◆ states

std::map<DWORD,DWORD> Rendering::RenderDevice::states
private

Definition at line 153 of file ClientRenderer11.h.

◆ stride

UINT Rendering::RenderDevice::stride =0
private

Definition at line 156 of file ClientRenderer11.h.

◆ vertexFormat

DWORD Rendering::RenderDevice::vertexFormat =0
private

Definition at line 155 of file ClientRenderer11.h.

◆ vertices

Microsoft::WRL::ComPtr<RenderBuffer> Rendering::RenderDevice::vertices
private

Definition at line 154 of file ClientRenderer11.h.


The documentation for this class was generated from the following files: