Remove the NS_AX_BEGIN and NS_AX_END macros. (#2100)

This commit is contained in:
j-jorge 2024-08-25 18:25:33 +02:00 committed by GitHub
parent f14276c33e
commit 15268dc182
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
943 changed files with 2836 additions and 1899 deletions

View File

@ -33,7 +33,8 @@ THE SOFTWARE.
#include "base/Director.h"
#include "base/UTF8.h"
NS_AX_BEGIN
namespace ax
{
//
// Action Base Class
//
@ -298,4 +299,4 @@ void Follow::stop()
Action::stop();
}
NS_AX_END
}

View File

@ -33,7 +33,8 @@ THE SOFTWARE.
#include "math/Math.h"
#include "base/ScriptSupport.h"
NS_AX_BEGIN
namespace ax
{
class Node;
@ -445,6 +446,6 @@ private:
// end of actions group
/// @}
NS_AX_END
}
#endif // __ACTIONS_CCACTION_H__

View File

@ -30,7 +30,8 @@ THE SOFTWARE.
#include "2d/Node.h"
#include "platform/StdC.h"
NS_AX_BEGIN
namespace ax
{
//
// CameraAction
//
@ -242,4 +243,4 @@ void OrbitCamera::sphericalRadius(float* newRadius, float* zenith, float* azimut
*newRadius = r / FLT_EPSILON;
}
NS_AX_END
}

View File

@ -32,7 +32,8 @@ THE SOFTWARE.
#include "2d/ActionInterval.h"
#include "math/Math.h"
NS_AX_BEGIN
namespace ax
{
class Camera;
@ -183,6 +184,6 @@ protected:
// end of actions group
/// @}
NS_AX_END
}
#endif //__CCCAMERA_ACTION_H__

View File

@ -40,7 +40,8 @@
using namespace std;
NS_AX_BEGIN;
namespace ax
{
/*
* Implementation of PointArray
@ -508,4 +509,4 @@ CatmullRomBy* CatmullRomBy::reverse() const
return CatmullRomBy::create(_duration, reverse);
}
NS_AX_END;
}

View File

@ -42,7 +42,8 @@
#include "2d/ActionInterval.h"
#include "math/Math.h"
NS_AX_BEGIN;
namespace ax
{
class Node;
@ -341,6 +342,6 @@ ccCardinalSplineAt(const Vec2& p0, const Vec2& p1, const Vec2& p2, const Vec2& p
// end of actions group
/// @}
NS_AX_END;
}
#endif // __CCACTION_CATMULLROM_H__

View File

@ -29,7 +29,8 @@ THE SOFTWARE.
#include "ActionCoroutine.h"
NS_AX_BEGIN
namespace ax
{
//
// Coroutine
@ -118,4 +119,4 @@ void ActionCoroutine::step(float dt)
_coroutine.moveNext();
}
NS_AX_END
}

View File

@ -54,7 +54,8 @@ using coroutine_handle = std::experimental::coroutine_handle<_Ty>;
# error This compiler missing c++20 coroutine
#endif
NS_AX_BEGIN
namespace ax
{
/**
* @addtogroup actions
@ -153,6 +154,6 @@ private:
AX_DISALLOW_COPY_AND_ASSIGN(ActionCoroutine);
};
NS_AX_END
}
#endif // __ACTION_CCCOROUTINE_ACTION_H__

View File

@ -36,7 +36,8 @@ THE SOFTWARE.
#include "2d/ActionEase.h"
#include "2d/TweenFunction.h"
NS_AX_BEGIN
namespace ax
{
#ifndef M_PI_X_2
# define M_PI_X_2 (float)M_PI * 2.0f
@ -305,4 +306,4 @@ EaseBezierAction* EaseBezierAction::reverse() const
return reverseAction;
}
NS_AX_END
}

View File

@ -32,7 +32,8 @@ THE SOFTWARE.
#include "2d/ActionInterval.h"
#include "2d/TweenFunction.h"
NS_AX_BEGIN
namespace ax
{
/**
* @addtogroup actions
@ -552,6 +553,6 @@ private:
// end of actions group
/// @}
NS_AX_END
}
#endif // __ACTION_CCEASE_ACTION_H__

View File

@ -31,7 +31,8 @@ THE SOFTWARE.
#include "2d/NodeGrid.h"
#include "base/Director.h"
NS_AX_BEGIN
namespace ax
{
// implementation of GridAction
bool GridAction::initWithDuration(float duration, const Vec2& gridSize)
@ -446,4 +447,4 @@ ReuseGrid* ReuseGrid::reverse() const
return this->clone();
}
NS_AX_END
}

View File

@ -30,7 +30,8 @@ THE SOFTWARE.
#include "2d/ActionInterval.h"
#include "2d/ActionInstant.h"
NS_AX_BEGIN
namespace ax
{
class GridBase;
class NodeGrid;
@ -408,6 +409,6 @@ private:
// end of actions group
/// @}
NS_AX_END
}
#endif // __ACTION_CCGRID_ACTION_H__

View File

@ -28,7 +28,8 @@ THE SOFTWARE.
#include "2d/ActionGrid3D.h"
#include "base/Director.h"
NS_AX_BEGIN
namespace ax
{
// implementation of Waves3D
Waves3D* Waves3D::create(float duration, const Vec2& gridSize, unsigned int waves, float amplitude)
@ -736,4 +737,4 @@ void Twirl::update(float time)
}
}
NS_AX_END
}

View File

@ -30,7 +30,8 @@ THE SOFTWARE.
#include "2d/ActionGrid.h"
NS_AX_BEGIN
namespace ax
{
/**
* @addtogroup actions
@ -635,6 +636,6 @@ private:
// end of actions group
/// @}
NS_AX_END
}
#endif // __ACTION_CCGRID3D_ACTION_H__

View File

@ -30,7 +30,8 @@
#include "2d/Node.h"
#include "2d/Sprite.h"
NS_AX_BEGIN
namespace ax
{
//
// InstantAction
//
@ -399,4 +400,4 @@ CallFuncN* CallFuncN::clone() const
return a;
}
NS_AX_END
}

View File

@ -32,7 +32,8 @@ THE SOFTWARE.
#include <functional>
#include "2d/Action.h"
NS_AX_BEGIN
namespace ax
{
/**
* @addtogroup actions
@ -395,6 +396,6 @@ private:
// end of actions group
/// @}
NS_AX_END
}
#endif //__CCINSTANT_ACTION_H__

View File

@ -41,7 +41,8 @@ THE SOFTWARE.
#include "platform/StdC.h"
#include "base/ScriptSupport.h"
NS_AX_BEGIN
namespace ax
{
// Extra action for making a Sequence or Spawn when only adding one action to it.
class ExtraAction : public FiniteTimeAction
@ -2765,4 +2766,4 @@ ActionFloat* ActionFloat::reverse() const
return ActionFloat::create(_duration, _to, _from, _callback);
}
NS_AX_END
}

View File

@ -37,7 +37,8 @@ THE SOFTWARE.
#include "base/Protocols.h"
#include "base/Vector.h"
NS_AX_BEGIN
namespace ax
{
class Node;
class SpriteFrame;
@ -1617,6 +1618,6 @@ private:
// end of actions group
/// @}
NS_AX_END
}
#endif //__ACTION_CCINTERVAL_ACTION_H__

View File

@ -34,7 +34,8 @@ THE SOFTWARE.
#include "base/Scheduler.h"
#include "base/Macros.h"
NS_AX_BEGIN
namespace ax
{
//
// singleton stuff
//
@ -453,4 +454,4 @@ void ActionManager::update(float dt)
_currentTarget = nullptr;
}
NS_AX_END
}

View File

@ -35,7 +35,8 @@ THE SOFTWARE.
#include "base/Vector.h"
#include "base/Object.h"
NS_AX_BEGIN
namespace ax
{
struct ActionHandle
{
@ -220,6 +221,6 @@ protected:
// end of actions group
/// @}
NS_AX_END
}
#endif // __ACTION_CCACTION_MANAGER_H__

View File

@ -28,7 +28,8 @@ THE SOFTWARE.
#include "2d/Grid.h"
#include "2d/NodeGrid.h"
NS_AX_BEGIN
namespace ax
{
PageTurn3D* PageTurn3D::create(float duration, const Vec2& gridSize)
{
@ -130,4 +131,4 @@ void PageTurn3D::update(float time)
}
}
NS_AX_END
}

View File

@ -29,7 +29,8 @@ THE SOFTWARE.
#include "2d/ActionGrid3D.h"
NS_AX_BEGIN
namespace ax
{
/**
* @addtogroup actions
@ -69,6 +70,6 @@ public:
// end of actions group
/// @}
NS_AX_END
}
#endif // __ACTION_CCPAGETURN3D_ACTION_H__

View File

@ -27,7 +27,8 @@ THE SOFTWARE.
#include "2d/ActionProgressTimer.h"
#include "2d/ProgressTimer.h"
NS_AX_BEGIN
namespace ax
{
#define kProgressTimerCast ProgressTimer*
@ -130,4 +131,4 @@ void ProgressFromTo::update(float time)
((kProgressTimerCast)(_target))->setPercentage(_from + (_to - _from) * time);
}
NS_AX_END
}

View File

@ -29,7 +29,8 @@ THE SOFTWARE.
#include "2d/ActionInterval.h"
NS_AX_BEGIN
namespace ax
{
/**
* @addtogroup actions
@ -127,6 +128,6 @@ private:
// end of actions group
/// @}
NS_AX_END
}
#endif // __ACTION_CCPROGRESS_TIMER_H__

View File

@ -30,7 +30,8 @@ THE SOFTWARE.
#include "base/Director.h"
#include "base/Macros.h"
NS_AX_BEGIN
namespace ax
{
struct Tile
{
@ -876,4 +877,4 @@ void SplitCols::update(float time)
}
}
NS_AX_END
}

View File

@ -29,7 +29,8 @@ THE SOFTWARE.
#include "2d/ActionGrid.h"
NS_AX_BEGIN
namespace ax
{
/**
* @addtogroup actions
@ -592,6 +593,6 @@ private:
// end of actions group
/// @}
NS_AX_END
}
#endif // __ACTION_CCTILEDGRID_ACTION_H__

View File

@ -27,7 +27,8 @@ THE SOFTWARE.
#include "2d/ActionTween.h"
NS_AX_BEGIN
namespace ax
{
ActionTween* ActionTween::create(float duration, std::string_view key, float from, float to)
{
@ -77,4 +78,4 @@ ActionTween* ActionTween::reverse() const
return ActionTween::create(_duration, _key, _to, _from);
}
NS_AX_END
}

View File

@ -29,7 +29,8 @@ THE SOFTWARE.
#include "2d/ActionInterval.h"
NS_AX_BEGIN
namespace ax
{
/**
* @addtogroup actions
@ -120,6 +121,6 @@ protected:
// end of actions group
/// @}
NS_AX_END
}
#endif /* __CCACTIONTWEEN_H__ */

View File

@ -29,7 +29,8 @@ THE SOFTWARE.
#include "2d/AnchoredSprite.h"
#include "renderer/backend/DriverBase.h"
NS_AX_BEGIN
namespace ax
{
// FIXME: HACK: optimization
#define SET_DIRTY_RECURSIVELY() \
@ -206,4 +207,4 @@ Rect AnchoredSprite::getTouchRect()
return Rect(-a.x, -a.y, s.width, s.height);
}
NS_AX_END
}

View File

@ -31,7 +31,8 @@ THE SOFTWARE.
#include <string>
#include "2d/Sprite.h"
NS_AX_BEGIN
namespace ax
{
/**
* @addtogroup _2d
@ -149,4 +150,4 @@ protected:
// end of sprite_nodes group
/// @}
NS_AX_END
}

View File

@ -31,7 +31,8 @@ THE SOFTWARE.
#include "renderer/Texture2D.h"
#include "base/Director.h"
NS_AX_BEGIN
namespace ax
{
AnimationFrame* AnimationFrame::create(SpriteFrame* spriteFrame, float delayUnits, const ValueMap& userInfo)
{
@ -196,4 +197,4 @@ Animation* Animation::clone() const
return a;
}
NS_AX_END
}

View File

@ -37,7 +37,8 @@ THE SOFTWARE.
#include <string>
NS_AX_BEGIN
namespace ax
{
class Texture2D;
class SpriteFrame;
@ -321,6 +322,6 @@ private:
// end of sprite_nodes group
/// @}
NS_AX_END
}
#endif // __AX_ANIMATION_H__

View File

@ -32,7 +32,8 @@ THE SOFTWARE.
using namespace std;
NS_AX_BEGIN
namespace ax
{
AnimationCache* AnimationCache::s_sharedAnimationCache = nullptr;
@ -266,4 +267,4 @@ void AnimationCache::addAnimationsWithFile(std::string_view plist)
addAnimationsWithDictionary(dict, plist);
}
NS_AX_END
}

View File

@ -36,7 +36,8 @@ THE SOFTWARE.
#include <string>
NS_AX_BEGIN
namespace ax
{
class Animation;
@ -128,6 +129,6 @@ private:
// end of sprite_nodes group
/// @}
NS_AX_END
}
#endif // __AX_ANIMATION_CACHE_H__

View File

@ -36,7 +36,8 @@ THE SOFTWARE.
#include "renderer/Renderer.h"
#include "renderer/backend/ProgramState.h"
NS_AX_BEGIN
namespace ax
{
// implementation AtlasNode
@ -272,4 +273,4 @@ void AtlasNode::setQuadsToDraw(ssize_t quadsToDraw)
_quadsToDraw = quadsToDraw;
}
NS_AX_END
}

View File

@ -32,7 +32,8 @@ THE SOFTWARE.
#include "base/Types.h"
#include "renderer/QuadCommand.h"
NS_AX_BEGIN
namespace ax
{
/**
* @addtogroup _2d
@ -153,4 +154,4 @@ private:
// end of base_node group
/// @}
NS_AX_END
}

View File

@ -47,7 +47,8 @@ static unsigned short quadIndices9[] = {
const static float PRECISION = 10.0f;
NS_AX_BEGIN
namespace ax
{
PolygonInfo::PolygonInfo() : _isVertsOwner(true), _rect(Rect::ZERO), _filename("")
{
@ -728,4 +729,4 @@ PolygonInfo AutoPolygon::generatePolygon(std::string_view filename, const Rect&
return ap.generateTriangles(rect, epsilon, threshold);
}
NS_AX_END
}

View File

@ -36,7 +36,8 @@ THE SOFTWARE.
#include "platform/Image.h"
#include "renderer/TrianglesCommand.h"
NS_AX_BEGIN
namespace ax
{
/**
* @addtogroup _2d
@ -290,6 +291,6 @@ protected:
unsigned int _threshold;
};
NS_AX_END
}
#endif // #ifndef COCOS_2D_CCAUTOPOLYGON_H__

View File

@ -33,7 +33,8 @@
#include "renderer/Renderer.h"
#include "renderer/QuadCommand.h"
NS_AX_BEGIN
namespace ax
{
Camera* Camera::_visitingCamera = nullptr;
Viewport Camera::_defaultViewport;
@ -555,4 +556,4 @@ bool Camera::isBrushValid()
return _clearBrush != nullptr && _clearBrush->isValid();
}
NS_AX_END
}

View File

@ -36,7 +36,8 @@ THE SOFTWARE.
#include "renderer/CustomCommand.h"
#include "base/Director.h"
NS_AX_BEGIN
namespace ax
{
class Scene;
class CameraBackgroundBrush;
@ -377,4 +378,4 @@ protected:
CameraBackgroundBrush* _clearBrush = nullptr; // brush used to clear the back ground
};
NS_AX_END
}

View File

@ -43,7 +43,8 @@
# include "base/EventDispatcher.h"
#endif
NS_AX_BEGIN
namespace ax
{
CameraBackgroundBrush::CameraBackgroundBrush() {}
@ -460,4 +461,4 @@ void CameraBackgroundSkyBoxBrush::onAfterDraw()
renderer->setCullMode(_stateBlock.cullMode);
}
NS_AX_END
}

View File

@ -35,7 +35,8 @@
#include "renderer/backend/Types.h"
#include <vector>
NS_AX_BEGIN
namespace ax
{
class CameraBackgroundColorBrush;
class CameraBackgroundDepthBrush;
@ -320,4 +321,4 @@ private:
} _stateBlock;
};
NS_AX_END
}

View File

@ -33,7 +33,8 @@
#include "base/Director.h"
#include "base/StencilStateManager.h"
NS_AX_BEGIN
namespace ax
{
ClippingNode::ClippingNode() : _stencilStateManager(new StencilStateManager()) {}
@ -383,4 +384,4 @@ void ClippingNode::restoreAllProgramStates()
}
}
NS_AX_END
}

View File

@ -33,7 +33,8 @@
#include "renderer/CustomCommand.h"
#include "renderer/CallbackCommand.h"
#include <unordered_map>
NS_AX_BEGIN
namespace ax
{
class StencilStateManager;
/**
@ -174,4 +175,4 @@ private:
AX_DISALLOW_COPY_AND_ASSIGN(ClippingNode);
};
/** @} */
NS_AX_END
}

View File

@ -27,7 +27,8 @@
#include "math/Vec2.h"
#include "platform/GLView.h"
NS_AX_BEGIN
namespace ax
{
ClippingRectangleNode* ClippingRectangleNode::create(const Rect& clippingRegion)
{
@ -105,4 +106,4 @@ void ClippingRectangleNode::visit(Renderer* renderer, const Mat4& parentTransfor
renderer->addCommand(afterVisitCmdScissor);
}
NS_AX_END
}

View File

@ -30,7 +30,8 @@
#include "2d/Node.h"
#include "renderer/CallbackCommand.h"
NS_AX_BEGIN
namespace ax
{
/**
* @addtogroup _2d
@ -102,4 +103,4 @@ protected:
// end of _2d group
/// @}
NS_AX_END
}

View File

@ -25,7 +25,8 @@ THE SOFTWARE.
#include "2d/Component.h"
NS_AX_BEGIN
namespace ax
{
Component::Component() : _owner(nullptr), _enabled(true) {}
@ -77,4 +78,4 @@ void Component::setEnabled(bool enabled)
_enabled = enabled;
}
NS_AX_END
}

View File

@ -31,7 +31,8 @@ THE SOFTWARE.
#include "base/Object.h"
#include "base/ScriptSupport.h"
NS_AX_BEGIN
namespace ax
{
class Node;
@ -85,7 +86,7 @@ protected:
bool _enabled;
};
NS_AX_END
}
/// @endcond
#endif // __AX_FRAMEWORK_COMPONENT_H__

View File

@ -27,7 +27,8 @@ THE SOFTWARE.
#include "2d/Component.h"
#include "2d/Node.h"
NS_AX_BEGIN
namespace ax
{
ComponentContainer::ComponentContainer(Node* node) : _owner(node) {}
@ -141,4 +142,4 @@ void ComponentContainer::onExit()
}
}
NS_AX_END
}

View File

@ -31,7 +31,8 @@ THE SOFTWARE.
#include "base/Map.h"
#include <string>
NS_AX_BEGIN
namespace ax
{
class Component;
class Node;
@ -74,7 +75,7 @@ private:
friend class Node;
};
NS_AX_END
}
/// @endcond
#endif // __AX_FRAMEWORK_COMCONTAINER_H__

View File

@ -38,7 +38,8 @@
#include "renderer/backend/ProgramState.h"
#include "poly2tri/poly2tri.h"
NS_AX_BEGIN
namespace ax
{
static inline Tex2F v2ToTex2F(const Vec2& v)
{
@ -949,4 +950,4 @@ void DrawNode::visit(Renderer* renderer, const Mat4& parentTransform, uint32_t p
}
}
NS_AX_END
}

View File

@ -39,7 +39,8 @@
#include "math/Math.h"
#include "base/any_buffer.h"
NS_AX_BEGIN
namespace ax
{
static const int DEFAULT_LINE_WIDTH = 2;
@ -463,6 +464,6 @@ private:
AX_DISALLOW_COPY_AND_ASSIGN(DrawNode);
};
/** @} */
NS_AX_END
}
#endif // __CCDRAWNODES_CCDRAW_NODE_H__

View File

@ -51,7 +51,8 @@ THE SOFTWARE.
#include "base/UTF8.h"
#include "renderer/backend/ProgramState.h"
NS_AX_BEGIN
namespace ax
{
const int FastTMXLayer::FAST_TMX_ORIENTATION_ORTHO = 0;
const int FastTMXLayer::FAST_TMX_ORIENTATION_HEX = 1;
@ -1051,4 +1052,4 @@ TMXTileAnimTask* TMXTileAnimTask::create(FastTMXLayer* layer, TMXTileAnimInfo* a
return ret;
}
NS_AX_END
}

View File

@ -33,7 +33,8 @@ THE SOFTWARE.
#include "2d/TMXXMLParser.h"
#include "renderer/CustomCommand.h"
NS_AX_BEGIN
namespace ax
{
class TMXMapInfo;
class TMXLayerInfo;
@ -455,4 +456,4 @@ typedef FastTMXLayer TMXLayer;
// end of tilemap_parallax_nodes group
/// @}
NS_AX_END
}

View File

@ -30,7 +30,8 @@ THE SOFTWARE.
#include "2d/FastTMXLayer.h"
#include "base/UTF8.h"
NS_AX_BEGIN
namespace ax
{
// implementation FastTMXTiledMap
@ -311,4 +312,4 @@ Vector<FastTMXLayer*> FastTMXTiledMap::getLayers() const
return layers;
}
NS_AX_END
}

View File

@ -31,7 +31,8 @@ THE SOFTWARE.
#include "2d/Node.h"
#include "2d/TMXObjectGroup.h"
NS_AX_BEGIN
namespace ax
{
class TMXLayerInfo;
class TMXTilesetInfo;
@ -267,4 +268,4 @@ private:
// @API compatible
typedef FastTMXTiledMap TMXTiledMap;
NS_AX_END
}

View File

@ -33,7 +33,8 @@
#include "base/Types.h"
#include "base/UTF8.h"
NS_AX_BEGIN
namespace ax
{
class FontAtlas;
@ -45,7 +46,7 @@ public:
virtual int getFontMaxHeight() const { return 0; }
};
NS_AX_END
}
/// @endcond

View File

@ -45,7 +45,8 @@
#include "base/PaddedString.h"
NS_AX_BEGIN
namespace ax
{
const int FontAtlas::CacheTextureWidth = 512;
const int FontAtlas::CacheTextureHeight = 512;
@ -553,4 +554,4 @@ void FontAtlas::setAntiAliasTexParameters()
}
}
NS_AX_END
}

View File

@ -41,7 +41,8 @@
#include "base/Map.h"
#include "2d/FontFreeType.h"
NS_AX_BEGIN
namespace ax
{
class Font;
class EventCustom;
@ -181,7 +182,7 @@ protected:
friend class Label;
};
NS_AX_END
}
/// @endcond
#endif /* defined(_AX_FONTATLAS_H_) */

View File

@ -35,7 +35,8 @@
#include "platform/FileUtils.h"
#include "base/format.h"
NS_AX_BEGIN
namespace ax
{
hlookup::string_map<FontAtlas*> FontAtlasCache::_atlasMap;
@ -279,4 +280,4 @@ void FontAtlasCache::unloadFontAtlasTTF(std::string_view fontFileName)
}
}
NS_AX_END
}

View File

@ -32,7 +32,8 @@
#include <unordered_map>
#include "base/Types.h"
NS_AX_BEGIN
namespace ax
{
class FontAtlas;
class Texture2D;
@ -86,7 +87,7 @@ private:
static hlookup::string_map<FontAtlas*> _atlasMap;
};
NS_AX_END
}
/// @endcond
#endif

View File

@ -31,7 +31,8 @@
#include "base/Director.h"
#include "renderer/TextureCache.h"
NS_AX_BEGIN
namespace ax
{
FontCharMap* FontCharMap::create(std::string_view plistFile)
{
@ -142,4 +143,4 @@ FontAtlas* FontCharMap::newFontAtlas()
return tempAtlas;
}
NS_AX_END
}

View File

@ -32,7 +32,8 @@
#include "2d/Font.h"
NS_AX_BEGIN
namespace ax
{
class Texture2D;
class FontCharMap : public Font
@ -64,6 +65,6 @@ private:
/// @endcond
NS_AX_END
}
#endif /* defined(_CCFontCharMap_h_) */

View File

@ -37,7 +37,8 @@
#include <cmath>
NS_AX_BEGIN
namespace ax
{
/**
* @addtogroup GUI
@ -783,4 +784,4 @@ void FontFNT::reloadBMFontResource(std::string_view fntFilePath)
}
}
NS_AX_END
}

View File

@ -34,7 +34,8 @@
#include <set>
#include <unordered_map>
NS_AX_BEGIN
namespace ax
{
/**
@struct BMFontDef
@ -188,6 +189,6 @@ protected:
/// @endcond
NS_AX_END
}
#endif /* defined(_AX_FONTFNT_H_) */

View File

@ -41,7 +41,8 @@ THE SOFTWARE.
#include FT_BBOX_H
#include FT_FONT_FORMATS_H
NS_AX_BEGIN
namespace ax
{
FT_Library FontFreeType::_FTlibrary;
bool FontFreeType::_FTInitialized = false;
@ -709,4 +710,4 @@ void FontFreeType::releaseFont(std::string_view fontName)
}
}
NS_AX_END
}

View File

@ -30,7 +30,8 @@
#include "2d/IFontEngine.h"
#include <string>
NS_AX_BEGIN
namespace ax
{
/**
* @addtogroup _2d
@ -184,4 +185,4 @@ private:
// end of _2d group
/// @}
NS_AX_END
}

View File

@ -38,7 +38,8 @@ THE SOFTWARE.
#include "renderer/backend/RenderTarget.h"
#include "2d/Camera.h"
NS_AX_BEGIN
namespace ax
{
// implementation of GridBase
bool GridBase::initWithSize(const Vec2& gridSize)
@ -796,4 +797,4 @@ void TiledGrid3D::updateVertexAndTexCoordinate()
_drawCommand.updateIndexBuffer(_indices, gradSize * 6 * sizeof(unsigned short));
}
NS_AX_END
}

View File

@ -34,7 +34,8 @@ THE SOFTWARE.
#include "renderer/CustomCommand.h"
#include "renderer/CallbackCommand.h"
NS_AX_BEGIN
namespace ax
{
class Texture2D;
// class Grabber;
@ -309,4 +310,4 @@ protected:
// end of effects group
/// @}
NS_AX_END
}

View File

@ -34,7 +34,8 @@ typedef struct FT_FaceRec_* FT_Face;
typedef struct FT_StrokerRec_* FT_Stroker;
typedef struct FT_BBox_ FT_BBox;
NS_AX_BEGIN
namespace ax
{
/**
* @addtogroup _2d
@ -57,4 +58,4 @@ public:
virtual FontFaceInfo* lookupFontFaceForCodepoint(char32_t charCode) = 0;
};
NS_AX_END
}

View File

@ -51,7 +51,8 @@
#include "renderer/backend/ProgramState.h"
#include "renderer/backend/ProgramStateRegistry.h"
NS_AX_BEGIN
namespace ax
{
namespace
{
@ -3071,4 +3072,4 @@ void Label::recordPlaceholderInfo(int letterIndex, char32_t utf32Char)
_lettersInfo[letterIndex].valid = false;
}
NS_AX_END
}

View File

@ -35,7 +35,8 @@
#include "2d/FontFreeType.h"
#include "base/Types.h"
NS_AX_BEGIN
namespace ax
{
/**
* @addtogroup _2d
@ -943,6 +944,6 @@ private:
// end group
/// @}
NS_AX_END
}
#endif /*_AX_LABEL_H */

View File

@ -36,7 +36,8 @@ THE SOFTWARE.
# include "renderer/Renderer.h"
#endif
NS_AX_BEGIN
namespace ax
{
// CCLabelAtlas - Creation & Init
@ -286,4 +287,4 @@ std::string LabelAtlas::getDescription() const
return fmt::format("<LabelAtlas | Tag = {}, Label = '{}'>", _tag, _string);
}
NS_AX_END
}

View File

@ -33,7 +33,8 @@ THE SOFTWARE.
# include "renderer/CustomCommand.h"
# include "2d/DrawNode.h"
#endif
NS_AX_BEGIN
namespace ax
{
/**
* @addtogroup _2d
@ -137,6 +138,6 @@ protected:
// end group
/// @}
NS_AX_END
}
#endif //__CCLABEL_ATLAS_H__

View File

@ -46,7 +46,8 @@ THE SOFTWARE.
#include "renderer/Shaders.h"
#include "renderer/backend/ProgramState.h"
NS_AX_BEGIN
namespace ax
{
Layer* Layer::create()
{
@ -753,4 +754,4 @@ std::string LayerMultiplex::getDescription() const
return fmt::format("<LayerMultiplex | Tag = {}, Layers = {}", _tag, static_cast<int>(_children.size()));
}
NS_AX_END
}

View File

@ -33,7 +33,8 @@ THE SOFTWARE.
#include <vector>
NS_AX_BEGIN
namespace ax
{
/**
* @addtogroup _2d
@ -445,4 +446,4 @@ private:
// end of _2d group
/// @}
NS_AX_END
}

View File

@ -25,7 +25,8 @@
#include "2d/Light.h"
#include "2d/Scene.h"
NS_AX_BEGIN
namespace ax
{
void BaseLight::setIntensity(float intensity)
{
@ -176,4 +177,4 @@ AmbientLight::AmbientLight() {}
AmbientLight::~AmbientLight() {}
NS_AX_END
}

View File

@ -28,7 +28,8 @@
#include "2d/Node.h"
NS_AX_BEGIN
namespace ax
{
enum class LightType
{
@ -288,6 +289,6 @@ public:
virtual ~AmbientLight();
};
NS_AX_END
}
#endif

View File

@ -38,7 +38,8 @@ THE SOFTWARE.
using namespace std;
NS_AX_BEGIN
namespace ax
{
enum
{
@ -558,4 +559,4 @@ std::string Menu::getDescription() const
return fmt::format("<Menu | Tag = {}>", _tag);
}
NS_AX_END
}

View File

@ -32,7 +32,8 @@ THE SOFTWARE.
#include "2d/Layer.h"
#include "base/Value.h"
NS_AX_BEGIN
namespace ax
{
class Touch;
/**
@ -186,6 +187,6 @@ private:
// end of _2d group
/// @}
NS_AX_END
}
#endif //__CCMENU_H_

View File

@ -35,7 +35,8 @@ THE SOFTWARE.
#include "base/UTF8.h"
#include <stdarg.h>
NS_AX_BEGIN
namespace ax
{
static int _globalFontSize = kItemSize;
static std::string _globalFontName = "Marker Felt";
@ -868,4 +869,4 @@ MenuItem* MenuItemToggle::getSelectedItem()
return _subItems.at(_selectedIndex);
}
NS_AX_END
}

View File

@ -37,7 +37,8 @@ THE SOFTWARE.
#include "2d/Node.h"
#include "base/Protocols.h"
NS_AX_BEGIN
namespace ax
{
typedef std::function<void(Object*)> ccMenuCallback;
@ -508,6 +509,6 @@ private:
// end of 2d group
/// @}
NS_AX_END
}
#endif //__CCMENU_ITEM_H__

View File

@ -34,7 +34,8 @@ THE SOFTWARE.
#include "renderer/Shaders.h"
#include "renderer/backend/ProgramState.h"
NS_AX_BEGIN
namespace ax
{
MotionStreak::MotionStreak()
{
@ -437,4 +438,4 @@ void MotionStreak::draw(Renderer* renderer, const Mat4& transform, uint32_t flag
}
}
NS_AX_END
}

View File

@ -30,7 +30,8 @@ THE SOFTWARE.
#include "2d/Node.h"
#include "renderer/CustomCommand.h"
NS_AX_BEGIN
namespace ax
{
class Texture2D;
@ -206,4 +207,4 @@ private:
// end of _2d group
/// @}
NS_AX_END
}

View File

@ -59,7 +59,8 @@ THE SOFTWARE.
*/
#define AX_HASH_NODE_NAME(name) (!name.empty() ? XXH3_64bits(name.data(), name.length()) : 0)
NS_AX_BEGIN
namespace ax
{
// FIXME:: Yes, nodes might have a sort problem once every 30 days if the game runs at 60 FPS and each frame sprites are
// reordered.
@ -2281,4 +2282,4 @@ backend::ProgramState* Node::getProgramState() const
return _programState;
}
NS_AX_END
}

View File

@ -45,7 +45,8 @@
# include "physics/PhysicsBody.h"
#endif
NS_AX_BEGIN
namespace ax
{
class GridBase;
class Touch;
@ -2069,6 +2070,6 @@ bool AX_DLL isScreenPointInRect(const Vec2& pt, const Camera* camera, const Mat4
// end of _2d group
/// @}
NS_AX_END
}
#endif // __CCNODE_H__

View File

@ -26,7 +26,8 @@
#include "2d/Grid.h"
#include "renderer/Renderer.h"
NS_AX_BEGIN
namespace ax
{
NodeGrid* NodeGrid::create()
{
@ -178,4 +179,4 @@ void NodeGrid::setGrid(GridBase* grid)
_nodeGrid = grid;
}
NS_AX_END
}

View File

@ -28,7 +28,8 @@
#include "renderer/GroupCommand.h"
#include "renderer/CustomCommand.h"
NS_AX_BEGIN
namespace ax
{
class GridBase;
/**
@ -106,4 +107,4 @@ private:
AX_DISALLOW_COPY_AND_ASSIGN(NodeGrid);
};
/** @} */
NS_AX_END
}

View File

@ -27,7 +27,8 @@ THE SOFTWARE.
****************************************************************************/
#include "2d/ParallaxNode.h"
NS_AX_BEGIN
namespace ax
{
class PointObject : public Object
{
@ -161,4 +162,4 @@ void ParallaxNode::visit(Renderer* renderer, const Mat4& parentTransform, uint32
Node::visit(renderer, parentTransform, parentFlags);
}
NS_AX_END
}

View File

@ -31,7 +31,8 @@ THE SOFTWARE.
#include "2d/Node.h"
#include "base/Vector.h"
NS_AX_BEGIN
namespace ax
{
/**
* @addtogroup _2d
@ -111,6 +112,6 @@ private:
// end of _2d group
/// @}
NS_AX_END
}
#endif //__CCPARALLAX_NODE_H__

View File

@ -44,7 +44,8 @@
#include "renderer/Shaders.h"
#include "renderer/backend/ProgramState.h"
NS_AX_BEGIN
namespace ax
{
ParticleBatchNode::ParticleBatchNode()
{
@ -561,4 +562,4 @@ const BlendFunc& ParticleBatchNode::getBlendFunc() const
return _blendFunc;
}
NS_AX_END
}

View File

@ -35,7 +35,8 @@
#include "base/Protocols.h"
#include "renderer/CustomCommand.h"
NS_AX_BEGIN
namespace ax
{
class Texture2D;
class TextureAtlas;
@ -191,4 +192,4 @@ private:
// end of _2d group
/// @}
NS_AX_END
}

View File

@ -31,7 +31,8 @@ THE SOFTWARE.
#include "base/firePngData.h"
#include "renderer/TextureCache.h"
NS_AX_BEGIN
namespace ax
{
//
// ParticleFire
//
@ -1229,4 +1230,4 @@ bool ParticleRain::initWithTotalParticles(int numberOfParticles)
return false;
}
NS_AX_END
}

View File

@ -30,7 +30,8 @@ THE SOFTWARE.
#include "2d/ParticleSystemQuad.h"
NS_AX_BEGIN
namespace ax
{
/**
* @addtogroup _2d
@ -436,6 +437,6 @@ private:
// end of _2d group
/// @}
NS_AX_END
}
#endif //__CCPARTICLE_EXAMPLE_H__

View File

@ -60,7 +60,8 @@ THE SOFTWARE.
using namespace std;
NS_AX_BEGIN
namespace ax
{
// ideas taken from:
// . The ocean spray in your face [Jeff Lander]
@ -2374,4 +2375,4 @@ void ParticleEmissionMaskCache::removeAllMasks()
this->masks.clear();
}
NS_AX_END
}

View File

@ -36,7 +36,8 @@ THE SOFTWARE.
#include "2d/SpriteFrameCache.h"
#include "math/FastRNG.h"
NS_AX_BEGIN
namespace ax
{
class ParticleBatchNode;
@ -1690,6 +1691,6 @@ private:
// end of _2d group
/// @}
NS_AX_END
}
#endif //__CCPARTICLE_SYSTEM_H__

View File

@ -46,7 +46,8 @@ THE SOFTWARE.
#include "renderer/backend/ProgramState.h"
#include "2d/TweenFunction.h"
NS_AX_BEGIN
namespace ax
{
ParticleSystemQuad::ParticleSystemQuad()
{
@ -843,4 +844,4 @@ std::string ParticleSystemQuad::getDescription() const
{
return fmt::format("<ParticleSystemQuad | Tag = {}, Total Particles = {}>", _tag, _totalParticles);
}
NS_AX_END
}

View File

@ -32,7 +32,8 @@ THE SOFTWARE.
#include "2d/ParticleSystem.h"
#include "renderer/QuadCommand.h"
NS_AX_BEGIN
namespace ax
{
class SpriteFrame;
class EventCustom;
@ -183,4 +184,4 @@ private:
// end of _2d group
/// @}
NS_AX_END
}

View File

@ -40,7 +40,8 @@
using namespace std;
NS_AX_BEGIN
namespace ax
{
void PlistSpriteSheetLoader::load(std::string_view filePath, SpriteFrameCache& cache)
{
@ -506,4 +507,4 @@ void PlistSpriteSheetLoader::reloadSpriteFramesWithDictionary(ValueMap& dict,
}
}
NS_AX_END
}

View File

@ -30,7 +30,8 @@
#include "base/Value.h"
#include "base/Data.h"
NS_AX_BEGIN
namespace ax
{
class PlistSpriteSheetLoader : public SpriteSheetLoader
{
@ -65,4 +66,4 @@ protected:
SpriteFrameCache& cache);
};
NS_AX_END
}

Some files were not shown because too many files have changed in this diff Show More