Archived

This topic is now archived and is closed to further replies.

Problem moving a bmp across the screen, help :(

This topic is 5621 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Hey Im trying to move a small bmp arround the screen. Im loading it like that: image=auxDIBImageLoad("d:/project/ship.bmp"); And drawing it with this: glClear(GL_COLOR_BUFFER_BIT); glRasterPos2i(x,y); glPixelStorei(GL_UNPACK_ALIGNMENT, 1); glPixelZoom(1,1); glDrawPixels(image->sizeX,image->sizeY,GL_RGB,GL_UNSIGNED_BYTE,image->data); Now when For example i click on Enter I want it to to move right (increasing x position): case 13: { x=200; glutPostRedisplay(); break;} thats inside the keyboard glut function. Now I checked if it DOES go to the Draw function and it does but it wont change the position of the bmp even in a bit . Anyone knows why?

Share this post


Link to post
Share on other sites