Transfering EXIF data in .NET

When resizing photographs using .NET, you end up losing your meta data. Here is a snippet you can use to transfer meta data:

foreach (System.Drawing.Imaging.PropertyItem pi in bitmapToResize.PropertyItems)
{
  resizedBitmap.SetPropertyItem(pi);
}

You could use SetPropertyItem to change properties too.

  • Share/Bookmark

1 Comment

mosziSeptember 14th, 2007 at 1:52 pm

Did you also take a look into the the .net3.0 framework for exif management ? It is a lot more easier to handle exif data and it’s really more extensive then in 2.0.
All my best, Moszi.

Leave a comment

Your comment