+ 1
Can you tell me a mistake in given program
#include<I/path/to/SFML/Graphics.hpp> using namespace sf; int width=1024; int height=798; void drawQuad(RenderWindow &c, color c ,int x1,int y1,int w1,int x2,int y2,int w2) { Convexshape shape(4); Shape.setfillcolor(0); shape.setpoint( 0 ,Vector2f(x1-w1,y1)); shape.setpoint(1, Vector2f(x2-w2,y2)); shape.setpoint(2,Vector2f(x2+w2,y2)); shape.setpoint(3,vector2f(x1+w1,y2); w.draw(shape); int main() { Renderwindow app(Video mode(width,height), " outrun racing!"); app.(); app.setFramerateLimit(60); While(app.isopen()); { Event e; While(app.pollevent(e)); { if(e.type==Event::closed) app.close(); } app.clear(); drawQuad(app. Color::,500,500,200,300); app.display(); } return(0); }
1 Réponse
0
thankx