I have a relative simple CamanJS that is working well to add a layer, set it to a fill color and set the blending mode.
function changeColor(layer, hexCode) {
Caman(layer, function() {
this.greyscale();
this.contrast(-10);
this.newLayer(function () {
this.setBlendingMode("overlay");
this.fillColor(hexCode);
});
this.render();
});
};
changeColor('#paint','#ff0000');
function changeFilter(layer, hexCode) {
Caman(layer).revert(false);
changeColor(layer,hexCode);
};
However, I can't figure out how to change just one of the settings (fillColor) on that layer without reverting the image and starting over. Is this the best way to do it? Or can I just update the fillColor itself?