CRenderer: Make use of in-class initializers
Same behavior, less code.
This commit is contained in:
parent
f88122b2ed
commit
9441933ce2
|
@ -7,7 +7,6 @@
|
|||
#include <Common/Math/CTransform4f.h>
|
||||
|
||||
#include <algorithm>
|
||||
#include <iostream>
|
||||
#include <fstream>
|
||||
#include <vector>
|
||||
#include <sstream>
|
||||
|
@ -17,11 +16,6 @@ uint32 CRenderer::sNumRenderers = 0;
|
|||
|
||||
// ************ INITIALIZATION ************
|
||||
CRenderer::CRenderer()
|
||||
: mOptions(ERenderOption::EnableUVScroll | ERenderOption::EnableBackfaceCull)
|
||||
, mBloomMode(EBloomMode::NoBloom)
|
||||
, mDrawGrid(true)
|
||||
, mInitialized(false)
|
||||
, mContextIndex(-1)
|
||||
{
|
||||
sNumRenderers++;
|
||||
}
|
||||
|
|
|
@ -48,20 +48,23 @@ enum class EBloomMode
|
|||
*/
|
||||
class CRenderer
|
||||
{
|
||||
FRenderOptions mOptions;
|
||||
EBloomMode mBloomMode;
|
||||
bool mDrawGrid;
|
||||
FRenderOptions mOptions{ERenderOption::EnableUVScroll | ERenderOption::EnableBackfaceCull};
|
||||
EBloomMode mBloomMode{EBloomMode::NoBloom};
|
||||
bool mDrawGrid = true;
|
||||
CColor mClearColor;
|
||||
uint32 mContextIndex;
|
||||
bool mInitialized;
|
||||
uint32 mViewportWidth, mViewportHeight;
|
||||
uint32 mBloomWidth, mBloomHeight;
|
||||
float mBloomHScale, mBloomVScale;
|
||||
uint32 mContextIndex = UINT32_MAX;
|
||||
bool mInitialized = false;
|
||||
uint32 mViewportWidth = 0;
|
||||
uint32 mViewportHeight = 0;
|
||||
uint32 mBloomWidth = 0;
|
||||
uint32 mBloomHeight = 0;
|
||||
float mBloomHScale = 0.0f;
|
||||
float mBloomVScale = 0.0f;
|
||||
|
||||
CFramebuffer mSceneFramebuffer;
|
||||
CFramebuffer mPostProcessFramebuffer;
|
||||
CFramebuffer mBloomFramebuffers[3];
|
||||
GLint mDefaultFramebuffer;
|
||||
GLint mDefaultFramebuffer = 0;
|
||||
|
||||
CRenderBucket mBackgroundBucket;
|
||||
CRenderBucket mMidgroundBucket;
|
||||
|
|
Loading…
Reference in New Issue