Skip to content

Commit 10c60c2

Browse files
committed
NULL and 0 replaced by nullptr
IC, inline and etc removed where they're not needed
1 parent 290e016 commit 10c60c2

File tree

166 files changed

+962
-914
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

166 files changed

+962
-914
lines changed

src/Include/xrRender/EnvironmentRender.h

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ class CEnvDescriptor;
1313
class IEnvDescriptorRender
1414
{
1515
public:
16-
virtual ~IEnvDescriptorRender() { ; }
16+
virtual ~IEnvDescriptorRender() {}
1717
virtual void Copy(IEnvDescriptorRender& _in) = 0;
1818

1919
virtual void OnDeviceCreate(CEnvDescriptor& owner) = 0;
@@ -23,7 +23,7 @@ class IEnvDescriptorRender
2323
class IEnvDescriptorMixerRender
2424
{
2525
public:
26-
virtual ~IEnvDescriptorMixerRender() { ; }
26+
virtual ~IEnvDescriptorMixerRender() {}
2727
virtual void Copy(IEnvDescriptorMixerRender& _in) = 0;
2828

2929
virtual void Destroy() = 0;
@@ -34,7 +34,7 @@ class IEnvDescriptorMixerRender
3434
class IEnvironmentRender
3535
{
3636
public:
37-
virtual ~IEnvironmentRender() { ; }
37+
virtual ~IEnvironmentRender() {}
3838
virtual void Copy(IEnvironmentRender& _in) = 0;
3939
virtual void OnFrame(CEnvironment& env) = 0;
4040
virtual void OnLoad() = 0;

src/Include/xrRender/FactoryPtr.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@ class FactoryPtr
3939
// unspecified bool type
4040
typedef T const* (FactoryPtr::*unspecified_bool_type)() const;
4141
operator unspecified_bool_type() const { return (!m_pObject ? 0 : &FactoryPtr::get); }
42-
bool operator!() const { return m_pObject == 0; }
42+
bool operator!() const { return m_pObject == nullptr; }
4343
private:
4444
void CreateObject();
4545
void DestroyObject();

src/Include/xrRender/KinematicsAnimated.h

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -91,11 +91,11 @@ class IKinematicsAnimated
9191
virtual MotionID ID_Cycle(shared_str N) = 0;
9292
virtual MotionID ID_Cycle_Safe(shared_str N) = 0;
9393
virtual CBlend* PlayCycle(
94-
LPCSTR N, BOOL bMixIn = TRUE, PlayCallback Callback = 0, LPVOID CallbackParam = 0, u8 channel = 0) = 0;
94+
LPCSTR N, BOOL bMixIn = TRUE, PlayCallback Callback = nullptr, LPVOID CallbackParam = nullptr, u8 channel = 0) = 0;
9595
virtual CBlend* PlayCycle(
96-
MotionID M, BOOL bMixIn = TRUE, PlayCallback Callback = 0, LPVOID CallbackParam = 0, u8 channel = 0) = 0;
97-
virtual CBlend* PlayCycle(u16 partition, MotionID M, BOOL bMixIn = TRUE, PlayCallback Callback = 0,
98-
LPVOID CallbackParam = 0, u8 channel = 0) = 0;
96+
MotionID M, BOOL bMixIn = TRUE, PlayCallback Callback = nullptr, LPVOID CallbackParam = nullptr, u8 channel = 0) = 0;
97+
virtual CBlend* PlayCycle(u16 partition, MotionID M, BOOL bMixIn = TRUE, PlayCallback Callback = nullptr,
98+
LPVOID CallbackParam = nullptr, u8 channel = 0) = 0;
9999
// fx'es
100100
virtual MotionID ID_FX(LPCSTR N) = 0;
101101
virtual MotionID ID_FX_Safe(LPCSTR N) = 0;

src/Include/xrRender/RenderVisual.h

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -18,9 +18,9 @@ class IRenderVisual
1818
virtual shared_str getDebugName() = 0;
1919
#endif
2020

21-
virtual IKinematics* dcast_PKinematics() { return 0; }
22-
virtual IKinematicsAnimated* dcast_PKinematicsAnimated() { return 0; }
23-
virtual IParticleCustom* dcast_ParticleCustom() { return 0; }
21+
virtual IKinematics* dcast_PKinematics() { return nullptr; }
22+
virtual IKinematicsAnimated* dcast_PKinematicsAnimated() { return nullptr; }
23+
virtual IParticleCustom* dcast_ParticleCustom() { return nullptr; }
2424
};
2525

2626
#endif // RenderVisual_included

src/Include/xrRender/UIRender.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@ class IUIRender
5050
//. virtual void FlushLineStrip() = 0;
5151
//. virtual void StartLineList(u32 iMaxVerts) = 0;
5252
//. virtual void FlushLineList() = 0;
53-
virtual void SetScissor(Irect* rect = NULL) = 0;
53+
virtual void SetScissor(Irect* rect = nullptr) = 0;
5454
virtual void GetActiveTextureResolution(Fvector2& res) = 0;
5555

5656
//. virtual void PushPoint(float x, float y, u32 c, float u, float v) = 0;

src/Include/xrRender/UIShader.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ class IUIShader
77
public:
88
virtual ~IUIShader() { ; }
99
virtual void Copy(IUIShader& _in) = 0;
10-
virtual void create(LPCSTR sh, LPCSTR tex = 0) = 0;
10+
virtual void create(LPCSTR sh, LPCSTR tex = nullptr) = 0;
1111
virtual bool inited() = 0;
1212
virtual void destroy() = 0;
1313
};

src/Include/xrRender/animation_blend.h

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -60,19 +60,19 @@ class CBlend
6060
IC void update_play(float dt, PlayCallback _Callback);
6161
IC bool update_falloff(float dt);
6262
IC bool update(float dt, PlayCallback _Callback);
63-
IC ECurvature blend_state() const { return blend; }
64-
IC void set_free_state() { blend = eFREE_SLOT; }
65-
IC void set_accrue_state() { blend = eAccrue; }
66-
IC void set_falloff_state() { blend = eFalloff; }
67-
IC void set(const CBlend& r) { *this = r; }
63+
ECurvature blend_state() const { return blend; }
64+
void set_free_state() { blend = eFREE_SLOT; }
65+
void set_accrue_state() { blend = eAccrue; }
66+
void set_falloff_state() { blend = eFalloff; }
67+
void set(const CBlend& r) { *this = r; }
6868
#ifdef DEBUG
6969
CBlend()
7070
:
7171

7272
blendAmount(0),
7373
timeCurrent(0), timeTotal(0), motionID(), bone_or_part(0), channel(0), blend(eFREE_SLOT), blendAccrue(0),
7474
blendFalloff(0), blendPower(0), speed(0), playing(0), stop_at_end_callback(0), stop_at_end(0), fall_at_end(0),
75-
Callback(0), CallbackParam(0), dwFrame(0)
75+
Callback(nullptr), CallbackParam(nullptr), dwFrame(0)
7676
{
7777
}
7878

src/Include/xrRender/animation_motion.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ struct MotionID
3737
if (valid())
3838
return &MotionID::get;
3939
else
40-
return 0;
40+
return nullptr;
4141
// return(!valid()?0:&MotionID::get);
4242
}
4343
};

src/Layers/xrRender/Animation.h

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -37,8 +37,9 @@ class channels
3737
void set_factor(u16 channel, float factor);
3838

3939
public:
40-
IC const channal_rule& rule(u16 channel) { return rules[channel]; }
41-
IC void get_def(u16 channel, channel_def& def)
40+
const channal_rule& rule(u16 channel) { return rules[channel]; }
41+
42+
void get_def(u16 channel, channel_def& def)
4243
{
4344
VERIFY(channel < max);
4445
def.rule = rules[channel];

src/Layers/xrRender/AnimationKeyCalculate.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ struct ConsistantKey
1414
const CKey* K;
1515
float w;
1616

17-
IC void set(const CKey* _K, float _w)
17+
void set(const CKey* _K, float _w)
1818
{
1919
K = _K;
2020
w = _w;

0 commit comments

Comments
 (0)