I need a fast polygon clipping implementation against an axis aligned rectangle and I've implemented Sutherland–Hodgman algorithm based on my particular data set and it's 40 to 100 times faster than ClipperLib and other generic polygon clipping algorithms, but the output is a degenerate polygon in some cases:
results in:
Is there a variation of Sutherland–Hodgman algorithm to generate multiple polygons instead of a degenerate one or any fast and simple way to transform the degenerate polygon into multiple polygons?

