Exit
  • Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
  • 한국 커뮤니티
0

Does anyone have a script to export multiple assets that remain the size of the artboard?

New Here ,
Feb 18, 2022 Feb 18, 2022

I'm creating an NFT that needs to have hundreds of PNG's layered ontop of one another. Because of this I need all my assets to export as the size of the artboard, not just the bounding box of the asset. I created all of my assets in layers on one artboard. 

Does anyone have a script to create multiple artboards within one document so that I can export that way? or a script to export all of my assets the size of the artboard?

HELP IM HOPELESS. 

 

TOPICS
Import and export , Scripting , Tools
661
Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Adobe
Community Expert ,
Feb 18, 2022 Feb 18, 2022
Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Valorous Hero ,
Feb 18, 2022 Feb 18, 2022

Can you try to use the Save-for-Web legacy option, there's a checkbox to 'clip to artboard'. Use it with Ctrl+Shift+S, but it only is good for exporting images that have a screen resolution. Even if you do need a higher resolution, you could still export at a very large scale and still at the 72 resolution, then put it through some photoshop batch process to down-size the dimensions while up-sizing the resolution.

However it's probably likely that Save-for-Web resolution may be ever prefereable, so try giving it a go.

SillyV_0-1645243809332.png

 

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Advocate ,
Feb 19, 2022 Feb 19, 2022
LATEST

Bonjour,

Avec calques supperposés, essayez ceci...

// JavaScript Document
if ( app.documents.length > 0 ) {
  var exportOptions = new ExportOptionsPNG24();
      exportOptions.antiAliasing = false;
      exportOptions.transparency = false;
      exportOptions.saveAsHTML = true;
      exportOptions.artBoardClipping = true;
  var type = ExportType.PNG24;
  var fileSpec = "~/sample";

      for(var h = 0; h < activeDocument.layers.length; h++) {
         app.activeDocument.layers[h].visible = false;
      }
      for(h = 0; h < activeDocument.layers.length; h++) {
          activeDocument.layers[h].visible = true;
         app.activeDocument.exportFile( new File(fileSpec+"_"+h+".png"), type, exportOptions );
          activeDocument.layers[h].visible = false;
      }
      for(h = 0; h < activeDocument.layers.length; h++) {
         app.activeDocument.layers[h].visible = true;
      }
}

 

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines