xmp:copyrightstatus

Started by SteveB, August 31, 2012, 11:54:33 AM

Previous topic - Next topic

SteveB

Howdy all,

I'm having some issues setting the copyright status for images I'm uploading into Razuna, a digital asset management solution.  The devleloper for Razuna indicated that the proper syntax is:

QuoteThe proper way is to set them like:

-xmp:copyrightstatus='true'
-XMP-xmpRights:Marked='true'

but when I run

exiftool "-xmp:copyrightstatus=true" "-xmp-xmprights:marked=true" -overwrite_original $file.FullName

I get:

Warning: Can't convert XMP-plus:CopyrightStatus (not in PrintConv)

I have tried various methods of quoting, single quoting, double quoting, only quoting 'true', etc with no success.

The only mention of a copyright status tag I can find in the exiftool documentation is in the XMP plus section, but using something like the following line doesn't work either

exiftool "-xmp:copyrightstatus=http://ns.useplus.org/ldf/vocab/CS-PRO" "-xmp-xmprights:marked=true" -overwrite_original $file.FullName

Does anyone know how to do this?  For reference I'm on Windows and calling exiftool from a PowerShell script.

Thanks in advance!

Phil Harvey

You seem to have read this in the XMP tag name documentation:


    Note that all controlled-vocabulary tags in this table (ie. tags
    with a fixed set of values) have raw values which begin with
    "http://ns.useplus.org/ldf/vocab/", but to reduce clutter this
    prefix has been removed from the values shown below

   'CS-PRO' = Protected
   'CS-PUB' = Public Domain
   'CS-UNK' = Unknown


So according to the PLUS specification, this tag must be set to one of 3 possible values.

FAQ number 6 explains the problem you have having setting the value.

- Phil
...where DIR is the name of a directory/folder containing the images.  On Mac/Linux/PowerShell, use single quotes (') instead of double quotes (") around arguments containing a dollar sign ($).

SteveB

So, I'm guessing you mean to use "-n" or a # at the end of the tag name?

That stops the errors, but doesn't actually accomplish anything.


This throws no errors, doesn't update copyright status either:
exiftool -n -xmp:copyrightstatus='CS-PRO' -xmp-xmprights:marked=true -overwrite_original $file.FullName

This throws errors:
exiftool -n -xmp:copyrightstatus='CS-PRO' -xmp-xmprights:marked=true -overwrite_original $file.FullName

This throws errors:
exiftool -n -xmp:copyrightstatus='http://ns.useplus.org/ldf/vocab/CS-PRO' -xmp-xmprights:marked=true -overwrite_original $file.FullName


Regardless, since the tag I'm looking for is xmp:copyrightstatus, and accepts True/False as the data, I'm thinking that the xmp-plus tag is not what I'm looking for.

Looks like I'll be bouncing back and forth between here and the Razuna forums!

Phil Harvey

#3
What version of exiftool are you using?  (type "exiftool -ver")

This all works for me with ExifTool 9.01 (and should work for you too unless your version is VERY old):

> exiftool -n -xmp:copyrightstatus='CS-PRO' -xmp-xmprights:marked=true -overwrite_original a.xmp
    1 image files updated

> exiftool -n -xmp:copyrightstatus='http://ns.useplus.org/ldf/vocab/CS-PRO' -xmp-xmprights:marked=true -overwrite_original a.xmp
    1 image files updated


(although the last case is NOT correct, and will actually write "http://ns.useplus.org/ldf/vocab/http://ns.useplus.org/ldf/vocab/CS-PRO" to the file.)

Also, writing the converted values works:

> exiftool -xmp:copyrightstatus=protected -xmp-xmprights:marked=true a.xmp
    1 image files updated


But as you said, you need to figure out what you want to write.

- Phil
...where DIR is the name of a directory/folder containing the images.  On Mac/Linux/PowerShell, use single quotes (') instead of double quotes (") around arguments containing a dollar sign ($).

SteveB

I'm on 8.97 at the moment.

I see that you did indeed mean to use the -n syntax, so as far as I'm concerned exiftool is doing it's job, that works for me as well.

I'll figure out where the mix up is between Razuna and the tags.

Thank you very much for your quick response and for creating a great tool!

JAI

I'm a newbie to ExifTool (v11.10), fairly new to metadata, but an old hand at programming.  I'm glad SteveB got this figured out, but I haven't yet.  I'm trying to write an appropriate value to XMP-xmpRights:Marked.  This thread and PLUS say that this field is a controlled tri-state field.  Acceptable values are true (1, CS_PRO, Copyrighted, or protected), false (0, CS_PUB, or Public Domain),  or  null (CS_UNK or Unknown).  Adding to the complexity is at least one other related field, "xmp:copyrightstatus".  I'm working in batch files, not by specifying parameters in the executable's file name.  I run test cases by changing values in the batch files.

I have a batch file that reads the XMP-xmpRights:Marked field:
exiftool.exe -k -n -S -U -"XMP-xmpRights:Marked" "myFile.jpg"

And a second batch file that writes to the same field:
exiftool.exe -k -n -XMP-xmpRights:Marked=true -overwrite_original "myFile.jpg"

I have three ways to cross-check the results of writing to the field:  (1) run the first batch file, (2) drag and drop the image file onto the exiftool(-a -u -g1 -w txt) executable and inspect the resulting text file, and (3) open the metadata viewer in Paint Shop Pro's Management pane.  That's where it gets weird.

FIRST QUESTION:  I understand how to set this field true or false, but how do I set it to null, yet still have it reported by the first batch file?  Using ^= removes the field from the metadata, even from the drag/drop text file method.  My expectation was that XMP-xmpRights:Marked line would end with only a colon and blank space, but not disappear from the listing entirely.  Maybe this is just a wrong expectation on my part?  In my database experience, setting a field to null is different than setting it to an empty string and different than deleting the field!

SECOND QUESTION: Using the second batch file I can set it to true or false, but if I try to set it to "Copyright", "Public Domain", or "Unknown", the first batch file always returns true.  On the other hand, if I then view it in Paint Shop Pro, it always shows as "Unknown".  If I then set it to "Copyright" or "Public Domain" in Paint Shop Pro, the first batch file's call to ExifTool will report it's value as "Copyright" or "Public Domain" (as does Paint Shop Pro in later sessions -- the setting "sticks").  It seems very strange to me that a boolean field can contain strings such as "Copyright" and "Public Domain" and cannot be set to those values by ExifTool!  I'd be happy if I could get a result from both ExifTool and Paint Shop Pro that agrees!

ExifTool is fantastic, and just the documentation has increased my understanding of JPEG metadata structure immensely.  It seems like ExifTool works great on every field except the one I need.  And this ancient thread has been very informative.  I know it's not ExifTool, it's some flaw in my understanding.  Any help will be greatly appreciated.