Skip to main content
Participant
June 19, 2021
Question

Modo de fusión

  • June 19, 2021
  • 3 replies
  • 612 views

eliminar el Modo de fusión aplicado a una capa, sin eliminar su contenido.

This topic has been closed for replies.

3 replies

Shulipa Bernad
Inspiring
June 19, 2021
quote

eliminar el Modo de fusión aplicado a una capa, sin eliminar su contenido.


By @Maggie5F9D

If it's just to remove the blend mode in the layers palette and keep the current blend, maybe this method will help.

main();
function main(){
    var LName= activeDocument.activeLayer.name;
    targetLayer("Bckw");
    executeAction(app.stringIDToTypeID("copyToLayer"), undefined, DialogModes.NO);
    targetLayer("Frwr");
    executeAction(app.stringIDToTypeID("mergeLayersNew"), undefined, DialogModes.NO);
    activeDocument.activeLayer.name= LName;
    function targetLayer(method){
    var d = new ActionDescriptor();
    var r = new ActionReference();
    r.putEnumerated(app.charIDToTypeID("Lyr "), app.charIDToTypeID("Ordn"), app.charIDToTypeID(method));
    d.putReference(app.charIDToTypeID("null"), r);
    var list1 = new ActionList();
    d.putList(app.charIDToTypeID("LyrI"), list1);
    executeAction(app.charIDToTypeID("slct"), d, DialogModes.NO);
    }
}
Kukurykus
Legend
June 19, 2021
activeDocument.activeLayer.blendMode = BlendMode.NORMAL
Mylenium
Legend
June 19, 2021

It's really not clear what you mean. Layer modes can easily be switched in the layers palette, but it sounds like you want to actually retain the appearance of a blending mode, which may require extra steps like duplicating the layers involved in the setup before merging/ flattening them. anyway, you need to offer a better explanation of what you are actualyl trying to do.

 

Mylenium