IPTC Comments

The IPTC-NAA comments are standardized by the International Press Telecommunications Council in collaboration with Newspaper Association of America. More information about these comments can be found on IPTCs web site https://iptc.org/. Many comments have to follow a particular format, so refer to the IPTC documentation to make sure you are writing valid comments.

LEADTOOLS will verify that the size of the comment is within the limits specified by the standard. Comments with invalid length will NOT be written in the file. LEADTOOLS will NOT verify the contents of the data (it will not verify that the numerical comments contain only digits, etc.).

Some of these comments are repeatable (ie you can have more than one comment of this type). To write two or more values for a repeatable comment, concatenate the comments using the IPTC_SEPARATOR as the separator. IPTC_SEPARATOR has an ASCII code of 1 and cannot appear in any comment, so there is not a possibility of confusion about this character is the separator or part of the comment. Do not confuse this with the character 1, whose ASCII code is 49!

When reading a repeatable comment with more than one value, LEADTOOLS will concatenate all the values and use the IPTC_SEPARATOR to separate the values. Therefore, when a comment that might be repeatable is retrieved, it is best to search for the separator.

CMNT_IPTC_KEYWORDS is the best example of a comment that is repeatable. If the file has three keywords (keyword1, keyword2 and keyword3), they will be returned as the following string:

"keyword1\001keyword2\001keyword3".

Every IPTC comment is identified by x:y, where x is the Record number and y is the DataSet number. For example, CMNT_IPTC_KEYWORDS is identified as 2:15. We will list the corresponding "x:y" identifier for every comment supported in LEADTOOLS, together with the length limits.

All the date comments use the format YYYYMMDD, so July 4, 2001 is "20010704".

All the time comments use the format HHMMSSHHMM, following the ISO 8601 standard. The part after is the reference to the Universal Time Format. For example, 3PM Eastern USA time is "150000-0500".

Please note that the IPTC_SEPARATOR is not a comment, it is only a define used for the separator!

IPTC_SEPARATOR \001 A separator used for repeatable comments.

IPTC comments can be saved inside TIFF and JPEG files.

Value Meaning
CMNT_IPTC_FIRST [181] The first IPTC comment To get all IPTC comments, use the comment type constant as a loop counter. The first constant is CMNT_IPTC_FIRST and the last is CMNT_IPTC_ LAST.
CMNT_IPTC_LAST [226] The last IPTC comment
CMNT_IPTC_VERSION [181] 2:0, the version of IPTC comments (read-only). Non-repeatable, (min=2 bytes, max=2). This is the only comment that is binary. The first byte is the lower version number (usually 0) and the second byte is the high version number (the current version is 4 - binary 4, not ASCII 4). LEADTOOLS writes 4 here.
CMNT_IPTC_OBJECTTYPEREFERENCE [182] 2:3, Object type reference. Non repeatable. Length = 3..67.
CMNT_IPTC_OBJECTATTRIBUTEREFERENCE [183] 2:4, Object Attribute Reference. Repeatable. Length = 4..68.
CMNT_IPTC_OBJECTNAME [184] 2:5, Object name. Non repeatable. Length = 1..64.
CMNT_IPTC_EDITSTATUS [185] 2:7, Edit status. Non repeatable. Length = 1..64.
CMNT_IPTC_EDITORIALUPDATE [186] 2:8, Editorial update. Non repeatable. Length = 2..2.
CMNT_IPTC_URGENCY [187] 2:10, Urgency. Non repeatable. 1 is most urgent, 5 = Normal, 8 is least urgent. Length = 1..1.
CMNT_IPTC_SUBJECTREFERENCE [188] 2:12, Subject reference. Repeatable. Length = 13..236.
CMNT_IPTC_CATEGORY [189] 2:15, Category. Non repeatable. Length = 1..3.
CMNT_IPTC_SUPPLEMENTALCATEGORY [190] 2:20, Supplemental category. Repeatable. Length = 1..32.
CMNT_IPTC_FIXTUREIDENTIFIER [191] 2:22, Fixture identifier. Non repeatable. Length = 1..32.
CMNT_IPTC_KEYWORDS [192] 2:25, Keywords. Repeatable. Length = 1..64.
CMNT_IPTC_CONTENTLOCATIONCODE [193] 2:26, Content location code. Repeatable. Length = 3..3.
CMNT_IPTC_CONTENTLOCATIONNAME [194] 2:27, Content location name. Repeatable. Length = 1..64.
CMNT_IPTC_RELEASEDATE [195] 2:30, Release date. Non repeatable. Length = 8..8.
CMNT_IPTC_RELEASETIME [196] 2:35, Release time. Non repeatable. Length = 11..11.
CMNT_IPTC_EXPIRATIONDATE [197] 2:37, Expiration date. Non repeatable. Length = 8..8.
CMNT_IPTC_EXPIRATIONTIME [198] 2:38, Expiration time. Non repeatable. Length = 11..11.
CMNT_IPTC_SPECIALINSTRUCTIONS [199] 2:40, Special instructions. Non repeatable. Length = 1..256.
CMNT_IPTC_ACTIONADVISED [200] 2:42, Action advised. Non repeatable. Length = 2..2.
CMNT_IPTC_REFERENCESERVICE [201] 2:45, Reference service. Repeatable. Length = 1..10.
CMNT_IPTC_REFERENCEDATE [202] 2:47, Reference date. Repeatable. Length = 8..8.
CMNT_IPTC_REFERENCENUMBER [203] 2:50, Reference number. Repeatable. Length = 8..8.
CMNT_IPTC_DATECREATED [204] 2:55, Date created. Non repeatable. Length = 8..8.
CMNT_IPTC_TIMECREATED [205] 2:60, Time created. Non repeatable. Length = 11..11.
CMNT_IPTC_DIGITALCREATIONDATE [206] 2:62, Digital creation date. Non repeatable. Length = 8..8.
CMNT_IPTC_DIGITALCREATIONTIME [207] 2:63, Digital creation time. Non repeatable. Length = 11..11.
CMNT_IPTC_ORIGINATINGPROGRAM [208] 2:65, Originating program. Non repeatable. Length = 1..32.
CMNT_IPTC_PROGRAMVERSION [209] 2:70, Program version. Non repeatable. Length = 1..10.
CMNT_IPTC_OBJECTCYCLE [210] 2:75, Object cycle. Non repeatable. Length = 1..1.
CMNT_IPTC_BYLINE [211] 2:80, By-line. Repeatable. Length = 1..32.
CMNT_IPTC_BYLINETITLE [212] 2:85, By-line title. Repeatable. Length = 1..32.
CMNT_IPTC_CITY [213] 2:90, City Non repeatable. Length = 1..32.
CMNT_IPTC_SUBLOCATION [214] 2:92, Sub-location. Non repeatable. Length = 1..32.
CMNT_IPTC_PROVINCE_STATE [215] 2:95, Province/State. Non repeatable. Length = 1..32.
CMNT_IPTC_PRIMARYLOCATIONCODE [216] 2:100, Country/Primary location code. Non repeatable. Length = 3..3.
CMNT_IPTC_PRIMARYLOCATIONNAME [217] 2:101, Country/Primary location name. Non repeatable. Length = 1..64.
CMNT_IPTC_ORIGINALTRANSMISSIONREFERENCE [218] 2:103, Original transmission reference. Non repeatable. Length = 1..32.
CMNT_IPTC_HEADLINE [219] 2:105, Headline. Non repeatable. Length = 1..256.
CMNT_IPTC_CREDIT [220] 2:110, Credit. Non repeatable. Length = 1..32.
CMNT_IPTC_SOURCE [221] 2:115, Source. Non repeatable. Length = 1..32.
CMNT_IPTC_COPYRIGHT [222] 2:116, Copyright Notice. Non repeatable. Length = 1..128.
CMNT_IPTC_CONTACT [223] 2:118, Contact. Repeatable. Length = 1..128.
CMNT_IPTC_CAPTION [224] 2:120, Caption/Abstract. Non repeatable. Length = 1..2000.
CMNT_IPTC_AUTHOR [225] 2:122, Writer/Editor. Repeatable. Length = 1..32.
CMNT_IPTC_LANGUAGEIDENTIFIER [226] 2:135, Language identifier. Non repeatable. Length = 2..3.
Help Version 23.0.2024.2.29
Products | Support | Contact Us | Intellectual Property Notices
© 1991-2024 LEAD Technologies, Inc. All Rights Reserved.

LEADTOOLS Raster Imaging C++ Class Library Help
Products | Support | Contact Us | Intellectual Property Notices
© 1991-2023 LEAD Technologies, Inc. All Rights Reserved.