coord: use size_t/intmax_t for u and i suffixes

size_t matches array indices we are likely to be used in conjuction with
these types.
This commit is contained in:
Danny Robson 2015-04-07 16:53:46 +10:00
parent 14cab4fb9b
commit 5627c573eb
4 changed files with 7 additions and 6 deletions

View File

@ -45,12 +45,12 @@ namespace util {
};
typedef AABB<2,float> AABB2f;
typedef AABB<2,uint32_t> AABB2u;
typedef AABB<2,int32_t> AABB2i;
typedef AABB<2,size_t> AABB2u;
typedef AABB<2,intmax_t> AABB2i;
typedef AABB<3,float> AABB3f;
typedef AABB<3,uint32_t> AABB3u;
typedef AABB<3,uint32_t> AABB3i;
typedef AABB<3,size_t> AABB3u;
typedef AABB<3,intmax_t> AABB3i;
template <size_t S, typename T>
std::ostream& operator<< (std::ostream&, AABB<S,T>);

View File

@ -55,7 +55,7 @@ namespace util {
static const extent MIN;
};
typedef extent<2,int> extent2i;
typedef extent<2,intmax_t> extent2i;
typedef extent<2,size_t> extent2u;
typedef extent<2,float> extent2f;
typedef extent<2,double> extent2d;

View File

@ -70,6 +70,7 @@ namespace util {
typedef point<3,double> point3d;
typedef point<2,size_t> point2u;
typedef point<2,intmax_t> point2i;
}
#include <functional>

View File

@ -71,7 +71,7 @@ namespace util {
// convenience typedefs
typedef vector<2,size_t> vector2u;
typedef vector<2,long> vector2i;
typedef vector<2,intmax_t> vector2i;
typedef vector<2,float> vector2f;
typedef vector<3,float> vector3f;