Skip Menu |

This queue is for tickets about the GD CPAN distribution.

Report information
The Basics
Id: 60488
Status: resolved
Priority: 0/
Queue: GD

People
Owner: Nobody in particular
Requestors: user42 [...] zip.com.au
Cc:
AdminCc:

Bug Information
Severity: (no value)
Broken in: (no value)
Fixed in: (no value)



Subject: new() file type loaded
Date: Thu, 19 Aug 2010 07:36:46 +1000
To: bug-GD [...] rt.cpan.org
From: Kevin Ryde <user42 [...] zip.com.au>
When GD::Image->new loads from a file, does it record the file type detected? I thought perhaps to write back a file in the same format as loaded and wondered if the format is returned, or recorded in the GD::Image object, or something.
On Wed Aug 18 17:36:59 2010, user42@zip.com.au wrote: Show quoted text
> When GD::Image->new loads from a file, does it record the file type > detected? I thought perhaps to write back a file in the same format as > loaded and wondered if the format is returned, or recorded in the > GD::Image object, or something.
How should that be called? $image->write maybe. Very good idea. I started implementing it in a write branch -- Reini Urban
It would involve changing the simple SCALAR gdImagePtr to a HASH as the libgd internal gdImage does not store its original type. So I skipped changing the typemap, and only added a _file method which calls gdImageFile(image, filename) and uses the file extension as type. -- Reini Urban
Will be in the upcoming 2.67 release. -- Reini Urban