from PIL import Image
import struct
import sys

import os
dosya = os.path.join(os.curdir, os.sep, 'LockBackground.cpbitmap')

with open(dosya) as f:
    contents = f.read()

   
unk1, width, height, unk2, unk3, unk4 = struct.unpack('<6i', contents[-24:])
im = Image.fromstring('RGBA', (width,height), contents, 'raw', 'RGBA', 0, 1)
im.save('converted.png')