Copy link to clipboard
Copied
Does anyone have a script that can be used in cs5 to copy the keywords to the description field?
Thanks
Mark
@Lumigraphics is correct, there is no way in Bridge (in the app or via scripting) to change file Date Created.
ExifTool is your best bet to do the batch edit you want.
ExifTool is an amazing tool but it is command line, which can be cumbersome if you're not used to it.
For what you want to do, I think this would be the command:
exiftool "-filecreatedate<datetimeoriginal" "DIR"
...where DIR is the name of a directory/folder containing the images.
I tested this and it works for me, meaning
...Copy link to clipboard
Copied
My idea is to have a list of all your saved keywords on the left. You would select keywords and they would be added to a "Match" list on the right. These would then be saved to the Description.
Question: Do you want all of your chosen keywords added to all images in the folder or do you want them added only if they exist in each image?
I would imagine that your chosen keywords would not apply to every image otherwise you could just enter them in a single batch edit.
I thought you might want a list of chosen keywords that searched against each image and if a keyword is found, it would be added to the Description. This is possible, but there are some pitfalls.
Can you send a sample image so I can see if you are using Dublin Core subject or Lightroom hierarchicalSubject? If you don;t want to share an image, I can explain how to copy the raw XMP from FileInfo.
Copy link to clipboard
Copied
A 1x1 px crop would suffice as long as it contains the required metadata.
Copy link to clipboard
Copied
gregreser: Thanks for your Post of ideas. I believe our delimma is that Fotoxx does not recognize Adobe/Lightroom's XMP sidecars. But, per my prior post tonight, I think Fotoxx can derive sufficient info merely from metadata fields based on my tests. Yes, I'd like to have Adobe Bridge 2022-selected certain images then be given the specific Hierarchical Keywords per each image/selected images to choose what is copied into the metadata "Description" field -- which becomes Fotoxx's slideshow "Captions-Abstract" displayed field.
Copy link to clipboard
Copied
If sidecars are not recognized then you can't use ANY metadata with RAW files. Other file types (JPEG, TIFF, PNG, etc) have metadata embedded and don't use sidecar files.
Copy link to clipboard
Copied
@X-T4Newbie is going to send me an image file to work with. I'll post the XMP so we can see what we are working with.
Copy link to clipboard
Copied
Summary of "fields" to be displayed during Fotoxx slideshow"
1. Metadata " DateCreated "
2. Text Constant " - "
3. Select one or more metadata hierachical keyword(s) " HierarchicalSubject " copied into metadata " Description " field which Fotoxx ultimately calls its Caption-Abstract slideshow field.
P.S. While I'm copying image file and any XML sidecar files for Fotoxx input, I agree with Lumigraphics that the XML file seems to be ignored -- thus info I want displayed impossible; in fact, looking closer, none of my RAW files appear to be available for slideshow within Fotoxx... just JPGs. Bumber!
Copy link to clipboard
Copied
Here is the XMP from a sample JPG from @X-T4Newbie
It has both dc:subject and lr:hierarchicalSubject. Either one will be easy to work with.
For your RAW files, you might want to create a Bridge workflow to convert them to JPG. The sidecar metadata will be embedded in the JPG and then it will be easier to have the script make the changes to want before the files go to Fotoxx.
<x:xmpmeta xmlns:x="adobe:ns:meta/" x:xmptk="Adobe XMP Core 7.1-c000 79.4d2f597, 2021/09/01-20:51:22 ">
<rdf:RDF xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#">
<rdf:Description rdf:about=""
xmlns:xmp="http://ns.adobe.com/xap/1.0/"
xmlns:photoshop="http://ns.adobe.com/photoshop/1.0/"
xmlns:xmpMM="http://ns.adobe.com/xap/1.0/mm/"
xmlns:stEvt="http://ns.adobe.com/xap/1.0/sType/ResourceEvent#"
xmlns:dc="http://purl.org/dc/elements/1.1/"
xmlns:kbrg="http://ns.adobe.com/bridge/1.0/"
xmlns:exifEX="http://cipa.jp/exif/1.0/"
xmlns:lr="http://ns.adobe.com/lightroom/1.0/"
xmlns:tiff="http://ns.adobe.com/tiff/1.0/"
xmlns:exif="http://ns.adobe.com/exif/1.0/">
<xmp:CreatorTool>M125-20220118</xmp:CreatorTool>
<xmp:ModifyDate>2021-01-01T23:47:29</xmp:ModifyDate>
<xmp:CreateDate>2021-01-01T23:47:29</xmp:CreateDate>
<xmp:MetadataDate>2022-06-29T23:46:35-07:00</xmp:MetadataDate>
<xmp:Label>Second</xmp:Label>
<photoshop:DateCreated>2021-01-01T23:47:29</photoshop:DateCreated>
<photoshop:Headline>Headline - Anne Frank, Amsterdam</photoshop:Headline>
<photoshop:LegacyIPTCDigest>898FECEC844C92CA3C78C128982BFCE4</photoshop:LegacyIPTCDigest>
<photoshop:ColorMode>3</photoshop:ColorMode>
<photoshop:ICCProfile>sRGB IEC61966-2.1</photoshop:ICCProfile>
<xmpMM:DocumentID>C4CEC59D9F874F3EA53E7ED9C853461A</xmpMM:DocumentID>
<xmpMM:OriginalDocumentID>C4CEC59D9F874F3EA53E7ED9C853461A</xmpMM:OriginalDocumentID>
<xmpMM:InstanceID>xmp.iid:9e58a1ff-7fa9-2e44-97db-1f1bbfe0ff45</xmpMM:InstanceID>
<xmpMM:History>
<rdf:Seq>
<rdf:li rdf:parseType="Resource">
<stEvt:action>saved</stEvt:action>
<stEvt:instanceID>xmp.iid:2527ad08-cc97-ca48-bc70-9fd1d2d4f8c1</stEvt:instanceID>
<stEvt:when>2022-06-11T16:17:12-07:00</stEvt:when>
<stEvt:softwareAgent>Adobe Photoshop Camera Raw 14.3</stEvt:softwareAgent>
<stEvt:changed>/metadata</stEvt:changed>
</rdf:li>
<rdf:li rdf:parseType="Resource">
<stEvt:action>saved</stEvt:action>
<stEvt:instanceID>xmp.iid:9e58a1ff-7fa9-2e44-97db-1f1bbfe0ff45</stEvt:instanceID>
<stEvt:when>2022-06-29T23:46:35-07:00</stEvt:when>
<stEvt:softwareAgent>Adobe Photoshop Camera Raw 14.3 (Windows)</stEvt:softwareAgent>
<stEvt:changed>/metadata</stEvt:changed>
</rdf:li>
</rdf:Seq>
</xmpMM:History>
<dc:format>image/jpeg</dc:format>
<dc:subject>
<rdf:Bag>
<rdf:li>Keywords - Netherlands</rdf:li>
<rdf:li>Places</rdf:li>
<rdf:li>Amsterdam</rdf:li>
<rdf:li>People</rdf:li>
<rdf:li>Bob</rdf:li>
<rdf:li>Carol</rdf:li>
<rdf:li>Trips</rdf:li>
<rdf:li>Events</rdf:li>
<rdf:li>1981 Europe</rdf:li>
<rdf:li>Anne Frank</rdf:li>
</rdf:Bag>
</dc:subject>
<dc:title>
<rdf:Alt>
<rdf:li xml:lang="x-default">Anne Frank, Amsterdam</rdf:li>
</rdf:Alt>
</dc:title>
<dc:description>
<rdf:Alt>
<rdf:li xml:lang="x-default">Description - Anne Frank, Amsterdam</rdf:li>
</rdf:Alt>
</dc:description>
<kbrg:InitialEditCaptureTime>2021-01-01T23:47:29Z</kbrg:InitialEditCaptureTime>
<exifEX:PhotographicSensitivity>50</exifEX:PhotographicSensitivity>
<lr:hierarchicalSubject>
<rdf:Bag>
<rdf:li>Places|Netherlands</rdf:li>
<rdf:li>Places</rdf:li>
<rdf:li>Places|Netherlands|Amsterdam</rdf:li>
<rdf:li>People</rdf:li>
<rdf:li>People|Bob</rdf:li>
<rdf:li>People|Carol</rdf:li>
<rdf:li>Events|Trips</rdf:li>
<rdf:li>Events</rdf:li>
<rdf:li>Events|Trips|1981 Europe</rdf:li>
<rdf:li>Places|Netherlands|Amsterdam|Anne Frank</rdf:li>
</rdf:Bag>
</lr:hierarchicalSubject>
<tiff:Make>IMAGE</tiff:Make>
<tiff:Model>M125</tiff:Model>
<tiff:Orientation>1</tiff:Orientation>
<tiff:ImageWidth>3952</tiff:ImageWidth>
<tiff:ImageLength>2736</tiff:ImageLength>
<tiff:PhotometricInterpretation>2</tiff:PhotometricInterpretation>
<tiff:SamplesPerPixel>3</tiff:SamplesPerPixel>
<tiff:BitsPerSample>
<rdf:Seq>
<rdf:li>8</rdf:li>
<rdf:li>8</rdf:li>
<rdf:li>8</rdf:li>
</rdf:Seq>
</tiff:BitsPerSample>
<tiff:XResolution>180/1</tiff:XResolution>
<tiff:YResolution>180/1</tiff:YResolution>
<tiff:ResolutionUnit>2</tiff:ResolutionUnit>
<exif:ExifVersion>0220</exif:ExifVersion>
<exif:ExposureTime>1/110</exif:ExposureTime>
<exif:ShutterSpeedValue>678136/100000</exif:ShutterSpeedValue>
<exif:FNumber>3/1</exif:FNumber>
<exif:ApertureValue>3169925/1000000</exif:ApertureValue>
<exif:ExposureProgram>2</exif:ExposureProgram>
<exif:ISOSpeedRatings>
<rdf:Seq>
<rdf:li>50</rdf:li>
</rdf:Seq>
</exif:ISOSpeedRatings>
<exif:BrightnessValue>100/100</exif:BrightnessValue>
<exif:ExposureBiasValue>0/3</exif:ExposureBiasValue>
<exif:MaxApertureValue>30/10</exif:MaxApertureValue>
<exif:MeteringMode>5</exif:MeteringMode>
<exif:LightSource>0</exif:LightSource>
<exif:Flash rdf:parseType="Resource">
<exif:Fired>False</exif:Fired>
<exif:Return>0</exif:Return>
<exif:Mode>2</exif:Mode>
<exif:Function>False</exif:Function>
<exif:RedEyeMode>False</exif:RedEyeMode>
</exif:Flash>
<exif:FocalLength>50/10</exif:FocalLength>
<exif:SensingMethod>2</exif:SensingMethod>
<exif:FileSource>3</exif:FileSource>
<exif:CustomRendered>0</exif:CustomRendered>
<exif:ExposureMode>0</exif:ExposureMode>
<exif:WhiteBalance>0</exif:WhiteBalance>
<exif:SceneCaptureType>0</exif:SceneCaptureType>
<exif:Sharpness>0</exif:Sharpness>
<exif:DateTimeOriginal>1900-05-31T15:47:29</exif:DateTimeOriginal>
<exif:PixelXDimension>3952</exif:PixelXDimension>
<exif:PixelYDimension>2736</exif:PixelYDimension>
<exif:ColorSpace>1</exif:ColorSpace>
</rdf:Description>
</rdf:RDF>
</x:xmpmeta>
Copy link to clipboard
Copied
@X-T4Newbie is this what you are imagining?
Copy link to clipboard
Copied
Yes, GregReser, I believe that would be quite handy for JPG's only. (Motivation for more dicipline outputting JPG's only to Fotoxx, save my RAW elsewhere!) Only for clarification, step #3 would present HieracicalKewords only list (drill-down order if possible???), not all keywords alphanumerically. For #5, separate image's DateCreated and selected hieracial keyword(s) and with " - " after date for clarity on screen. NICE! Thank you! Thank you! Bob
Copy link to clipboard
Copied
Unfortunately, Bridge scripting eliminated the treeview list (hierarchical list) a few years ago, so we'll have to work with a flat list.
Your example hierarchicalSubject list looks like this:
<lr:hierarchicalSubject>
<rdf:Bag>
<rdf:li>Places|Netherlands</rdf:li>
<rdf:li>Places</rdf:li>
<rdf:li>Places|Netherlands|Amsterdam</rdf:li>
<rdf:li>People</rdf:li>
<rdf:li>People|Bob</rdf:li>
<rdf:li>People|Carol</rdf:li>
<rdf:li>Events|Trips</rdf:li>
<rdf:li>Events</rdf:li>
<rdf:li>Events|Trips|1981 Europe</rdf:li>
<rdf:li>Places|Netherlands|Amsterdam|Anne Frank</rdf:li>
</rdf:Bag>
</lr:hierarchicalSubject>
Here it is without the XML tags for clarity:
Places|Netherlands
Places
Places|Netherlands|Amsterdam
People
People|Bob
People|Carol
Events|Trips
Events
Events|Trips|1981 Europe
Places|Netherlands|Amsterdam|Anne Frank
There's a lot of duplicate values there to deal with.
I thought you would be unlikely to use the hierachical categories like "People". You would mostly want the names or people and places.
From the above hierarchicalSubject list, what would you like to see in a selection list for the script?
How do you want DateCreated to be formatted?
2021
2021-10
2021-01-01
January, 2021
January 1, 2021
What would you like the Description to be in this example?
Copy link to clipboard
Copied
There is a bug in Photoshop and Bridge where dc:subject and lr:hierarchicalKeywords can get out of sync, and the latter can have duplicate entries. I have a Bridge script to dedupe and sync the two on my Dropbox (Keyword Optimizer.)
https://www.dropbox.com/sh/mg817g9a9ymbasi/AADTmXUVxmFfM58bcyYE7yiwa?dl=0
Copy link to clipboard
Copied
From the above hierarchicalSubject list, what would you like to see in a selection list for the script?
(a) If possible, allow first selection item to be "<sp>-<sp>" where <sp> means a space; - means a dash;
(b) To reduce Keword duplication somewhat, I think macro ought to eliminate offering major Keyword category names in list: "Event", "People", "Places", and one extra I added, '"Thing". Thus, remaining HierachicalKeywords would be:
Netherlands
Netherlands|Amsterdam
Bob
Carol
Trips
Trips|1981 Europe
Netherlands|Amsterdam|Anne Frank
(On my Wish List: Maybe Sorted?)
How do you want DateCreated to be formatted?
Always "<sp>2021-01-01<sp>--<sp>" where <sp> means space; -- means double-dash
What would you like the Description to be in this example (see attached; apparently in Fotoxx I’ve got ‘unlimited’ one-line horizonal space for Caption?)
"1981-05-31 -- Trips|1981 Europe - Netherlands|Amsterdam|Anne Frank - Bob – Carol"
Copy link to clipboard
Copied
If you think your Lightroom keywords contain all the values you need, I'll work with that. The keyword list might not be perfetly clean, but it should be workable.
How does this look:
- I'll add a field where you can enter the keywords to be eliminated, because these might change over time.
- I'll add options for date and keyword separators.
- When you double-click a keyword, it will be added to the description box. You will be able to manually edit the description.
- Yes, I can make the first keyword selection item to be "<sp>-<sp>", but you might not need it with the separator option shown below.
Copy link to clipboard
Copied
Good job. Let's give it a spin. I'll be available later tonight to play with it. Tnx, Bob
Copy link to clipboard
Copied
It will take a while to get it working.
Copy link to clipboard
Copied
Greg, that's fine. I just bought a new Samsung Surround SoundBar + wireless Woofer + wireless back speakers (5.1) to replace an incompatible unit with my UHD TV... had for a year but didn't realize wasn't getting full video out through old SS unit until tried streaming. So my plate full too. THANK YOU for all your Adobe Bridge help! Bob
Copy link to clipboard
Copied
@X-T4Newbie here is the script I came up with. Copy it to your Bridge Startup Scripts folder and restart Bridge. Select image file(s) then look in the Tools menu for "Copy Select Keywords to Description". When you select it you should see this window:
Some features:
Notes:
Download the script from Dropbox. You should be able to do it without creating an account. If not, let me know.
https://www.dropbox.com/s/tlk6a2n2qxz3su6/Copy_Select_Keywords_to_Description_2022-07-07.jsx?dl=0
Copy link to clipboard
Copied
Hi Greg, this looks very, very good! Easy to execute! I'm not certain which Keyword group(s) to designate up front... but my further practice will help in understanding.
One issue we have is "Date Created": there are two (1) in IPTC Core which you used in code (I presume written by a camera) and (2) in File Properties which is modified by Adobe Bridge's "Edit Capture Time" commsnd (which I use to properly backdate scanned inages.) I think we need to add query up front asking user which "Date Created" desired to be prepended in Description field for selected bunch of images. It's possible two "Date Created" will be equal if image(s) were never Capture Time edited... but not totally certain. What do you think? THANK YOU for all your hard work Java Script coding for me! Bob
Copy link to clipboard
Copied
If you have duplicate keywords, use (or incorporate) my Keyword Optimizer script, which removes duplicates.
Copy link to clipboard
Copied
@Lumigraphics your Keyword Optimizer was very helpful and I based my de-duping and sorting on it (Thanks for making and sharing so many great scripts). I think the clean keyword list is pretty good, given the complexity of the source keywords. The duplicates are really cases when a single word is also part of a hierarchy. I think that's OK, because the user might decide to use the single word in some cases and the hierarchy in others.
Example cleaned list:
Amsterdam
Anne Frank
Netherlands
Netherlands|Amsterdam
Netherlands|Amsterdam|Anne Frank
Copy link to clipboard
Copied
@X-T4Newbie Yes, I think it would be a good idea to provide a choice of original date - probably exif:DateTimeOriginal and photoshop:DateCreated. In most cases these are the same for born digital images, but not always for scanned images, especially if the date was edited later.
IPTC reccomends photoshop:DateCreated for the original photo date, so it's worth including, in case another person using the script prefers it.
exif:DateTimeOriginal is used by the Bridge "Edit Capture Time" command, it would make sense to include it as an option.
Side note: there are endless debates about the definition of metadata standards. One could argue that "Capture Time" is for the scan date of an older photo. There could all kinds of reasons to follow this or not. I think it's fine to use it for the date of the orignal photo, especially since Bridge provides an easy way to edit it.
Copy link to clipboard
Copied
Thanks, Greg, for giving the user the option to select either "photoshop:DateCreated" and "exif:DateTimeOriginal" Date Created. Hopefully, one will be clearly designated something like "this one out-of-camera"; "this one editable." I'd get them confused! : Yes, "Capture Time" is in the eyes of the beholder!
Copy link to clipboard
Copied
@Bob251702024mhq is @X-T4Newbie. Looks like I blew it! Bob
Copy link to clipboard
Copied
No worries, now we know your secret identity.
Which do you prefer?
Copy link to clipboard
Copied
X-T4Newbie.... as I still am with my Fugi XT-4 camera. Had it down pretty well with Sony A6000 mirrorless.