I'm also looking for something like this so please post any info you might find on the subject if you don't get the answer in this group.
PS! FYI: I think most software writing metadata into a file writes at exif, perhaps xmp or iptc in addition to plain exif, so you only need to check for exif data to get the date. Pil is the fastest way to do that, but pyexiv2 handles xmp very well too, but is much slower ( in my tests so far ). Pil does not handle metadata from all image files either, but pyexiv2 has never let me down. I've written a metadata extraction method that tries pil first and falls back to pyexiv2 if pil fails to extract the date from exif. Perhaps a custom storage backend which handles metadata as well could solve this? Anyway, please post any findings you might have. I'm in the middle of a huge photo library project in django and any piece of information about images, metadata and django is appreciated. Regards, Thomas On Tue, Apr 26, 2011 at 8:16 AM, Ian Turner <ian.tur...@gmail.com> wrote: > I'm in need of direction to access the temporary file that is stored > in memory or on disk from an ImageField/FileField so that I can read > it before it gets moved to its final location. > > The topics I've found all deal with only modifying the storage path > based on other fields in a model. My requirement is reading EXIF/IPTC/ > XMP data to grab the Date created of a photo. > > Providing a callable to "upload_to" gives an instance but the image > field doesn't have a file associated with it yet (working logically). > So how can I access the temporary memory or file to read it? > > -- > You received this message because you are subscribed to the Google Groups > "Django users" group. > To post to this group, send email to django-users@googlegroups.com. > To unsubscribe from this group, send email to > django-users+unsubscr...@googlegroups.com. > For more options, visit this group at > http://groups.google.com/group/django-users?hl=en. > > -- Mvh/Best regards, Thomas Weholt http://www.weholt.org -- You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to django-users@googlegroups.com. To unsubscribe from this group, send email to django-users+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/django-users?hl=en.