dfc15780c7
This pull request introduces the `til::math` namespace, which provides some casting functions to be used in support of `til::point` and `til::size`. When point/size want to ingest a floating-point structure, they _must_ be instructed on how to convert those floating-point values into integers. This enables: ``` Windows::Foundation::Point wfPoint = /* ... */; til::point tp{ til::math::rounding, wfPoint }; ``` Future thoughts: should the TilMath types be stackable? Right now, you cannot get "checked + rounding" behavior (where it throws if it doesn't fit) so everything is saturating. ## PR Checklist * [x] Closes a request by Michael * [x] I've discussed this with core contributors already |
||
---|---|---|
.. | ||
ut_til | ||
dirs | ||
precomp.cpp | ||
precomp.h |