我想编写一个脚本,将文本文件中的不同文本替换到我的 Shalon 中,并以 jpeg 格式保存图像。
在这行代码上出现了错误:“此版本的 Photoshop 可能无法使用此函数”:
activeDocument.saveAs(saveFile, jpgSaveOptions, true,Extension.LOWERCASE);
我的代码:
while(!myFile.eof)
{
line = myFile.readln();
createText(line);
var thistimestamp = Math.round(new Date().getTime() / 1000);
saveFile = new File( "/c/Users/marki/Desktop/Temp001/" +thistimestamp)
saveOptions = new JPEGSaveOptions();
saveOptions.embedColorProfile = true;
saveOptions.formatOptions = FormatOptions.STANDARDBASELINE;
saveOptions.matte = MatteType.NONE;
saveOptions.quality = 9;
app.activeDocument.saveAs(saveFile, saveOptions, true,Extension.LOWERCASE);
}
我使用 Adobe Photoshop:2017.0.0 20161012.r.53 2016/10/12:23:00:00 CL 1094006(x64)