← All ideas
  • Published 17 Apr 2020

Automatically crop out excessive alpha background from rendered image

I think it would be neat either if there was like a checkbox in Scene > Dimensions right below "Crop to Render Region" that would automatically crop the image to remove any transparent pixels at the edges of the render to keep the rendered image file size down and to sure what you have in your render is perfectly centered.

Alternatively if there was a node for this in the compositor

Im working on a HUD for a video game and make a render for each icon. When making icons related to the crosshair, its very important that your icon is perfectly centered in the image, or else you will have to manually adjust the placement of the icon in the game engine (or crop the image by hand), which is mostly why Im suggesting this <3. Another more obvious benefit would be possibly reducing the file size of the image by a tiny bit :p

To demonstrate: imgur.com/a/duPswNm

0%

Development Status: Open

Upvote 0 Downvote 0
MrWillyWonka
17 Apr 2020

6 Comments

egonfreeman

I'd also love to see such an option - it would cut our image sizes by 2/3rds, and it'd be nice if I didn't have to spend two hours each batch reducing it all from 20 GB down to 8... Not to mention upload/download times.

MrWillyWonka Author

* @egonfreeman * Yep. For some purposes it would be quite a fine addition to Blender

Vyach
  1. This function looks more like 2d editing.
  2. Why didn`t you change output size and camera zoom?
  3. Many 2D browsers have this functions (crop alpha and resize to certain size), so you can do it batch.
MrWillyWonka Author

* @ Vyacheslav * Hi, if you mean the render resolution and camera scale then its because Im having my cameras set to 1080p, placing all of my icons like theyre supposed to be laid out on my game HUD and then using render regions cutting out and rendering each icon individually.

Also its not a browser game if thats what you mean by that I can do it batch.

Blender actually added functionality to manually drag/fine tune the render region with help of handles making this a lot easier for me, so my issue is kinda fixed now however

Vyach

* @Willy Wonka * ot a browser game I mean not web browser, I mean 2d-browser. As XnVview 4 example. And faster solution (if you have ~thousand of pictures) is imagemagick processing

MrWillyWonka Author

To demonstrate: imgur.com/a/duPswNm