void DrawQuad(int x, int y,int width,int height, int angle=0,float scalex=0,float scaley=0) { glPushMatrix(); glTranslatef(x,y,0); glTranslatef(width*scalex/2,height*scaley/2,0); glRotatef(angle,0,0,1); glTranslatef(-(width*scalex/2),-(height*scaley/2),0); glScalef(scalex,scaley,0); glBegin(GL_QUADS); glVertex2f(0,0); glVertex2f(0,width); glVertex2f(width,height); glVertex2f(height,0); glEnd(); glPopMatrix(); }