0

I am using commons.imaging library to add metadata to image by using exifDirectory.add() and exifDirectory.removeField() functions. But I am not able to add customized tag in image. Can someone help me out with this. Instead of "ExifTagConstants.EXIF_TAG_EXPOSURE" I want my own custom title

final JpegImageMetadata metadata =(JpegImageMetadata)Imaging.getMetadata(jpegImageFile);
final JpegImageMetadata jpegMetadata = metadata;
final TiffOutputDirectory exifDirectory = outputSet.getOrCreateExifDirectory();              
exifDirectory.removeField(ExifTagConstants.EXIF_TAG_EXPOSURE);
exifDirectory.add(ExifTagConstants.EXIF_TAG_EXPOSURE, "P100111");
Pang
  • 9,564
  • 146
  • 81
  • 122
Aditya
  • 1
  • 1
  • See this [thread](https://stackoverflow.com/questions/6495518/writing-image-metadata-in-java-preferably-png) it could help you – Amin Bahiraee Feb 20 '18 at 07:20
  • _"I am not able to add customized tag in image"_ -- what actually happens? How can you tell? How do you know? What makes you think you can change the title associated with a tag? – Jim Garrison Feb 20 '18 at 07:24
  • I have some information which I need to bind with image metadata with title and the value.Ex: -->, -->. For that reason came up with a solution to append new metatag in image. So is it possible to bind custom metadata tag like this ? – Aditya Feb 20 '18 at 09:19

0 Answers0