2013-10-31 08:45:00 +04:00
|
|
|
#ifndef CLIPPER_UTILS_H_
|
|
|
|
#define CLIPPER_UTILS_H_
|
|
|
|
|
2013-11-25 09:28:26 +04:00
|
|
|
#include "polyclipping/clipper.hpp"
|
2013-10-31 08:45:00 +04:00
|
|
|
#include "Polygon2d.h"
|
|
|
|
|
|
|
|
namespace ClipperUtils {
|
|
|
|
|
|
|
|
static const unsigned int CLIPPER_SCALE = 100000;
|
|
|
|
|
2013-12-02 02:33:40 +04:00
|
|
|
ClipperLib::Polygon fromOutline2d(const Outline2d &poly);
|
|
|
|
ClipperLib::Polygons fromPolygon2d(const Polygon2d &poly);
|
|
|
|
Polygon2d *toPolygon2d(const ClipperLib::Polygon &poly);
|
2013-10-31 08:45:00 +04:00
|
|
|
Polygon2d *toPolygon2d(const ClipperLib::Polygons &poly);
|
2013-11-25 09:28:26 +04:00
|
|
|
ClipperLib::Polygons process(const ClipperLib::Polygons &polygons,
|
|
|
|
ClipperLib::ClipType, ClipperLib::PolyFillType);
|
2013-10-31 08:45:00 +04:00
|
|
|
|
|
|
|
};
|
|
|
|
|
|
|
|
#endif
|