Fixes https://github.com/prusa3d/Slic3r/issues/670
and some of https://github.com/prusa3d/Slic3r/issues/895
PerimeterGenerator was using an unsafe clipper offset function,
which performed offset for both a contour and its holes together.
With this commit the offsets were replaced with their safe counterparts,
though these safe counterparts may be somehow slower
(performing offset on ExPolygon or ExPolygons, piece by piece).
Also there was a bug, where if the infill & gap fill consumed
everything of the polygon, a polygon one onion shell above was still
used for infill.
due to avoiding the 128bit multiply operations:
A filtered predicate is tried to calculate SlopesEqual()
to minimize the invocation of 128bit multiply operations.
inside ClipperUtils are now using bit shifts instead of multiplication
by doubles, which makes the scaling precise.
Removed the scale parameter from all offset functions.
Modified the safety offset to calculate offset per polygon instead
of over all polygons at once. The old way was not safe and very slow,
sometimes this meant a kiss of death for supports for example.
Added a safe variant of offset(const Slic3r::ExPolygon...), which offsets each loop separately.
New functions "remove_sticks" to remove zero area parts of polygons.
New functions "remove_small" and "remove_degenerate" for polygon clean up.
Extended the C++ supports, those are not finalized yet though.