CommonLibSSE (Parapets fork)
Loading...
Searching...
No Matches
RE::GRenderer Class Referenceabstract

#include <GRenderer.h>

Inheritance diagram for RE::GRenderer:
RE::GRefCountBase< GRenderer, GStatRenderer::kMem > RE::GRefCountBaseStatImpl< GRefCountImpl, STAT > RE::GRefCountImpl RE::GRefCountImplCore

Classes

struct  BitmapDesc
 
struct  BlurFilterParams
 
class  CachedData
 
class  CacheProvider
 
class  Cxform
 
struct  DistanceFieldParams
 
struct  FillTexture
 
struct  RenderCaps
 
class  Stats
 
struct  StereoParams
 
struct  UserData
 
struct  VertexXY16i
 
struct  VertexXY16iC32
 
struct  VertexXY16iCF32
 

Public Types

enum class  BlendType {
  kNone = 0 , kNormal = 1 , kLayer = 2 , kMultiply = 3 ,
  kScreen = 4 , kLighten = 5 , kDarken = 6 , kDifference = 7 ,
  kAdd = 8 , kSubtract = 9 , kInvert = 10 , kAlpha = 11 ,
  kErase = 12 , kOverlay = 13 , kHardLight = 14
}
 
enum class  ResizeImageType { kRGBToRGB , kRGBAToRGBA , kRGBToRGBA , kGray }
 
enum class  VertexFormat {
  kNone = 0 , kXY16i = 1 << 1 , kXY32f = 1 << 2 , kXY16iC32 = 1 << 3 ,
  kXY16iCF32 = 1 << 4
}
 
enum class  IndexFormat { kNone = 0 , k16 = 1 , k32 = 2 }
 
enum class  RenderCapBits {
  kNone = 0 , kCacheDataUse = 1 << 0 , kIndex16 = 1 << 2 , kIndex32 = 1 << 3 ,
  kRenderStats = 1 << 4 , kRenderTargets = 1 << 5 , kRenderTargetPrePass = 1 << 6 , kRenderTargetNonPow2 = 1 << 7 ,
  kFillGouraud = 1 << 8 , kFillGouraudTex = 1 << 9 , kCxformAdd = 1 << 12 , kNestedMasks = 1 << 13 ,
  kTexNonPower2 = 1 << 14 , kTexNonPower2Wrap = 1 << 15 , kCanLoseData = 1 << 16 , kKeepVertexData = 1 << 17 ,
  kNoTexOverwrite = 1 << 18 , kTexNonPower2Mip = 1 << 19 , kThreadedTextureCreation = 1 << 20 , kRenderTargetMip = 1 << 21 ,
  kFilter_Blurs = 1 << 22 , kFilter_ColorMatrix = 1 << 23
}
 
enum class  StereoDisplay { kStereoCenter , kStereoLeft , kStereoRight }
 
enum class  CachedDataType { kVertex = 1 , kIndex = 2 , kBitmapList = 3 }
 
enum class  UserDataPropertyFlag { kNone , kHasString , kHasFloat , kHasMatrix }
 
enum class  BitmapWrapMode { kRepeat , kClamp }
 
enum class  BitmapSampleMode { kPoint , kLinear }
 
enum class  GouraudFillType {
  kColor , k1Texture , k1TextureColor , k2Texture ,
  k2TextureColor , k3Texture
}
 
enum class  SubmitMaskMode { kClear , kIncrement , kDecrement }
 
enum class  FilterModes {
  kBlur = 1 << 0 , kShadow = 1 << 1 , kHighlight = 1 << 2 , Filter_Knockout = 1 << 8 ,
  Filter_Inner = 1 << 9 , Filter_HideObject = 1 << 10 , Filter_UserModes = 0xFFFF , Filter_SkipLastPass = 1 << 16 ,
  Filter_LastPassOnly = 1 << 17
}
 
enum class  FilterSupport { kNone = 0 , kOk = 1 << 0 , kMultipass = 1 << 1 , kSlow = 1 << 2 }
 
using Handle = void *
 
using Matrix = GMatrix2D
 
using Point = GPointF
 
using Rect = GRectF
 
- Public Types inherited from RE::GRefCountBase< GRenderer, GStatRenderer::kMem >
enum  
 

Public Member Functions

 ~GRenderer () override
 
virtual bool GetRenderCaps (RenderCaps *a_caps)=0
 
virtual GTextureCreateTexture ()=0
 
virtual GTextureCreateTextureYUV ()=0
 
virtual void BeginFrame ()
 
virtual void EndFrame ()
 
virtual GRenderTarget * CreateRenderTarget ()=0
 
virtual void SetDisplayRenderTarget (GRenderTarget *a_renderTarget, bool a_setstate=true)=0
 
virtual void PushRenderTarget (const GRectF &a_frameRect, GRenderTarget *a_renderTarget)=0
 
virtual void PopRenderTarget ()=0
 
virtual GTexturePushTempRenderTarget (const GRectF &a_frameRect, std::uint32_t a_targetW, std::uint32_t a_targetH)=0
 
virtual void ReleaseTempRenderTargets (std::uint32_t a_keepArea)
 
virtual void BeginDisplay (GColor a_backgroundColor, const GViewport &a_viewport, float a_x0, float a_x1, float a_y0, float a_y1)=0
 
virtual void EndDisplay ()=0
 
virtual void SetMatrix (const Matrix &a_matrix)=0
 
virtual void SetUserMatrix (const Matrix &a_matrix)=0
 
virtual void SetCxform (const Cxform &a_cxForm)=0
 
virtual void PushBlendMode (BlendType a_mode)=0
 
virtual void PopBlendMode ()=0
 
virtual bool PushUserData (UserData *a_data)
 
virtual void PopUserData ()
 
virtual void SetPerspective3D (const GMatrix3D &a_projMatIn)=0
 
virtual void SetView3D (const GMatrix3D &a_viewMatIn)=0
 
virtual void SetWorld3D (const GMatrix3D *a_worldMatIn)=0
 
virtual void MakeViewAndPersp3D (const GRectF &a_visFrameRectInTwips, GMatrix3D &a_matView, GMatrix3D &a_matPersp, float a_perspFOV, bool a_InvertY=false)
 
virtual void SetStereoParams (StereoParams a_params)
 
virtual void SetStereoDisplay (StereoDisplay a_display, bool a_setstate=false)
 
virtual void SetVertexData (const void *a_vertices, std::int32_t a_numVertices, VertexFormat a_vtxFmt, CacheProvider *a_cache=0)=0
 
virtual void SetIndexData (const void *a_indices, std::int32_t a_numIndices, IndexFormat a_idxFmt, CacheProvider *a_cache=0)=0
 
virtual void ReleaseCachedData (CachedData *a_data, CachedDataType a_type)=0
 
virtual void DrawIndexedTriList (std::int32_t a_baseVertexIndex, std::int32_t a_minVertexIndex, std::int32_t a_numVertices, std::int32_t a_startIndex, std::int32_t a_triangleCount)=0
 
virtual void DrawLineStrip (std::int32_t a_baseVertexIndex, std::int32_t a_lineCount)=0
 
virtual void LineStyleDisable ()=0
 
virtual void LineStyleColor (GColor a_color)=0
 
virtual void FillStyleDisable ()=0
 
virtual void FillStyleColor (GColor a_color)=0
 
virtual void FillStyleBitmap (const FillTexture *a_fill)=0
 
virtual void FillStyleGouraud (GouraudFillType a_fillType, const FillTexture *a_texture0=0, const FillTexture *a_texture1=0, const FillTexture *a_texture2=0)=0
 
virtual void DrawBitmaps (BitmapDesc *a_bitmapList, std::int32_t a_listSize, std::int32_t a_startIndex, std::int32_t a_count, const GTexture *a_texture, const Matrix &a_matrix, CacheProvider *a_cache=0)=0
 
virtual void DrawDistanceFieldBitmaps (BitmapDesc *a_bitmapList, std::int32_t a_listSize, std::int32_t a_startIndex, std::int32_t a_count, const GTexture *a_texture, const Matrix &a_matrix, const DistanceFieldParams &a_params, CacheProvider *a_cache=0)
 
virtual void BeginSubmitMask (SubmitMaskMode a_maskMode=SubmitMaskMode::kClear)=0
 
virtual void EndSubmitMask ()=0
 
virtual void DisableMask ()=0
 
virtual std::uint32_t CheckFilterSupport (const BlurFilterParams &a_params)=0
 
virtual void DrawBlurRect (GTexture *a_srcIn, const GRectF &a_inSrcRect, const GRectF &a_inDstRect, const BlurFilterParams &a_params)=0
 
virtual void DrawColorMatrixRect (GTexture *a_srcIn, const GRectF &a_inSrcRect, const GRectF &a_dstRect, const float *a_matrix)=0
 
virtual void GetRenderStats (Stats *a_stats, bool a_resetStats=0)=0
 
virtual void GetStats (GStatBag *a_bag, bool a_reset=true)=0
 
virtual void ReleaseResources ()=0
 
virtual bool AddEventHandler (GRendererEventHandler *a_handler)
 
virtual void RemoveEventHandler (GRendererEventHandler *a_handler)
 
void FillStyleBitmap (GTexture *a_texture, const Matrix &a_matrix, BitmapWrapMode a_wrapMode, BitmapSampleMode a_sampleMode)
 
- Public Member Functions inherited from RE::GRefCountBaseStatImpl< GRefCountImpl, STAT >
 GFC_MEMORY_REDEFINE_NEW_IMPL (GRefCountImpl, GFC_REFCOUNTALLOC_CHECK_DELETE, StatType)
 
- Public Member Functions inherited from RE::GRefCountImpl
 ~GRefCountImpl () override=default
 
void AddRef ()
 
void Release ()
 

Public Attributes

GList< GRendererEventHandlerhandlers
 
StereoParams s3DParams
 
stl::enumeration< StereoDisplay, std::uint32_t > s3DDisplay
 

Additional Inherited Members

- Static Public Attributes inherited from RE::GRefCountImpl
static constexpr auto RTTI = RTTI_GRefCountImpl
 

Member Typedef Documentation

◆ Handle

using RE::GRenderer::Handle = void*

◆ Matrix

◆ Point

◆ Rect

Member Enumeration Documentation

◆ BitmapSampleMode

Enumerator
kPoint 
kLinear 

◆ BitmapWrapMode

enum class RE::GRenderer::BitmapWrapMode
strong
Enumerator
kRepeat 
kClamp 

◆ BlendType

enum class RE::GRenderer::BlendType
strong
Enumerator
kNone 
kNormal 
kLayer 
kMultiply 
kScreen 
kLighten 
kDarken 
kDifference 
kAdd 
kSubtract 
kInvert 
kAlpha 
kErase 
kOverlay 
kHardLight 

◆ CachedDataType

enum class RE::GRenderer::CachedDataType
strong
Enumerator
kVertex 
kIndex 
kBitmapList 

◆ FilterModes

enum class RE::GRenderer::FilterModes
strong
Enumerator
kBlur 
kShadow 
kHighlight 
Filter_Knockout 
Filter_Inner 
Filter_HideObject 
Filter_UserModes 
Filter_SkipLastPass 
Filter_LastPassOnly 

◆ FilterSupport

enum class RE::GRenderer::FilterSupport
strong
Enumerator
kNone 
kOk 
kMultipass 
kSlow 

◆ GouraudFillType

enum class RE::GRenderer::GouraudFillType
strong
Enumerator
kColor 
k1Texture 
k1TextureColor 
k2Texture 
k2TextureColor 
k3Texture 

◆ IndexFormat

enum class RE::GRenderer::IndexFormat
strong
Enumerator
kNone 
k16 
k32 

◆ RenderCapBits

enum class RE::GRenderer::RenderCapBits
strong
Enumerator
kNone 
kCacheDataUse 
kIndex16 
kIndex32 
kRenderStats 
kRenderTargets 
kRenderTargetPrePass 
kRenderTargetNonPow2 
kFillGouraud 
kFillGouraudTex 
kCxformAdd 
kNestedMasks 
kTexNonPower2 
kTexNonPower2Wrap 
kCanLoseData 
kKeepVertexData 
kNoTexOverwrite 
kTexNonPower2Mip 
kThreadedTextureCreation 
kRenderTargetMip 
kFilter_Blurs 
kFilter_ColorMatrix 

◆ ResizeImageType

enum class RE::GRenderer::ResizeImageType
strong
Enumerator
kRGBToRGB 
kRGBAToRGBA 
kRGBToRGBA 
kGray 

◆ StereoDisplay

enum class RE::GRenderer::StereoDisplay
strong
Enumerator
kStereoCenter 
kStereoLeft 
kStereoRight 

◆ SubmitMaskMode

enum class RE::GRenderer::SubmitMaskMode
strong
Enumerator
kClear 
kIncrement 
kDecrement 

◆ UserDataPropertyFlag

Enumerator
kNone 
kHasString 
kHasFloat 
kHasMatrix 

◆ VertexFormat

enum class RE::GRenderer::VertexFormat
strong
Enumerator
kNone 
kXY16i 
kXY32f 
kXY16iC32 
kXY16iCF32 

Constructor & Destructor Documentation

◆ ~GRenderer()

RE::GRenderer::~GRenderer ( )
override

Member Function Documentation

◆ AddEventHandler()

virtual bool RE::GRenderer::AddEventHandler ( GRendererEventHandler a_handler)
virtual

◆ BeginDisplay()

virtual void RE::GRenderer::BeginDisplay ( GColor  a_backgroundColor,
const GViewport a_viewport,
float  a_x0,
float  a_x1,
float  a_y0,
float  a_y1 
)
pure virtual

◆ BeginFrame()

virtual void RE::GRenderer::BeginFrame ( )
virtual

◆ BeginSubmitMask()

virtual void RE::GRenderer::BeginSubmitMask ( SubmitMaskMode  a_maskMode = SubmitMaskMode::kClear)
pure virtual

◆ CheckFilterSupport()

virtual std::uint32_t RE::GRenderer::CheckFilterSupport ( const BlurFilterParams a_params)
pure virtual

◆ CreateRenderTarget()

virtual GRenderTarget * RE::GRenderer::CreateRenderTarget ( )
pure virtual

◆ CreateTexture()

virtual GTexture * RE::GRenderer::CreateTexture ( )
pure virtual

◆ CreateTextureYUV()

virtual GTexture * RE::GRenderer::CreateTextureYUV ( )
pure virtual

◆ DisableMask()

virtual void RE::GRenderer::DisableMask ( )
pure virtual

◆ DrawBitmaps()

virtual void RE::GRenderer::DrawBitmaps ( BitmapDesc a_bitmapList,
std::int32_t  a_listSize,
std::int32_t  a_startIndex,
std::int32_t  a_count,
const GTexture a_texture,
const Matrix a_matrix,
CacheProvider a_cache = 0 
)
pure virtual

◆ DrawBlurRect()

virtual void RE::GRenderer::DrawBlurRect ( GTexture a_srcIn,
const GRectF a_inSrcRect,
const GRectF a_inDstRect,
const BlurFilterParams a_params 
)
pure virtual

◆ DrawColorMatrixRect()

virtual void RE::GRenderer::DrawColorMatrixRect ( GTexture a_srcIn,
const GRectF a_inSrcRect,
const GRectF a_dstRect,
const float *  a_matrix 
)
pure virtual

◆ DrawDistanceFieldBitmaps()

virtual void RE::GRenderer::DrawDistanceFieldBitmaps ( BitmapDesc a_bitmapList,
std::int32_t  a_listSize,
std::int32_t  a_startIndex,
std::int32_t  a_count,
const GTexture a_texture,
const Matrix a_matrix,
const DistanceFieldParams a_params,
CacheProvider a_cache = 0 
)
virtual

◆ DrawIndexedTriList()

virtual void RE::GRenderer::DrawIndexedTriList ( std::int32_t  a_baseVertexIndex,
std::int32_t  a_minVertexIndex,
std::int32_t  a_numVertices,
std::int32_t  a_startIndex,
std::int32_t  a_triangleCount 
)
pure virtual

◆ DrawLineStrip()

virtual void RE::GRenderer::DrawLineStrip ( std::int32_t  a_baseVertexIndex,
std::int32_t  a_lineCount 
)
pure virtual

◆ EndDisplay()

virtual void RE::GRenderer::EndDisplay ( )
pure virtual

◆ EndFrame()

virtual void RE::GRenderer::EndFrame ( )
virtual

◆ EndSubmitMask()

virtual void RE::GRenderer::EndSubmitMask ( )
pure virtual

◆ FillStyleBitmap() [1/2]

virtual void RE::GRenderer::FillStyleBitmap ( const FillTexture a_fill)
pure virtual

◆ FillStyleBitmap() [2/2]

void RE::GRenderer::FillStyleBitmap ( GTexture a_texture,
const Matrix a_matrix,
BitmapWrapMode  a_wrapMode,
BitmapSampleMode  a_sampleMode 
)

◆ FillStyleColor()

virtual void RE::GRenderer::FillStyleColor ( GColor  a_color)
pure virtual

◆ FillStyleDisable()

virtual void RE::GRenderer::FillStyleDisable ( )
pure virtual

◆ FillStyleGouraud()

virtual void RE::GRenderer::FillStyleGouraud ( GouraudFillType  a_fillType,
const FillTexture a_texture0 = 0,
const FillTexture a_texture1 = 0,
const FillTexture a_texture2 = 0 
)
pure virtual

◆ GetRenderCaps()

virtual bool RE::GRenderer::GetRenderCaps ( RenderCaps a_caps)
pure virtual

◆ GetRenderStats()

virtual void RE::GRenderer::GetRenderStats ( Stats a_stats,
bool  a_resetStats = 0 
)
pure virtual

◆ GetStats()

virtual void RE::GRenderer::GetStats ( GStatBag *  a_bag,
bool  a_reset = true 
)
pure virtual

◆ LineStyleColor()

virtual void RE::GRenderer::LineStyleColor ( GColor  a_color)
pure virtual

◆ LineStyleDisable()

virtual void RE::GRenderer::LineStyleDisable ( )
pure virtual

◆ MakeViewAndPersp3D()

virtual void RE::GRenderer::MakeViewAndPersp3D ( const GRectF a_visFrameRectInTwips,
GMatrix3D a_matView,
GMatrix3D a_matPersp,
float  a_perspFOV,
bool  a_InvertY = false 
)
virtual

◆ PopBlendMode()

virtual void RE::GRenderer::PopBlendMode ( )
pure virtual

◆ PopRenderTarget()

virtual void RE::GRenderer::PopRenderTarget ( )
pure virtual

◆ PopUserData()

virtual void RE::GRenderer::PopUserData ( )
virtual

◆ PushBlendMode()

virtual void RE::GRenderer::PushBlendMode ( BlendType  a_mode)
pure virtual

◆ PushRenderTarget()

virtual void RE::GRenderer::PushRenderTarget ( const GRectF a_frameRect,
GRenderTarget *  a_renderTarget 
)
pure virtual

◆ PushTempRenderTarget()

virtual GTexture * RE::GRenderer::PushTempRenderTarget ( const GRectF a_frameRect,
std::uint32_t  a_targetW,
std::uint32_t  a_targetH 
)
pure virtual

◆ PushUserData()

virtual bool RE::GRenderer::PushUserData ( UserData a_data)
virtual

◆ ReleaseCachedData()

virtual void RE::GRenderer::ReleaseCachedData ( CachedData a_data,
CachedDataType  a_type 
)
pure virtual

◆ ReleaseResources()

virtual void RE::GRenderer::ReleaseResources ( )
pure virtual

◆ ReleaseTempRenderTargets()

virtual void RE::GRenderer::ReleaseTempRenderTargets ( std::uint32_t  a_keepArea)
virtual

◆ RemoveEventHandler()

virtual void RE::GRenderer::RemoveEventHandler ( GRendererEventHandler a_handler)
virtual

◆ SetCxform()

virtual void RE::GRenderer::SetCxform ( const Cxform a_cxForm)
pure virtual

◆ SetDisplayRenderTarget()

virtual void RE::GRenderer::SetDisplayRenderTarget ( GRenderTarget *  a_renderTarget,
bool  a_setstate = true 
)
pure virtual

◆ SetIndexData()

virtual void RE::GRenderer::SetIndexData ( const void *  a_indices,
std::int32_t  a_numIndices,
IndexFormat  a_idxFmt,
CacheProvider a_cache = 0 
)
pure virtual

◆ SetMatrix()

virtual void RE::GRenderer::SetMatrix ( const Matrix a_matrix)
pure virtual

◆ SetPerspective3D()

virtual void RE::GRenderer::SetPerspective3D ( const GMatrix3D a_projMatIn)
pure virtual

◆ SetStereoDisplay()

virtual void RE::GRenderer::SetStereoDisplay ( StereoDisplay  a_display,
bool  a_setstate = false 
)
virtual

◆ SetStereoParams()

virtual void RE::GRenderer::SetStereoParams ( StereoParams  a_params)
virtual

◆ SetUserMatrix()

virtual void RE::GRenderer::SetUserMatrix ( const Matrix a_matrix)
pure virtual

◆ SetVertexData()

virtual void RE::GRenderer::SetVertexData ( const void *  a_vertices,
std::int32_t  a_numVertices,
VertexFormat  a_vtxFmt,
CacheProvider a_cache = 0 
)
pure virtual

◆ SetView3D()

virtual void RE::GRenderer::SetView3D ( const GMatrix3D a_viewMatIn)
pure virtual

◆ SetWorld3D()

virtual void RE::GRenderer::SetWorld3D ( const GMatrix3D a_worldMatIn)
pure virtual

Member Data Documentation

◆ handlers

GList<GRendererEventHandler> RE::GRenderer::handlers

◆ s3DDisplay

stl::enumeration<StereoDisplay, std::uint32_t> RE::GRenderer::s3DDisplay

◆ s3DParams

StereoParams RE::GRenderer::s3DParams

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