made matrix stack OpenGL ES 2 compatible