How to Add JPEG EXIF TAGS (url,keywords..)

Magick.NET is an object-oriented C# interface to ImageMagick. Use this forum to discuss, make suggestions about, or report bugs concerning Magick.NET
Post Reply
laleh
Posts: 3
Joined: 2019-07-14T10:54:10-07:00
Authentication code: 1152

How to Add JPEG EXIF TAGS (url,keywords..)

Post by laleh »

Hi
I'm using Magick.NET-Q16-AnyCPU for mvc core2 .

I am trying to add exif tags to jpeg images, copyright and author and url and keyword but not working except copyright


My Code :

Code: Select all

  using (MagickImage image = new MagickImage(media.Name))
                {
                   var profile = new ExifProfile();
                    profile.SetValue(ExifTag.Copyright, Title);
                    profile.SetValue(ExifTag.Artist, "laleh");
                    profile.SetValue(ExifTag.XPKeywords, Encoding.UTF32.GetBytes("one two three"));
                    profile.SetValue(ExifTag.XPAuthor, Encoding.UTF32.GetBytes("one"));
                    image.AddProfile(profile);
		   image.Write( media.Name);
                }



Image
thank you
Last edited by laleh on 2019-07-14T11:11:00-07:00, edited 1 time in total.
User avatar
fmw42
Posts: 25562
Joined: 2007-07-02T17:14:51-07:00
Authentication code: 1152
Location: Sunnyvale, California, USA

Re: How to Add JPEG EXIF TAGS (url,keywords..)

Post by fmw42 »

Imagemagick does not currently allow for adding or modifying EXIF data. Use Exiftool.
Post Reply