Subject: [ggl] Hello + some newbie questions
From: Barend (barend)
Date: 2009-05-05 20:04:57
>> Or remove out own constants and use boost::math::* directly in all
>> ggl:: code?
> I have applied (r685, r686) use of boost::math::constants for PI and for
> Also, I const-qualified intermediate results in functions, to be sure
> compilers will always optimize these values.
> I think the ggl::math::hav function could be template for easy
> interchangeable use with float and double types:
> template <typename T>
> inline T hav(T const& theta)
> using boost::math::constants::half;
> T const sn = std::sin(half<T>() * theta);
> return sn * sn;
Good idea, actually I was thinking the same when I revisited this one of
these days. Strange it was not there.
> Same ggl::math::sqrt.
OK (it is "sqr" and maybe it can go).
-------------- next part --------------
An HTML attachment was scrubbed...
Geometry list run by mateusz at loskot.net