Re: [Tutor] Obtaining image date of creation

2007-11-15 Thread pyprog
On jeu, 2007-11-15 at 04:17 +0100, pyprog wrote: > > >>> import Image > >>> ouv=Image.open('path_to_your_picture_with_exif_data__jpeg') > >>> exifdata=imgExif._getexif() A little error : >>> import Image >>> ouv=Image.open('path_to_your_picture_with_exif_data__jpeg') >>> exifdata=ouv._getexif(

Re: [Tutor] Obtaining image date of creation

2007-11-14 Thread Scott SA
On 11/14/07, Roy Chen ([EMAIL PROTECTED]) wrote: >I would like to write a simple script that would rename a bunch of >photos according to their creation date, i.e. the date which the >photo was taken. > >Is there a way to use Python to obtain that information from the >image file, or is that

Re: [Tutor] Obtaining image date of creation

2007-11-14 Thread pyprog
Hello, I'm new here . To read EXIF with Python Imaging Library : >>> import Image >>> ouv=Image.open('path_to_your_picture_with_exif_data__jpeg') >>> exifdata=imgExif._getexif() >>> # Here a personnal exemple >>> for keyExif, valueExif in zip(exifdata.keys(), exifdata.values()): ... print ke

Re: [Tutor] Obtaining image date of creation

2007-11-14 Thread Eric Abrahamsen
> And while I haven't tried it, this page (http://effbot.org/zone/pil- > changes-114.htm) appears to indicate exif format is somewhat > supported in PIL; perhaps pyexif does a better job though? PIL does a pretty job, though it's a pain. from PIL import Image from PIL.ExifTags import TAGS def get

Re: [Tutor] Obtaining image date of creation

2007-11-14 Thread Marc Tompkins
Thus spake Roy Chen: > Hello, > > I would like to write a simple script that would rename a bunch of > photos according to their creation date, i.e. the date which the > photo was taken. > > Is there a way to use Python to obtain that information from the > image file, or is that information not s

Re: [Tutor] Obtaining image date of creation

2007-11-14 Thread Evert Rol
> I'm assuming you don't want the last changed date you see on the file > on your PC, but the creation date that the camera stored when the > picture was taken. > > Now I don't know much about that, but I thought it was interesting, so > I did some Googling :-) > > I don't know whether it's always

Re: [Tutor] Obtaining image date of creation

2007-11-14 Thread Remco Gerlich
Hi, I'm assuming you don't want the last changed date you see on the file on your PC, but the creation date that the camera stored when the picture was taken. Now I don't know much about that, but I thought it was interesting, so I did some Googling :-) I don't know whether it's always stored, b

Re: [Tutor] Obtaining image date of creation

2007-11-14 Thread Eric Abrahamsen
On Nov 14, 2007, at 9:05 PM, Kent Johnson wrote: > Roy Chen wrote: >> Hello, >> >> I would like to write a simple script that would rename a bunch of >> photos according to their creation date, i.e. the date which the >> photo was taken. >> >> Is there a way to use Python to obtain that informatio

Re: [Tutor] Obtaining image date of creation

2007-11-14 Thread Kent Johnson
Roy Chen wrote: > Hello, > > I would like to write a simple script that would rename a bunch of > photos according to their creation date, i.e. the date which the > photo was taken. > > Is there a way to use Python to obtain that information from the > image file, or is that information not

[Tutor] Obtaining image date of creation

2007-11-14 Thread Roy Chen
Hello, I would like to write a simple script that would rename a bunch of photos according to their creation date, i.e. the date which the photo was taken. Is there a way to use Python to obtain that information from the image file, or is that information not stored in the file? Thanks, Ro