API BREAKER: Replacing defines in irrTypes.h which are conflicting with c++ reserved identifier rules.
C++ has undefined behavior for identifiers starting with __ or with _ followed by an uppercase letter. We still have many more (in IrrCompileConfig.h and in all header-guards), will likely replace those later as well. As a workaround for users which might use irrlicht defines in their code, I've added the header irrLegacyDefines.h Including that allows to continue using old defines for a while - or make it easier to have code which compiles with old and new Irrlicht library versions. git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/trunk@6251 dfc29bdd-3216-0410-991c-e03cc46cb475
This commit is contained in:
@@ -26,7 +26,7 @@ public:
|
||||
COpenGLMaterialRenderer_SOLID(video::COpenGLDriver* d) : Driver(d) {}
|
||||
|
||||
virtual void OnSetMaterial(const SMaterial& material, const SMaterial& lastMaterial,
|
||||
bool resetAllRenderstates, IMaterialRendererServices* services) _IRR_OVERRIDE_
|
||||
bool resetAllRenderstates, IMaterialRendererServices* services) IRR_OVERRIDE
|
||||
{
|
||||
if (Driver->getFixedPipelineState() == COpenGLDriver::EOFPS_DISABLE)
|
||||
Driver->setFixedPipelineState(COpenGLDriver::EOFPS_DISABLE_TO_ENABLE);
|
||||
@@ -51,7 +51,7 @@ public:
|
||||
COpenGLMaterialRenderer_ONETEXTURE_BLEND(video::COpenGLDriver* d) : Driver(d) {}
|
||||
|
||||
virtual void OnSetMaterial(const SMaterial& material, const SMaterial& lastMaterial,
|
||||
bool resetAllRenderstates, IMaterialRendererServices* services) _IRR_OVERRIDE_
|
||||
bool resetAllRenderstates, IMaterialRendererServices* services) IRR_OVERRIDE
|
||||
{
|
||||
if (Driver->getFixedPipelineState() == COpenGLDriver::EOFPS_DISABLE)
|
||||
Driver->setFixedPipelineState(COpenGLDriver::EOFPS_DISABLE_TO_ENABLE);
|
||||
@@ -137,7 +137,7 @@ public:
|
||||
}
|
||||
}
|
||||
|
||||
virtual void OnUnsetMaterial() _IRR_OVERRIDE_
|
||||
virtual void OnUnsetMaterial() IRR_OVERRIDE
|
||||
{
|
||||
Driver->getCacheHandler()->setActiveTexture(GL_TEXTURE0_ARB);
|
||||
|
||||
@@ -158,7 +158,7 @@ public:
|
||||
|
||||
//! Returns if the material is transparent.
|
||||
/** Is not always transparent, but mostly. */
|
||||
virtual bool isTransparent() const _IRR_OVERRIDE_
|
||||
virtual bool isTransparent() const IRR_OVERRIDE
|
||||
{
|
||||
return true;
|
||||
}
|
||||
@@ -177,7 +177,7 @@ public:
|
||||
COpenGLMaterialRenderer_SOLID_2_LAYER(video::COpenGLDriver* d) : Driver(d) {}
|
||||
|
||||
virtual void OnSetMaterial(const SMaterial& material, const SMaterial& lastMaterial,
|
||||
bool resetAllRenderstates, IMaterialRendererServices* services) _IRR_OVERRIDE_
|
||||
bool resetAllRenderstates, IMaterialRendererServices* services) IRR_OVERRIDE
|
||||
{
|
||||
if (Driver->getFixedPipelineState() == COpenGLDriver::EOFPS_DISABLE)
|
||||
Driver->setFixedPipelineState(COpenGLDriver::EOFPS_DISABLE_TO_ENABLE);
|
||||
@@ -215,7 +215,7 @@ public:
|
||||
}
|
||||
}
|
||||
|
||||
virtual void OnUnsetMaterial() _IRR_OVERRIDE_
|
||||
virtual void OnUnsetMaterial() IRR_OVERRIDE
|
||||
{
|
||||
if (Driver->queryFeature(EVDF_MULTITEXTURE))
|
||||
{
|
||||
@@ -245,7 +245,7 @@ public:
|
||||
COpenGLMaterialRenderer_TRANSPARENT_ADD_COLOR(video::COpenGLDriver* d) : Driver(d) {}
|
||||
|
||||
virtual void OnSetMaterial(const SMaterial& material, const SMaterial& lastMaterial,
|
||||
bool resetAllRenderstates, IMaterialRendererServices* services) _IRR_OVERRIDE_
|
||||
bool resetAllRenderstates, IMaterialRendererServices* services) IRR_OVERRIDE
|
||||
{
|
||||
if (Driver->getFixedPipelineState() == COpenGLDriver::EOFPS_DISABLE)
|
||||
Driver->setFixedPipelineState(COpenGLDriver::EOFPS_DISABLE_TO_ENABLE);
|
||||
@@ -259,13 +259,13 @@ public:
|
||||
Driver->getCacheHandler()->setBlend(true);
|
||||
}
|
||||
|
||||
virtual void OnUnsetMaterial() _IRR_OVERRIDE_
|
||||
virtual void OnUnsetMaterial() IRR_OVERRIDE
|
||||
{
|
||||
Driver->getCacheHandler()->setBlend(false);
|
||||
}
|
||||
|
||||
//! Returns if the material is transparent.
|
||||
virtual bool isTransparent() const _IRR_OVERRIDE_
|
||||
virtual bool isTransparent() const IRR_OVERRIDE
|
||||
{
|
||||
return true;
|
||||
}
|
||||
@@ -284,7 +284,7 @@ public:
|
||||
COpenGLMaterialRenderer_TRANSPARENT_VERTEX_ALPHA(video::COpenGLDriver* d) : Driver(d) {}
|
||||
|
||||
virtual void OnSetMaterial(const SMaterial& material, const SMaterial& lastMaterial,
|
||||
bool resetAllRenderstates, IMaterialRendererServices* services) _IRR_OVERRIDE_
|
||||
bool resetAllRenderstates, IMaterialRendererServices* services) IRR_OVERRIDE
|
||||
{
|
||||
if (Driver->getFixedPipelineState() == COpenGLDriver::EOFPS_DISABLE)
|
||||
Driver->setFixedPipelineState(COpenGLDriver::EOFPS_DISABLE_TO_ENABLE);
|
||||
@@ -319,7 +319,7 @@ public:
|
||||
}
|
||||
}
|
||||
|
||||
virtual void OnUnsetMaterial() _IRR_OVERRIDE_
|
||||
virtual void OnUnsetMaterial() IRR_OVERRIDE
|
||||
{
|
||||
Driver->getCacheHandler()->setActiveTexture(GL_TEXTURE0_ARB);
|
||||
|
||||
@@ -336,7 +336,7 @@ public:
|
||||
}
|
||||
|
||||
//! Returns if the material is transparent.
|
||||
virtual bool isTransparent() const _IRR_OVERRIDE_
|
||||
virtual bool isTransparent() const IRR_OVERRIDE
|
||||
{
|
||||
return true;
|
||||
}
|
||||
@@ -355,7 +355,7 @@ public:
|
||||
COpenGLMaterialRenderer_TRANSPARENT_ALPHA_CHANNEL(video::COpenGLDriver* d) : Driver(d) {}
|
||||
|
||||
virtual void OnSetMaterial(const SMaterial& material, const SMaterial& lastMaterial,
|
||||
bool resetAllRenderstates, IMaterialRendererServices* services) _IRR_OVERRIDE_
|
||||
bool resetAllRenderstates, IMaterialRendererServices* services) IRR_OVERRIDE
|
||||
{
|
||||
if (Driver->getFixedPipelineState() == COpenGLDriver::EOFPS_DISABLE)
|
||||
Driver->setFixedPipelineState(COpenGLDriver::EOFPS_DISABLE_TO_ENABLE);
|
||||
@@ -392,7 +392,7 @@ public:
|
||||
}
|
||||
}
|
||||
|
||||
virtual void OnUnsetMaterial() _IRR_OVERRIDE_
|
||||
virtual void OnUnsetMaterial() IRR_OVERRIDE
|
||||
{
|
||||
Driver->getCacheHandler()->setActiveTexture(GL_TEXTURE0_ARB);
|
||||
|
||||
@@ -407,7 +407,7 @@ public:
|
||||
}
|
||||
|
||||
//! Returns if the material is transparent.
|
||||
virtual bool isTransparent() const _IRR_OVERRIDE_
|
||||
virtual bool isTransparent() const IRR_OVERRIDE
|
||||
{
|
||||
return true;
|
||||
}
|
||||
@@ -426,7 +426,7 @@ public:
|
||||
COpenGLMaterialRenderer_TRANSPARENT_ALPHA_CHANNEL_REF(video::COpenGLDriver* d) : Driver(d) {}
|
||||
|
||||
virtual void OnSetMaterial(const SMaterial& material, const SMaterial& lastMaterial,
|
||||
bool resetAllRenderstates, IMaterialRendererServices* services) _IRR_OVERRIDE_
|
||||
bool resetAllRenderstates, IMaterialRendererServices* services) IRR_OVERRIDE
|
||||
{
|
||||
if (Driver->getFixedPipelineState() == COpenGLDriver::EOFPS_DISABLE)
|
||||
Driver->setFixedPipelineState(COpenGLDriver::EOFPS_DISABLE_TO_ENABLE);
|
||||
@@ -443,13 +443,13 @@ public:
|
||||
}
|
||||
}
|
||||
|
||||
virtual void OnUnsetMaterial() _IRR_OVERRIDE_
|
||||
virtual void OnUnsetMaterial() IRR_OVERRIDE
|
||||
{
|
||||
Driver->getCacheHandler()->setAlphaTest(false);
|
||||
}
|
||||
|
||||
//! Returns if the material is transparent.
|
||||
virtual bool isTransparent() const _IRR_OVERRIDE_
|
||||
virtual bool isTransparent() const IRR_OVERRIDE
|
||||
{
|
||||
return false; // this material is not really transparent because it does no blending.
|
||||
}
|
||||
@@ -468,7 +468,7 @@ public:
|
||||
COpenGLMaterialRenderer_LIGHTMAP(video::COpenGLDriver* d) : Driver(d) {}
|
||||
|
||||
virtual void OnSetMaterial(const SMaterial& material, const SMaterial& lastMaterial,
|
||||
bool resetAllRenderstates, IMaterialRendererServices* services) _IRR_OVERRIDE_
|
||||
bool resetAllRenderstates, IMaterialRendererServices* services) IRR_OVERRIDE
|
||||
{
|
||||
if (Driver->getFixedPipelineState() == COpenGLDriver::EOFPS_DISABLE)
|
||||
Driver->setFixedPipelineState(COpenGLDriver::EOFPS_DISABLE_TO_ENABLE);
|
||||
@@ -562,7 +562,7 @@ public:
|
||||
}
|
||||
}
|
||||
|
||||
virtual void OnUnsetMaterial() _IRR_OVERRIDE_
|
||||
virtual void OnUnsetMaterial() IRR_OVERRIDE
|
||||
{
|
||||
if (Driver->queryFeature(EVDF_MULTITEXTURE))
|
||||
{
|
||||
@@ -595,7 +595,7 @@ public:
|
||||
COpenGLMaterialRenderer_DETAIL_MAP(video::COpenGLDriver* d) : Driver(d) {}
|
||||
|
||||
virtual void OnSetMaterial(const SMaterial& material, const SMaterial& lastMaterial,
|
||||
bool resetAllRenderstates, IMaterialRendererServices* services) _IRR_OVERRIDE_
|
||||
bool resetAllRenderstates, IMaterialRendererServices* services) IRR_OVERRIDE
|
||||
{
|
||||
if (Driver->getFixedPipelineState() == COpenGLDriver::EOFPS_DISABLE)
|
||||
Driver->setFixedPipelineState(COpenGLDriver::EOFPS_DISABLE_TO_ENABLE);
|
||||
@@ -627,7 +627,7 @@ public:
|
||||
}
|
||||
}
|
||||
|
||||
virtual void OnUnsetMaterial() _IRR_OVERRIDE_
|
||||
virtual void OnUnsetMaterial() IRR_OVERRIDE
|
||||
{
|
||||
if (Driver->queryFeature(EVDF_MULTITEXTURE))
|
||||
{
|
||||
@@ -651,7 +651,7 @@ public:
|
||||
COpenGLMaterialRenderer_SPHERE_MAP(video::COpenGLDriver* d) : Driver(d) {}
|
||||
|
||||
virtual void OnSetMaterial(const SMaterial& material, const SMaterial& lastMaterial,
|
||||
bool resetAllRenderstates, IMaterialRendererServices* services) _IRR_OVERRIDE_
|
||||
bool resetAllRenderstates, IMaterialRendererServices* services) IRR_OVERRIDE
|
||||
{
|
||||
if (Driver->getFixedPipelineState() == COpenGLDriver::EOFPS_DISABLE)
|
||||
Driver->setFixedPipelineState(COpenGLDriver::EOFPS_DISABLE_TO_ENABLE);
|
||||
@@ -677,7 +677,7 @@ public:
|
||||
}
|
||||
}
|
||||
|
||||
virtual void OnUnsetMaterial() _IRR_OVERRIDE_
|
||||
virtual void OnUnsetMaterial() IRR_OVERRIDE
|
||||
{
|
||||
Driver->getCacheHandler()->setActiveTexture(GL_TEXTURE0_ARB);
|
||||
|
||||
@@ -699,7 +699,7 @@ public:
|
||||
COpenGLMaterialRenderer_REFLECTION_2_LAYER(video::COpenGLDriver* d) : Driver(d) {}
|
||||
|
||||
virtual void OnSetMaterial(const SMaterial& material, const SMaterial& lastMaterial,
|
||||
bool resetAllRenderstates, IMaterialRendererServices* services) _IRR_OVERRIDE_
|
||||
bool resetAllRenderstates, IMaterialRendererServices* services) IRR_OVERRIDE
|
||||
{
|
||||
if (Driver->getFixedPipelineState() == COpenGLDriver::EOFPS_DISABLE)
|
||||
Driver->setFixedPipelineState(COpenGLDriver::EOFPS_DISABLE_TO_ENABLE);
|
||||
@@ -735,7 +735,7 @@ public:
|
||||
}
|
||||
}
|
||||
|
||||
virtual void OnUnsetMaterial() _IRR_OVERRIDE_
|
||||
virtual void OnUnsetMaterial() IRR_OVERRIDE
|
||||
{
|
||||
if (Driver->queryFeature(EVDF_MULTITEXTURE))
|
||||
{
|
||||
@@ -761,7 +761,7 @@ public:
|
||||
COpenGLMaterialRenderer_TRANSPARENT_REFLECTION_2_LAYER(video::COpenGLDriver* d) : Driver(d) {}
|
||||
|
||||
virtual void OnSetMaterial(const SMaterial& material, const SMaterial& lastMaterial,
|
||||
bool resetAllRenderstates, IMaterialRendererServices* services) _IRR_OVERRIDE_
|
||||
bool resetAllRenderstates, IMaterialRendererServices* services) IRR_OVERRIDE
|
||||
{
|
||||
if (Driver->getFixedPipelineState() == COpenGLDriver::EOFPS_DISABLE)
|
||||
Driver->setFixedPipelineState(COpenGLDriver::EOFPS_DISABLE_TO_ENABLE);
|
||||
@@ -820,7 +820,7 @@ public:
|
||||
}
|
||||
}
|
||||
|
||||
virtual void OnUnsetMaterial() _IRR_OVERRIDE_
|
||||
virtual void OnUnsetMaterial() IRR_OVERRIDE
|
||||
{
|
||||
if (Driver->queryFeature(EVDF_MULTITEXTURE))
|
||||
{
|
||||
@@ -840,7 +840,7 @@ public:
|
||||
}
|
||||
|
||||
//! Returns if the material is transparent.
|
||||
virtual bool isTransparent() const _IRR_OVERRIDE_
|
||||
virtual bool isTransparent() const IRR_OVERRIDE
|
||||
{
|
||||
return true;
|
||||
}
|
||||
|
Reference in New Issue
Block a user