[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]
Re: [pygame] pygame.image.save()
- To: pygame-users@xxxxxxxx
- Subject: Re: [pygame] pygame.image.save()
- From: "René Dudfield" <renesd@xxxxxxxxx>
- Date: Tue, 15 Apr 2008 10:06:52 +1000
- Delivered-to: archiver@xxxxxxxx
- Delivered-to: pygame-users-outgoing@xxxxxxxx
- Delivered-to: pygame-users@xxxxxxxx
- Delivery-date: Mon, 14 Apr 2008 20:06:56 -0400
- Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:message-id:date:from:to:subject:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references; bh=kDkYnhJCa1cn0x4BKWZ5/yqyg8CS5WCQbuOqvt5OLYE=; b=DWf14Kp2+vR0zuZ+rAINZxR8ga4RPKsS/q4tnOwwDuDP+7bu/B4pACcBRIGoAJk0xW+sHcMX48J7l7e9FF2Ecq8ZetSQfiED9MCfBqLk+6E/xVlXpaya5i9uV2ei+mYUgymDHjCre2W+pR8+Zn7RahtYfsBLNz2x47WaA+kNHTk=
- Domainkey-signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=message-id:date:from:to:subject:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references; b=kChudrsFDtlDWN+hAbWQRHqw3Q/VUgvAOb5Uv9gRwyQi22w3cSJx+4s0MEtMcfLQ6ZAjvm0LeorrjMVCYR3jUfC9lz6CE0Iwc6U41NgGa9Q5UKxDn+ajIMkEI2pcvjZT4HjSqNlsSFfeUNQvxxI4eHKv5xPnwdca79n/tsgP8es=
- In-reply-to: <a62fab400804141629h32ab2630u25c5fc1cf4a3af4f@xxxxxxxxxxxxxx>
- References: <a62fab400804141629h32ab2630u25c5fc1cf4a3af4f@xxxxxxxxxxxxxx>
- Reply-to: pygame-users@xxxxxxxx
- Sender: owner-pygame-users@xxxxxxxx
hello,
I think this might be to do with the pygame version?
Older pygame (1.7.1) can save to .tga I think - I think it also is
buggy and names files in any way, even though the file is actually a
bmp.
You could add a test in there to see what type of file is produced, or
save a different type depending on the version of pygame... or require
pygame 1.8+
cheers,
On Tue, Apr 15, 2008 at 9:29 AM, Ian Mallett <geometrian@xxxxxxxxx> wrote:
> Hi,
> On my project, http://www.pygame.org/project/698/?release_id=1226, there
> is a render option, which allows you to render an image of an arbitrary size
> using the coordinates on the viewport. The image is then saved.
> Unfortunately, for some people this works, and for others, it returns an
> invalid .png file. I'm guessing it has something to do with the surface
> type (e.g. 16 bit, 32 bit, etc.). I'm not sure though. Ideas?
> Thanks,
> Ian
>