Having implicit conversion on Unit class causes much more harm than
doing the conversion some other way -- mainly for multiplication and
division, which is done with builtin operators and thus the result is
unitless. Also it is possible to do wrong "retyping" between degrees and
radians:
Rad a = Constants::pi();
Deg b(a*2);
On GCC >4.5 b is `180`, but on GCC 4.4 it is `2pi`, which is obviously
wrong and not wanted.
The conversion is done using Unit::toUnderlyingType() which is now used
everywhere instead of conversion operator. The conversion operator is
made available only for GCC 4.5, where it can be marked as explicit.
This might cause incompatibilites with `master` branch, where no
Unit::toUnderlyingType() exists, but users should have no need to
convert it to underlying type anyway as all required functions are
available through the library.
This reverts commit 36ac4de5c4 and
partially also 0db3a183ae (UnitTest.cpp).
Not documented yet, because I am ashamed of this way of doing things.
With shared libraries the resources are imported automatically, with
static ones the user must explicitly include these files in some
non-static library or executable to have them imported.
Four tests (SceneGraph::Animable, Mesh, MeshTools::Tipsify,
TextureTools::Atlas) however fail, not sure what the cause is, as they
fail somewhere deep long after exiting from main().
Now it is possible to open either pure data arrays or arrays specified
with filename. The function calls might be ambiguous now (i.e.
open("image.tga") would open data array instead of handling it as
filename), renamed them to avoid that. Default implementations now
fire an assertion. Bumped plugin interface string version as this is
pretty incompatible change.
In next few commits AbstractFont will become plugin interface. Font
implementations are now in magnum-plugins repository. Removed all traces
of FreeType and HarfBuzz dependencies.