Name
cx:metadata-extractor — Extract metadata from images.
Synopsis
<p:declare-step
type
="
cx:metadata-extractor
"
xmlns:cx
="
http://xmlcalabash.com/ns/extensions
"
>
<p:output
port
="
result
"
/>
<p:option
name
="
href
"
/>
<!--
anyURI -->
</p:declare-step>
Description
The cx:metadata-extractor
step returns an XML description of
the metadata associated with an image. For example, the metadata associated with
the image in
Figure 1, “Amaryllis” is shown in
Example 2, “Amaryllis metadata”.
In practice, the amount of metadata associated with an image is almost arbitrarily large. Example 3, “Digital Camera metadata”, for example, shows the metadata associated with an image from a digital camera.
The cx:metadata-extractor
step relies on
Drew Noakes’
Metadata Extractor
libraries. If the image identified is not a JPEG image, then the underlying Java
Image
properties are returned, if possible. For example, a PNG image
might return results such as those shown in Example 4, “PNG metadata”.
The “Exif Version” of “0” is returned to identify this case.
Implementation
This step is implemented by the xmlcalabash1-metadata-extractor module. The jar file from that project must be in the class path in order to use this step.