support for gl without GL_PRIMITIVE_RESTART