polylineDrawing package
Nothing really difficult there, the decomposition is done in the C++ code.
The only difficulty the use of the Tesselator for filled polylines. See http://glprogramming.com/red/chapter11.html for more information.
The tesselator could be also used in PolylineInterpColorDrawerGL to be able to fill polylines with more than 4 edges. It would be very similar to PolylineFillDrawerGL.