Castor3D 0.16.0
Multiplatform 3D engine
Macros
Macros.hpp File Reference

Macros

#define __FUNCTION__   ""
 Defines this macro if not in debug.
 
#define CU_DeclareMap(key, value, name)
 
#define CU_DeclareMultimap(key, value, name)
 
#define CU_DeclareSet(key, name)
 
#define CU_DeclareMultiset(key, name)
 
#define CU_DeclareVector(key, name)
 
#define CU_DeclareArray(key, count, name)
 
#define CU_DeclareList(key, name)
 
#define CU_DeclareTemplateMap(key, value, name)
 
#define CU_DeclareTemplateSet(key, name)
 
#define CU_DeclareTemplateVector(key, name)
 
#define CU_DeclareTemplateArray(key, count, name)
 
#define CU_DeclareTemplateList(key, name)
 
#define CU_DeclarePoint(type, count, name)
 
#define CU_DeclareCoord(type, count, name)
 
#define CU_DeclareConstCoord(type, count, name)
 
#define CU_DeclareMtx(type, rows, cols, name)
 
#define CU_DeclareSqMtx(type, count, name)
 
#define CU_UnusedParam(t, x)   [[maybe_unused]] t x
 
#define CU_EnumBounds(EnumName, EnumMin, EnumMax)
 
#define CU_ScopedEnumBounds(EnumMin, EnumMax)
 
#define CU_ImplementFlags(FlagType)
 
#define CU_ImplementClassFlags(Class, FlagType)
 

Macro Definition Documentation

◆ __FUNCTION__

#define __FUNCTION__   ""

Defines this macro if not in debug.

◆ CU_DeclareArray

#define CU_DeclareArray ( key,
count,
name )
Value:
using name##Array = castor::Array< key, size_t( count ) >;\
using name##ArrayIt = name##Array::iterator;\
using name##ArrayRIt = name##Array::reverse_iterator;\
using name##ArrayConstIt = name##Array::const_iterator;\
using name##ArrayConstRIt = name##Array::const_reverse_iterator
std::array< DataT, SizeT > Array
Definition ConfigModule.hpp:148

◆ CU_DeclareConstCoord

#define CU_DeclareConstCoord ( type,
count,
name )
Value:
using ConstCoords##count##name = Coords< type const, count >;\
CU_DeclareVector( ConstCoords##count##name, ConstCoords##count##name );\
CU_DeclareList( ConstCoords##count##name, ConstCoords##count##name )

◆ CU_DeclareCoord

#define CU_DeclareCoord ( type,
count,
name )
Value:
using Coords##count##name = Coords< type, count >;\
CU_DeclareVector( Coords##count##name, Coords##count##name );\
CU_DeclareList( Coords##count##name, Coords##count##name )

◆ CU_DeclareList

#define CU_DeclareList ( key,
name )
Value:
using name##List = castor::List< key >;\
using name##ListIt = name##List::iterator;\
using name##ListRIt = name##List::reverse_iterator;\
using name##ListConstIt = name##List::const_iterator;\
using name##ListConstRIt = name##List::const_reverse_iterator

◆ CU_DeclareMap

#define CU_DeclareMap ( key,
value,
name )
Value:
using name##Map = castor::Map< key, value >;\
using name##MapIt = name##Map::iterator;\
using name##MapRIt = name##Map::reverse_iterator;\
using name##MapConstIt = name##Map::const_iterator;\
using name##MapConstRIt = name##Map::const_reverse_iterator;\
using name##MapValueType = name##Map::value_type

◆ CU_DeclareMtx

#define CU_DeclareMtx ( type,
rows,
cols,
name )
Value:
using Matrix##rows##x##cols##name = Matrix< type, rows, cols >;\
CU_DeclareVector( Matrix##rows##x##cols##name, Matrix##rows##x##cols##name );\
CU_DeclareList( Matrix##rows##x##cols##name, Matrix##rows##x##cols##name )

◆ CU_DeclareMultimap

#define CU_DeclareMultimap ( key,
value,
name )
Value:
using name##MMap = castor::MultiMap< key, value >;\
using name##MMapIt = name##MMap::iterator;\
using name##MMapRIt = name##MMap::reverse_iterator;\
using name##MMapConstIt = name##MMap::const_iterator;\
using name##MMapConstRIt = name##MMap::const_reverse_iterator;\
using name##MapValueType = name##MMap::value_type

◆ CU_DeclareMultiset

#define CU_DeclareMultiset ( key,
name )
Value:
using name##Mset = castor::MultiSet< key >;\
using name##MSetIt = name##MSet::iterator;\
using name##MSetRIt = name##MSet::reverse_iterator;\
using name##MSetConstIt = name##MSet::const_iterator;\
using name##MSetConstRIt = name##MSet::const_reverse_iterator

◆ CU_DeclarePoint

#define CU_DeclarePoint ( type,
count,
name )
Value:
using Point##count##name = Point< type, count >;\
CU_DeclareVector( Point##count##name, Point##count##name );\
CU_DeclareList( Point##count##name, Point##count##name )

◆ CU_DeclareSet

#define CU_DeclareSet ( key,
name )
Value:
using name##Set = castor::Set< key >;\
using name##SetIt = name##Set::iterator;\
using name##SetRIt = name##Set::reverse_iterator;\
using name##SetConstIt = name##Set::const_iterator;\
using name##SetConstRIt = name##Set::const_reverse_iterator

◆ CU_DeclareSqMtx

#define CU_DeclareSqMtx ( type,
count,
name )
Value:
using Matrix##count##x##count##name = SquareMatrix< type, count >;\
CU_DeclareVector( Matrix##count##x##count##name, Matrix##count##x##count##name );\
CU_DeclareList( Matrix##count##x##count##name, Matrix##count##x##count##name )

◆ CU_DeclareTemplateArray

#define CU_DeclareTemplateArray ( key,
count,
name )
Value:
using name##Array = castor::Array< key, count >;\
using name##ArrayIt = typename name##Array::iterator;\
using name##ArrayRIt = typename name##Array::reverse_iterator;\
using name##ArrayConstIt = typename name##Array::const_iterator;\
using name##ArrayConstRIt = typename name##Array::const_reverse_iterator

◆ CU_DeclareTemplateList

#define CU_DeclareTemplateList ( key,
name )
Value:
using name##List = castor::List< key >;\
using name##ListIt = typename name##List::iterator;\
using name##ListRIt = typename name##List::reverse_iterator;\
using name##ListConstIt = typename name##List::const_iterator;\
using name##ListConstRIt = typename name##List::const_reverse_iterator

◆ CU_DeclareTemplateMap

#define CU_DeclareTemplateMap ( key,
value,
name )
Value:
using name##Map = castor::Map< key, value >;\
using name##MapIt = typename name##Map::iterator;\
using name##MapRIt = typename name##Map::reverse_iterator;\
using name##MapConstIt = typename name##Map::const_iterator;\
using name##MapConstRIt = typename name##Map::const_reverse_iterator;\
using name##Pair = typename name##Map::value_type

◆ CU_DeclareTemplateSet

#define CU_DeclareTemplateSet ( key,
name )
Value:
using name##Set = castor::Set< key >;\
using name##SetIt = typename name##Set::iterator;\
using name##SetRIt = typename name##Set::reverse_iterator;\
using name##SetConstIt = typename name##Set::const_iterator;\
using name##SetConstRIt = typename name##Set::const_reverse_iterator

◆ CU_DeclareTemplateVector

#define CU_DeclareTemplateVector ( key,
name )
Value:
using name##Array = castor::Vector< key >;\
using name##ArrayIt = typename name##Array::iterator;\
using name##ArrayRIt = typename name##Array::reverse_iterator;\
using name##ArrayConstIt = typename name##Array::const_iterator;\
using name##ArrayConstRIt = typename name##Array::const_reverse_iterator

◆ CU_DeclareVector

#define CU_DeclareVector ( key,
name )
Value:
using name##Array = castor::Vector< key >;\
using name##ArrayIt = name##Array::iterator;\
using name##ArrayRIt = name##Array::reverse_iterator;\
using name##ArrayConstIt = name##Array::const_iterator;\
using name##ArrayConstRIt = name##Array::const_reverse_iterator

◆ CU_EnumBounds

#define CU_EnumBounds ( EnumName,
EnumMin,
EnumMax )
Value:
EnumName##_COUNT = EnumMax + 1,\
EnumName##_MIN = EnumMin,\
EnumName##_MAX = EnumName##_COUNT - 1

◆ CU_ImplementClassFlags

#define CU_ImplementClassFlags ( Class,
FlagType )
Value:
using Class##FlagType##s = castor::FlagCombination< Class::FlagType >;\
inline constexpr Class##FlagType##s operator|( Class::FlagType lhs, Class::FlagType rhs )\
{\
return Class##FlagType##s( lhs ) | rhs;\
}\
inline constexpr Class##FlagType##s operator|( Class##FlagType##s::BaseType lhs, Class::FlagType rhs )\
{\
return Class##FlagType##s( lhs ) | rhs;\
}\
inline constexpr Class##FlagType##s operator|( Class::FlagType lhs, Class##FlagType##s::BaseType rhs )\
{\
return Class##FlagType##s( lhs ) | rhs;\
}
DynamicBitsetT< BlockTypeT > operator|(DynamicBitsetT< BlockTypeT > const &lhs, DynamicBitsetT< BlockTypeT > const &rhs)

◆ CU_ImplementFlags

#define CU_ImplementFlags ( FlagType)
Value:
using FlagType##s = castor::FlagCombination< FlagType >;\
inline constexpr FlagType##s operator|( FlagType lhs, FlagType rhs )\
{\
return FlagType##s( lhs ) | rhs;\
}\
inline constexpr FlagType##s operator|( FlagType##s::BaseType lhs, FlagType rhs )\
{\
return FlagType##s( lhs ) | rhs;\
}\
inline constexpr FlagType##s operator|( FlagType lhs, FlagType##s::BaseType rhs )\
{\
return FlagType##s( lhs ) | rhs;\
}

◆ CU_ScopedEnumBounds

#define CU_ScopedEnumBounds ( EnumMin,
EnumMax )
Value:
eCount = EnumMax + 1,\
eMin = EnumMin,\
eMax = eCount - 1

◆ CU_UnusedParam

#define CU_UnusedParam ( t,
x )   [[maybe_unused]] t x