Added workaround for polygon clipping