1
0

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:
cutealien
2021-08-27 12:55:10 +00:00
parent ee180dbd24
commit ffd7b63af0
289 changed files with 3401 additions and 3379 deletions

View File

@@ -23,40 +23,40 @@ public:
const core::vector3df& position, video::SColorf color, f32 range);
//! pre render event
virtual void OnRegisterSceneNode() _IRR_OVERRIDE_;
virtual void OnRegisterSceneNode() IRR_OVERRIDE;
//! render
virtual void render() _IRR_OVERRIDE_;
virtual void render() IRR_OVERRIDE;
//! set node light data from light info
virtual void setLightData(const video::SLight& light) _IRR_OVERRIDE_;
virtual void setLightData(const video::SLight& light) IRR_OVERRIDE;
//! \return Returns the light data.
virtual const video::SLight& getLightData() const _IRR_OVERRIDE_;
virtual const video::SLight& getLightData() const IRR_OVERRIDE;
//! \return Returns the light data.
virtual video::SLight& getLightData() _IRR_OVERRIDE_;
virtual video::SLight& getLightData() IRR_OVERRIDE;
//! Sets if the node should be visible or not.
/** All children of this node won't be visible either, when set
to true.
\param isVisible If the node shall be visible. */
virtual void setVisible(bool isVisible) _IRR_OVERRIDE_;
virtual void setVisible(bool isVisible) IRR_OVERRIDE;
//! returns the axis aligned bounding box of this node
virtual const core::aabbox3d<f32>& getBoundingBox() const _IRR_OVERRIDE_;
virtual const core::aabbox3d<f32>& getBoundingBox() const IRR_OVERRIDE;
//! Returns type of the scene node
virtual ESCENE_NODE_TYPE getType() const _IRR_OVERRIDE_ { return ESNT_LIGHT; }
virtual ESCENE_NODE_TYPE getType() const IRR_OVERRIDE { return ESNT_LIGHT; }
//! Writes attributes of the scene node.
virtual void serializeAttributes(io::IAttributes* out, io::SAttributeReadWriteOptions* options=0) const _IRR_OVERRIDE_;
virtual void serializeAttributes(io::IAttributes* out, io::SAttributeReadWriteOptions* options=0) const IRR_OVERRIDE;
//! Reads attributes of the scene node.
virtual void deserializeAttributes(io::IAttributes* in, io::SAttributeReadWriteOptions* options=0) _IRR_OVERRIDE_;
virtual void deserializeAttributes(io::IAttributes* in, io::SAttributeReadWriteOptions* options=0) IRR_OVERRIDE;
//! Creates a clone of this scene node and its children.
virtual ISceneNode* clone(ISceneNode* newParent=0, ISceneManager* newManager=0) _IRR_OVERRIDE_;
virtual ISceneNode* clone(ISceneNode* newParent=0, ISceneManager* newManager=0) IRR_OVERRIDE;
//! Sets the light's radius of influence.
/** Outside this radius the light won't lighten geometry and cast no
@@ -64,33 +64,33 @@ public:
it to (0,1/radius,0). If you want to override this behavior, set the
attenuation after the radius.
\param radius The new radius. */
virtual void setRadius(f32 radius) _IRR_OVERRIDE_;
virtual void setRadius(f32 radius) IRR_OVERRIDE;
//! Gets the light's radius of influence.
/** \return The current radius. */
virtual f32 getRadius() const _IRR_OVERRIDE_;
virtual f32 getRadius() const IRR_OVERRIDE;
//! Sets the light type.
/** \param type The new type. */
virtual void setLightType(video::E_LIGHT_TYPE type) _IRR_OVERRIDE_;
virtual void setLightType(video::E_LIGHT_TYPE type) IRR_OVERRIDE;
//! Gets the light type.
/** \return The current light type. */
virtual video::E_LIGHT_TYPE getLightType() const _IRR_OVERRIDE_;
virtual video::E_LIGHT_TYPE getLightType() const IRR_OVERRIDE;
//! Sets whether this light casts shadows.
/** Enabling this flag won't automatically cast shadows, the meshes
will still need shadow scene nodes attached. But one can enable or
disable distinct lights for shadow casting for performance reasons.
\param shadow True if this light shall cast shadows. */
virtual void enableCastShadow(bool shadow=true) _IRR_OVERRIDE_;
virtual void enableCastShadow(bool shadow=true) IRR_OVERRIDE;
//! Check whether this light casts shadows.
/** \return True if light would cast shadows, else false. */
virtual bool getCastShadow() const _IRR_OVERRIDE_;
virtual bool getCastShadow() const IRR_OVERRIDE;
//! Updates the absolute position based on the relative and the parents position
virtual void updateAbsolutePosition() _IRR_OVERRIDE_;
virtual void updateAbsolutePosition() IRR_OVERRIDE;
private: