diff --git a/region.cpp b/region.cpp index c076a273..a2b20061 100644 --- a/region.cpp +++ b/region.cpp @@ -69,6 +69,15 @@ util::region::diameter (void) const } +//----------------------------------------------------------------------------- +template +util::extent::size_type> +util::region::size (void) const +{ + return { w, h }; +} + + //----------------------------------------------------------------------------- template void diff --git a/region.hpp b/region.hpp index 3af41a92..b89d6a79 100644 --- a/region.hpp +++ b/region.hpp @@ -47,6 +47,8 @@ namespace util { size_type area (void) const; size_type diameter (void) const; + util::extent size (void) const; + void scale (T factor); bool empty (void) const;