extent: add scalar variant of expanded
This commit is contained in:
parent
7b3ea29856
commit
23ffd18acb
10
extent.cpp
10
extent.cpp
@ -81,9 +81,17 @@ extent<T>::expanded (util::vector<2,T> size) const
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
//-----------------------------------------------------------------------------
|
//-----------------------------------------------------------------------------
|
||||||
template <typename T>
|
template <typename T>
|
||||||
|
extent<T>
|
||||||
|
extent<T>::expanded (T t) const
|
||||||
|
{
|
||||||
|
return expanded (util::vector<2,T> {t});
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
///////////////////////////////////////////////////////////////////////////////
|
||||||
|
template <typename T>
|
||||||
float
|
float
|
||||||
extent<T>::aspect (void) const
|
extent<T>::aspect (void) const
|
||||||
{
|
{
|
||||||
|
@ -41,6 +41,7 @@ namespace util {
|
|||||||
T diameter (void) const;
|
T diameter (void) const;
|
||||||
|
|
||||||
extent<T> expanded (util::vector<2,T>) const;
|
extent<T> expanded (util::vector<2,T>) const;
|
||||||
|
extent<T> expanded (T) const;
|
||||||
|
|
||||||
float aspect (void) const;
|
float aspect (void) const;
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user