Book
Module 7 - Section 2 - Bitmap Graphics
Module 7 - Section 2 - Bitmap Graphics
Completion requirements
View
After the completion of this module the students will be able to:
- use an image as a background image in Pygame basic template
- create python code to load sprites
- superimpose sprites on top of the background image
- rewrite Python code to move the sprites using the keyboard or the mouse
7.2.2 - Background image
Instead of the dull one color backgrounds that we have created so far, in pygame we can use whatever picture or graphics as a background image of our games. The images should already be sized to the resolution of our screen. If it is not we can use whatever program we like to crop and resize the image to the size of our game's screen.
For our game we have some background images to choose if you don't want to find one. Right click on the image that you like and Save image as in the Documents folder Module7.2 with the name background.jpg without the number.