Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

What is the best EXIF library for .Net?

Tags:

.net

exif

I am looking for simple straightforward solution for accessing EXIF information of jpeg images in .Net. Does anybody has experience with this?

like image 570
Jakub Šturc Avatar asked Sep 03 '08 16:09

Jakub Šturc


People also ask

Does Google read EXIF data?

EXIF data helps Google to understand your pictures.

What is the difference between EXIF and metadata?

What's the difference between metadata and EXIF? In digital photography, metadata is the information stored within an image describing the camera settings used, the shoot location, and more. An EXIF is the file that stores this metadata.

Which file formats have EXIF data?

The exchangeable image file format (EXIF) is a standard for embedding technical metadata in image files that many camera manufacturers use and many image-processing programs support. EXIF metadata can be embedded in TIFF and JPEG images.


2 Answers

If you're willing to use an open-source library, may I humbly suggest one of my own creation?

The metadata-extractor project has been alive and well since 2002 for Java, and is now available for .NET.

  • Open source (Apache 2.0)
  • Heavily tested and widely used
  • Supports many image types (JPEG, TIFF, PNG, WebP, GIF, BMP, ICO, PCX...)
  • Supports many metadata types (Exif, IPTC, XMP, JFIF, ...)
  • Supports many manufacturer-specific fields (Canon, Nikon, ...)
  • Very fast (fully processes ~400 images totalling 1.33GB in ~3 seconds) with low memory consumption
  • Builds for .NET 3.5, .NET 4.0+ and PCL

It's available via NuGet or GitHub.

Sample usage:

IEnumerable<Directory> directories = ImageMetadataReader.ReadMetadata(path);  foreach (var directory in directories) foreach (var tag in directory.Tags)     Console.WriteLine($"{directory.Name} - {tag.TagName} = {tag.Description}"); 
like image 199
Drew Noakes Avatar answered Sep 20 '22 07:09

Drew Noakes


If you're compiling against v3 of the Framework (or later), then you can load the images using the BitmapSource class, which exposes the EXIF metadata through the Metadata property

like image 20
Rowland Shaw Avatar answered Sep 21 '22 07:09

Rowland Shaw