Re: Re: [pygame] image conversion in memory

2014-08-11 Thread diliup gabadamudalige
Dear Radomir, s = pygame.image.load("88keykbd.png") f = StringIO.StringIO() f.name = '88keykbd.jpg' pygame.image.save(s, f) pygame.image.load("88keykbd.jpg") yourimage = f.getvalue() why does the line pygame.image.load("88keykbd.jpg") throw an error? It throws pygame.error: Couldn't open 88keyk

Re: Re: [pygame] image conversion in memory

2014-08-11 Thread diliup gabadamudalige
get_screen = SCREEN.subsurface(0, 0, SCREENW, SCREENH) # grab the screen how can you concert get_screen to a jpeg or a png WITHOUT saving to disk? In Pygame.. Thanks On Mon, Aug 11, 2014 at 12:21 AM, Radomir Dopieralski wrote: > On 08/08/2014 11:16 AM, diliup gabadamudalige wrote: > > Hi all