fix windows build

This commit is contained in:
Matthias Hochsteger 2020-08-19 16:25:54 +02:00
parent 79ebf6eca1
commit 7cbeca147a
2 changed files with 6 additions and 3 deletions

View File

@ -574,7 +574,7 @@ class CSG2d
}; };
Solid2d Circle(double x, double y, double r, string name="", string bc=""); Solid2d Circle(double x, double y, double r, string name="", string bc="");
Solid2d Rectangle(double x0, double x1, double y0, double y1, string name="", string bc=""); Solid2d Rectangle(double x0, double x1, double y0, double y1, string name, string bc);
Solid2d AddIntersectionPoints ( Solid2d s1, Solid2d s2 ); Solid2d AddIntersectionPoints ( Solid2d s1, Solid2d s2 );
Solid2d ClipSolids ( Solid2d s1, Solid2d s2, bool intersect=true ); Solid2d ClipSolids ( Solid2d s1, Solid2d s2, bool intersect=true );

View File

@ -418,8 +418,11 @@ DLL_HEADER void ExportGeom2d(py::module &m)
; ;
m.def("Rectangle", &Rectangle); m.def("Rectangle", [](double x0, double x1, double y0, double y1, string bc, string mat)
m.def("Circle", &Circle); { return Rectangle(x0,x1,y0,y1,bc,mat); },
py::arg("x0"), py::arg("x1"), py::arg("y0"), py::arg("y1"), py::arg("bc")="", py::arg("mat")=""
);
m.def("Circle", Circle, py::arg("x"), py::arg("y"), py::arg("r"), py::arg("bc")="", py::arg("mat")="");
py::class_<CSG2d>(m, "CSG2d") py::class_<CSG2d>(m, "CSG2d")
.def(py::init<>()) .def(py::init<>())