Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Pygame Error: File is not a windows BMP file

Tags:

python

pygame

I'm having problem following this tutorial. After I run it, an error message pops up

"ball = pygame.image.load("...) Error:File is not a Windows BMP file.

I'm on OSX 10.9.5

I highly suspect I messed up the installation for all the necessary components, and the my steps are the following when I install:

  1. Delete Python 3 and reinstall Python 2.7 32-bit version (using the .dmg)
  2. Install the pygame package using the .dmg
  3. Was asked to install X11, installed X11
  4. Open SDL framework .zip and drag and drop into a folder in Application/Library

Did I mess it up? Especially for the SDL? Please tell me the solution, thank you.

//Tried putting the image file in the same directory; saving the image file as .bmp

like image 256
LeonBrain Avatar asked Jan 28 '15 13:01

LeonBrain


1 Answers

I followed the solution here answer. Head to Macintosh HD/Library/Frameworks/..... and delete the pygame folder within and reinstall.

like image 92
LeonBrain Avatar answered Oct 21 '22 00:10

LeonBrain