Zum Hauptinhalt gehen

⚠️ Please note that this topic or post has been archived. The information contained here may no longer be accurate or up-to-date. ⚠️

color editor options

Kommentare

6 Kommentare

  • Eric Valk
    I suggest that you down load a trial copy of Script Debugger.

    Script Debugger has a really good dictionary feature, and a very handy Object Model Explorer, which allows you to observe all the properties of the and values of the Objects (catalog, variants, images) of Capture One while it is running.
    0
  • Rick Allen
    Interestingly if you run the below in Scriptdebugger

    tell application "Capture One 12" to tell current document to set theVAR to variants whose selected is true


    You get a list of all the properties for a selected image, what I dont understand is that the color editor settings array is always empty regardless of if the image has editor adjustments are not. So running the below will get you the brightness setting as you'd expect as part of a layer array or not (variables a & b). I cant return the editor settings array with any combo I can think of.

    tell application "Capture One 12" to tell current document
    set theVAR to variants whose selected is true
    set a to get brightness of adjustments of item 1 of theVAR
    set b to get brightness of adjustments of layer "Background" of item 1 of theVAR
    set c to get color editor settings of adjustments of layer "Background" of item 1 of theVAR
    end tell


    Strange or am I just missing something super obvious?
    0
  • Eric Valk
    I am sure that color editor settings is a reference, but I'm having trouble learning what it refers to

    Here is a quick script with some of my usual tricks to extract information. This didn't tell me anything except that it is a reference.

    use AppleScript version "2.4" -- Yosemite (10.10) or later
    use scripting additions

    tell application "Capture One 20" to tell current document
    set theVAR to variants whose selected is true
    set a to get brightness of adjustments of item 1 of theVAR
    set b to get brightness of adjustments of layer "Background" of item 1 of theVAR
    set d to get color editor settings of adjustments of layer "Background" of item 1 of theVAR
    set d2 to my isaref(d) -- returns TRUE
    set d1 to get properties of d -- returns {}
    try
    || of {d}
    on error ErrorMess
    log ErrorMess
    copy ErrorMess to d3
    end try
    ## returns Can’t get || of {color editor settings of adjustments of layer "Background" of variant id "5792" of collection id "682" of collection id "11" of collection id "10" of document "Incoming20" of application "Capture One 20"}
    end tell

    on isaref(objectToBeTested)
    ## Matt Nueberg
    try
    objectToBeTested as reference
    return true
    on error
    return false
    end try
    end isaref

    I suspect it is a reference to the following items:
      color balance master hue (real)
      color balance master saturation (real)
      color balance shadow hue (real)
      color balance shadow saturation (real)
      color balance shadow lightness (real)
      color balance midtone hue (real)
      color balance midtone saturation (real)
      color balance midtone lightness (real)
      color balance highlight hue (real)
      color balance highlight saturation (real)
      color balance highlight lightness (real)
    0
  • Rick Allen
    I'm glad its nothing obvious then 🤓

    I dont think its color balance because running the below does effect the 3-way color balance tool.


    set color balance midtone hue of adjustments of item 1 of theVAR to 90


    Having said all this I cant imagine how you could possibly set a color range selection, I'm guessing it would be require 16bit triplets and then the required calc to transform that to the desired colour would be pretty arduous.

    I wonder if there's another way to achieve the result you are after?
    0
  • Eric Valk
    [quote="rapdigital" wrote:
    I'm glad its nothing obvious then 🤓

    I dont think its color balance because running the below does effect the 3-way color balance tool.


    set color balance midtone hue of adjustments of item 1 of theVAR to 90


    Having said all this I cant imagine how you could possibly set a color range selection, I'm guessing it would be require 16bit triplets and then the required calc to transform that to the desired colour would be pretty arduous.

    I wonder if there's another way to achieve the result you are after?

    I think you may have hit the nail on the head. The color range parameters are very complex, and so C1 developers don't break them out to individual controls. All you get is a reference to them. You can this copy them from one variant to another,but you can't adjust the indifividual parameters. As a consequence II wonder if Applescript may not be able to save them.

    This typically works for referenced value, but I did not get it to work here:
    get contents of someReference

    This doesn't crash, but as best as I can tell, its still a reference tothe color editor settings of the variant
    set R1 to (get color editor settings of adjustments of layer "Background")
    0
  • NN110943UL
    Thanks all for your help. I'm new to AppleScripts, I downloaded Script Debugger and that has helped a lot. I have found a partial alternative solution, though I think that the color editor options would have been easier.
    0

Post ist für Kommentare geschlossen.