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

Why the Shapes Contours Colors are not the same than the shape himself when I export them as PNG

New Here ,
Jul 19, 2023 Jul 19, 2023

Copy link to clipboard

Copied

Hello,

i would like to create shapes from several .png layers added together. 
When I export them (3000x3000pxl) and add them together we can see the contours of the shape from each layers. 

However on Ai when I add the layers together those contours are not visible. 

Do you know if it's possible to avoid that visible contours so the layers of the same color added together could match perfectly?

 

Please find attached an exemple where we can see the contours of each .png layer

TOPICS
Draw and design , Tools

Views

1.7K

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
Adobe
Community Expert ,
Jul 19, 2023 Jul 19, 2023

Copy link to clipboard

Copied

Hugo,

 

I believe it can be an anti aliasing issue, possibly caused by PNG images that are not contained within whole pixels, owing to positions and/or sizes with decimals.

 

 

The following may sound unforgivably outdated and boring, sorry.


If you wish to have PNGs (PNG24 (also (little) known as PNG32, it holds 24 bit colour and 8 bit Alpha channel (transparency)), of course) look crisp and clean, at least when it is (also) to be used at moderate screen resolutions, it is important to have the images in the exact desired final pixel x pixel size, or at sizes that are powers of 2 times as large (2x, 4x, 8x, and so on, the larger values can improve the appearance on high resolution screens and still ensure best possible appearance at low resolution screens); forget about image resolution which may actually lead to wrong sizes and hence blurriness, or work at 72PPI or powers of 2 times as large (144PPI, 266PPI, 576PPI, and so on).


It is easiest and safest to work at the desired size when creating the artwork.


It is important to remember that a raster image represents the whole appearance, including strokes, so to make sure you get it right you can click Show Preview Bounds in the General Preferences (and untick it afterwards).


A very common unsuitable way is to Export to PNG (remember to use PNG24 and use Transparency for artwork to be in front of different backgrounds) with a medium or high resolution, such as 300PPI.


And a common misunderstanding: (almost) 11 out of 10 times, a statement like "I created the document at 300 PPI" means that the value is chosen in Effect>Document Raster Effects Settings; however that only means that the (current) resolution of any raster effects applied to the vector artwork, such as (any kind of) Blur, is set to that value (and only unless/until the value is changed to something else); when zooming in, this resolution can be seen in contrast to and on the background of the vector artwork. So this setting has nothing whatsoever to do with the actual resolution of a raster image created from the (vector) artwork (but it ought to (at least) match it).


For clean and crisp artwork avoid JPEG; to get the colours right, you may wish/need to finalize by opening the PNG in PS (Photoshop) and attach the (missing) colour profile (such as sRGB) there.


It is also important to have the artwork and also the Artboard(s) placed fully within integer/whole pixel X and Y values in the Workspace, which means that the X and Y values at the corners must be integer; this can be ensured by using one of the corner Reference Points in the Transform palette, and then checking that all the values X, Y, W, and H, are integer (the centre Reference Point can only be used if both W and H are even numbers).


If you have issues with the Artboard(s), make sure the rulers are Global Rulers (RightClick), if not change from Artboard to Global Rulers; and to align your artboards, click the Rearrange All Artboards button in the Artboards panel. First posted by Ton here,
https://community.adobe.com/t5/illustrator-discussions/why-is-illustrator-not-exporting-artboard-siz...


Otherwise the resulting image will become a bit wider/taller and the extension(s) will be empty and therefore be (partially) transparent/white.


Therefore, a safe way is to create the artwork at the final pixel x pixel size and use a corresponding Artboard, then use the Legacity Save for Web (where you can look in the Image Size window for size confirmation and possibly multiply by 2, 4, 8, whatever), or use Export at 72PPI (or 144/288/576/whatever PPI), or use Export for Screens (in either way). In either case, use the relevant optimization (available with both ways); it is also convenient to have 72PPI (or 144/288/576/whatever PPI) in the Effect>Document Raster Effect Settings.


If you have pure vector artwork, you can relax a bit and have the artwork/Artboard at any size (the Artboard must have the same proportions as the final image), then use the Legacity Save for Web and set either Width or Height in the Image Size and Apply (make sure the other value is also correct).


The Legacy Save for Web may be an old carthorse, but it knows its way home, even if the driver is drunk and sleeping it off in the hay in the back.

 

 

 

 

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
New Here ,
Jul 19, 2023 Jul 19, 2023

Copy link to clipboard

Copied

Dear Jacob, 

Thank you for the very clear reply. 

 

The project is the creation of an NFT collection so you need to create hundreds of layers in .png to have the empty background and then create a program who'll superpose them as Layer 1 + Layer 2 + Layer 3 and finally you'll have an entire object. Doing it handly and exporte every object could be possible but it's not the aim of the project which is to mix technology and art to generate randomly few thousands of pieces. 

The error I did is that when you work on illustrator you are in vectorial mode so visually on the app there is perfect match between layers. It's not the same when you export it as .png if I understood well because it's not obviously a perfect match pixel by pixel? 
The fact is that I work already at the size I want (3000x3000pxls) finally but there is not a perfect match when I export it as PNG but on Ai it's perfect, that's what missed me... 

 

I already create more than a hundred layers so if there is a way to fix it easy as possible it could be amazing, otherwise even if you have a method to being able to make new layers who'll match perfectly it could be great. 

Please find attached an exemple with 5 layers and the final result when I export them as one object or when I added .png layers on Ai and then export as an object (final goal).

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 ,
Jul 19, 2023 Jul 19, 2023

Copy link to clipboard

Copied

Please show us the objects in the layers panel and select each of the affected objects and then post a screenshot of object and appearance panel.

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
New Here ,
Jul 19, 2023 Jul 19, 2023

Copy link to clipboard

Copied

Hello Monika, 

Please find an exemple of 5 .png layers added together and the final result when I added the .png together and when I export it from Ai as one object. 

Best,

Hugo

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 ,
Jul 19, 2023 Jul 19, 2023

Copy link to clipboard

Copied

If you are trying to combine images in Illustrator, I would recommend Photoshop for that task.

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 ,
Jul 19, 2023 Jul 19, 2023

Copy link to clipboard

Copied

Are you exporting each shape tto PNG and then having them layer? Can you not make all the objects to a PNG?

This is antialiasing. You need to work pixel perfect by aligning to pixel grid which will help with vertical strokes, but curves and diagonals may get mathematical floating point operations that cause visual hairlines. (The problem is 50% of 50% is not zero, so it's a bit of a mathematical problem.)
PNG also is not true transparency only alpha transparency of edge pixels and this has effect on how the edges blend. 
You can rasterise the image from illustrator, before exporting it, or have the one shape under the smaller shape rather than having your shapes meet edge to edge.

If you can explain more why you need each layer as a seperate PNG maybe we can help you think of a workflow that works for you.

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
New Here ,
Jul 19, 2023 Jul 19, 2023

Copy link to clipboard

Copied

Hi Lukas, 

The project is the creation of an NFT collection so you need to create hundreds of layers in .png to have the empty background and then create a program who'll superpose them as Layer 1 + Layer 2 + Layer 3 and finally you'll have an entire object. Doing it handly and exporte every object could be possible but it's not the aim of the project which is to mix technology and art to generate randomly few thousands of pieces. 

The error I did is that when you work on illustrator you are in vectorial mode so visually on the app there is perfect match between layers. It's not the same when you export it as .png

 

I already create more than a hundred layers so if there is a way to fix it easy as possible it could be amazing, otherwise even if you have a method to being able to make new layers who'll match perfectly it could be great. 

Please find attached an exemple with the 7 layers and the final result when I export them as one object or when I added .png layers on Ai and then export as an object (final goal).

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 ,
Jul 20, 2023 Jul 20, 2023

Copy link to clipboard

Copied

So the screenshot which started this thread actually was not a screenshot done inside Illustrator and also it wasn't one PNG exported from Illustrator, but it was several PNGs exported from Illustrator and then layered in some coding app? And you think the error is within Illustrator? Right?

 

What I do not get: You have Illustrator. And Illustrator is scriptable. You could create these color variations inside Illustrator. You could even use artificial intelligence to create color variations in "Recolor artwork" to generate that. But you export low res PNGs in order to layer them in other apps? That doesn't sound like a good idea.

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
New Here ,
Jul 20, 2023 Jul 20, 2023

Copy link to clipboard

Copied

Dear Monika,

 

Actually no, I did everything on Illustrator. The .png export (the ones I joined), and th me addition together (the final .png file). 
I used only illustrator on my IPad! You think that could be due to the Ai app and not the real software? 
for the color variation, the layer from the left wall have all the same color, my problème is that they don't match perfectly together and neither with the layers from the right wall. 

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 ,
Jul 21, 2023 Jul 21, 2023

Copy link to clipboard

Copied

Can you please tell us step by step what you are doing?

1.

2.

3.

 

I don't get that workflow. 

I don't understand why you are piecing together PNG files. That doesn't really make any sense.

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 ,
Jul 19, 2023 Jul 19, 2023

Copy link to clipboard

Copied

I guess it should be possible to batch open the png files in Photoshop and expand each objects shape (increase opacity of partially opaque pixels) in printing this would be similar to trapping.

In illustrator add a thin stroke would make objects slightly larger, and touch on overlapping rather than the hairline spaces you have. Snapping artwork to pixels would be a better way to go but diagonals and arcs may still be a problem. 

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
New Here ,
Jul 20, 2023 Jul 20, 2023

Copy link to clipboard

Copied

Thank you Lukas, 

I'll try that on Photo Shop. That will fill the pixels which are not 100% opacity? 
On illustrator add a thin stroke don't help, it's even worse when I export it as .png
How could I do to snap artwork to pixels and make those pixels match perfectly? 

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 ,
Jul 21, 2023 Jul 21, 2023

Copy link to clipboard

Copied

You can read about it here. https://helpx.adobe.com/illustrator/how-to/pixel-perfect.html
I would suggest just doing some smaller test files to get used to the principles first. 


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 ,
Jul 21, 2023 Jul 21, 2023

Copy link to clipboard

Copied

LATEST

Avoiding anti-aliasing by snap to pixel works for horizontal and vertical lines/objects, but not for curved ones.

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 ,
Jul 20, 2023 Jul 20, 2023

Copy link to clipboard

Copied

Try if your can export your layered vector content as a layered PSD with Art Optimized for anti-aliasing and a resolution of 72 ppi or multiples thereoff (144, 288).

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