diff --git a/inc/hgl/graph/CoordinateSystem.h b/inc/hgl/graph/CoordinateSystem.h index 762a7979..9a28428f 100644 --- a/inc/hgl/graph/CoordinateSystem.h +++ b/inc/hgl/graph/CoordinateSystem.h @@ -11,4 +11,18 @@ namespace hgl::graph ENUM_CLASS_RANGE(NDC,Ortho) }; + + constexpr const char *CoordinateSystem2DName[]= + { + "NDC", + "0to1", + "Ortho" + }; + + inline const char *GetCoordinateSystem2DName(const enum class CoordinateSystem2D &cs) + { + RANGE_CHECK_RETURN_NULLPTR(cs) + + return CoordinateSystem2DName[size_t(cs)]; + } }//namespace hgl::graph