解决PSD文件过大问题

沈阳/UI设计师/8年前/5257浏览
解决PSD文件过大问题

解决PSD文件过大问题,让你的PSD瞬间瘦身!

function deleteDocumentAncestorsMetadata() {

whatApp = String(app.name);//String version of the app name

if(whatApp.search("Photoshop") > 0) { //Check for photoshop specifically, or this will cause errors

//Function Scrubs Document Ancestors from Files

if(!documents.length) {

alert("There are no open documents. Please open a file to run this s cript.")

return;

}

if (ExternalObject.AdobeXMPs cript == undefined) ExternalObject.AdobeXMPs cript = new ExternalObject("lib:AdobeXMPs cript");

var xmp = new XMPMeta( activeDocument.xmpMetadata.rawData);

// Begone foul Document Ancestors!

xmp.deleteProperty(XMPConst.NS_PHOTOSHOP, "DocumentAncestors");

app.activeDocument.xmpMetadata.rawData = xmp.serialize();

}

}

//Now run the function to remove the document ancestors

deleteDocumentAncestorsMetadata();




100
Report
|
40
Share
评论
in to comment
Add emoji
喜欢TA的作品吗?喜欢就快来夸夸TA吧!
推荐素材
You may like
大家都在看
Log in