Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

93
Views
Photoshop multyply Layer Effect execution

i have a task to get all solidFill effects by layer, get color from each and put it to layer name. I test it with one “Color Overlay” effect and its work. But that shld i do for execute several “Color Overlay” effects? I need to put each color from each “Color Overlay” effect to name by hex. My code for one effect:

if (BridgeTalk.appName == "photoshop")
{
    var doc = app.activeDocument;
    var layers = activeDocument.artLayers;
    for (var i=0; i<layers.length; i++)
    {
        doc.activeLayer = layers[i];
        solidFill();
    }
}


function solidFill()
{
    var fxDesc = getFxDesc();
    
    doc.activeLayer.name = fxDesc.p    
    
    var solidDesc = getSolidFillDesc(fxDesc);        
}

function modifyLayerName(desc)
{    
    var colObj = desc.getObjectValue(stringIDToTypeID("color"));

    var redHex = (0 + colObj.getDouble(charIDToTypeID("Rd  ")).toString(16)).slice(-2);
    var grnHex = (0 + colObj.getDouble(charIDToTypeID("Grn ")).toString(16)).slice(-2);
    var blHex = (0 + colObj.getDouble(charIDToTypeID("Bl  ")).toString(16)).slice(-2);

    doc.activeLayer.name = '#' +  redHex + grnHex + blHex;
}

function getFxDesc(){
    var ref = new ActionReference();
    ref.putEnumerated( charIDToTypeID("Lyr "), charIDToTypeID("Ordn"), charIDToTypeID("Trgt") );
    var desc = executeActionGet(ref);
    if(desc.hasKey(stringIDToTypeID('layerEffects'))){
        var fxDesc = desc.getObjectValue(stringIDToTypeID('layerEffects'));        
    }
    if(undefined != fxDesc) return fxDesc; 
    else doc.activeLayer.name = "nothing";
};

function getSolidFillDesc(desc)
{
    if(desc.hasKey(stringIDToTypeID('solidFill'))){
        var solidFillDesc = desc.getObjectValue(stringIDToTypeID('solidFill'));
    }
    if(undefined != solidFillDesc) return solidFillDesc;
}

but i can add several Color Overlay effect for layer and how i should get its all for check every color of them?

about 4 years ago · Juan Pablo Isaza
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!