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

Why do compound shapes render differently at the pixel level than individual shapes in Illustrator?

Community Beginner ,
Dec 14, 2016 Dec 14, 2016

When working with compound shapes, pixels are rendered differently than individual shapes. To give some context, I have a set of pixel grid optimized icons that I am trying to export in a transparent format, after creating compound shapes.

Simple example shown below, of a 20 px by 20 px rectangle, with a 4 px by 4 px circle on top, both perfectly aligned to the pixel grid. The left is two individual shapes. The right is a compound shape, created using Minus Front in the Pathfinder Palette.

White Artboard (Zoomed In View):

White Artboard.png

Transparent Artboard (Zoomed In View):

Transparent Artboard.png

Exported PNG 24 graphic with transparency, using Save for Web (Anti-Aliasing - Art Optimized):

Exported-Graphic-With-Transparency-Using-Save-For-Web.png

Exported PNG 24 graphic with transparency, using Export for Screens (Anti-Aliasing - Art Optimized):

Exported-Graphic-With-Transparency-Using-Export-For-Screens.png

As you can see the left circle appears sharp and precise, regardless of export method, while the right compound shape appears fuzzy and smaller, so to speak.

To make things more interesting, below is an example of the same compound shape brought over into Photoshop, as a Smart Object, by pasting from the clipboard (Zoomed In View):

Photoshop-Compound-Shape.png

The same Photoshop file exported using Export, Export As, in PNG 24 format with transparency:

Exported-Graphic-Photoshop-Using-Export-Export-As-With-Transparency.png

The compound shape appears perfectly sharp, when exported from Photoshop, but does not when exported from Illustrator.

Is there any way to achieve sharp raster graphics from compound shapes, directly from Illustrator?

1.2K
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 Beginner ,
Dec 20, 2016 Dec 20, 2016

Here's another example (without transparency this time, although the issue occurs both with and without transparency).

Individual shapes:

arrow-individual-shapes.png

Compound shape:

arrow-compound-shape.png

Notice how the top of the arrow is not as sharp in the compound shape.

Zoomed in view from Photoshop below.

Individual shapes:

zoomed-in-view-individual-shapes.png

Compound shape:

zoomed-in-view-compound-shape.png

The pixels are rendered completely differently between the individual and compound shapes. The color values are also different. The individual shapes have a lighter, more defined edge. The compound shape has a harsher transition directly from white to a darker shade of gray.

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
Community Expert ,
Dec 20, 2016 Dec 20, 2016

You might want to post this as a bug/feature request.

Most people on this forum are normal users just as you. We don't have any insight into the working of the code.

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
Community Beginner ,
Dec 20, 2016 Dec 20, 2016

Thanks for the suggestion Monika. I wasn't sure if there was a setting or something I was overlooking. I thought maybe someone had run into the issue before.

If it is a bug, I'm looking for recommendations on how I might be able to solve the issue, or a workaround to it. Potentially an alternative method for creating transparency.

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
Community Expert ,
Dec 20, 2016 Dec 20, 2016

I don't think it's a bug. Compound shapes are live objects and their rendering is presumably just different.

In your case there's no transparency involved. There are only holes in your graphic, but no transparency.

Try if a compound path behaves differently.

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
Community Beginner ,
Dec 20, 2016 Dec 20, 2016

It appears to be identical with both compound shapes and compound paths.

Right. What I am trying to achieve is creating graphics that have transparency. So, the holes will be transparent when exported as transparent PNG files.

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
Community Expert ,
Dec 20, 2016 Dec 20, 2016

It is probably the difference between transparency and no transparency.

The compound paths are rendered transparent which is probably using a different anti-aliasing algorithm as opaque objects.

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
Community Beginner ,
Dec 21, 2016 Dec 21, 2016

The same issue happens whether it is exported without transparency, as in the second example I posted. However, you may be correct that the algorithm differs between compound shapes and paths vs. individual objects.

However, if that is the case, is there any way that I can achieve the same sharpness as when the objects were individual shapes?

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
Community Expert ,
Dec 21, 2016 Dec 21, 2016

You may try the Rasterize Effect in Illustrator to see if that gives a result that comes closer to what you want.

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
New Here ,
Jun 29, 2023 Jun 29, 2023
LATEST

I know that this is a very old thread, but has this been resolved in the last 7 years or so? I have scoured the site and internet to find any other reference to this anomoly but surprisingly this thread is the only reference I have found that describes this!

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