Made compatible with MSVC++ : included math.h before framework.h everywhere, changed Polyline to LLPos2, and added #pragma comment(lib)s