Questions about using custom fields in PSu V 3.3 +

Post Reply
PhilBurton
Posts: 307
Joined: 12 Sep 10 17:47
Location: CA, USA

Questions about using custom fields in PSu V 3.3 +

Post by PhilBurton »

1. If I create PSu custom fields for one image in the catalog, does that set of custom fields automatically get applied to all existing images in the catalog? What about images added later on?

2. Is it possible to have only some of the images in a catalog have the custom fields, and others not? How? Is it possible to add custom fields to only some images in a catalog?

3. Custom fields are limited to only text. I would also like to have simple, unsigned numeric fields supported. Is it possible to use an XML editor to redefine a field from text to a numeric type? [How???] If that change can be done, would PSu treat that field as numeric?

4. Where does PSu store custom field definitions?

Phil
Photo Supreme user
Home built i7 3930, 32 GB RAM, Win 10 Pro 64, latest version of Photo Supreme 3, Lightroom 6 and Photoshop CS 6 (perpetual licenses)
fbungarz
Posts: 1826
Joined: 08 Dec 06 4:03
Location: Arizona, USA

Re: Questions about using custom fields in PSu V 3.3 +

Post by fbungarz »

Hi Phil,
I think your post reflects a basic misunderstanding about XMP.
There is a difference between the XMP fields that you see onscreen as part of your database and the actual data written to your files.
In PSU the fields will always show up, but for images that do not contain the XMP data these fields will simply be displayed as empty.
For any image where you do not enter any information into its XMP field that image actually does simply NOT contain that block of XMP data.

So, to answer (some) of your questions:
1. If I create PSu custom fields for one image in the catalog, does that set of custom fields automatically get applied to all existing images in the catalog? What about images added later on?
The fields are part of the catalog database, not part of the images. The field definitions with the content of the fields get written only, when you actually enter data and synchronize it into the image files.
2. Is it possible to have only some of the images in a catalog have the custom fields, and others not? How? Is it possible to add custom fields to only some images in a catalog?
Same difference: the fields are part of the database, the data and the XMP definitions (i.e., how a progarm is supposed to read the data) are written to the image files.

Just to give you an idea of what I am talking about. XMP is essentially a variant of XML (eXtensible Markup Language), more simply said it is a syntax that "explains" the data written to an image file. For example, for one of my images, the actual metadata block for example looks like this:

Code: Select all

<?xpacket begin="" id="W5M0MpCehiHzreSzNTczkc9d"?>
<x:xmpmeta xmlns:x="adobe:ns:meta/" x:xmptk="Adobe XMP Core 5.3-c011 66.145661, 2012/02/06-14:56:27        ">
   <rdf:RDF xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#">
      <rdf:Description rdf:about=""
            xmlns:xmpMM="http://ns.adobe.com/xap/1.0/mm/">
         <xmpMM:PreservedFileName>[color=#0000FF]_DSC7086.JPG[/color]</xmpMM:PreservedFileName>
         <xmpMM:DocumentID>[color=#0000FF]93BA43AF049634C2389CD2D1E865945F[/color]</xmpMM:DocumentID>
         <xmpMM:InstanceID>[color=#0000FF]93BA43AF049634C2389CD2D1E865945F[/color]</xmpMM:InstanceID>
      </rdf:Description>
      <rdf:Description rdf:about=""
            xmlns:dc="http://purl.org/dc/elements/1.1/">
         <dc:format>image/jpeg</dc:format>
         <dc:rights>
            <rdf:Alt>
               <rdf:li xml:lang="x-default">[color=#0000F]© 2011 - Frank Bungartz, all rights reserved.[/color]</rdf:li>
            </rdf:Alt>
         </dc:rights>
         <dc:creator>
[...CLIPPED...]
   </rdf:RDF>
</x:xmpmeta>
I highlighted the "content" of the fields in blue, all the rest is "bla bla" that instructs programs (including PSu) how to read that metadata.
3. & 4...
Where PSu stores the custom field definitions and why only simple text fields are supported will have to be answered by the developer...
sanphotgn
Posts: 334
Joined: 26 Aug 07 17:06

Re: Questions about using custom fields in PSu V 3.3 +

Post by sanphotgn »

PhilBurton wrote:3. Custom fields are limited to only text. I would also like to have simple, unsigned numeric fields supported. Is it possible to use an XML editor to redefine a field from text to a numeric type? [How???] If that change can be done, would PSu treat that field as numeric?
The custom fields can contain anything. You can enter numbers. I have. I made the statement in a previous post they are simple text fields and should have added one can enter anything in them. I brought it up for folks familiar with ID5 and building custom fields. In ID5, one can build drop down boxes, check boxes, ... a rather sophisticated graphical front end for the fields, including, if I remember correctly, forcing specific formatting.
PhilBurton wrote:4. Where does PSu store custom field definitions?
%xmp:icd:
Photo Supreme 6.7.2.4201 (64 bits) (Windows)
PhilBurton
Posts: 307
Joined: 12 Sep 10 17:47
Location: CA, USA

Re: Questions about using custom fields in PSu V 3.3 +

Post by PhilBurton »

Restating my question 4, is there a separate XML type of "unsigned integer?" Or is numeric data stored as a text string? What if I wanted to sort low to high on numeric data or do a filter based on a numeric range?

Phil
Photo Supreme user
Home built i7 3930, 32 GB RAM, Win 10 Pro 64, latest version of Photo Supreme 3, Lightroom 6 and Photoshop CS 6 (perpetual licenses)
sanphotgn
Posts: 334
Joined: 26 Aug 07 17:06

Re: Questions about using custom fields in PSu V 3.3 +

Post by sanphotgn »

PhilBurton wrote:Restating my question 4, is there a separate XML type of "unsigned integer?"
In the context of what gets written to the XMP. I believe the answer is no. When writing a schema - the fancy graphical front end - yes.
PhilBurton wrote:Or is numeric data stored as a text string? What if I wanted to sort low to high on numeric data or do a filter based on a numeric range?
This is one of my custom XMP fields in 3.3 Photo Supreme. So, what you are seeing is via Catalog - By Image Details - Your Custom Fields.
Custom_Field_w_Numbers.PNG
Custom_Field_w_Numbers.PNG (2.63 KiB) Viewed 7455 times
I tried sorting via Macro Command. The sort order was the order shown in the attachment.

I tried this: StrToInt(%xmp:icd:AFAdj) in the sorting Macro command. No luck.

There might be another way. I am not very good at coding.
Photo Supreme 6.7.2.4201 (64 bits) (Windows)
PhilBurton
Posts: 307
Joined: 12 Sep 10 17:47
Location: CA, USA

Re: Questions about using custom fields in PSu V 3.3 +

Post by PhilBurton »

This result has nothing to do with coding. It has to do with sorting on a string vs. sorting on a number. You would get the sort order you want if you used leading "0", e.g. -02 or 03.

Your result is why I wanted to have a field that was defined as integer.

Phil
Photo Supreme user
Home built i7 3930, 32 GB RAM, Win 10 Pro 64, latest version of Photo Supreme 3, Lightroom 6 and Photoshop CS 6 (perpetual licenses)
sanphotgn
Posts: 334
Joined: 26 Aug 07 17:06

Re: Questions about using custom fields in PSu V 3.3 +

Post by sanphotgn »

PhilBurton wrote:You would get the sort order you want if you used leading "0", e.g. -02 or 03.
Understood. But I have seen some programs sort that type of numbering correctly. My guess is they are looking for numbers and if they see numbers, they sort accordingly. One example: Sorting by file name in Lightroom ... where the last four digits of the first file is 2869 and the last five digits of the last file is 16256 ... they are sorted correctly. Same folder in Photo Supreme, sorted by file name ... 12893 is first and 3075 is last.
Photo Supreme 6.7.2.4201 (64 bits) (Windows)
Post Reply