Skip to main content
phillips12177306
Participant
November 30, 2021
Answered

Batch export layers as png WITH transparency IN CANVAS-SIZE not cropped to the asset ?

  • November 30, 2021
  • 2 replies
  • 1767 views

Hi, maybe you can help me. 

I am trying to export very high numbers of layers as png files. 

the layers > export as, will allow me to batch all layers ton png with transparency. but it will crop the size to the layer but I need them all in the size of the canvas so they align afterwards again… for an nft project. 

 

the batch command… file > export layers doesnt work bc. the transparency gets lost for some reason as png 

 

thx 

This topic has been closed for replies.
Correct answer c.pfaffenbichler

Have you tried PNG-24 with

File > Export > Export Layers To Files

2 replies

Stephen Marsh
Community Expert
Community Expert
November 30, 2021

A script in the following topic can add a 1% 1x1 pixel in the upper left and lower right corners of the active layer, which is a hack to work around the issue (the same can be done via an action):

 

https://community.adobe.com/t5/photoshop-ecosystem-discussions/export-as-now-crops-to-contents-instead-of-using-the-mask/m-p/12336888

 

This would need to be included with further code to process all layers and not just the active layer.

 

More on this topic here, where Adobe explain why:

 

https://community.adobe.com/t5/photoshop-ecosystem-discussions/export-as-now-crops-to-contents-instead-of-using-the-mask/m-p/12336888

 

c.pfaffenbichler
Community Expert
c.pfaffenbichlerCommunity ExpertCorrect answer
Community Expert
November 30, 2021

Have you tried PNG-24 with

File > Export > Export Layers To Files

phillips12177306
Participant
November 30, 2021

that did the trick. thx a lot !

so png-8 has NO transparency…? 

c.pfaffenbichler
Community Expert
Community Expert
November 30, 2021

PNG-8 only has 1-bit transparency.