Option to export to clipping mask boundaries
When exporting assets to raster formats, it would be a huge time saver if we had an option to use the boundaries of clipping masks as the edge of the exported artwork. I created three triangles and used a circle as a clipping mask in the attached image. You can see that the exported file has a lot of padding around the artwork because the outer edges of the triangles are used as the boundaries of the file.
If there was an additional option to use the clipping mask boundary as the edge of the exported raster file, it would mean that I wouldn’t have to open every exported file in Photoshop to then crop to the edges of the artwork and re-save the file.
The fix has been rolled out and is available in our latest release build – 24.1.1 for Win and 24.1 for Mac which is available worldwide now.
What’s new in 24.1: https://helpx.adobe.com/illustrator/using/whats-new.html
You can update to the latest release using Creative Cloud desktop App: https://helpx.adobe.com/in/creative-cloud/help/creative-cloud-updates.html
Thank you for all the feedback.
Paul Jakovich commented
Lol only took 793 days for someone at Adobe to acknowledge this. I hope I'm still around to see this feature added so I can reminisce about the countless hours of my life wasted working around this flaw.
How is this not a feature yet... I came here googling for where the option to do this is found, only to realise you can't do it!
Orbit Design commented
Another new release of illustrator and still no fix....
I figured it out for my particular situation (a heavy line drawing): I had to dig in a level deep into the drawing and noticed there were some leftover lines, I probably applied a clipping mask to at some point, that didn't seem to be showing whether I enabled or disabled their visibility. By just turning their visibility off, my drawing is fixed. The way I'm getting to these invisible lines for other drawing is using the black arrow (shorcut "V") and selecting approximately the white space outside of where they're showing up after I export or Save As... pdf. This will outline an invisible box that will surround most of my drawing. I then double click on the invisible box to dive into it, and then peruse through its sub-layers in the layer panel. These invisible unclipped lines seem to always be standing out (fingers crossed this keeps happening!) in their layer icon, and I disable their visibility. Conversely, I've had to delete chunks of my drawing, until I'm able to select the invisible box with the black arrow. ***This does not take away from it being a bug on Adobe's side because it's not a "what you see is what you get" experience! Perhaps test clipping mass on complex line drawings, or reach out to other users having this issue to share their file (I can't share mine because they're patent drawings)?***
Stephen Mitchell commented
This is a really fundamental feature...it's basic, it's not even a feature, it's a basic requirement,
It's ludicrous that you can't create artwork with a mask and have it export the way you see it on the screen.
It's almost not worth creating it in Illustrator as the added work to chop the white space off totally negates the use of asset export @ different sizes.
This isn't something we should have to find workarounds for, if asset exporter won't export the artwork as WYSIWYG, it's not fit for purpose.
Another method that I have found out that is super quick.
1. Save your Ai file in PDF.
2. Open the PDF file in photoshop
3. Save the file in whichever file format you require
*PDF will preserve the clipping masks and crop whatever is outside the artboard hence making our lives easier.
This won't affect your artwork at all and you still get the option to save in whichever res you need. Hope it works for you guys too ;)
A workaround that I stumbled upon while experimenting that is reasonably fast is this:
1. Copy your Illustrator file so that anything you do will not have consequences for the original
2. Choose the artboard tool from the tool shelf
3. Double click the object you want to export to resize the artboard to the object
4. Use Export -> Save for screens and choose to export the artboard instead of the object
5. Repeat double-clicking and exporting for all your objects
This is the fastest workaround I have found so far.
How in the WORLD can this bug still exist after so many years?? What?
The fix is not even difficult, they need to run a simple script when exporting PNG. Get the stupid file and then run the script to remove transparent pixels, thats it. The script is from the 90s and is open source, it works on C, Java, Pearl, Python, LUA and many other languages. They could really solve it in 30 minutes if they want to. They wanna make it sound like is something difficult, but I am a noob programmer and even I could fix it.
Tannie Low commented
This some egregious ********. We must gather outside the Adobe offices and prohibit employees from going home until this BUG is fixed!!
This is been on for already 2 years and seems like Adobe is just not going to listen to their customers.
Here is my work-arround this annoying thing:
I export all my objects to one folder, then open terminal and use ImageMagick suite of tools’ “convert” program to trim the transparent pixels around the image. It works flawlessly on all the files in the folder.
If you guys want I can make a tutorial on it. It is an extra step I wish I didn’t need to do, but is better than opening photoshop for each image or doing the PDF thing. Just open terminal on that folder and use same command to look for all PNG and trim transparent edges and voila.
We're having to export to pdf then open in photoshop and export to pdf to make this work. It's a real time sink.
Hans, thats totally incorrect! it doesnt matter how you create or export the clipping mask Illustrator will not clip the transparent pixels outside of the clipping mask unless you are exporting jpegs. ADOBE - fix this you pathetic trash donkeys, stop renting us broken ****** software! ITS BEEN YEARS THAT PEOPLE HAVE POINTED OUT THIS MAJOR FLAW YET YOU CONTINUE TO RENT US BROKEN SOFTWARE AND UPDATE REGULARLY WITHOUT ADDRESSING THIS FUNDAMENTAL BASIC PROBLEM!
Yes! (Or if "Use Artboards" is checked off by default so I don't have to click it every time I want to "crop" my exports, but that's just a band-aid non-solution.)
Erik Enrique Lopez commented
PLEASE REVIEW & CONSIDER THIS !!!!!
MUY IMPORTANTE !!
Diego Martinez commented
I'd love to see this behavior changed to exporting without the masked areas showing around your art. +1
I need to point out that this bug ONLY happens when you use a clipping mask in the layers panel and not through right click → make clipping mask, object → clipping mask → make clipping mask or draw inside.
Steps to reproduce:
1. Create two shapes on top of each other and select both.
2. Go to the layers panel and click Make/Release Clipping Mask.
3. Click Export As...
Clipping mask is not shown on the exported image.
Clipping mask to be shown on the exported image.
Priscilla Candelas commented
I have no idea why but Illustrator makes it so hard to export your file into an image with the clipping masks on. I don't know what's the point of having a clipping mask option when it won't even work when exporting. I have tried with multiple computers so it's not my computer. And I've been having this issue for over a year, so it's not a new bug. I just expected it to be fixed by now and didn't bother to report it until today. The only option that works is "Save for Web (Legacy)" but it saves the image at 74ppi, which makes the image blurry. And the weird part is when you preview the export, it looks like the clipping masks are on, but once it's exported, it shows everything. It's infuriating. I don't have this issue with Photoshop, so I don't know why Illustrator does this. And I haven't found a single solution online. In the example image I attached, it's supposed to be clipped in the big circle outline, and in the preview, it did look like how it does in the file. It however did not export like in the preview. I use Creative Cloud on both Windows (7 and 10) and Mac.
Thomas Frogh commented
Hello. I installed the new 23.0.4 version today and the problem is still there. Both Export As and Export for Screens produce PNG files where the layer clipping masks are not preserved in the rasterizing process. JPG works fine. What is really interesting, the preview of what the PNG will look like in the dialogs looks right.
Von Glitschka (Vonster) commented
The whole concept of a clipping mask it prevent content from showing visually. That is why we masked it out. So why is your code saying "Eh, forget your mask we're going to include the stuff you can't see." Of course if they had real-world beta testing this bug would have been caught before they released another half-baked feature.
Every MAX they tout the power of Adobe Sensei and the so-called magical machine learning abilities. Look at how it can smart remove this stuff in a video at real-time. Yet none of that can solve this?
Nope. When I asked an engineer about this several months back in person they acted like it was really hard? Like I was requesting them to program a worm hole to a parallel universe kind of hard? Than again they can't figure out canvas rotate yet either, they've tried and failed three times. Something about not being able to get raster effects to rotate or something.
I remember when masked items screwed up alignment because it would consider the unseen masked content. They seemed to have solved that which seems like a similar problem to this?
Don't hold your breath though. They still have a basic fundamental snapping bug in Ai that they never fully fixed. How about this as an Ai Team strategy. Forego any new features until all major bugs are completely resolved and killed off. If that takes two years so be it. This includes stability too, Ai still crashes way too much.