January 2014 updates to Magnum

Since the pre­vi­ous Oc­to­ber snap­shot Mag­num gained Visu­al Stu­dio port, font con­ver­sion util­ity, im­proved text ren­der­ing along with ex­ample ap­plic­a­tion, sup­port for OpenGL de­bug out­put, doc­u­ment­a­tion up­dates, bet­ter test cov­er­age and many more us­ab­il­ity im­prove­ments and fixes.

The ver­sion 2014.01 is avail­able un­der the v2014.01 tag in Cor­rade, Mag­num, Mag­num Plu­gins and Mag­num In­teg­ra­tion Git­Hub re­pos­it­or­ies. This art­icle will de­scribe the most im­port­ant changes, for de­tailed list fol­low the changelog links at the end of this an­nounce­ment.

For com­pat­ib­il­ity branch there is the snapshot-2014-01-compatibility tag in Cor­rade, Mag­num and Mag­num Plu­gins re­pos­it­or­ies.

Google Groups dis­cus­sion

You can now ask for help, share your work or par­ti­cipi­ate in de­vel­op­ment at the new Google Groups for­um. The group is open to every­one, you just need Google ac­count to post. In my opin­ion this is bet­ter than re­quir­ing every­one to cre­ate new ac­count on some self-hos­ted for­um.

New text ren­der­ing ex­ample

I ad­ded text ren­der­ing ex­ample to show­case new fea­tures such as text align­ment and multi-line text, in ad­di­tion to already ex­ist­ing dis­tance-field ren­der­ing cap­ab­il­it­ies. See show­case page for live ap­plic­a­tion run­ning on both Em­scripten and Nat­ive Cli­ent. I also ad­ded live Tex­tured Tri­angle ex­ample.

Textured triangle example screenshot
Tex­tured Tri­angle Ex­ample webgl1
Slightly ex­ten­ded ver­sion of the tri­angle ex­ample; uses TGA im­port­er plu­gin to load a stone im­age and dis­plays a tri­angle with colored tex­ture on it.
Text example screenshot
Text Ex­ample webgl1
Show­case of Mag­num text ren­der­ing us­ing signed dis­tance fields. Full UTF-8 sup­port.

Us­ing ab­so­lute in­cludes by de­fault

All pro­jects were switched to use ab­so­lute in­cludes by de­fault, i.e. head­ers are in­cluded this way:

#include <Magnum/Math/Vector3.h>

rather than this way:

#include <Math/Vector3.h>

This solves many prob­lems with fi­le­name col­li­sions (namely with Visu­al Stu­dio com­piler, Doxy­gen and pos­sibly else­where), see mosra/mag­num#36 for more in­form­a­tion. As this is a very drastic change, you may need to re­cre­ate your build dir­ect­or­ies and up­date at least FindCorrade.cmake and FindMagnum.cmake CMake mod­ules with new ones from modules/ sub­dir­ect­ory in Cor­rade and Mag­num re­pos­it­or­ies (and pos­sibly also oth­er ones).

If you are build­ing with de­prec­ated fea­tures en­abled (BUILD_DEPRECATED CMake para­met­er in both Cor­rade and Mag­num), you can still use the old non-ab­so­lute in­cludes, but you are en­cour­aged to switch to ab­so­lute ones.

Visu­al Stu­dio 2013 sup­port

This re­lease is the first one with ex­per­i­ment­al Visu­al Stu­dio 2013 sup­port. Be­cause the com­piler still lacks some re­quired fea­tures (constexpr and noexcept keywords) and has some ser­i­ous bugs in C++11 im­ple­ment­a­tion, the sup­port is provided only through compatibility branch. The port in­volves some ugly hacks and work­arounds which can’t be put in master, hope­fully the next MS­VC re­lease will make my life easi­er. Snap­shot of compatibility branch with MS­VC 2013 sup­port is avail­able un­der snapshot-2014-01-compatibility tag in Cor­rade and Mag­num Git­Hub re­pos­it­or­ies. The com­pat­ib­il­ity branch doesn’t con­tain any­thing new ex­cept work­arounds for said com­pilers.

Com­plete changelog

You can find a de­tailed list of changes in ver­sion 2014.01 in the doc­u­ment­a­tion: