Zen API
 All Classes Files Functions Variables Typedefs Friends Macros Modules Pages
template<typename T >
T kQuantizeFloor ( const T &  value,
const T &  granularity 
)

Rounds the specified input value down to the nearest multiple of the specified granularity.

This method requires C++ 2011; accordingly, it cannot be used in inline functions that may be processed by C compilers or older C++ compilers.

Parameters
valueInput value.
granularityGranularity (quantum; must be positive).
Returns
Input value, rounded down to closest multiple of granularity.