Welcome Guest! You need to login or register to make posts.



Go to last post Go to first unread
#1 Posted : Thursday, May 15, 2008 6:08:35 PM(UTC)

Rank: Advanced Member

Groups: Member
Joined: 3/3/2008(UTC)
Posts: 185

Thanks: 8 times

May I know how can I get the DateTimeOriginal from EXIF?

From the given example, I was only able to work up to this

                Dim formatReader As Codecs.IFormatReader
                formatReader = Codecs.FormatManager.CreateFormatReader(file)
                Dim exifData As Codecs.MetadataDictionary

                Select Case formatReader.MediaFormat
                    Case Codecs.FormatManager.JpegFormat
                        Dim jpegReader As Codecs.JpegReader
                        jpegReader = CType(formatReader, Codecs.JpegReader)
                        exifData = jpegReader.Exif

                    Case Codecs.FormatManager.PsdFormat
                        Dim psdReader As Codecs.PsdReader
                        psdReader = CType(formatReader, Codecs.PsdReader)
                        exifData = psdReader.Exif

                    Case Codecs.FormatManager.TiffFormat
                        Dim tiffReader As Codecs.TiffReader
                        tiffReader = CType(formatReader, Codecs.TiffReader)
                        exifData = tiffReader.Exif
                    Case Else
                        Exit Sub
                End Select

From the example given, seems like it's a loop. Just wondering is that possible for us to direct get the value and not go into the loop to match the keywords?


Alex Kon  
#2 Posted : Friday, May 16, 2008 3:51:59 PM(UTC)
Alex Kon

Rank: Advanced Member

Groups: Member
Joined: 1/31/2005(UTC)
Posts: 458

Was thanked: 5 time(s) in 5 post(s)

Yes, of course. Here is the last line which you need:

MessageBox.Show( _         exifData.Item(Aurigma.GraphicsMill.Codecs.ExifDictionary.DateTimeOriginal))

Edited by user Friday, May 16, 2008 3:53:55 PM(UTC)  | Reason: Not specified

Users browsing this topic
Forum Jump  
You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.