opengl little optimizations