XML Flash Slideshow v4 Help    |    Support Home    |    DWUser.com Home  Download Help PDF (29MB)    |    Search:

Image Metadata Integration

Image metadata is special data or information that is encoded into an image file.  The information is stored as a part of the image file itself, rather than being stored externally and linked to that image file.  Especially for users of Adobe Bridge, the ability to encode photo information directly into its file may be a convenient option.  

The XML Flash Slideshow v4 includes the option to read this metadata (in XMP [Extensible Metadata Platform] format) from images at runtime.  Currently supported parameters are the Creator field, the Title field, and the Description field.  Harnessing the power of metadata can allow clients to more easily add and remove images with titles and captions in their slideshows, or simply prevent unnecessary duplication of data entry when configuring image titles and captions.

Setting Metadata Parameters in Bridge

For this example, Adobe Bridge will be used to set metadata parameters.  First, browse to and select the desired photo(s) in the Content panel:

Switch to the Metadata panel (Window > Metadata Panel) and expand the IPTC Core section:

The three currently-supported properties have been highlighted -- Creator, Title, and Description.  To edit a field, click in the area to the right of the property name and enter text:

Enter any relevant fields, then select a different photo in the Content panel.  When you browse away from the photo whose metadata was just modified, you may be asked if you wish to save the metadata changes -- be sure to allow this.

Using the Metadata Within a Slideshow

Back within your slideshow, metadata can be used just for specific photos, or used on dynamic text elements to display the available metadata for all photos (including ones from external data sources).  In either case, one or more special replacement values are used to designate the inclusion of metadata:

  • {metadata.creator} - This value will be replaced with the Creator metadata property
  • {metadata.title} - This value will be replaced with the Title metadata property
  • {metadata.description} - This value will be replaced with the Description metadata property
  • Tip: On all of the above properties, a default value (in case the requested value is not yet available or doesn't exist) may be specified in the following format: {metadata.description|Default Value} . After the property name, a pipe character is followed by the default value.

Generally, the easiest way to implement metadata into a gallery is to use the Default Image Title and Default Image Caption gallery properties.  For example, setting a Default Image Title of {metadata.title|} would make the image title in the Caption element (and anywhere else {image.title} is used) display the metadata title if one exists, or an empty string if none exists.

For specific photos, you can use the replacement values in the Caption or Title properties for that given image (in the Image Properties dialog in the slideshow wizard).  For more general inclusion, these replacement values are used in the DynamicText, DynamicScrollableText, or DynamicLinkButton elements. For example, the following DynamicText element is configured to display the available metadata-specified title:

If Some Photos Don't Display Metadata Properly

If metadata doesn't display properly for a few photos in your slideshow but does display properly for other photos, there is usually a simple solution.  When metadata is read from photos, only the first several thousand bytes are searched for metadata by default.  This helps to ensure the best possible performance.  For most photos, the default maximum (up to 10,000 bytes) works fine.  For some of your photos, though, the location of the metadata may be farther along in the files. 

To make your metadata appear for all photos, you'll need to increase this maximum value; do this by right-clicking on the ImagesStandard element in the Layout/Presentation section and selecting Quick Edit Element XML.  The code will look like this:

<ImagesStandard ... />

At the end of the tag, dd the highlighted code as shown:

<ImagesStandard ...  event_creationComplete="import com.dwuser.ss4.core.ImageMetadataUtils; ImageMetadataUtils.maxBytes = 20000;" />

Experiment with what value works for all photos, starting with e.g. 20000.  If that doesn't work, bump it up a bit higher.