I'm dealing with a polygon "fracture" problem which is to decompose a polygon with (or without) holes into trapezoids.
I've found something similar implemented in Python here: https://deparkes.co.uk/2015/02/05/trapezoidal-decomposition-polygons-python/.
Is there a way to do it in C++?
Given a list of point(x, y) (std::vector), then return a list of trapezoids(points).
I don't know of a library that does this, but here's a rough outline of an algorithm to do this, it's an instance of a scan-line or line-sweep algorithm.
The idea is that you imagine a line parallel to your slice direction sweeping across your data. As this happens you maintain a set of active edges. Each time your line hits a vertex, you emit appropriate trapezoids and remove edges that have become inactive and introduce any new active edges.
I'm glossing over some awkward details here. You may need to "grid" the output trapezoids depending on your application and you have to be quite careful with the floating point portions of the calculations.
If you can find code that does polygon rasterization it can often be adapted to do this. In that case you alter the code for calculating the edge intersections at every x or y coordinate to only those at vertices. Another place to look would be for open source EDA packages. This algorithm is needed to prepare chip design data for mask preparation, but since you used the term "fracture" maybe you knew this already ;-)