extent: add scalar constructor

This commit is contained in:
Danny Robson 2015-03-02 18:47:12 +11:00
parent 29a148e2e5
commit 22a492e58a
2 changed files with 8 additions and 0 deletions

View File

@ -35,6 +35,13 @@ util::extent<T>::extent (const T _width, const T _height):
}
//-----------------------------------------------------------------------------
template <typename T>
util::extent<T>::extent (T t):
extent (t, t)
{ ; }
//-----------------------------------------------------------------------------
template <typename T>
util::extent<T>::extent (vector<2,T> _v):

View File

@ -34,6 +34,7 @@ namespace util {
T w, h;
extent (const T _width, const T _height);
extent (T);
extent (vector<2,T>);
extent (const extent&);
extent& operator= (const extent&);