src/misc/rect.hpp
branchcpp_gui
changeset 6294 6c74bf9cc5a4
parent 6278 c09f5e53af9b
child 6295 a88d8c2cff6e
equal deleted inserted replaced
6293:59b7305f9a8b 6294:6c74bf9cc5a4
    90 
    90 
    91 	PointT operator /(T coef) const
    91 	PointT operator /(T coef) const
    92 	{
    92 	{
    93 		return PointT(PointRaw::x / coef, PointRaw::y / coef);
    93 		return PointT(PointRaw::x / coef, PointRaw::y / coef);
    94 	}
    94 	}
       
    95 
       
    96 	static const PointT& min()
       
    97 	{
       
    98 		static PointT val(std::numeric_limits<T>::min(), std::numeric_limits<T>::min());
       
    99 		return val;
       
   100 	}
       
   101 
       
   102 	static const PointT& zero()
       
   103 	{
       
   104 		static PointT val(0, 0);
       
   105 		return val;
       
   106 	}
       
   107 
       
   108 	static const PointT& one()
       
   109 	{
       
   110 		static PointT val(1, 1);
       
   111 		return val;
       
   112 	}
       
   113 
       
   114 	static const PointT& max()
       
   115 	{
       
   116 		static PointT val(std::numeric_limits<T>::max(), std::numeric_limits<T>::max());
       
   117 		return val;
       
   118 	}
       
   119 
    95 };
   120 };
    96 
   121 
    97 
   122 
    98 
   123 
    99 /** Template based rectangle */
   124 /** Template based rectangle */