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

batch resize export

Explorer ,
Mar 19, 2024 Mar 19, 2024

Copy link to clipboard

Copied

image-resizing.pngHello!

I wonder if there is a way to batch export based on the contents of the file? 

For eg. I work with clipped products (transparent pngs). I need my final output to be a 3000px 3000px image based on the clipped image (no white space).

The items I am shooting are all different sizes and angles.

Currently, I am doing this manually but I wonder if there is a script/plugin that will automate this process for me? 

I have tried running an action but this won't work. It cuts off the image/uncentered. 

I hope I have explained that properly. 

TOPICS
Actions and scripting

Views

203

Translate

Translate

Report

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

correct answers 1 Correct answer

Community Expert , Mar 25, 2024 Mar 25, 2024
quote

Ok, so I have managed to get the selection to crop, I just can't get the canvas to be a square. It will size the canvas to the longest side. 


By @mbenton75


Step 4: Canvas size...

 

Stop recording the action after the Fit Image step. The canvas should now be 3000px on the longest edge.

 

To record a 3000px square canvas resize, you need to prime the document so that the longest edge isn't 3000px. So either resize, crop or create a dummy document smaller than 3000px on each edge.

 

Then press re

...

Votes

Translate

Translate
Adobe
Community Expert ,
Mar 19, 2024 Mar 19, 2024

Copy link to clipboard

Copied

Have you looked into Export As or Generator/Generate Image Assets?

 

It should be possible to record the trim command using transparency into an action with an image size and or canvas size or fit image steps.

 

Can you provide before/after samples?

Votes

Translate

Translate

Report

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
Explorer ,
Mar 19, 2024 Mar 19, 2024

Copy link to clipboard

Copied

I just uploaded a sample. The objects photographed are hardly ever the same size/shape etc. The final images are sized to fully fit into a 3000px space. 

Votes

Translate

Translate

Report

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
Community Expert ,
Mar 19, 2024 Mar 19, 2024

Copy link to clipboard

Copied

Thanks for the screenshot, can you please post 2 or more actual images?

 

An action with the following basic steps should do what you need:

 

* Load transparency channel as selection, or Select Subject or inverted colour range selection from white

* Image > Crop (to selection)

* Automate > Fit Image (3000,3000)

* Image > Canvas Size (3000,3000)

Votes

Translate

Translate

Report

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
Explorer ,
Mar 20, 2024 Mar 20, 2024

Copy link to clipboard

Copied

These are samples of products in various shapes; clipped

Votes

Translate

Translate

Report

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
Community Expert ,
Mar 20, 2024 Mar 20, 2024

Copy link to clipboard

Copied

Thanks for the actual sample images, it does help!

 

So, it was as simple as I previously wrote:

 

  1. Load transparency channel as selection
  2. Image > Crop (to selection)
  3. Automate > Fit Image (3000,3000)
  4. Image > Canvas Size (3000,3000)

 

2024-03-21_09-35-50.png

 

Then run the action via Automate > Batch

Votes

Translate

Translate

Report

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
Explorer ,
Mar 25, 2024 Mar 25, 2024

Copy link to clipboard

Copied

Will creating a "Ctrl Click" to select the item and continue on with the remaining steps work? I must be doing something wrong. When the action operates on the next file, it selects the same shape as the original file, and the crop to selection is not cropping to selection. So I end up with cropped images and a lot of white space around the item. 

I have "loaded" the transparency selection on the channels tab, but it doesn't select the whole image. I have all the confusion. 

Votes

Translate

Translate

Report

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
Explorer ,
Mar 25, 2024 Mar 25, 2024

Copy link to clipboard

Copied

Ok, so I have managed to get the selection to crop, I just can't get the canvas to be a square. It will size the canvas to the longest side. 

Votes

Translate

Translate

Report

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
Community Expert ,
Mar 25, 2024 Mar 25, 2024

Copy link to clipboard

Copied

quote

Ok, so I have managed to get the selection to crop, I just can't get the canvas to be a square. It will size the canvas to the longest side. 


By @mbenton75


Step 4: Canvas size...

 

Stop recording the action after the Fit Image step. The canvas should now be 3000px on the longest edge.

 

To record a 3000px square canvas resize, you need to prime the document so that the longest edge isn't 3000px. So either resize, crop or create a dummy document smaller than 3000px on each edge.

 

Then press record and use canvas size to 3000px on each edge. Stop recording. Your recorded action step for canvas size should now have a width of 3000px and a height of 3000px, creating a square canvas for both portrait and landscape images.

 

Actions are not always recorded in a linear start-to-finish manner. Sometimes you need to record and stop, insert menu items, setup the document in another manner, record again etc.

 

Hope this helps.

 

 

 

Votes

Translate

Translate

Report

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
Explorer ,
Mar 26, 2024 Mar 26, 2024

Copy link to clipboard

Copied

LATEST

Goodness gracious! You sir, are a LEGEND! I have been working my same tedious process for years! 1) I have always found actions intimidating 2) I always just put it off because I just needed to get that week's job done. I got close a couple of times but was always just missing one tiny element. It all worked perfectly! Me and my wrists are so thankful for your knowledge! 

Votes

Translate

Translate

Report

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