Project

General

Profile

RE: Identified (but un-delete-able) XMP key data. ยป properties.cpp.c

Steve Wright, 11 Feb 2010 23:41

 
1
// ***************************************************************** -*- C++ -*-
2
/*
3
 * Copyright (C) 2004-2009 Andreas Huggel <ahuggel@gmx.net>
4
 *
5
 * This program is part of the Exiv2 distribution.
6
 *
7
 * This program is free software; you can redistribute it and/or
8
 * modify it under the terms of the GNU General Public License
9
 * as published by the Free Software Foundation; either version 2
10
 * of the License, or (at your option) any later version.
11
 *
12
 * This program is distributed in the hope that it will be useful,
13
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
14
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
15
 * GNU General Public License for more details.
16
 *
17
 * You should have received a copy of the GNU General Public License
18
 * along with this program; if not, write to the Free Software
19
 * Foundation, Inc., 51 Franklin Street, 5th Floor, Boston, MA 02110-1301 USA.
20
 */
21
/*
22
  File:      properties.cpp
23
  Version:   $Rev: 1977 $
24
  Author(s): Andreas Huggel (ahu) <ahuggel@gmx.net>
25
             Gilles Caulier (cgilles) <caulier dot gilles at gmail dot com>
26
  History:   13-July-07, ahu: created
27
 */
28
// *****************************************************************************
29
#include "rcsid.hpp"
30
EXIV2_RCSID("@(#) $Id: properties.cpp 1977 2009-12-28 14:47:58Z ahuggel $")
31

    
32
// *****************************************************************************
33
// included header files
34
#include "properties.hpp"
35
#include "tags.hpp"
36
#include "error.hpp"
37
#include "types.hpp"
38
#include "value.hpp"
39
#include "metadatum.hpp"
40
#include "i18n.h"                // NLS support.
41
#include "xmp.hpp"
42

    
43
#include <iostream>
44
#include <iomanip>
45
#include <sstream>
46
#include <cstring>
47
#include <cstdlib>
48

    
49
// *****************************************************************************
50
namespace {
51

    
52
    //! Struct used in the lookup table for pretty print functions
53
    struct XmpPrintInfo {
54
        //! Comparison operator for key
55
        bool operator==(const std::string& key) const
56
        {
57
            return 0 == strcmp(key_, key.c_str());
58
        }
59

    
60
        const char* key_;               //!< XMP key
61
        Exiv2::PrintFct printFct_;             //!< Print function
62
    };
63

    
64
}
65

    
66
// *****************************************************************************
67
// class member definitions
68
namespace Exiv2 {
69

    
70
    //! @cond IGNORE
71
    extern const XmpPropertyInfo xmpDcInfo[];
72
    extern const XmpPropertyInfo xmpDigikamInfo[];
73
    extern const XmpPropertyInfo xmpXmpInfo[];
74
    extern const XmpPropertyInfo xmpXmpRightsInfo[];
75
    extern const XmpPropertyInfo xmpXmpMMInfo[];
76
    extern const XmpPropertyInfo xmpXmpBJInfo[];
77
    extern const XmpPropertyInfo xmpXmpTPgInfo[];
78
    extern const XmpPropertyInfo xmpXmpDMInfo[];
79
    extern const XmpPropertyInfo xmpMicrosoftInfo[];
80
    extern const XmpPropertyInfo xmpPdfInfo[];
81
    extern const XmpPropertyInfo xmpPhotoshopInfo[];
82
    extern const XmpPropertyInfo xmpCrsInfo[];
83
    extern const XmpPropertyInfo xmpTiffInfo[];
84
    extern const XmpPropertyInfo xmpExifInfo[];
85
    extern const XmpPropertyInfo xmpAuxInfo[];
86
    extern const XmpPropertyInfo xmpIptcInfo[];
87
    extern const XmpPropertyInfo xmpIptcExtInfo[];
88
    extern const XmpPropertyInfo xmpPlusInfo[];
89
    extern const XmpPropertyInfo XmpmediaproInfo[];
90
    extern const XmpPropertyInfo XmpexpressionmediaInfo[];
91

    
92
    extern const XmpNsInfo xmpNsInfo[] = {
93
        // Schemas   -   NOTE: Schemas which the XMP-SDK doesn't know must be registered in XmpParser::initialize - Todo: Automate this
94
        { "http://purl.org/dc/elements/1.1/",             "dc",             xmpDcInfo,        N_("Dublin Core schema")                        },
95
        { "http://www.digikam.org/ns/1.0/",               "digiKam",        xmpDigikamInfo,   N_("digiKam Photo Management schema")           },
96
        { "http://ns.adobe.com/xap/1.0/",                 "xmp",            xmpXmpInfo,       N_("XMP Basic schema")                          },
97
        { "http://ns.adobe.com/xap/1.0/rights/",          "xmpRights",      xmpXmpRightsInfo, N_("XMP Rights Management schema")              },
98
        { "http://ns.adobe.com/xap/1.0/mm/",              "xmpMM",          xmpXmpMMInfo,     N_("XMP Media Management schema")               },
99
        { "http://ns.adobe.com/xap/1.0/bj/",              "xmpBJ",          xmpXmpBJInfo,     N_("XMP Basic Job Ticket schema")               },
100
        { "http://ns.adobe.com/xap/1.0/t/pg/",            "xmpTPg",         xmpXmpTPgInfo,    N_("XMP Paged-Text schema")                     },
101
        { "http://ns.adobe.com/xmp/1.0/DynamicMedia/",    "xmpDM",          xmpXmpDMInfo,     N_("XMP Dynamic Media schema")                  },
102
        { "http://ns.microsoft.com/photo/1.0/",           "MicrosoftPhoto", xmpMicrosoftInfo, N_("Microsoft Photo schema")                    },
103
        { "http://ns.adobe.com/pdf/1.3/",                 "pdf",            xmpPdfInfo,       N_("Adobe PDF schema")                          },
104
        { "http://ns.adobe.com/photoshop/1.0/",           "photoshop",      xmpPhotoshopInfo, N_("Adobe photoshop schema")                    },
105
        { "http://ns.adobe.com/camera-raw-settings/1.0/", "crs",            xmpCrsInfo,       N_("Camera Raw schema")                         },
106
        { "http://ns.adobe.com/tiff/1.0/",                "tiff",           xmpTiffInfo,      N_("Exif Schema for TIFF Properties")           },
107
        { "http://ns.adobe.com/exif/1.0/",                "exif",           xmpExifInfo,      N_("Exif schema for Exif-specific Properties")  },
108
        { "http://ns.adobe.com/exif/1.0/aux/",            "aux",            xmpAuxInfo,       N_("Exif schema for Additional Exif Properties")},
109
        { "http://iptc.org/std/Iptc4xmpCore/1.0/xmlns/",  "iptc",           xmpIptcInfo,      N_("IPTC Core schema")                          },
110
                                                                                             // NOTE: 'Iptc4xmpCore' is just too long
111
        { "http://iptc.org/std/Iptc4xmpExt/2008-02-29/",  "iptcExt",        xmpIptcExtInfo,   N_("IPTC Extension schema")                     },
112
                                                                                             // NOTE: It really should be 'Iptc4xmpExt' but following example above
113
        { "http://ns.useplus.org/ldf/xmp/1.0/",           "plus",           xmpPlusInfo,      N_("PLUS License Data Format schema")           },
114

    
115
        // Structures
116
        { "http://ns.adobe.com/xap/1.0/g/",                   "xapG",    0, N_("Colorant structure")           },
117
        { "http://ns.adobe.com/xap/1.0/sType/Dimensions#",    "stDim",   0, N_("Dimensions structure")         },
118
        { "http://ns.adobe.com/xap/1.0/sType/Font#",          "stFnt",   0, N_("Font structure")               },
119
        { "http://ns.adobe.com/xap/1.0/g/img/",               "xapGImg", 0, N_("Thumbnail structure")          },
120
        { "http://ns.adobe.com/xap/1.0/sType/ResourceEvent#", "stEvt",   0, N_("Resource Event structure")     },
121
        { "http://ns.adobe.com/xap/1.0/sType/ResourceRef#",   "stRef",   0, N_("ResourceRef structure")        },
122
        { "http://ns.adobe.com/xap/1.0/sType/Version#",       "stVer",   0, N_("Version structure")            },
123
        { "http://ns.adobe.com/xap/1.0/sType/Job#",           "stJob",   0, N_("Basic Job/Workflow structure") },
124

    
125
        // Qualifiers
126
        { "http://ns.adobe.com/xmp/Identifier/qual/1.0/", "xmpidq", 0, N_("Qualifier for xmp:Identifier") }
127
    };
128

    
129
    extern const XmpPropertyInfo xmpDcInfo[] = {
130
        { "contributor",      N_("Contributor"),      "bag ProperName",  xmpBag,       xmpExternal, N_("Contributors to the resource (other than the authors).")                               },
131
        { "coverage",         N_("Coverage"),         "Text",            xmpText,      xmpExternal, N_("The spatial or temporal topic of the resource, the spatial applicability of the "
132
                                                                                                   "resource, or the jurisdiction under which the resource is relevant.")                      },
133
        { "creator",          N_("Creator"),          "seq ProperName",  xmpSeq,       xmpExternal, N_("The authors of the resource (listed in order of precedence, if significant).")         },
134
        { "date",             N_("Date"),             "seq Date",        xmpSeq,       xmpExternal, N_("Date(s) that something interesting happened to the resource.")                         },
135
        { "description",      N_("Description"),      "Lang Alt",        langAlt,      xmpExternal, N_("A textual description of the content of the resource. Multiple values may be "
136
                                                                                                       "present for different languages.")                                                     },
137
        { "format",           N_("Format"),           "MIMEType",        xmpText,      xmpInternal, N_("The file format used when saving the resource. Tools and applications should set "
138
                                                                                                       "this property to the save format of the data. It may include appropriate qualifiers.") },
139
        { "identifier",       N_("Identifier"),       "Text",            xmpText,      xmpExternal, N_("Unique identifier of the resource. Recommended best practice is to identify the "
140
                                                                                                   "resource by means of a string conforming to a formal identification system.")              },
141
        { "language",         N_("Language"),         "bag Locale",      xmpBag,       xmpInternal, N_("An unordered array specifying the languages used in the resource.")                    },
142
        { "publisher",        N_("Publisher"),        "bag ProperName",  xmpBag,       xmpExternal, N_("An entity responsible for making the resource available. Examples of a Publisher "
143
                                                                                                   "include a person, an organization, or a service. Typically, the name of a Publisher "
144
                                                       "should be used to indicate the entity.")                                               },
145
        { "relation",         N_("Relation"),         "bag Text",        xmpBag,       xmpInternal, N_("Relationships to other documents. Recommended best practice is to identify the "
146
                                                                                                   "related resource by means of a string conforming to a formal identification system.")      },
147
        { "rights",           N_("Rights"),           "Lang Alt",        langAlt,      xmpExternal, N_("Informal rights statement, selected by language. Typically, rights information "
148
                                                                                                   "includes a statement about various property rights associated with the resource, "
149
                                                       "including intellectual property rights.")                                              },
150
        { "source",           N_("Source"),           "Text",            xmpText,      xmpExternal, N_("Unique identifier of the work from which this resource was derived.")                  },
151
        { "subject",          N_("Subject"),          "bag Text",        xmpBag,       xmpExternal, N_("An unordered array of descriptive phrases or keywords that specify the topic of the "
152
                                                                                                       "content of the resource.")                                                             },
153
        { "title",            N_("Title"),            "Lang Alt",        langAlt,      xmpExternal, N_("The title of the document, or the name given to the resource. Typically, it will be "
154
                                                                                                       "a name by which the resource is formally known.")                                      },
155
        { "type",             N_("Type"),             "bag open Choice", xmpBag,       xmpExternal, N_("A document type; for example, novel, poem, or working paper.")                         },
156
        // End of list marker
157
        { 0, 0, 0, invalidTypeId, xmpInternal, 0 }
158
    };
159

    
160
    extern const XmpPropertyInfo xmpDigikamInfo[] = {
161
        { "TagsList",               N_("Tags List"),                 "seq Text", xmpSeq,  xmpExternal, N_("The list of complete tags path as string. The path hierarchy is separated by '/' character (ex.: \"City/Paris/Monument/Eiffel Tower\".") },
162
        { "CaptionsAuthorNames",    N_("Captions Author Names"),     "Lang Alt", langAlt, xmpExternal, N_("The list of all captions author names for each language alternative captions set in standard XMP tags.") },
163
        { "CaptionsDateTimeStamps", N_("Captions Date Time Stamps"), "Lang Alt", langAlt, xmpExternal, N_("The list of all captions date time stamps for each language alternative captions set in standard XMP tags.") },
164

    
165
        // End of list marker
166
        { 0, 0, 0, invalidTypeId, xmpInternal, 0 }
167
    };
168

    
169
    extern const XmpPropertyInfo xmpXmpInfo[] = {
170
        { "Advisory",         N_("Advisory"),         "bag XPath",                xmpBag,    xmpExternal, N_("An unordered array specifying properties that were edited outside the authoring "
171
                                                                                                             "application. Each item should contain a single namespace and XPath separated by "
172
                                                                                                             "one ASCII space (U+0020).") },
173
        { "BaseURL",          N_("Base URL"),         "URL",                      xmpText,   xmpInternal, N_("The base URL for relative URLs in the document content. If this document contains "
174
                                                                                                             "Internet links, and those links are relative, they are relative to this base URL. "
175
                                                                                                             "This property provides a standard way for embedded relative URLs to be interpreted "
176
                                                                                                             "by tools. Web authoring tools should set the value based on their notion of where "
177
                                                                                                             "URLs will be interpreted.") },
178
        { "CreateDate",       N_("Create Date"),      "Date",                     xmpText,   xmpInternal, N_("The date and time the resource was originally created.") },
179
        { "CreatorTool",      N_("Creator Tool"),     "AgentName",                xmpText,   xmpInternal, N_("The name of the first known tool used to create the resource. If history is "
180
                                                                                                             "present in the metadata, this value should be equivalent to that of "
181
                                                                                                             "xmpMM:History's softwareAgent property.") },
182
        { "Identifier",       N_("Identifier"),       "bag Text",                 xmpBag,    xmpExternal, N_("An unordered array of text strings that unambiguously identify the resource within "
183
                                                                                                             "a given context. An array item may be qualified with xmpidq:Scheme to denote the "
184
                                                                                                             "formal identification system to which that identifier conforms. Note: The "
185
                                                                                                             "dc:identifier property is not used because it lacks a defined scheme qualifier and "
186
                                                                                                             "has been defined in the XMP Specification as a simple (single-valued) property.") },
187
        { "Label",            N_("Label"),            "Text",                     xmpText,   xmpExternal, N_("A word or short phrase that identifies a document as a member of a user-defined "
188
                                                                                                             "collection. Used to organize documents in a file browser.") },
189
        { "MetadataDate",     N_("Metadata Date"),    "Date",                     xmpText,   xmpInternal, N_("The date and time that any metadata for this resource was last changed. It should "
190
                                                                                                             "be the same as or more recent than xmp:ModifyDate.") },
191
        { "ModifyDate",       N_("Modify Date"),      "Date",                     xmpText,   xmpInternal, N_("The date and time the resource was last modified. Note: The value of this property "
192
                                                                                                             "is not necessarily the same as the file's system modification date because it is "
193
                                                                                                             "set before the file is saved.") },
194
        { "Nickname",         N_("Nickname"),         "Text",                     xmpText,   xmpExternal, N_("A short informal name for the resource.") },
195
        { "Rating",           N_("Rating"),           "Closed Choice of Integer", xmpText,   xmpExternal, N_("A number that indicates a document's status relative to other documents, "
196
                                                                                                             "used to organize documents in a file browser. Values are user-defined within an "
197
                                                                                                             "application-defined range.") },
198
        { "Thumbnails",       N_("Thumbnails"),       "alt Thumbnail",            undefined, xmpInternal, N_("An alternative array of thumbnail images for a file, which can differ in "
199
                                                                                                             "characteristics such as size or image encoding.") },
200
        // End of list marker
201
        { 0, 0, 0, invalidTypeId, xmpInternal, 0 }
202
    };
203

    
204
    extern const XmpPropertyInfo xmpXmpRightsInfo[] = {
205
        { "Certificate",      N_("Certificate"),   "URL",            xmpText,       xmpExternal, N_("Online rights management certificate.") },
206
        { "Marked",           N_("Marked"),        "Boolean",        xmpText,       xmpExternal, N_("Indicates that this is a rights-managed resource.") },
207
        { "Owner",            N_("Owner"),         "bag ProperName", xmpBag,        xmpExternal, N_("An unordered array specifying the legal owner(s) of a resource.") },
208
        { "UsageTerms",       N_("Usage Terms"),   "Lang Alt",       langAlt,       xmpExternal, N_("Text instructions on how a resource can be legally used.") },
209
        { "WebStatement",     N_("Web Statement"), "URL",            xmpText,       xmpExternal, N_("The location of a web page describing the owner and/or rights statement for this resource.") },
210
        // End of list marker
211
        { 0, 0, 0, invalidTypeId, xmpInternal, 0 }
212
    };
213

    
214
    extern const XmpPropertyInfo xmpXmpMMInfo[] = {
215
        { "DerivedFrom",      N_("Derived From"),      "ResourceRef",       xmpText,    xmpInternal, N_("A reference to the original document from which this one is derived. It is a "
216
                                                                                                        "minimal reference; missing components can be assumed to be unchanged. For example, "
217
                                                                                                        "a new version might only need to specify the instance ID and version number of the "
218
                                                                                                        "previous version, or a rendition might only need to specify the instance ID and "
219
                                                                                                        "rendition class of the original.") },
220
        { "DocumentID",       N_("Document ID"),       "URI",               xmpText,    xmpInternal, N_("The common identifier for all versions and renditions of a document. It should be "
221
                                                                                                        "based on a UUID; see Document and Instance IDs below.") },
222
        { "History",          N_("History"),           "seq ResourceEvent", xmpText,    xmpInternal, N_("An ordered array of high-level user actions that resulted in this resource. It is "
223
                                                                                                        "intended to give human readers a general indication of the steps taken to make the "
224
                                                                                                        "changes from the previous version to this one. The list should be at an abstract "
225
                                                                                                        "level; it is not intended to be an exhaustive keystroke or other detailed history.") },
226
        { "InstanceID",       N_("Instance ID"),       "URI",               xmpText,    xmpInternal, N_("An identifier for a specific incarnation of a document, updated each time a file "
227
                                                                                                        "is saved. It should be based on a UUID; see Document and Instance IDs below.") },
228
        { "ManagedFrom",      N_("Managed From"),      "ResourceRef",       xmpText,    xmpInternal, N_("A reference to the document as it was prior to becoming managed. It is set when a "
229
                                                                                                        "managed document is introduced to an asset management system that does not "
230
                                                                                                        "currently own it. It may or may not include references to different management systems.") },
231
        { "Manager",          N_("Manager"),           "AgentName",         xmpText,    xmpInternal, N_("The name of the asset management system that manages this resource. Along with "
232
                                                                                                        "xmpMM: ManagerVariant, it tells applications which asset management system to "
233
                                                                                                        "contact concerning this document.") },
234
        { "ManageTo",         N_("Manage To"),         "URI",               xmpText,    xmpInternal, N_("A URI identifying the managed resource to the asset management system; the presence "
235
                                                                                                        "of this property is the formal indication that this resource is managed. The form "
236
                                                                                                        "and content of this URI is private to the asset management system.") },
237
        { "ManageUI",         N_("Manage UI"),         "URI",               xmpText,    xmpInternal, N_("A URI that can be used to access information about the managed resource through a "
238
                                                                                                        "web browser. It might require a custom browser plug-in.") },
239
        { "ManagerVariant",   N_("Manager Variant"),   "Text",              xmpText,    xmpInternal, N_("Specifies a particular variant of the asset management system. The format of this "
240
                                                                                                        "property is private to the specific asset management system.") },
241
        { "RenditionClass",   N_("Rendition Class"),   "RenditionClass",    xmpText,    xmpInternal, N_("The rendition class name for this resource. This property should be absent or set "
242
                                                                                                        "to default for a document version that is not a derived rendition.") },
243
        { "RenditionParams",  N_("Rendition Params"),  "Text",              xmpText,    xmpInternal, N_("Can be used to provide additional rendition parameters that are too complex or "
244
                                                                                                        "verbose to encode in xmpMM: RenditionClass.") },
245
        { "VersionID",        N_("Version ID"),        "Text",              xmpText,    xmpInternal, N_("The document version identifier for this resource. Each version of a document gets "
246
                                                                                                        "a new identifier, usually simply by incrementing integers 1, 2, 3 . . . and so on. "
247
                                                                                                        "Media management systems can have other conventions or support branching which "
248
                                                                                                        "requires a more complex scheme.") },
249
        { "Versions",         N_("Versions"),          "seq Version",       xmpText,    xmpInternal, N_("The version history associated with this resource. Entry [1] is the oldest known "
250
                                                                                                        "version for this document, entry [last()] is the most recent version. Typically, a "
251
                                                                                                        "media management system would fill in the version information in the metadata on "
252
                                                                                                        "check-in. It is not guaranteed that a complete history  versions from the first to "
253
                                                                                                        "this one will be present in the xmpMM:Versions property. Interior version information "
254
                                                                                                        "can be compressed or eliminated and the version history can be truncated at some point.") },
255
        { "LastURL",          N_("Last URL"),          "URL",               xmpText,    xmpInternal, N_("Deprecated for privacy protection.") },
256
        { "RenditionOf",      N_("Rendition Of"),      "ResourceRef",       xmpText,    xmpInternal, N_("Deprecated in favor of xmpMM:DerivedFrom. A reference to the document of which this is "
257
                                                                                                        "a rendition.") },
258
        { "SaveID",           N_("Save ID"),           "Integer",           xmpText,    xmpInternal, N_("Deprecated. Previously used only to support the xmpMM:LastURL property.") },
259
        // End of list marker
260
        { 0, 0, 0, invalidTypeId, xmpInternal, 0 }
261
    };
262

    
263
    extern const XmpPropertyInfo xmpXmpBJInfo[] = {
264
        { "JobRef",           N_("Job Reference"),     "bag Job",   xmpText,    xmpExternal, N_("References an external job management file for a job process in which the document is being used. Use of job "
265
                                                                                                "names is under user control. Typical use would be to identify all documents that are part of a particular job or contract. "
266
                                                                                                "There are multiple values because there can be more than one job using a particular document at any time, and it can "
267
                                                                                                "also be useful to keep historical information about what jobs a document was part of previously.") },
268
        // End of list marker
269
        { 0, 0, 0, invalidTypeId, xmpInternal, 0 }
270
    };
271

    
272
    extern const XmpPropertyInfo xmpXmpTPgInfo[] = {
273
        { "MaxPageSize",      N_("Maximum Page Size"), "Dimensions",   xmpText,    xmpInternal, N_("The size of the largest page in the document (including any in contained documents).") },
274
        { "NPages",           N_("Number of Pages"),   "Integer",      xmpText,    xmpInternal, N_("The number of pages in the document (including any in contained documents).") },
275
        { "Fonts",            N_("Fonts"),             "bag Font",     xmpText,    xmpInternal, N_("An unordered array of fonts that are used in the document (including any in contained documents).") },
276
        { "Colorants",        N_("Colorants"),         "seq Colorant", xmpText,    xmpInternal, N_("An ordered array of colorants (swatches) that are used in the document (including any in contained documents).") },
277
        { "PlateNames",       N_("Plate Names"),       "seq Text",     xmpSeq,     xmpInternal, N_("An ordered array of plate names that are needed to print the document (including any in contained documents).") },
278
        // End of list marker
279
        { 0, 0, 0, invalidTypeId, xmpInternal, 0 }
280
    };
281

    
282
    extern const XmpPropertyInfo xmpXmpDMInfo[] = {
283
        { "projectRef",                   N_("Project Reference"),                "ProjectLink",           xmpText, xmpInternal, N_("A reference to the project that created this file.") },
284
        { "videoFrameRate",               N_("Video Frame Rate"),                 "open Choice of Text",   xmpText, xmpInternal, N_("The video frame rate. One of: 24, NTSC, PAL.") },
285
        { "videoFrameSize",               N_("Video Frame Size"),                 "Dimensions",            xmpText, xmpInternal, N_("The frame size. For example: w:720, h: 480, unit:pixels") },
286
        { "videoPixelAspectRatio",        N_("Video Pixel Aspect Ratio"),         "Rational",              xmpText, xmpInternal, N_("The aspect ratio, expressed as ht/wd. For example: \"648/720\" = 0.9") },
287
        { "videoPixelDepth",              N_("Video Pixel Depth"),                "closed Choice of Text", xmpText, xmpInternal, N_("The size in bits of each color component of a pixel. Standard Windows 32-bit "
288
                                                                                                                                    "pixels have 8 bits per component. One of: 8Int, 16Int, 32Int, 32Float.") },
289
        { "videoColorSpace",              N_("Video Color Space"),                "closed Choice of Text", xmpText, xmpInternal, N_("The color space. One of: sRGB (used by Photoshop), CCIR-601 (used for NTSC), "
290
                                                                                                                                    "CCIR-709 (used for HD).") },
291
        { "videoAlphaMode",               N_("Video Alpha Mode"),                 "closed Choice of Text", xmpText, xmpExternal, N_("The alpha mode. One of: straight, pre-multiplied.") },
292
        { "videoAlphaPremultipleColor",   N_("Video Alpha Premultiple Color"),    "Colorant",              xmpText, xmpExternal, N_("A color in CMYK or RGB to be used as the pre-multiple color when "
293
                                                                                                                                    "alpha mode is pre-multiplied.") },
294
        { "videoAlphaUnityIsTransparent", N_("Video Alpha Unity Is Transparent"), "Boolean",               xmpText, xmpInternal, N_("When true, unity is clear, when false, it is opaque.") },
295
        { "videoCompressor",              N_("Video Compressor"),                 "Text",                  xmpText, xmpInternal, N_("Video compression used. For example, jpeg.") },
296
        { "videoFieldOrder",              N_("Video Field Order"),                "closed Choice of Text", xmpText, xmpInternal, N_("The field order for video. One of: Upper, Lower, Progressive.") },
297
        { "pullDown",                     N_("Pull Down"),                        "closed Choice of Text", xmpText, xmpInternal, N_("The sampling phase of film to be converted to video (pull-down). One of: "
298
                                                                                                                                    "WSSWW, SSWWW, SWWWS, WWWSS, WWSSW, WSSWW_24p, SSWWW_24p, SWWWS_24p, WWWSS_24p, WWSSW_24p.") },
299
        { "audioSampleRate",              N_("Audio Sample Rate"),                "Integer",               xmpText, xmpInternal, N_("The audio sample rate. Can be any value, but commonly 32000, 41100, or 48000.") },
300
        { "audioSampleType",              N_("Audio Sample Type"),                "closed Choice of Text", xmpText, xmpInternal, N_("The audio sample type. One of: 8Int, 16Int, 32Int, 32Float.") },
301
        { "audioChannelType",             N_("Audio Channel Type"),               "closed Choice of Text", xmpText, xmpInternal, N_("The audio channel type. One of: Mono, Stereo, 5.1, 7.1.") },
302
        { "audioCompressor",              N_("Audio Compressor"),                 "Text",                  xmpText, xmpInternal, N_("The audio compression used. For example, MP3.") },
303
        { "speakerPlacement",             N_("Speaker Placement"),                "Text",                  xmpText, xmpExternal, N_("A description of the speaker angles from center front in degrees. For example: "
304
                                                                                                                                    "\"Left = -30, Right = 30, Center = 0, LFE = 45, Left Surround = -110, Right Surround = 110\"") },
305
        { "fileDataRate",                 N_("File Data Rate"),                   "Rational",              xmpText, xmpInternal, N_("The file data rate in megabytes per second. For example: \"36/10\" = 3.6 MB/sec") },
306
        { "tapeName",                     N_("Tape Name"),                        "Text",                  xmpText, xmpExternal, N_("The name of the tape from which the clip was captured, as set during the capture process.") },
307
        { "altTapeName",                  N_("Alternative Tape Name"),            "Text",                  xmpText, xmpExternal, N_("An alternative tape name, set via the project window or timecode dialog in Premiere. "
308
                                                                                                                                    "If an alternative name has been set and has not been reverted, that name is displayed.") },
309
        { "startTimecode",                N_("Start Time Code"),                  "Timecode",              xmpText, xmpInternal, N_("The timecode of the first frame of video in the file, as obtained from the device control.") },
310
        { "altTimecode",                  N_("Alternative Time code"),            "Timecode",              xmpText, xmpExternal, N_("A timecode set by the user. When specified, it is used instead of the startTimecode.") },
311
        { "duration",                     N_("Duration"),                         "Time",                  xmpText, xmpInternal, N_("The duration of the media file.") },
312
        { "scene",                        N_("Scene"),                            "Text",                  xmpText, xmpExternal, N_("The name of the scene.") },
313
        { "shotName",                     N_("Shot Name"),                        "Text",                  xmpText, xmpExternal, N_("The name of the shot or take.") },
314
        { "shotDate",                     N_("Shot Date"),                        "Date",                  xmpText, xmpExternal, N_("The date and time when the video was shot.") },
315
        { "shotLocation",                 N_("Shot Location"),                    "Text",                  xmpText, xmpExternal, N_("The name of the location where the video was shot. For example: \"Oktoberfest, Munich Germany\" "
316
                                                                                                                                    "For more accurate positioning, use the EXIF GPS values.") },
317
        { "logComment",                   N_("Log Comment"),                      "Text",                  xmpText, xmpExternal, N_("User's log comments.") },
318
        { "markers",                      N_("Markers"),                          "seq Marker",            xmpText, xmpInternal, N_("An ordered list of markers") },
319
        { "contributedMedia",             N_("Contributed Media"),                "bag Media",             xmpText, xmpInternal, N_("An unordered list of all media used to create this media.") },
320
        { "absPeakAudioFilePath",         N_("Absolute Peak Audio File Path"),    "URI",                   xmpText, xmpInternal, N_("The absolute path to the file's peak audio file. If empty, no peak file exists.") },
321
        { "relativePeakAudioFilePath",    N_("Relative Peak Audio File Path"),    "URI",                   xmpText, xmpInternal, N_("The relative path to the file's peak audio file. If empty, no peak file exists.") },
322
        { "videoModDate",                 N_("Video Modified Date"),              "Date",                  xmpText, xmpInternal, N_("The date and time when the video was last modified.") },
323
        { "audioModDate",                 N_("Audio Modified Date"),              "Date",                  xmpText, xmpInternal, N_("The date and time when the audio was last modified.") },
324
        { "metadataModDate",              N_("Metadata Modified Date"),           "Date",                  xmpText, xmpInternal, N_("The date and time when the metadata was last modified.") },
325
        { "artist",                       N_("Artist"),                           "Text",                  xmpText, xmpExternal, N_("The name of the artist or artists.") },
326
        { "album",                        N_("Album"),                            "Text",                  xmpText, xmpExternal, N_("The name of the album.") },
327
        { "trackNumber",                  N_("Track Number"),                     "Integer",               xmpText, xmpExternal, N_("A numeric value indicating the order of the audio file within its original recording.") },
328
        { "genre",                        N_("Genre"),                            "Text",                  xmpText, xmpExternal, N_("The name of the genre.") },
329
        { "copyright",                    N_("Copyright"),                        "Text",                  xmpText, xmpExternal, N_("The copyright information.") },
330
        { "releaseDate",                  N_("Release Date"),                     "Date",                  xmpText, xmpExternal, N_("The date the title was released.") },
331
        { "composer",                     N_("Composer"),                         "Text",                  xmpText, xmpExternal, N_("The composer's name.") },
332
        { "engineer",                     N_("Engineer"),                         "Text",                  xmpText, xmpExternal, N_("The engineer's name.") },
333
        { "tempo",                        N_("Tempo"),                            "Real",                  xmpText, xmpInternal, N_("The audio's tempo.") },
334
        { "instrument",                   N_("Instrument"),                       "Text",                  xmpText, xmpExternal, N_("The musical instrument.") },
335
        { "introTime",                    N_("Intro Time"),                       "Time",                  xmpText, xmpInternal, N_("The duration of lead time for queuing music.") },
336
        { "outCue",                       N_("Out Cue"),                          "Time",                  xmpText, xmpInternal, N_("The time at which to fade out.") },
337
        { "relativeTimestamp",            N_("Relative Timestamp"),               "Time",                  xmpText, xmpInternal, N_("The start time of the media inside the audio project.") },
338
        { "loop",                         N_("Loop"),                             "Boolean",               xmpText, xmpInternal, N_("When true, the clip can be looped seemlessly.") },
339
        { "numberOfBeats",                N_("Number Of Beats"),                  "Real",                  xmpText, xmpInternal, N_("The number of beats.") },
340
        { "key",                          N_("Key"),                              "closed Choice of Text", xmpText, xmpInternal, N_("The audio's musical key. One of: C, C#, D, D#, E, F, F#, G, G#, A, A#, B.") },
341
        { "stretchMode",                  N_("Stretch Mode"),                     "closed Choice of Text", xmpText, xmpInternal, N_("The audio stretch mode. One of: Fixed length, Time-Scale, Resample, Beat Splice, Hybrid.") },
342
        { "timeScaleParams",              N_("Time Scale Parameters"),            "timeScaleStretch",      xmpText, xmpInternal, N_("Additional parameters for Time-Scale stretch mode.") },
343
        { "resampleParams",               N_("Resample Parameters"),              "resampleStretch",       xmpText, xmpInternal, N_("Additional parameters for Resample stretch mode.") },
344
        { "beatSpliceParams",             N_("Beat Splice Parameters"),           "beatSpliceStretch",     xmpText, xmpInternal, N_("Additional parameters for Beat Splice stretch mode.") },
345
        { "timeSignature",                N_("Time Signature"),                   "closed Choice of Text", xmpText, xmpInternal, N_("The time signature of the music. One of: 2/4, 3/4, 4/4, 5/4, 7/4, 6/8, 9/8, 12/8, other.") },
346
        { "scaleType",                    N_("Scale Type"),                       "closed Choice of Text", xmpText, xmpInternal, N_("The musical scale used in the music. One of: Major, Minor, Both, Neither. "
347
                                                                                                                                    "Neither is most often used for instruments with no associated scale, such as drums.") },
348
        // End of list marker
349
        { 0, 0, 0, invalidTypeId, xmpInternal, 0 }
350
    };
351

    
352
    extern const XmpPropertyInfo xmpMicrosoftInfo[] = {
353
        { "CameraSerialNumber", N_("Camera Serial Number"), "Text",     xmpText, xmpExternal, N_("Camera Serial Number.") },
354
        { "DateAcquired",       N_("Date Acquired"),        "Date",     xmpText, xmpExternal, N_("Date Acquired.")        },
355
        { "FlashManufacturer",  N_("Flash Manufacturer"),   "Text",     xmpText, xmpExternal, N_("Flash Manufacturer.")   },
356
        { "FlashModel",         N_("Flash Model"),          "Text",     xmpText, xmpExternal, N_("Flash Model.")          },
357
        { "LastKeywordIPTC",    N_("Last Keyword IPTC"),    "bag Text", xmpBag,  xmpExternal, N_("Last Keyword IPTC.")    },
358
        { "LastKeywordXMP",     N_("Last Keyword XMP"),     "bag Text", xmpBag,  xmpExternal, N_("Last Keyword XMP.")     },
359
        { "LensManufacturer",   N_("Lens Manufacturer"),    "Text",     xmpText, xmpExternal, N_("Lens Manufacturer.")    },
360
        { "LensModel",          N_("Lens Model"),           "Text",     xmpText, xmpExternal, N_("Lens Model.")           },
361
        { "Rating",             N_("Rating Percent"),       "Text",     xmpText, xmpExternal, N_("Rating Percent.")       },
362
        // End of list marker
363
        { 0, 0, 0, invalidTypeId, xmpInternal, 0 }
364
    };
365

    
366
    extern const XmpPropertyInfo xmpPdfInfo[] = {
367
        { "Keywords",   N_("Keywords"),    "Text",      xmpText, xmpExternal, N_("Keywords.") },
368
        { "PDFVersion", N_("PDF Version"), "Text",      xmpText, xmpInternal, N_("The PDF file version (for example: 1.0, 1.3, and so on).") },
369
        { "Producer",   N_("Producer"),    "AgentName", xmpText, xmpInternal, N_("The name of the tool that created the PDF document.") },
370
        // End of list marker
371
        { 0, 0, 0, invalidTypeId, xmpInternal, 0 }
372
    };
373

    
374
    extern const XmpPropertyInfo xmpPhotoshopInfo[] = {
375
        { "AuthorsPosition",        N_("Authors Position"),        "Text",       xmpText, xmpExternal, N_("By-line title.") },
376
        { "CaptionWriter",          N_("Caption Writer"),          "ProperName", xmpText, xmpExternal, N_("Writer/editor.") },
377
        { "Category",               N_("Category"),                "Text",       xmpText, xmpExternal, N_("Category. Limited to 3 7-bit ASCII characters.") },
378
        { "City",                   N_("City"),                    "Text",       xmpText, xmpExternal, N_("City.") },
379
        { "Country",                N_("Country"),                 "Text",       xmpText, xmpExternal, N_("Country/primary location.") },
380
        { "Credit",                 N_("Credit"),                  "Text",       xmpText, xmpExternal, N_("Credit.") },
381
        { "DateCreated",            N_("Date Created"),            "Date",       xmpText, xmpExternal, N_("The date the intellectual content of the document was created (rather than the creation "
382
                                                                                                          "date of the physical representation), following IIM conventions. For example, a photo "
383
                                                                                                          "taken during the American Civil War would have a creation date during that epoch "
384
                                                                                                          "(1861-1865) rather than the date the photo was digitized for archiving.") },
385
        { "Headline",               N_("Headline"),                "Text",       xmpText, xmpExternal, N_("Headline.") },
386
        { "Instructions",           N_("Instructions"),            "Text",       xmpText, xmpExternal, N_("Special instructions.") },
387
        { "Source",                 N_("Source"),                  "Text",       xmpText, xmpExternal, N_("Source.") },
388
        { "State",                  N_("State"),                   "Text",       xmpText, xmpExternal, N_("Province/state.") },
389
        { "SupplementalCategories", N_("Supplemental Categories"), "bag Text",   xmpBag,  xmpExternal, N_("Supplemental category.") },
390
        { "TransmissionReference",  N_("Transmission Reference"),  "Text",       xmpText, xmpExternal, N_("Original transmission reference.") },
391
        { "Urgency",                N_("Urgency"),                 "Integer",    xmpText, xmpExternal, N_("Urgency. Valid range is 1-8.") },
392
        // End of list marker
393
        { 0, 0, 0, invalidTypeId, xmpInternal, 0 }
394
    };
395

    
396
    //! XMP crs:CropUnits
397
    extern const TagDetails crsCropUnits[] = {
398
        { 0, N_("pixels") },
399
        { 1, N_("inches") },
400
        { 2, N_("cm")     }
401
    };
402

    
403
    extern const XmpPropertyInfo xmpCrsInfo[] = {
404
        { "AutoBrightness",       N_("Auto Brightness"),           "Boolean",                          xmpText, xmpExternal, N_("When true, \"Brightness\" is automatically adjusted.") },
405
        { "AutoContrast",         N_("Auto Contrast"),             "Boolean",                          xmpText, xmpExternal, N_("When true, \"Contrast\" is automatically adjusted.") },
406
        { "AutoExposure",         N_("Auto Exposure"),             "Boolean",                          xmpText, xmpExternal, N_("When true, \"Exposure\" is automatically adjusted.") },
407
        { "AutoShadows",          N_("Auto Shadows"),              "Boolean",                          xmpText, xmpExternal, N_("When true,\"Shadows\" is automatically adjusted.") },
408
        { "BlueHue",              N_("Blue Hue"),                  "Integer",                          xmpText, xmpExternal, N_("\"Blue Hue\" setting. Range -100 to 100.") },
409
        { "BlueSaturation",       N_("Blue Saturation"),           "Integer",                          xmpText, xmpExternal, N_("\"Blue Saturation\" setting. Range -100 to +100.") },
410
        { "Brightness",           N_("Brightness"),                "Integer",                          xmpText, xmpExternal, N_("\"Brightness\" setting. Range 0 to +150.") },
411
        { "CameraProfile",        N_("Camera Profile"),            "Text",                             xmpText, xmpExternal, N_("\"Camera Profile\" setting.") },
412
        { "ChromaticAberrationB", N_("Chromatic Aberration Blue"), "Integer",                          xmpText, xmpExternal, N_("\"Chromatic Aberration, Fix Blue/Yellow Fringe\" setting. Range -100 to +100.") },
413
        { "ChromaticAberrationR", N_("Chromatic Aberration Red"),  "Integer",                          xmpText, xmpExternal, N_("\"Chromatic Aberration, Fix Red/Cyan Fringe\" setting. Range -100 to +100.") },
414
        { "ColorNoiseReduction",  N_("Color Noise Reduction"),     "Integer",                          xmpText, xmpExternal, N_("\"Color Noise Reducton\" setting. Range 0 to +100.") },
415
        { "Contrast",             N_("Contrast"),                  "Integer",                          xmpText, xmpExternal, N_("\"Contrast\" setting. Range -50 to +100.") },
416
        { "CropTop",              N_("Crop Top"),                  "Real",                             xmpText, xmpExternal, N_("When \"Has Crop\" is true, top of crop rectangle") },
417
        { "CropLeft",             N_("Crop Left"),                 "Real",                             xmpText, xmpExternal, N_("When \"Has Crop\" is true, left of crop rectangle.") },
418
        { "CropBottom",           N_("Crop Bottom"),               "Real",                             xmpText, xmpExternal, N_("When \"Has Crop\" is true, bottom of crop rectangle.") },
419
        { "CropRight",            N_("Crop Right"),                "Real",                             xmpText, xmpExternal, N_("When \"Has Crop\" is true, right of crop rectangle.") },
420
        { "CropAngle",            N_("Crop Angle"),                "Real",                             xmpText, xmpExternal, N_("When \"Has Crop\" is true, angle of crop rectangle.") },
421
        { "CropWidth",            N_("Crop Width"),                "Real",                             xmpText, xmpExternal, N_("Width of resulting cropped image in CropUnits units.") },
422
        { "CropHeight",           N_("Crop Height"),               "Real",                             xmpText, xmpExternal, N_("Height of resulting cropped image in CropUnits units.") },
423
        { "CropUnits",            N_("Crop Units"),                "Integer",                          xmpText, xmpExternal, N_("Units for CropWidth and CropHeight. 0=pixels, 1=inches, 2=cm") },
424
        { "Exposure",             N_("Exposure"),                  "Real",                             xmpText, xmpExternal, N_("\"Exposure\" setting. Range -4.0 to +4.0.") },
425
        { "GreenHue",             N_("GreenHue"),                  "Integer",                          xmpText, xmpExternal, N_("\"Green Hue\" setting. Range -100 to +100.") },
426
        { "GreenSaturation",      N_("Green Saturation"),          "Integer",                          xmpText, xmpExternal, N_("\"Green Saturation\" setting. Range -100 to +100.") },
427
        { "HasCrop",              N_("Has Crop"),                  "Boolean",                          xmpText, xmpExternal, N_("When true, image has a cropping rectangle.") },
428
        { "HasSettings",          N_("Has Settings"),              "Boolean",                          xmpText, xmpExternal, N_("When true, non-default camera raw settings.") },
429
        { "LuminanceSmoothing",   N_("Luminance Smoothing"),       "Integer",                          xmpText, xmpExternal, N_("\"Luminance Smoothing\" setting. Range 0 to +100.") },
430
        { "RawFileName",          N_("Raw File Name"),             "Text",                             xmpText, xmpInternal, N_("File name of raw file (not a complete path).") },
431
        { "RedHue",               N_("Red Hue"),                   "Integer",                          xmpText, xmpExternal, N_("\"Red Hue\" setting. Range -100 to +100.") },
432
        { "RedSaturation",        N_("Red Saturation"),            "Integer",                          xmpText, xmpExternal, N_("\"Red Saturation\" setting. Range -100 to +100.") },
433
        { "Saturation",           N_("Saturation"),                "Integer",                          xmpText, xmpExternal, N_("\"Saturation\" setting. Range -100 to +100.") },
434
        { "Shadows",              N_("Shadows"),                   "Integer",                          xmpText, xmpExternal, N_("\"Shadows\" setting. Range 0 to +100.") },
435
        { "ShadowTint",           N_("Shadow Tint"),               "Integer",                          xmpText, xmpExternal, N_("\"Shadow Tint\" setting. Range -100 to +100.") },
436
        { "Sharpness",            N_("Sharpness"),                 "Integer",                          xmpText, xmpExternal, N_("\"Sharpness\" setting. Range 0 to +100.") },
437
        { "Temperature",          N_("Temperature"),               "Integer",                          xmpText, xmpExternal, N_("\"Temperature\" setting. Range 2000 to 50000.") },
438
        { "Tint",                 N_("Tint"),                      "Integer",                          xmpText, xmpExternal, N_("\"Tint\" setting. Range -150 to +150.") },
439
        { "ToneCurve",            N_("Tone Curve"),                "Seq of points (Integer, Integer)", xmpText, xmpExternal, N_("Array of points (Integer, Integer) defining a \"Tone Curve\".") },
440
        { "ToneCurveName",        N_("Tone Curve Name"),           "Choice Text",                      xmpText, xmpInternal, N_("The name of the Tone Curve described by ToneCurve. One of: Linear, Medium Contrast, "
441
                                                                                                                                "Strong Contrast, Custom or a user-defined preset name.") },
442
        { "Version",              N_("Version"),                   "Text",                             xmpText, xmpInternal, N_("Version of Camera Raw plugin.") },
443
        { "VignetteAmount",       N_("Vignette Amount"),           "Integer",                          xmpText, xmpExternal, N_("\"Vignetting Amount\" setting. Range -100 to +100.") },
444
        { "VignetteMidpoint",     N_("Vignette Midpoint"),         "Integer",                          xmpText, xmpExternal, N_("\"Vignetting Midpoint\" setting. Range 0 to +100.") },
445
        { "WhiteBalance",         N_("White Balance"),             "Closed Choice Text",               xmpText, xmpExternal, N_("\"White Balance\" setting. One of: As Shot, Auto, Daylight, Cloudy, Shade, Tungsten, "
446
                                                                                                                                "Fluorescent, Flash, Custom") },
447
        // End of list marker
448
        { 0, 0, 0, invalidTypeId, xmpInternal, 0 }
449
    };
450

    
451
    extern const XmpPropertyInfo xmpTiffInfo[] = {
452
        { "ImageWidth",                N_("Image Width"),                "Integer",                      xmpText, xmpInternal, N_("TIFF tag 256, 0x100. Image width in pixels.") },
453
        { "ImageLength",               N_("Image Length"),               "Integer",                      xmpText, xmpInternal, N_("TIFF tag 257, 0x101. Image height in pixels.") },
454
        { "BitsPerSample",             N_("Bits Per Sample"),            "seq Integer",                  xmpSeq,  xmpInternal, N_("TIFF tag 258, 0x102. Number of bits per component in each channel.") },
455
        { "Compression",               N_("Compression"),                "Closed Choice of Integer",     xmpText, xmpInternal, N_("TIFF tag 259, 0x103. Compression scheme: 1 = uncompressed; 6 = JPEG.") },
456
        { "PhotometricInterpretation", N_("Photometric Interpretation"), "Closed Choice of Integer",     xmpText, xmpInternal, N_("TIFF tag 262, 0x106. Pixel Composition: 2 = RGB; 6 = YCbCr.") },
457
        { "Orientation",               N_("Orientation"),                "Closed Choice of Integer",     xmpText, xmpInternal, N_("TIFF tag 274, 0x112. Orientation:"
458
                                                                                                                                  "1 = 0th row at top, 0th column at left "
459
                                                                                                                                  "2 = 0th row at top, 0th column at right "
460
                                                                                                                                  "3 = 0th row at bottom, 0th column at right "
461
                                                                                                                                  "4 = 0th row at bottom, 0th column at left "
462
                                                                                                                                  "5 = 0th row at left, 0th column at top "
463
                                                                                                                                  "6 = 0th row at right, 0th column at top "
464
                                                                                                                                  "7 = 0th row at right, 0th column at bottom "
465
                                                                                                                                  "8 = 0th row at left, 0th column at bottom") },
466
        { "SamplesPerPixel",           N_("Samples Per Pixel"),          "Integer",                      xmpText, xmpInternal, N_("TIFF tag 277, 0x115. Number of components per pixel.") },
467
        { "PlanarConfiguration",       N_("Planar Configuration"),       "Closed Choice of Integer",     xmpText, xmpInternal, N_("TIFF tag 284, 0x11C. Data layout:1 = chunky; 2 = planar.") },
468
        { "YCbCrSubSampling",          N_("YCbCr Sub Sampling"),         "Closed Choice of seq Integer", xmpSeq,  xmpInternal, N_("TIFF tag 530, 0x212. Sampling ratio of chrominance "
469
                                                                                                                                  "components: [2, 1] = YCbCr4:2:2; [2, 2] = YCbCr4:2:0") },
470
        { "YCbCrPositioning",          N_("YCbCr Positioning"),          "Closed Choice of Integer",     xmpText, xmpInternal, N_("TIFF tag 531, 0x213. Position of chrominance vs. "
471
                                                                                                                                  "luminance components: 1 = centered; 2 = co-sited.") },
472
        { "XResolution",               N_("X Resolution"),               "Rational",                     xmpText, xmpInternal, N_("TIFF tag 282, 0x11A. Horizontal resolution in pixels per unit.") },
473
        { "YResolution",               N_("Y Resolution"),               "Rational",                     xmpText, xmpInternal, N_("TIFF tag 283, 0x11B. Vertical resolution in pixels per unit.") },
474
        { "ResolutionUnit",            N_("Resolution Unit"),            "Closed Choice of Integer",     xmpText, xmpInternal, N_("TIFF tag 296, 0x128. Unit used for XResolution and "
475
                                                                                                                                  "YResolution. Value is one of: 2 = inches; 3 = centimeters.") },
476
        { "TransferFunction",          N_("Transfer Function"),          "seq Integer",                  xmpSeq,  xmpInternal, N_("TIFF tag 301, 0x12D. Transfer function for image "
477
                                                                                                                                  "described in tabular style with 3 * 256 entries.") },
478
        { "WhitePoint",                N_("White Point"),                "seq Rational",                 xmpSeq,  xmpInternal, N_("TIFF tag 318, 0x13E. Chromaticity of white point.") },
479
        { "PrimaryChromaticities",     N_("Primary Chromaticities"),     "seq Rational",                 xmpSeq,  xmpInternal, N_("TIFF tag 319, 0x13F. Chromaticity of the three primary colors.") },
480
        { "YCbCrCoefficients",         N_("YCbCr Coefficients"),         "seq Rational",                 xmpSeq,  xmpInternal, N_("TIFF tag 529, 0x211. Matrix coefficients for RGB to YCbCr transformation.") },
481
        { "ReferenceBlackWhite",       N_("Reference Black White"),      "seq Rational",                 xmpSeq,  xmpInternal, N_("TIFF tag 532, 0x214. Reference black and white point values.") },
482
        { "DateTime",                  N_("Date and Time"),              "Date",                         xmpText, xmpInternal, N_("TIFF tag 306, 0x132 (primary) and EXIF tag 37520, "
483
                                                                                                                                  "0x9290 (subseconds). Date and time of image creation "
484
                                                                                                                                  "(no time zone in EXIF), stored in ISO 8601 format, not "
485
                                                                                                                                  "the original EXIF format. This property includes the "
486
                                                                                                                                  "value for the EXIF SubSecTime attribute. "
487
                                                                                                                                  "NOTE: This property is stored in XMP as xmp:ModifyDate.") },
488
        { "ImageDescription",          N_("Image Description"),          "Lang Alt",                     langAlt, xmpExternal, N_("TIFF tag 270, 0x10E. Description of the image. Note: This property is stored in XMP as dc:description.") },
489
        { "Make",                      N_("Make"),                       "ProperName",                   xmpText, xmpInternal, N_("TIFF tag 271, 0x10F. Manufacturer of recording equipment.") },
490
        { "Model",                     N_("Model"),                      "ProperName",                   xmpText, xmpInternal, N_("TIFF tag 272, 0x110. Model name or number of equipment.") },
491
        { "Software",                  N_("Software"),                   "AgentName",                    xmpText, xmpInternal, N_("TIFF tag 305, 0x131. Software or firmware used to generate image. "
492
                                                                                                                                  "Note: This property is stored in XMP as xmp:CreatorTool. ") },
493
        { "Artist",                    N_("Artist"),                     "ProperName",                   xmpText, xmpExternal, N_("TIFF tag 315, 0x13B. Camera owner, photographer or image creator. "
494
                                                                                                                                  "Note: This property is stored in XMP as the first item in the dc:creator array.") },
495
        { "Copyright",                 N_("Copyright"),                  "Lang Alt",                     langAlt, xmpExternal, N_("TIFF tag 33432, 0x8298. Copyright information. "
496
                                                                                                                                  "Note: This property is stored in XMP as dc:rights.") },
497
        // End of list marker
498
        { 0, 0, 0, invalidTypeId, xmpInternal, 0 }
499
    };
500

    
501
    extern const XmpPropertyInfo xmpExifInfo[] = {
502
        { "ExifVersion",              N_("Exif Version"),                        "Closed Choice of Text",        xmpText, xmpInternal, N_("EXIF tag 36864, 0x9000. EXIF version number.") },
503
        { "FlashpixVersion",          N_("Flashpix Version"),                    "Closed Choice of Text",        xmpText, xmpInternal, N_("EXIF tag 40960, 0xA000. Version of FlashPix.") },
504
        { "ColorSpace",               N_("Color Space"),                         "Closed Choice of Integer",     xmpText, xmpInternal, N_("EXIF tag 40961, 0xA001. Color space information") },
505
        { "ComponentsConfiguration",  N_("Components Configuration"),            "Closed Choice of seq Integer", xmpSeq,  xmpInternal, N_("EXIF tag 37121, 0x9101. Configuration of components in data: 4 5 6 0 (if RGB compressed data), "
506
                                                                                                                                          "1 2 3 0 (other cases).") },
507
        { "CompressedBitsPerPixel",   N_("Compressed Bits Per Pixel"),           "Rational",                     xmpText, xmpInternal, N_("EXIF tag 37122, 0x9102. Compression mode used for a compressed image is indicated "
508
                                                                                                                                          "in unit bits per pixel.") },
509
        { "PixelXDimension",          N_("Pixel X Dimension"),                   "Integer",                      xmpText, xmpInternal, N_("EXIF tag 40962, 0xA002. Valid image width, in pixels.") },
510
        { "PixelYDimension",          N_("Pixel Y Dimension"),                   "Integer",                      xmpText, xmpInternal, N_("EXIF tag 40963, 0xA003. Valid image height, in pixels.") },
511
        { "UserComment",              N_("User Comment"),                        "Lang Alt",                     langAlt, xmpExternal, N_("EXIF tag 37510, 0x9286. Comments from user.") },
512
        { "RelatedSoundFile",         N_("Related Sound File"),                  "Text",                         xmpText, xmpInternal, N_("EXIF tag 40964, 0xA004. An \"8.3\" file name for the related sound file.") },
513
        { "DateTimeOriginal",         N_("Date and Time Original"),              "Date",                         xmpText, xmpInternal, N_("EXIF tags 36867, 0x9003 (primary) and 37521, 0x9291 (subseconds). "
514
                                                                                                                                          "Date and time when original image was generated, in ISO 8601 format. "
515
                                                                                                                                          "Includes the EXIF SubSecTimeOriginal data.") },
516
        { "DateTimeDigitized",        N_("Date and Time Digitized"),             "Date",                         xmpText, xmpInternal, N_("EXIF tag 36868, 0x9004 (primary) and 37522, 0x9292 (subseconds). Date and time when "
517
                                                                                                                                          "image was stored as digital data, can be the same as DateTimeOriginal if originally "
518
                                                                                                                                          "stored in digital form. Stored in ISO 8601 format. Includes the EXIF "
519
                                                                                                                                          "SubSecTimeDigitized data.") },
520
        { "ExposureTime",             N_("Exposure Time"),                       "Rational",                     xmpText, xmpInternal, N_("EXIF tag 33434, 0x829A. Exposure time in seconds.") },
521
        { "FNumber",                  N_("F Number"),                            "Rational",                     xmpText, xmpInternal, N_("EXIF tag 33437, 0x829D. F number.") },
522
        { "ExposureProgram",          N_("Exposure Program"),                    "Closed Choice of Integer",     xmpText, xmpInternal, N_("EXIF tag 34850, 0x8822. Class of program used for exposure.") },
523
        { "SpectralSensitivity",      N_("Spectral Sensitivity"),                "Text",                         xmpText, xmpInternal, N_("EXIF tag 34852, 0x8824. Spectral sensitivity of each channel.") },
524
        { "ISOSpeedRatings",          N_("ISOSpeedRatings"),                     "seq Integer",                  xmpSeq,  xmpInternal, N_("EXIF tag 34855, 0x8827. ISO Speed and ISO Latitude of the input device as "
525
                                                                                                                                          "specified in ISO 12232.") },
526
        { "OECF",                     N_("OECF"),                                "OECF/SFR",                     xmpText, xmpInternal, N_("EXIF tag 34856, 0x8828. Opto-Electoric Conversion Function as specified in ISO 14524.") },
527
        { "ShutterSpeedValue",        N_("Shutter Speed Value"),                 "Rational",                     xmpText, xmpInternal, N_("EXIF tag 37377, 0x9201. Shutter speed, unit is APEX. See Annex C of the EXIF specification.") },
528
        { "ApertureValue",            N_("Aperture Value"),                      "Rational",                     xmpText, xmpInternal, N_("EXIF tag 37378, 0x9202. Lens aperture, unit is APEX.") },
529
        { "BrightnessValue",          N_("Brightness Value"),                    "Rational",                     xmpText, xmpInternal, N_("EXIF tag 37379, 0x9203. Brightness, unit is APEX.") },
530
        { "ExposureBiasValue",        N_("Exposure Bias Value"),                 "Rational",                     xmpText, xmpInternal, N_("EXIF tag 37380, 0x9204. Exposure bias, unit is APEX.") },
531
        { "MaxApertureValue",         N_("Maximum Aperture Value"),              "Rational",                     xmpText, xmpInternal, N_("EXIF tag 37381, 0x9205. Smallest F number of lens, in APEX.") },
532
        { "SubjectDistance",          N_("Subject Distance"),                    "Rational",                     xmpText, xmpInternal, N_("EXIF tag 37382, 0x9206. Distance to subject, in meters.") },
533
        { "MeteringMode",             N_("Metering Mode"),                       "Closed Choice of Integer",     xmpText, xmpInternal, N_("EXIF tag 37383, 0x9207. Metering mode.") },
534
        { "LightSource",              N_("Light Source"),                        "Closed Choice of Integer",     xmpText, xmpInternal, N_("EXIF tag 37384, 0x9208. Light source.") },
535
        { "Flash",                    N_("Flash"),                               "Flash",                        xmpText, xmpInternal, N_("EXIF tag 37385, 0x9209. Strobe light (flash) source data.") },
536
        { "FocalLength",              N_("Focal Length"),                        "Rational",                     xmpText, xmpInternal, N_("EXIF tag 37386, 0x920A. Focal length of the lens, in millimeters.") },
537
        { "SubjectArea",              N_("Subject Area"),                        "seq Integer",                  xmpSeq,  xmpInternal, N_("EXIF tag 37396, 0x9214. The location and area of the main subject in the overall scene.") },
538
        { "FlashEnergy",              N_("Flash Energy"),                        "Rational",                     xmpText, xmpInternal, N_("EXIF tag 41483, 0xA20B. Strobe energy during image capture.") },
539
        { "SpatialFrequencyResponse", N_("Spatial Frequency Response"),          "OECF/SFR",                     xmpText, xmpInternal, N_("EXIF tag 41484, 0xA20C. Input device spatial frequency table and SFR values as "
540
                                                                                                                                          "specified in ISO 12233.") },
541
        { "FocalPlaneXResolution",    N_("Focal Plane X Resolution"),            "Rational",                     xmpText, xmpInternal, N_("EXIF tag 41486, 0xA20E. Horizontal focal resolution, measured pixels per unit.") },
542
        { "FocalPlaneYResolution",    N_("Focal Plane Y Resolution"),            "Rational",                     xmpText, xmpInternal, N_("EXIF tag 41487, 0xA20F. Vertical focal resolution, measured in pixels per unit.") },
543
        { "FocalPlaneResolutionUnit", N_("Focal Plane Resolution Unit"),         "Closed Choice of Integer",     xmpText, xmpInternal, N_("EXIF tag 41488, 0xA210. Unit used for FocalPlaneXResolution and FocalPlaneYResolution.") },
544
        { "SubjectLocation",          N_("Subject Location"),                    "seq Integer",                  xmpSeq,  xmpInternal, N_("EXIF tag 41492, 0xA214. Location of the main subject of the scene. The first value is the "
545
                                                                                                                                          "horizontal pixel and the second value is the vertical pixel at which the "
546
                                                                                                                                          "main subject appears.") },
547
        { "ExposureIndex",            N_("Exposure Index"),                      "Rational",                     xmpText, xmpInternal, N_("EXIF tag 41493, 0xA215. Exposure index of input device.") },
548
        { "SensingMethod",            N_("Sensing Method"),                      "Closed Choice of Integer",     xmpText, xmpInternal, N_("EXIF tag 41495, 0xA217. Image sensor type on input device.") },
549
        { "FileSource",               N_("File Source"),                         "Closed Choice of Integer",     xmpText, xmpInternal, N_("EXIF tag 41728, 0xA300. Indicates image source.") },
550
        { "SceneType",                N_("Scene Type"),                          "Closed Choice of Integer",     xmpText, xmpInternal, N_("EXIF tag 41729, 0xA301. Indicates the type of scene.") },
551
        { "CFAPattern",               N_("CFA Pattern"),                         "CFAPattern",                   xmpText, xmpInternal, N_("EXIF tag 41730, 0xA302. Color filter array geometric pattern of the image sense.") },
552
        { "CustomRendered",           N_("Custom Rendered"),                     "Closed Choice of Integer",     xmpText, xmpInternal, N_("EXIF tag 41985, 0xA401. Indicates the use of special processing on image data.") },
553
        { "ExposureMode",             N_("Exposure Mode"),                       "Closed Choice of Integer",     xmpText, xmpInternal, N_("EXIF tag 41986, 0xA402. Indicates the exposure mode set when the image was shot.") },
554
        { "WhiteBalance",             N_("White Balance"),                       "Closed Choice of Integer",     xmpText, xmpInternal, N_("EXIF tag 41987, 0xA403. Indicates the white balance mode set when the image was shot.") },
555
        { "DigitalZoomRatio",         N_("Digital Zoom Ratio"),                  "Rational",                     xmpText, xmpInternal, N_("EXIF tag 41988, 0xA404. Indicates the digital zoom ratio when the image was shot.") },
556
        { "FocalLengthIn35mmFilm",    N_("Focal Length In 35mm Film"),           "Integer",                      xmpText, xmpInternal, N_("EXIF tag 41989, 0xA405. Indicates the equivalent focal length assuming a 35mm film "
557
                                                                                                                                          "camera, in mm. A value of 0 means the focal length is unknown. Note that this tag "
558
                                                                                                                                          "differs from the FocalLength tag.") },
559
        { "SceneCaptureType",         N_("Scene Capture Type"),                  "Closed Choice of Integer",     xmpText, xmpInternal, N_("EXIF tag 41990, 0xA406. Indicates the type of scene that was shot.") },
560
        { "GainControl",              N_("Gain Control"),                        "Closed Choice of Integer",     xmpText, xmpInternal, N_("EXIF tag 41991, 0xA407. Indicates the degree of overall image gain adjustment.") },
561
        { "Contrast",                 N_("Contrast"),                            "Closed Choice of Integer",     xmpText, xmpInternal, N_("EXIF tag 41992, 0xA408. Indicates the direction of contrast processing applied by the camera.") },
562
        { "Saturation",               N_("Saturation"),                          "Closed Choice of Integer",     xmpText, xmpInternal, N_("EXIF tag 41993, 0xA409. Indicates the direction of saturation processing applied by the camera.") },
563
        { "Sharpness",                N_("Sharpness"),                           "Closed Choice of Integer",     xmpText, xmpInternal, N_("EXIF tag 41994, 0xA40A. Indicates the direction of sharpness processing applied by the camera.") },
564
        { "DeviceSettingDescription", N_("Device Setting Description"),          "DeviceSettings",               xmpText, xmpInternal, N_("EXIF tag 41995, 0xA40B. Indicates information on the picture-taking conditions of a particular camera model.") },
565
        { "SubjectDistanceRange",     N_("Subject Distance Range"),              "Closed Choice of Integer",     xmpText, xmpInternal, N_("EXIF tag 41996, 0xA40C. Indicates the distance to the subject.") },
566
        { "ImageUniqueID",            N_("Image Unique ID"),                     "Text",                         xmpText, xmpInternal, N_("EXIF tag 42016, 0xA420. An identifier assigned uniquely to each image. It is recorded as a 32 "
567
                                                                                                                                          "character ASCII string, equivalent to hexadecimal notation and 128-bit fixed length.") },
568
        { "GPSVersionID",             N_("GPS Version ID"),                      "Text",                         xmpText, xmpInternal, N_("GPS tag 0, 0x00. A decimal encoding of each of the four EXIF bytes with period separators. "
569
                                                                                                                                          "The current value is \"2.0.0.0\".") },
570
        { "GPSLatitude",              N_("GPS Latitude"),                        "GPSCoordinate",                xmpText, xmpInternal, N_("GPS tag 2, 0x02 (position) and 1, 0x01 (North/South). Indicates latitude.") },
571
        { "GPSLongitude",             N_("GPS Longitude"),                       "GPSCoordinate",                xmpText, xmpInternal, N_("GPS tag 4, 0x04 (position) and 3, 0x03 (East/West). Indicates longitude.") },
572
        { "GPSAltitudeRef",           N_("GPS Altitude Reference"),              "Closed Choice of Integer",     xmpText, xmpInternal, N_("GPS tag 5, 0x05. Indicates whether the altitude is above or below sea level.") },
573
        { "GPSAltitude",              N_("GPS Altitude"),                        "Rational",                     xmpText, xmpInternal, N_("GPS tag 6, 0x06. Indicates altitude in meters.") },
574
        { "GPSTimeStamp",             N_("GPS Time Stamp"),                      "Date",                         xmpText, xmpInternal, N_("GPS tag 29 (date), 0x1D, and, and GPS tag 7 (time), 0x07. Time stamp of GPS data, "
575
                                                                                                                                          "in Coordinated Universal Time. Note: The GPSDateStamp tag is new in EXIF 2.2. "
576
                                                                                                                                          "The GPS timestamp in EXIF 2.1 does not include a date. If not present, "
577
                                                                                                                                          "the date component for the XMP should be taken from exif:DateTimeOriginal, or if that is "
578
                                                                                                                                          "also lacking from exif:DateTimeDigitized. If no date is available, do not write "
579
                                                                                                                                          "exif:GPSTimeStamp to XMP.") },
580
        { "GPSSatellites",            N_("GPS Satellites"),                      "Text",                         xmpText, xmpInternal, N_("GPS tag 8, 0x08. Satellite information, format is unspecified.") },
581
        { "GPSStatus",                N_("GPS Status"),                          "Closed Choice of Text",        xmpText, xmpInternal, N_("GPS tag 9, 0x09. Status of GPS receiver at image creation time.") },
582
        { "GPSMeasureMode",           N_("GPS Measure Mode"),                    "Text",                         xmpText, xmpInternal, N_("GPS tag 10, 0x0A. GPS measurement mode, Text type.") },
583
        { "GPSDOP",                   N_("GPS DOP"),                             "Rational",                     xmpText, xmpInternal, N_("GPS tag 11, 0x0B. Degree of precision for GPS data.") },
584
        { "GPSSpeedRef",              N_("GPS Speed Reference"),                 "Closed Choice of Text",        xmpText, xmpInternal, N_("GPS tag 12, 0x0C. Units used to speed measurement.") },
585
        { "GPSSpeed",                 N_("GPS Speed"),                           "Rational",                     xmpText, xmpInternal, N_("GPS tag 13, 0x0D. Speed of GPS receiver movement.") },
586
        { "GPSTrackRef",              N_("GPS Track Reference"),                 "Closed Choice of Text",        xmpText, xmpInternal, N_("GPS tag 14, 0x0E. Reference for movement direction.") },
587
        { "GPSTrack",                 N_("GPS Track"),                           "Rational",                     xmpText, xmpInternal, N_("GPS tag 15, 0x0F. Direction of GPS movement, values range from 0 to 359.99.") },
588
        { "GPSImgDirectionRef",       N_("GPS Image Direction Reference"),       "Closed Choice of Text",        xmpText, xmpInternal, N_("GPS tag 16, 0x10. Reference for image direction.") },
589
        { "GPSImgDirection",          N_("GPS Image Direction"),                 "Rational",                     xmpText, xmpInternal, N_("GPS tag 17, 0x11. Direction of image when captured, values range from 0 to 359.99.") },
590
        { "GPSMapDatum",              N_("GPS Map Datum"),                       "Text",                         xmpText, xmpInternal, N_("GPS tag 18, 0x12. Geodetic survey data.") },
591
        { "GPSDestLatitude",          N_("GPS Destination Latitude"),            "GPSCoordinate",                xmpText, xmpInternal, N_("GPS tag 20, 0x14 (position) and 19, 0x13 (North/South). Indicates destination latitude.") },
592
        { "GPSDestLongitude",         N_("GPS Destination Longitude"),           "GPSCoordinate",                xmpText, xmpInternal, N_("GPS tag 22, 0x16 (position) and 21, 0x15 (East/West). Indicates destination longitude.") },
593
        { "GPSDestBearingRef",        N_("GPS Destination Bearing Reference"),   "Closed Choice of Text",        xmpText, xmpInternal, N_("GPS tag 23, 0x17. Reference for movement direction.") },
594
        { "GPSDestBearing",           N_("GPS Destination Bearing"),             "Rational",                     xmpText, xmpInternal, N_("GPS tag 24, 0x18. Destination bearing, values from 0 to 359.99.") },
595
        { "GPSDestDistanceRef",       N_("GPS Destination Distance Refefrence"), "Closed Choice  of Text",       xmpText, xmpInternal, N_("GPS tag 25, 0x19. Units used for speed measurement.") },
596
        { "GPSDestDistance",          N_("GPS Destination Distance"),            "Rational",                     xmpText, xmpInternal, N_("GPS tag 26, 0x1A. Distance to destination.") },
597
        { "GPSProcessingMethod",      N_("GPS Processing Method"),               "Text",                         xmpText, xmpInternal, N_("GPS tag 27, 0x1B. A character string recording the name of the method used for location finding.") },
598
        { "GPSAreaInformation",       N_("GPS Area Information"),                "Text",                         xmpText, xmpInternal, N_("GPS tag 28, 0x1C. A character string recording the name of the GPS area.") },
599
        { "GPSDifferential",          N_("GPS Differential"),                    "Closed Choice of Integer",     xmpText, xmpInternal, N_("GPS tag 30, 0x1E. Indicates whether differential correction is applied to the GPS receiver.") },
600
        // End of list marker
601
        { 0, 0, 0, invalidTypeId, xmpInternal, 0 }
602
    };
603

    
604
    extern const XmpPropertyInfo xmpAuxInfo[] = {
605
        { "Lens",             N_("Lens"),             "Text",        xmpText,          xmpInternal, N_("A description of the lens used to take the photograph. For example, \"70-200 mm f/2.8-4.0\".") },
606
        { "SerialNumber",     N_("SerialNumber"),     "Text",        xmpText,          xmpInternal, N_("The serial number of the camera or camera body used to take the photograph.") },
607
        // End of list marker
608
        { 0, 0, 0, invalidTypeId, xmpInternal, 0 }
609
    };
610

    
611
    extern const XmpPropertyInfo xmpIptcInfo[] = {
612
        { "CiAdrCity",          N_("Contact Info-City"),           "Text",                      xmpText, xmpExternal, N_("The contact information city part.") },
613
        { "CiAdrCtry",          N_("Contact Info-Country"),        "Text",                      xmpText, xmpExternal, N_("The contact information country part.") },
614
        { "CiAdrExtadr",        N_("Contact Info-Address"),        "Text",                      xmpText, xmpExternal, N_("The contact information address part. Comprises an optional company name and all required "
615
                                                                                                                         "information to locate the building or postbox to which mail should be sent.") },
616
        { "CiAdrPcode",         N_("Contact Info-Postal Code"),    "Text",                      xmpText, xmpExternal, N_("The contact information part denoting the local postal code.") },
617
        { "CiAdrRegion",        N_("Contact Info-State/Province"), "Text",                      xmpText, xmpExternal, N_("The contact information part denoting regional information like state or province.") },
618
        { "CiEmailWork",        N_("Contact Info-Email"),          "Text",                      xmpText, xmpExternal, N_("The contact information email address part.") },
619
        { "CiTelWork",          N_("Contact Info-Phone"),          "Text",                      xmpText, xmpExternal, N_("The contact information phone number part.") },
620
        { "CiUrlWork",          N_("Contact Info-Web URL"),        "Text",                      xmpText, xmpExternal, N_("The contact information web address part.") },
621
        { "CountryCode",        N_("Country Code"),                "closed Choice of Text",     xmpText, xmpExternal, N_("Code of the country the content is focussing on -- either the country shown in visual "
622
                                                                                                                         "media or referenced in text or audio media. This element is at the top/first level of "
623
                                                                                                                         "a top-down geographical hierarchy. The code should be taken from ISO 3166 two or three "
624
                                                                                                                         "letter code. The full name of a country should go to the \"Country\" element.") },
625
        { "CreatorContactInfo", N_("Creator's Contact Info"),      "ContactInfo",               xmpText, xmpExternal, N_("The creator's contact information provides all necessary information to get in contact "
626
                                                                                                                         "with the creator of this news object and comprises a set of sub-properties for proper addressing.") },
627
        { "IntellectualGenre",  N_("Intellectual Genre"),          "Text",                      xmpText, xmpExternal, N_("Describes the nature, intellectual or journalistic characteristic of a news object, not "
628
                                                                                                                         "specifically its content.") },
629
        { "Location",           N_("Location"),                    "Text",                      xmpText, xmpExternal, N_("Name of a location the content is focussing on -- either the location shown in visual "
630
                                                                                                                         "media or referenced by text or audio media. This location name could either be the name "
631
                                                                                                                         "of a sublocation to a city or the name of a well known location or (natural) monument "
632
                                                                                                                         "outside a city. In the sense of a sublocation to a city this element is at the fourth "
633
                                                                                                                         "level of a top-down geographical hierarchy.") },
634
        { "Scene",              N_("IPTC Scene"),                  "bag closed Choice of Text", xmpBag, xmpExternal, N_("Describes the scene of a photo content. Specifies one or more terms from the IPTC "
635
                                                                                                                        "\"Scene-NewsCodes\". Each Scene is represented as a string of 6 digits in an unordered list.") },
636
        { "SubjectCode",        N_("IPTC Subject Code"),           "bag closed Choice of Text", xmpBag, xmpExternal, N_("Specifies one or more Subjects from the IPTC \"Subject-NewsCodes\" taxonomy to "
637
                                                                                                                        "categorize the content. Each Subject is represented as a string of 8 digits in an unordered list.") },
638
        // End of list marker
639
        { 0, 0, 0, invalidTypeId, xmpInternal, 0 }
640
    };
641

    
642
    extern const XmpPropertyInfo xmpIptcExtInfo[] = {
643
        { "AddlModelInfo",           N_("Additional model info"),           "Text",                       xmpText, xmpExternal, N_("Information about the ethnicity and other facts of the model(s) in a model-released image.") },
644
        { "OrganisationInImageCode", N_("Code of featured Organisation"),   "bag Text",                   xmpBag,  xmpExternal, N_("Code from controlled vocabulary for identyfing the organisation or company which is featured in the image.") },
645
        { "CVterm",                  N_("Controlled Vocabulary Term"),      "bag URI",                    xmpBag,  xmpExternal, N_("A term to describe the content of the image by a value from a Controlled Vocabulary.") },
646
        { "ModelAge",                N_("Model age"),                       "bag Integer",                xmpBag,  xmpExternal, N_("Age of the human model(s) at the time this image was taken in a model released image.") },
647
        { "OrganisationInImageName", N_("Name of featured Organisation"),   "bag Text",                   xmpBag,  xmpExternal, N_("Name of the organisation or company which is featured in the image.") },
648
        { "PersonInImage",           N_("Person shown"),                    "bag Text",                   xmpBag,  xmpExternal, N_("Name of a person shown in the image.") },
649
        { "DigImageGUID",            N_("Digital Image Identifier"),        "Text",                       xmpText, xmpExternal, N_("Globally unique identifier for this digital image. It is created and applied by the creator of the digital image at the time of its creation. this value shall not be changed after that time.") },
650
        { "DigitalSourcefileType",   N_("Physical type of original photo"), "URI",                        xmpText, xmpExternal, N_("The type of the source digital file.") },
651
        { "Event",                   N_("Event"),                           "Lang Alt",                   langAlt, xmpExternal, N_("Names or describes the specific event at which the photo was taken.") },
652
        { "MaxAvailHeight",          N_("Maximum available height"),        "Integer",                    xmpText, xmpExternal, N_("The maximum available height in pixels of the original photo from which this photo has been derived by downsizing.") },
653
        { "MaxAvailWidth",           N_("Maximum available width"),         "Integer",                    xmpText, xmpExternal, N_("The maximum available width in pixels of the original photo from which this photo has been derived by downsizing.") },
654
        { "RegistryId",              N_("Registry Entry"),                  "bag RegistryEntryDetails",   xmpBag,  xmpExternal, N_("Both a Registry Item Id and a Registry Organisation Id to record any registration of this digital image with a registry.") },
655
        { "RegItemId",               N_("Registry Entry-Item Identifier"),  "Text",                       xmpText, xmpExternal, N_("A unique identifier created by a registry and applied by the creator of the digital image. This value shall not be changed after being applied. This identifier is linked to a corresponding Registry Organisation Identifier.") },
656
        { "RegOrgId",                N_("Registry Entry-Organisation Identifier"), "Text",                xmpText, xmpExternal, N_("An identifier for the registry which issued the corresponding Registry Image Id.") },
657
        { "IptcLastEdited",          N_("IPTC Fields Last Edited"),         "Date",                       xmpText, xmpExternal, N_("The date and optionally time when any of the IPTC photo metadata fields has been last edited.") },
658
        { "LocationShown",           N_("Location shown"),                  "bag LocationDetails",        xmpBag,  xmpExternal, N_("A location shown in the image.") },
659
        { "LocationCreated",         N_("Location Created"),                "bag LocationDetails",        xmpBag,  xmpExternal, N_("The location the photo was taken.") },
660
        { "City",                    N_("Location-City"),                   "Text",                       xmpText, xmpExternal, N_("Name of the city of a location.") },
661
        { "CountryCode",             N_("Location-Country ISO-Code"),       "Text",                       xmpText, xmpExternal, N_("The ISO code of a country of a location.") },
662
        { "CountryName",             N_("Location-Country Name"),           "Text",                       xmpText, xmpExternal, N_("The name of a country of a location.") },
663
        { "ProvinceState",           N_("Location-Province/State"),         "Text",                       xmpText, xmpExternal, N_("The name of a subregion of a country - a province or state - of a location.") },
664
        { "Sublocation",             N_("Location-Sublocation"),            "Text",                       xmpText, xmpExternal, N_("Name of a sublocation. This sublocation name could either be the name of a sublocation to a city or the name of a well known location or (natural) monument outside a city.") },
665
        { "WorldRegion",             N_("Location-World Region"),           "Text",                       xmpText, xmpExternal, N_("The name of a world region of a location.") },
666
        { "ArtworkOrObject",         N_("Artwork or object in the image"),  "bag ArtworkOrObjectDetails", xmpBag,  xmpExternal, N_("A set of metadata about artwork or an object in the image.") },
667
        { "AOCopyrightNotice",       N_("Artwork or object-Copyright notice"), "Text",                    xmpText, xmpExternal, N_("Contains any necessary copyright notice for claiming the intellectual property for artwork or an object in the image and should identify the current owner of the copyright of this work with associated intellectual property rights.") },
668
        { "AOCreator",               N_("Artwork or object-Creator"),       "seq ProperName",             xmpSeq,  xmpExternal, N_("Contains the name of the artist who has created artwork or an object in the image. In cases where the artist could or should not be identified the name of a company or organisation may be appropriate.") },
669
        { "AODateCreated",           N_("Artwork or object-Date Created"),  "Date",                       xmpText, xmpExternal, N_("Designates the date and optionally the time the artwork or object in the image was created. This relates to artwork or objects with associated intellectual property rights.") },
670
        { "AOSource",                N_("Artwork or object-Source"),        "Text",                       xmpText, xmpExternal, N_("The organisation or body holding and registering the artwork or object in the image for inventory purposes.") },
671
        { "AOSourceInvNo",           N_("Artwork or object-Source inventory number"), "Text",             xmpText, xmpExternal, N_("The inventory number issued by the organisation or body holding and registering the artwork or object in the image.") },
672
        { "AOTitle",                 N_("Artwork or object-Title"),         "Lang Alt",                   langAlt, xmpExternal, N_("A reference for the artwork or object in the image.") },
673
        // End of list marker
674
        { 0, 0, 0, invalidTypeId, xmpInternal, 0 }
675
    };
676

    
677
    //! XMP iptcExt:DigitalSourcefileType
678
    extern const TagVocabulary iptcExtDigitalSourcefileType[] = {
679
        { "scanfilm",         N_("Scan from film")                           },
680
        { "scantransparency", N_("Scan from transparency (including slide)") },
681
        { "scanprint",        N_("Scan from print")                          },
682
        { "cameraraw",        N_("Camera RAW")                               },
683
        { "cameratiff",       N_("Camera TIFF")                              },
684
        { "camerajpeg",       N_("Camera JPEG")                              }
685
    };
686

    
687
    extern const XmpPropertyInfo xmpPlusInfo[] = {
688
        // PLUS Version 1.2.0
689
        { "Version", N_("PLUS Version"), "Text", xmpText, xmpExternal, N_("The version number of the PLUS standards in place at the time of the transaction.") },
690
        { "Licensee", N_("Licensee"), "seq LicenseeDetail", xmpSeq, xmpExternal, N_("Party or parties to whom the license is granted by the Licensor/s under the license transaction.") },
691
        { "LicenseeID", N_("Licensee ID"), "Text", xmpText, xmpExternal, N_("Optional PLUS-ID identifying each Licensee.") },
692
        { "LicenseeName", N_("Licensee Name"), "ProperName", xmpText, xmpExternal, N_("Name of each Licensee.") },
693
        { "EndUser", N_("End User"), "seq EndUserDetail", xmpSeq, xmpExternal, N_("Party or parties ultimately making use of the image under the license.") },
694
        { "EndUserID", N_("End User ID"), "Text", xmpText, xmpExternal, N_("Optional PLUS-ID identifying each End User.") },
695
        { "EndUserName", N_("End User Name"), "ProperName", xmpText, xmpExternal, N_("Name of each End User.") },
696
        { "Licensor", N_("Licensor"), "seq LicensorDetail", xmpSeq, xmpExternal, N_("Party or parties granting the license to the Licensee.") },
697
        { "LicensorID", N_("Licensor ID"), "Text", xmpText, xmpExternal, N_("Optional PLUS-ID identifying each Licensor.") },
698
        { "LicensorName", N_("Licensor Name"), "ProperName", xmpText, xmpExternal, N_("Name of each Licensor.") },
699
        { "LicensorStreetAddress", N_("Licensor Address"), "Text", xmpText, xmpExternal, N_("Licensor street address.") },
700
        { "LicensorExtendedAddress", N_("Licensor Address Detail"), "Text", xmpText, xmpExternal, N_("Additional Licensor mailing address details.") },
701
        { "LicensorCity", N_("Licensor City"), "Text", xmpText, xmpExternal, N_("Licensor City name.") },
702
        { "LicensorRegion", N_("Licensor State or Province"), "Text", xmpText, xmpExternal, N_("Licensor State or Province name.") },
703
        { "LicensorPostalCode", N_("Licensor Postal Code"), "Text", xmpText, xmpExternal, N_("Licensor Postal Code or Zip Code.") },
704
        { "LicensorCountry", N_("Licensor Country"), "Text", xmpText, xmpExternal, N_("Licensor Country name.") },
705
        { "LicensorTelephoneType1", N_("Licensor Telephone Type 1"), "URL", xmpText, xmpExternal, N_("Licensor Telephone Type 1.") },
706
        { "LicensorTelephone1", N_("Licensor Telephone 1"), "Text", xmpText, xmpExternal, N_("Licensor Telephone number 1.") },
707
        { "LicensorTelephoneType2", N_("Licensor Telephone Type 2"), "URL", xmpText, xmpExternal, N_("Licensor Telephone Type 2.") },
708
        { "LicensorTelephone2", N_("Licensor Telephone 2"), "Text", xmpText, xmpExternal, N_("Licensor Telephone number 2.") },
709
        { "LicensorEmail", N_("Licensor Email"), "Text", xmpText, xmpExternal, N_("Licensor Email address.") },
710
        { "LicensorURL", N_("Licensor URL"), "URL", xmpText, xmpExternal, N_("Licensor world wide web address.") },
711
        { "LicensorNotes", N_("Licensor Notes"), "Lang Alt", langAlt, xmpExternal, N_("Supplemental information for use in identifying and contacting the Licensor/s.") },
712
        { "MediaSummaryCode", N_("PLUS Media Summary Code"), "Text", xmpText, xmpExternal, N_("A PLUS-standardized alphanumeric code string summarizing the media usages included in the license.") },
713
        { "LicenseStartDate", N_("License Start Date"), "Date", xmpText, xmpExternal, N_("The date on which the license takes effect.") },
714
        { "LicenseEndDate", N_("License End Date"), "Date", xmpText, xmpExternal, N_("The date on which the license expires.") },
715
        { "MediaConstraints", N_("Media Constraints"), "Lang Alt", langAlt, xmpExternal, N_("Constraints limiting the scope of PLUS Media Usage/s included in the license to particular named media or to media not yet specifically defined in the PLUS Media Matrix.") },
716
        { "RegionConstraints", N_("Region Constraints"), "Lang Alt", langAlt, xmpExternal, N_("Constraints limiting the scope of geographic distribution to specific cities, states, provinces or other areas to be included in or excluded from the PLUS Regions specified in the Media Usages specified in the license.") },
717
        { "ProductOrServiceConstraints", N_("Product or Service Constraints"), "Lang Alt", langAlt, xmpExternal, N_("Constraints limiting usage of the image to promotion of/association with a named product or service.") },
718
        { "ImageFileConstraints", N_("Image File Constraints"), "bag URL", xmpBag, xmpExternal, N_("Constraints on the changing of the image file name, metadata or file type.") },
719
        { "ImageAlterationConstraints", N_("Image Alteration Constraints"), "bag URL", xmpBag, xmpExternal, N_("Constraints on alteration of the image by cropping, flipping, retouching, colorization, de-colorization or merging.") },
720
        { "ImageDuplicationConstraints", N_("Image Duplication Constraints"), "URL", xmpText, xmpExternal, N_("Constraints on the creation of duplicates of the image.") },
721
        { "ModelReleaseStatus", N_("Model Release Status"), "URL", xmpText, xmpExternal, N_("Summarizes the availability and scope of model releases authorizing usage of the likenesses of persons appearing in the photograph.") },
722
        { "ModelReleaseID", N_("Model Release ID"), "bag Text", xmpBag, xmpExternal, N_("Optional identifier associated with each Model Release.") },
723
        { "MinorModelAgeDisclosure", N_("Minor Model Age Disclosure"), "URL", xmpText, xmpExternal, N_("Age of the youngest model pictured in the image, at the time that the image was made.") },
724
        { "PropertyReleaseStatus", N_("Property Release Status"), "URL", xmpText, xmpExternal, N_("Summarizes the availability and scope of property releases authorizing usage of the properties appearing in the photograph.") },
725
        { "PropertyReleaseID", N_("Property Release ID"), "bag Text", xmpBag, xmpExternal, N_("Optional identifier associated with each Property Release.") },
726
        { "OtherConstraints", N_("Other Constraints"), "Lang Alt", langAlt, xmpExternal, N_("Additional constraints on the license.") },
727
        { "CreditLineRequired", N_("Credit Line Required"), "URL", xmpText, xmpExternal, N_("Attribution requirements, if any.") },
728
        { "AdultContentWarning", N_("Adult Content Warning"), "URL", xmpText, xmpExternal, N_("Warning indicating the presence of content not suitable for minors.") },
729
        { "OtherLicenseRequirements", N_("Other License Requirements"), "Lang Alt", langAlt, xmpExternal, N_("Additional license requirements.") },
730
        { "TermsAndConditionsText", N_("Terms and Conditions Text"), "Lang Alt", langAlt, xmpExternal, N_("Terms and Conditions applying to the license.") },
731
        { "TermsAndConditionsURL", N_("Terms and Conditions URL"), "URL", xmpText, xmpExternal, N_("URL for Terms and Conditions applying to the license.") },
732
        { "OtherConditions", N_("Other License Conditions"), "Lang Alt", langAlt, xmpExternal, N_("Additional license conditions.") },
733
        { "ImageType", N_("Image Type"), "URL", xmpText, xmpExternal, N_("Identifies the type of image delivered.") },
734
        { "LicensorImageID", N_("Licensor Image ID"), "Text", xmpText, xmpExternal, N_("Optional identifier assigned by the Licensor to the image.") },
735
        { "FileNameAsDelivered", N_("Image File Name As Delivered"), "Text", xmpText, xmpExternal, N_("Name of the image file delivered to the Licensee for use under the license.") },
736
        { "ImageFileFormatAsDelivered", N_("Image File Format As Delivered"), "URL", xmpText, xmpExternal, N_("File format of the image file delivered to the Licensee for use under the license.") },
737
        { "ImageFileSizeAsDelivered", N_("Image File Size As Delivered"), "URL", xmpText, xmpExternal, N_("Size of the image file delivered to the Licensee.") },
738
        { "CopyrightStatus", N_("Copyright Status"), "URL", xmpText, xmpExternal, N_("Copyright status of the image.") },
739
        { "CopyrightRegistrationNumber", N_("Copyright Registration Number"), "Text", xmpText, xmpExternal, N_("Copyright Registration Number, if any, applying to the licensed image.") },
740
        { "FirstPublicationDate", N_("First Publication Date"), "Date", xmpText, xmpExternal, N_("The date on which the image was first published.") },
741
        { "CopyrightOwner", N_("Copyright Owner"), "seq CopyrightOwnerDetail", xmpSeq, xmpExternal, N_("Owner or owners of the copyright in the licensed image.") },
742
        { "CopyrightOwnerID", N_("Copyright Owner ID"), "Text", xmpText, xmpExternal, N_("Optional PLUS-ID identifying each Copyright Owner.") },
743
        { "CopyrightOwnerName", N_("Copyright Owner Name"), "ProperName", xmpText, xmpExternal, N_("Name of Copyright Owner.") },
744
        { "CopyrightOwnerImageID", N_("Copyright Owner Image ID"), "Text", xmpText, xmpExternal, N_("Optional identifier assigned by the Copyright Owner to the image.") },
745
        { "ImageCreator", N_("Image Creator"), "seq ImageCreatorDetail", xmpSeq, xmpExternal, N_("Creator/s of the image.") },
746
        { "ImageCreatorID", N_("Image Creator ID"), "Text", xmpText, xmpExternal, N_("Optional PLUS-ID identifying each Image Creator.") },
747
        { "ImageCreatorName", N_("Image Creator Name"), "ProperName", xmpText, xmpExternal, N_("Name of Image Creator.") },
748
        { "ImageCreatorImageID", N_("Image Creator Image ID"), "Text", xmpText, xmpExternal, N_("Optional identifier assigned by the Image Creator to the image.") },
749
        { "ImageSupplierID", N_("Image Supplier ID"), "Text", xmpText, xmpExternal, N_("Optional PLUS-ID identifying the Image Supplier.") },
750
        { "ImageSupplierName", N_("Image Supplier Name"), "ProperName", xmpText, xmpExternal, N_("Name of Image Supplier.") },
751
        { "ImageSupplierImageID", N_("Image Supplier Image ID"), "Text", xmpText, xmpExternal, N_("Optional identifier assigned by the Image Supplier to the image.") },
752
        { "LicenseeImageID", N_("Licensee Image ID"), "Text", xmpText, xmpExternal, N_("Optional identifier assigned by the Licensee to the image.") },
753
        { "LicenseeImageNotes", N_("Licensee Image Notes"), "Lang Alt", langAlt, xmpExternal, N_("Notes added by Licensee.") },
754
        { "OtherImageInfo", N_("Other Image Info"), "Lang Alt", langAlt, xmpExternal, N_("Additional image information.") },
755
        { "LicenseID", N_("License ID"), "Text", xmpText, xmpExternal, N_("Optional PLUS-ID assigned by the Licensor to the License.") },
756
        { "LicensorTransactionID", N_("Licensor Transaction ID"), "bag Text", xmpBag, xmpExternal, N_("Identifier assigned by Licensor for Licensor's reference and internal use.") },
757
        { "LicenseeTransactionID", N_("Licensee Transaction ID"), "bag Text", xmpBag, xmpExternal, N_("Identifier assigned by Licensee for Licensee's reference and internal use.") },
758
        { "LicenseeProjectReference", N_("Licensee Project Reference"), "bag Text", xmpBag, xmpExternal, N_("Project reference name or description assigned by Licensee.") },
759
        { "LicenseTransactionDate", N_("License Transaction Date"), "Date", xmpText, xmpExternal, N_("The date of the License Transaction.") },
760
        { "Reuse", N_("Reuse"), "URL", xmpText, xmpExternal, N_("Indicates whether a license is a repeat or an initial license.  Reuse may require that licenses stored in files previously delivered to the customer be updated.") },
761
        { "OtherLicenseDocuments", N_("Other License Documents"), "bag Text", xmpBag, xmpExternal, N_("Reference information for additional documents associated with the license.") },
762
        { "OtherLicenseInfo", N_("Other License Info"), "Lang Alt", langAlt, xmpExternal, N_("Additional license information.") },
763
        { "Custom1", N_("Custom 1"), "bag Lang Alt", xmpBag, xmpExternal, N_("Optional field for use at Licensor's discretion.") },
764
        { "Custom2", N_("Custom 2"), "bag Lang Alt", xmpBag, xmpExternal, N_("Optional field for use at Licensor's discretion.") },
765
        { "Custom3", N_("Custom 3"), "bag Lang Alt", xmpBag, xmpExternal, N_("Optional field for use at Licensor's discretion.") },
766
        { "Custom4", N_("Custom 4"), "bag Lang Alt", xmpBag, xmpExternal, N_("Optional field for use at Licensor's discretion.") },
767
        { "Custom5", N_("Custom 5"), "bag Lang Alt", xmpBag, xmpExternal, N_("Optional field for use at Licensor's discretion.") },
768
        { "Custom6", N_("Custom 6"), "bag Lang Alt", xmpBag, xmpExternal, N_("Optional field for use at Licensee's discretion.") },
769
        { "Custom7", N_("Custom 7"), "bag Lang Alt", xmpBag, xmpExternal, N_("Optional field for use at Licensee's discretion.") },
770
        { "Custom8", N_("Custom 8"), "bag Lang Alt", xmpBag, xmpExternal, N_("Optional field for use at Licensee's discretion.") },
771
        { "Custom9", N_("Custom 9"), "bag Lang Alt", xmpBag, xmpExternal, N_("Optional field for use at Licensee's discretion.") },
772
        { "Custom10", N_("Custom 10"), "bag Lang Alt", xmpBag, xmpExternal, N_("Optional field for use at Licensee's discretion.") },
773
        // End of list marker
774
        { 0, 0, 0, invalidTypeId, xmpInternal, 0 }
775
    };
776

    
777

    
778
        //! XMP plus:AdultContentWarning
779
    extern const TagVocabulary plusAdultContentWarning[] = {
780
        { "CW-AWR", N_("Adult Content Warning Required") },
781
        { "CW-NRQ", N_("Not Required")                   },
782
        { "CW-UNK", N_("Unknown")                        }
783
    };
784

    
785
    //! XMP plus:CopyrightStatus
786
    extern const TagVocabulary plusCopyrightStatus[] = {
787
        { "CS-PRO", N_("Protected")     },
788
        { "CS-PUB", N_("Public Domain") },
789
        { "CS-UNK", N_("Unknown")       }
790
    };
791

    
792
    //! XMP plus:CreditLineRequired
793
    extern const TagVocabulary plusCreditLineRequired[] = {
794
        { "CR-CAI", N_("Credit Adjacent To Image") },
795
        { "CR-CCA", N_("Credit in Credits Area")   },
796
        { "CR-COI", N_("Credit on Image")          },
797
        { "CR-NRQ", N_("Not Require")              }
798
    };
799

    
800
    //! XMP plus:ImageAlterationConstraints
801
    extern const TagVocabulary plusImageAlterationConstraints[] = {
802
        { "AL-CLR", N_("No Colorization")    },
803
        { "AL-CRP", N_("No Cropping")        },
804
        { "AL-DCL", N_("No De-Colorization") },
805
        { "AL-FLP", N_("No Flipping")        },
806
        { "AL-MRG", N_("No Merging")         },
807
        { "AL-RET", N_("No Retouching")      }
808
    };
809

    
810
    //! XMP plus:ImageDuplicationConstraints
811
    extern const TagVocabulary plusImageDuplicationConstraints[] = {
812
        { "DP-LIC", N_("Duplication Only as Necessary Under License") },
813
        { "DP-NDC", N_("No Duplication Constraints")                  },
814
        { "DP-NOD", N_("No Duplication")                              }
815
    };
816

    
817
    //! XMP plus:ImageFileConstraints
818
    extern const TagVocabulary plusImageFileConstraints[] = {
819
        { "IF-MFN", N_("Maintain File Name")       },
820
        { "IF-MFT", N_("Maintain File Type")       },
821
        { "IF-MID", N_("Maintain ID in File Name") },
822
        { "IF-MMD", N_("Maintain Metadata")        }
823
    };
824

    
825
    //! XMP plus:ImageFileFormatAsDelivered
826
    extern const TagVocabulary plusImageFileFormatAsDelivered[] = {
827
        { "FF-BMP", N_("Windows Bitmap (BMP)")                      },
828
        { "FF-DNG", N_("Digital Negative (DNG)")                    },
829
        { "FF-EPS", N_("Encapsulated PostScript (EPS)")             },
830
        { "FF-GIF", N_("Graphics Interchange Format (GIF)")         },
831
        { "FF-JPG", N_("JPEG Interchange Formats (JPG, JIF, JFIF)") },
832
        { "FF-OTR", N_("Other")                                     },
833
        { "FF-PIC", N_("Macintosh Picture (PICT)")                  },
834
        { "FF-PNG", N_("Portable Network Graphics (PNG)")           },
835
        { "FF-PSD", N_("Photoshop Document (PSD)")                  },
836
        { "FF-RAW", N_("Proprietary RAW Image Format")              },
837
        { "FF-TIF", N_("Tagged Image File Format (TIFF)")           },
838
        { "FF-WMP", N_("Windows Media Photo (HD Photo)")            }
839
    };
840

    
841
    //! XMP plus:ImageFileSizeAsDelivered
842
    extern const TagVocabulary plusImageFileSizeAsDelivered[] = {
843
        { "SZ-G50", N_("Greater than 50 MB") },
844
        { "SZ-U01", N_("Up to 1 MB")         },
845
        { "SZ-U10", N_("Up to 10 MB")        },
846
        { "SZ-U30", N_("Up to 30 MB")        },
847
        { "SZ-U50", N_("Up to 50 MB")        }
848
    };
849

    
850
    //! XMP plus:ImageType
851
    extern const TagVocabulary plusImageType[] = {
852
        { "TY-ILL", N_("Illustrated Image")              },
853
        { "TY-MCI", N_("Multimedia or Composited Image") },
854
        { "TY-OTR", N_("Other")                          },
855
        { "TY-PHO", N_("Photographic Image")             },
856
        { "TY-VID", N_("Video")                          }
857
    };
858

    
859
    //! XMP plus:LicensorTelephoneType
860
    extern const TagVocabulary plusLicensorTelephoneType[] = {
861
        { "cell",  N_("Cell")  },
862
        { "fax",   N_("FAX")   },
863
        { "home",  N_("Home")  },
864
        { "pager", N_("Pager") },
865
        { "work",  N_("Work")  }
866
    };
867

    
868
    //! XMP plus:MinorModelAgeDisclosure
869
    extern const TagVocabulary plusMinorModelAgeDisclosure[] = {
870
        { "AG-UNK", N_("Age Unknown")     },
871
        { "AG-A25", N_("Age 25 or Over")  },
872
        { "AG-A24", N_("Age 24")          },
873
        { "AG-A23", N_("Age 23")          },
874
        { "AG-A22", N_("Age 22")          },
875
        { "AG-A21", N_("Age 21")          },
876
        { "AG-A20", N_("Age 20")          },
877
        { "AG-A19", N_("Age 19")          },
878
        { "AG-A18", N_("Age 18")          },
879
        { "AG-A17", N_("Age 17")          },
880
        { "AG-A16", N_("Age 16")          },
881
        { "AG-A15", N_("Age 15")          },
882
        { "AG-U14", N_("Age 14 or Under") }
883
    };
884

    
885
    //! XMP plus:ModelReleaseStatus
886
    extern const TagVocabulary plusModelReleaseStatus[] = {
887
        { "MR-NON", N_("None")                                 },
888
        { "MR-NAP", N_("Not Applicable")                       },
889
        { "MR-UMR", N_("Unlimited Model Releases")             },
890
        { "MR-LMR", N_("Limited or Incomplete Model Releases") }
891
    };
892

    
893
    //! XMP plus:PropertyReleaseStatus
894
    extern const TagVocabulary plusPropertyReleaseStatus[] = {
895
        { "PR-NON", N_("None")                                    },
896
        { "PR-NAP", N_("Not Applicable")                          },
897
        { "PR-UPR", N_("Unlimited Property Releases")             },
898
        { "PR-LPR", N_("Limited or Incomplete Property Releases") }
899
    };
900

    
901
    //! XMP plus:Reuse
902
    extern const TagVocabulary plusReuse[] = {
903
        { "RE-NAP", N_("Not Applicable") },
904
        { "RE-REU", N_("Repeat Use")     }
905
    };
906

    
907
    extern const XmpPrintInfo xmpPrintInfo[] = {
908
        {"Xmp.crs.CropUnits",                 EXV_PRINT_TAG(crsCropUnits)   },
909
        {"Xmp.exif.ApertureValue",            print0x9202                   },
910
        {"Xmp.exif.BrightnessValue",          printFloat                    },
911
        {"Xmp.exif.ColorSpace",               print0xa001                   },
912
        {"Xmp.exif.ComponentsConfiguration",  print0x9101                   },
913
        {"Xmp.exif.Contrast",                 printNormalSoftHard           },
914
        {"Xmp.exif.CreateDate",               printXmpDate                  },
915
        {"Xmp.exif.CustomRendered",           print0xa401                   },
916
        {"Xmp.exif.DateTimeOriginal",         printXmpDate                  },
917
        {"Xmp.exif.ExifVersion",              printXmpVersion               },
918
        {"Xmp.exif.ExposureBiasValue",        print0x9204                   },
919
        {"Xmp.exif.ExposureMode",             print0xa402                   },
920
        {"Xmp.exif.ExposureProgram",          print0x8822                   },
921
        {"Xmp.exif.FileSource",               print0xa300                   },
922
        {"Xmp.exif.FlashpixVersion",          printXmpVersion               },
923
        {"Xmp.exif.FNumber",                  print0x829d                   },
924
        {"Xmp.exif.FocalLength",              print0x920a                   },
925
        {"Xmp.exif.FocalPlaneResolutionUnit", printExifUnit                 },
926
        {"Xmp.exif.FocalPlaneXResolution",    printFloat                    },
927
        {"Xmp.exif.FocalPlaneYResolution",    printFloat                    },
928
        {"Xmp.exif.GainControl",              print0xa407                   },
929
        {"Xmp.exif.GPSAltitudeRef",           print0x0005                   },
930
        {"Xmp.exif.GPSDestBearingRef",        printGPSDirRef                },
931
        {"Xmp.exif.GPSDestDistanceRef",       print0x0019                   },
932
        {"Xmp.exif.GPSDifferential",          print0x001e                   },
933
        {"Xmp.exif.GPSImgDirectionRef",       printGPSDirRef                },
934
        {"Xmp.exif.GPSMeasureMode",           print0x000a                   },
935
        {"Xmp.exif.GPSSpeedRef",              print0x000c                   },
936
        {"Xmp.exif.GPSStatus",                print0x0009                   },
937
        {"Xmp.exif.GPSTimeStamp",             printXmpDate                  },
938
        {"Xmp.exif.GPSTrackRef",              printGPSDirRef                },
939
        {"Xmp.exif.LightSource",              print0x9208                   },
940
        {"Xmp.exif.MeteringMode",             print0x9207                   },
941
        {"Xmp.exif.ModifyDate",               printXmpDate                  },
942
        {"Xmp.exif.Saturation",               print0xa409                   },
943
        {"Xmp.exif.SceneCaptureType",         print0xa406                   },
944
        {"Xmp.exif.SceneType",                print0xa301                   },
945
        {"Xmp.exif.SensingMethod",            print0xa217                   },
946
        {"Xmp.exif.Sharpness",                printNormalSoftHard           },
947
        {"Xmp.exif.ShutterSpeedValue",        print0x9201                   },
948
        {"Xmp.exif.SubjectDistanceRange",     print0xa40c                   },
949
        {"Xmp.exif.WhiteBalance",             print0xa403                   },
950
        {"Xmp.tiff.Orientation",              print0x0112                   },
951
        {"Xmp.tiff.ResolutionUnit",           printExifUnit                 },
952
        {"Xmp.tiff.XResolution",              printLong                     },
953
        {"Xmp.tiff.YCbCrPositioning",         print0x0213                   },
954
        {"Xmp.tiff.YResolution",              printLong                     },
955
        {"Xmp.iptcExt.DigitalSourcefileType",    EXV_PRINT_VOCABULARY(iptcExtDigitalSourcefileType)   },
956
        {"Xmp.plus.AdultContentWarning",         EXV_PRINT_VOCABULARY(plusAdultContentWarning)        },
957
        {"Xmp.plus.CopyrightStatus",             EXV_PRINT_VOCABULARY(plusCopyrightStatus)            },
958
        {"Xmp.plus.CreditLineRequired",          EXV_PRINT_VOCABULARY(plusCreditLineRequired)         },
959
        {"Xmp.plus.ImageAlterationConstraints",  EXV_PRINT_VOCABULARY(plusImageAlterationConstraints) },
960
        {"Xmp.plus.ImageDuplicationConstraints", EXV_PRINT_VOCABULARY(plusImageDuplicationConstraints)},
961
        {"Xmp.plus.ImageFileConstraints",        EXV_PRINT_VOCABULARY(plusImageFileConstraints)       },
962
        {"Xmp.plus.ImageFileFormatAsDelivered",  EXV_PRINT_VOCABULARY(plusImageFileFormatAsDelivered) },
963
        {"Xmp.plus.ImageFileSizeAsDelivered",    EXV_PRINT_VOCABULARY(plusImageFileSizeAsDelivered)   },
964
        {"Xmp.plus.ImageType",                   EXV_PRINT_VOCABULARY(plusImageType)                  },
965
        {"Xmp.plus.LicensorTelephoneType1",      EXV_PRINT_VOCABULARY(plusLicensorTelephoneType)      },
966
        {"Xmp.plus.LicensorTelephoneType2",      EXV_PRINT_VOCABULARY(plusLicensorTelephoneType)      },
967
        {"Xmp.plus.MinorModelAgeDisclosure",     EXV_PRINT_VOCABULARY(plusMinorModelAgeDisclosure)    },
968
        {"Xmp.plus.ModelReleaseStatus",          EXV_PRINT_VOCABULARY(plusModelReleaseStatus)         },
969
        {"Xmp.plus.PropertyReleaseStatus",       EXV_PRINT_VOCABULARY(plusPropertyReleaseStatus)      },
970
        {"Xmp.plus.Reuse",                       EXV_PRINT_VOCABULARY(plusReuse)                      }
971
    };
972

    
973
    extern const XmpPropertyInfo XmpmediaproInfo[] = {
974
		{ "Event",        N_("Event"),        "Text",       xmpText, xmpExternal, N_("Fixture Identification") },
975
		{ "Status",        N_("Status"),        "Text",       xmpText, xmpExternal, N_("A notation making the image unique") },
976
		{ "People",        N_("People"),        "bag Text",       xmpBag, xmpExternal, N_("Contact") },
977
		{ "CatalogSets",        N_("CatalogSets"),        "bag Text",       xmpBag, xmpExternal, N_("Descriptive markers of catalog items by content") },
978
		// End of list marker
979
        { 0, 0, 0, invalidTypeId, xmpInternal, 0 }
980
    };
981

    
982
        extern const XmpPropertyInfo XmpexpressionmediaInfo[] = {
983
		{ "Event",        N_("Event"),        "Text",       xmpText, xmpExternal, N_("Fixture Identification") },
984
		{ "Status",        N_("Status"),        "Text",       xmpText, xmpExternal, N_("A notation making the image unique") },
985
		{ "People",        N_("People"),        "bag Text",       xmpBag, xmpExternal, N_("Contact") },
986
		{ "CatalogSets",        N_("CatalogSets"),        "bag Text",       xmpBag, xmpExternal, N_("Descriptive markers of catalog items by content") },
987
		// End of list marker
988
        { 0, 0, 0, invalidTypeId, xmpInternal, 0 }
989
    };
990

    
991
    XmpNsInfo::Ns::Ns(const std::string& ns)
992
        : ns_(ns)
993
    {
994
    }
995

    
996
    XmpNsInfo::Prefix::Prefix(const std::string& prefix)
997
        : prefix_(prefix)
998
    {
999
    }
1000

    
1001
    bool XmpNsInfo::operator==(const XmpNsInfo::Ns& ns) const
1002
    {
1003
        std::string n(ns_);
1004
        return n == ns.ns_;
1005
    }
1006

    
1007
    bool XmpNsInfo::operator==(const XmpNsInfo::Prefix& prefix) const
1008
    {
1009
        std::string p(prefix_);
1010
        return p == prefix.prefix_;
1011
    }
1012

    
1013
    bool XmpPropertyInfo::operator==(const std::string& name) const
1014
    {
1015
        std::string n(name_);
1016
        return n == name;
1017
    }
1018

    
1019
    XmpProperties::NsRegistry XmpProperties::nsRegistry_;
1020

    
1021
    const XmpNsInfo* XmpProperties::lookupNsRegistry(const XmpNsInfo::Prefix& prefix)
1022
    {
1023
        for (NsRegistry::const_iterator i = nsRegistry_.begin();
1024
             i != nsRegistry_.end(); ++i) {
1025
            if (i->second == prefix) return &(i->second);
1026
        }
1027
        return 0;
1028
    }
1029

    
1030
    void XmpProperties::registerNs(const std::string& ns,
1031
                                   const std::string& prefix)
1032
    {
1033
        std::string ns2 = ns;
1034
        if (   ns2.substr(ns2.size() - 1, 1) != "/"
1035
            && ns2.substr(ns2.size() - 1, 1) != "#") ns2 += "/";
1036
        // Allocated memory is freed when the namespace is unregistered.
1037
        // Using malloc/free for better system compatibility in case
1038
        // users don't unregister their namespaces explicitely.
1039
        XmpNsInfo xn;
1040
        char* c = static_cast<char*>(std::malloc(ns2.size() + 1));
1041
        std::strcpy(c, ns2.c_str());
1042
        xn.ns_ = c;
1043
        c = static_cast<char*>(std::malloc(prefix.size() + 1));
1044
        std::strcpy(c, prefix.c_str());
1045
        xn.prefix_ = c;
1046
        xn.xmpPropertyInfo_ = 0;
1047
        xn.desc_ = "";
1048
        nsRegistry_[ns2] = xn;
1049
        XmpParser::registerNs(ns2, prefix);
1050
    }
1051

    
1052
    void XmpProperties::unregisterNs(const std::string& ns)
1053
    {
1054
        NsRegistry::iterator i = nsRegistry_.find(ns);
1055
        if (i != nsRegistry_.end()) {
1056
            XmpParser::unregisterNs(ns);
1057
            std::free(const_cast<char*>(i->second.prefix_));
1058
            std::free(const_cast<char*>(i->second.ns_));
1059
            nsRegistry_.erase(i);
1060
        }
1061
    }
1062

    
1063
    void XmpProperties::unregisterNs()
1064
    {
1065
        NsRegistry::iterator i = nsRegistry_.begin();
1066
        while (i != nsRegistry_.end()) {
1067
            NsRegistry::iterator kill = i++;
1068
            unregisterNs(kill->first);
1069
        }
1070
    }
1071

    
1072
    std::string XmpProperties::prefix(const std::string& ns)
1073
    {
1074
        std::string ns2 = ns;
1075
        if (   ns2.substr(ns2.size() - 1, 1) != "/"
1076
            && ns2.substr(ns2.size() - 1, 1) != "#") ns2 += "/";
1077
        NsRegistry::const_iterator i = nsRegistry_.find(ns2);
1078
        std::string p;
1079
        if (i != nsRegistry_.end()) {
1080
            p = i->second.prefix_;
1081
        }
1082
        else {
1083
            const XmpNsInfo* xn = find(xmpNsInfo, XmpNsInfo::Ns(ns2));
1084
            if (xn) p = std::string(xn->prefix_);
1085
        }
1086
        return p;
1087
    }
1088

    
1089
    std::string XmpProperties::ns(const std::string& prefix)
1090
    {
1091
        const XmpNsInfo* xn = lookupNsRegistry(XmpNsInfo::Prefix(prefix));
1092
        if (xn != 0) return xn->ns_;
1093
        return nsInfo(prefix)->ns_;
1094
    }
1095

    
1096
    const char* XmpProperties::propertyTitle(const XmpKey& key)
1097
    {
1098
        const XmpPropertyInfo* pi = propertyInfo(key);
1099
        return pi ? pi->title_ : 0;
1100
    }
1101

    
1102
    const char* XmpProperties::propertyDesc(const XmpKey& key)
1103
    {
1104
        const XmpPropertyInfo* pi = propertyInfo(key);
1105
        return pi ? pi->desc_ : 0;
1106
    }
1107

    
1108
    TypeId XmpProperties::propertyType(const XmpKey& key)
1109
    {
1110
        const XmpPropertyInfo* pi = propertyInfo(key);
1111
        return pi ? pi->typeId_ : xmpText;
1112
    }
1113

    
1114
    const XmpPropertyInfo* XmpProperties::propertyInfo(const XmpKey& key)
1115
    {
1116
        const XmpPropertyInfo* pl = propertyList(key.groupName());
1117
        if (!pl) return 0;
1118
        const XmpPropertyInfo* pi = 0;
1119
        for (int i = 0; pl[i].name_ != 0; ++i) {
1120
            if (0 == strcmp(pl[i].name_, key.tagName().c_str())) {
1121
                pi = pl + i;
1122
                break;
1123
            }
1124
        }
1125
        return pi;
1126
    }
1127

    
1128
    const char* XmpProperties::nsDesc(const std::string& prefix)
1129
    {
1130
        return nsInfo(prefix)->desc_;
1131
    }
1132

    
1133
    const XmpPropertyInfo* XmpProperties::propertyList(const std::string& prefix)
1134
    {
1135
        return nsInfo(prefix)->xmpPropertyInfo_;
1136
    }
1137

    
1138
    const XmpNsInfo* XmpProperties::nsInfo(const std::string& prefix)
1139
    {
1140
        const XmpNsInfo::Prefix pf(prefix);
1141
        const XmpNsInfo* xn = lookupNsRegistry(pf);
1142
        if (!xn) xn = find(xmpNsInfo, pf);
1143
        if (!xn) throw Error(35, prefix);
1144
        return xn;
1145
    }
1146

    
1147
    void XmpProperties::printProperties(std::ostream& os, const std::string& prefix)
1148
    {
1149
        const XmpPropertyInfo* pl = propertyList(prefix);
1150
        if (pl) {
1151
            for (int i = 0; pl[i].name_ != 0; ++i) {
1152
                os << pl[i];
1153
            }
1154
        }
1155

    
1156
    } // XmpProperties::printProperties
1157

    
1158
    std::ostream& XmpProperties::printProperty(std::ostream& os,
1159
                                               const std::string& key,
1160
                                               const Value& value)
1161
    {
1162
        PrintFct fct = printValue;
1163
        if (value.count() != 0) {
1164
            const XmpPrintInfo* info = find(xmpPrintInfo, key);
1165
            if (info) fct = info->printFct_;
1166
        }
1167
        return fct(os, value, 0);
1168
    }
1169

    
1170
    //! @cond IGNORE
1171

    
1172
    //! Internal Pimpl structure with private members and data of class XmpKey.
1173
    struct XmpKey::Impl {
1174
        Impl() {}                       //!< Default constructor
1175
        Impl(const std::string& prefix, const std::string& property); //!< Constructor
1176

    
1177
        /*!
1178
          @brief Parse and convert the \em key string into property and prefix.
1179
                 Updates data members if the string can be decomposed, or throws
1180
                 \em Error.
1181

    
1182
          @throw Error if the key cannot be decomposed.
1183
        */
1184
        void decomposeKey(const std::string& key);
1185

    
1186
        // DATA
1187
        static const char* familyName_; //!< "Xmp"
1188

    
1189
        std::string prefix_;            //!< Prefix
1190
        std::string property_;          //!< Property name
1191
    };
1192
    //! @endcond
1193

    
1194
    XmpKey::Impl::Impl(const std::string& prefix, const std::string& property)
1195
    {
1196
        // Validate prefix
1197
        if (XmpProperties::ns(prefix).empty()) throw Error(46, prefix);
1198

    
1199
        property_ = property;
1200
        prefix_ = prefix;
1201
    }
1202

    
1203
    const char* XmpKey::Impl::familyName_ = "Xmp";
1204

    
1205
    XmpKey::XmpKey(const std::string& key)
1206
        : p_(new Impl)
1207
    {
1208
        p_->decomposeKey(key);
1209
    }
1210

    
1211
    XmpKey::XmpKey(const std::string& prefix, const std::string& property)
1212
        : p_(new Impl(prefix, property))
1213
    {
1214
    }
1215

    
1216
    XmpKey::~XmpKey()
1217
    {
1218
        delete p_;
1219
    }
1220

    
1221
    XmpKey::XmpKey(const XmpKey& rhs)
1222
        : Key(rhs), p_(new Impl(*rhs.p_))
1223
    {
1224
    }
1225

    
1226
    XmpKey& XmpKey::operator=(const XmpKey& rhs)
1227
    {
1228
        if (this == &rhs) return *this;
1229
        *p_ = *rhs.p_;
1230
        return *this;
1231
    }
1232

    
1233
    XmpKey::AutoPtr XmpKey::clone() const
1234
    {
1235
        return AutoPtr(clone_());
1236
    }
1237

    
1238
    XmpKey* XmpKey::clone_() const
1239
    {
1240
        return new XmpKey(*this);
1241
    }
1242

    
1243
    std::string XmpKey::key() const
1244
    {
1245
        return std::string(p_->familyName_) + "." + p_->prefix_ + "." + p_->property_;
1246
    }
1247

    
1248
    const char* XmpKey::familyName() const
1249
    {
1250
        return p_->familyName_;
1251
    }
1252

    
1253
    std::string XmpKey::groupName() const
1254
    {
1255
        return p_->prefix_;
1256
    }
1257

    
1258
    std::string XmpKey::tagName() const
1259
    {
1260
        return p_->property_;
1261
    }
1262

    
1263
    std::string XmpKey::tagLabel() const
1264
    {
1265
        const char* pt = XmpProperties::propertyTitle(*this);
1266
        if (!pt) return tagName();
1267
        return pt;
1268
    }
1269

    
1270
    uint16_t XmpKey::tag() const
1271
    {
1272
        return 0;
1273
    }
1274

    
1275
    std::string XmpKey::ns() const
1276
    {
1277
        return XmpProperties::ns(p_->prefix_);
1278
    }
1279

    
1280
    void XmpKey::Impl::decomposeKey(const std::string& key)
1281
    {
1282
        // Get the family name, prefix and property name parts of the key
1283
        std::string::size_type pos1 = key.find('.');
1284
        if (pos1 == std::string::npos) throw Error(6, key);
1285
        std::string familyName = key.substr(0, pos1);
1286
        if (0 != strcmp(familyName.c_str(), familyName_)) {
1287
            throw Error(6, key);
1288
        }
1289
        std::string::size_type pos0 = pos1 + 1;
1290
        pos1 = key.find('.', pos0);
1291
        if (pos1 == std::string::npos) throw Error(6, key);
1292
        std::string prefix = key.substr(pos0, pos1 - pos0);
1293
        if (prefix == "") throw Error(6, key);
1294
        std::string property = key.substr(pos1 + 1);
1295
        if (property == "") throw Error(6, key);
1296

    
1297
        // Validate prefix
1298
        if (XmpProperties::ns(prefix).empty()) throw Error(46, prefix);
1299

    
1300
        property_ = property;
1301
        prefix_ = prefix;
1302
    } // XmpKey::Impl::decomposeKey
1303

    
1304
    // *************************************************************************
1305
    // free functions
1306
    std::ostream& operator<<(std::ostream& os, const XmpPropertyInfo& property)
1307
    {
1308
        return os << property.name_                       << ",\t"
1309
                  << property.title_                      << ",\t"
1310
                  << property.xmpValueType_               << ",\t"
1311
                  << TypeInfo::typeName(property.typeId_) << ",\t"
1312
                  << ( property.xmpCategory_ == xmpExternal ? "External" : "Internal" ) << ",\t"
1313
                  << property.desc_                       << "\n";
1314
    }
1315
    //! @endcond
1316

    
1317
}                                       // namespace Exiv2
    (1-1/1)