How do I go about converting a JPG file to BMP using PIL? Tried to use Image.open('ifile.jpg').save('ofile.bmp', 'BMP') but I get a 'bogus header data' when attempting to open the file.
Tried the copy / paste method as described in Convert RGBA PNG to RGB with PIL but it does not work too.
there is no problem in the code.(i have tried the following code and worked well.) it converts your file to desired format.
i think the problem is about Ubuntu. I also met a few times and I think it is a bug. try to open with gimp...