Jump to content
You must now use your email address to sign in [click for more info] ×

Recommended Posts

I am using Affinity Designer to create about 100 simple tables and charts for a work deliverable. Each table / chart needs to be exported as a PNG file. Most of the tables / charts use only four colours: black, blue, grey and white. I am not fluent in export settings and color spaces, so would appreciate some advice.

 

Attached is an example of one of the simplest tables, as well as the export settings that I am using. If I export the image with the PNG-8 Dithered preset, the resulting PNG file is 245KB in size (as shown in Mac Finder). If I export the same image with the PNG-24 preset, the PNG output file is 81KB in size. In both cases I am using Bilinear resampling.

 

If my goal is to minimise the PNG file size without significant loss of quality, what export settings would you recommend?

 

FYI that I know I can use 3rd-party software to compress the PNG files, but I am looking for a solution within Affinity Designer.  Thanks.

 

Screen Shot 2018-04-26 at 16.19.22.png

Link to comment
Share on other sites

  • Staff

Hi pomme27,

 

Thats odd that PNG-8 is producing a larger file than PNG-24, as PNG-8 has less colours to work with.  Any chance you can share the .afdesign file?

 

As you are only using 4 colours, PNG-8 should be fine for exporting and should export a much small file than the PNG-24, so it's odd that isn't happening for you.

Link to comment
Share on other sites

Consider the attached test table.afdesign file, a small (500 x 360 px) mockup of the @pomme27 table I made. I was careful to use only the 4 colors in the "test table 4 color" document palette you can see in this file's Swatches panel.

 

I exported this file to png 3 times, first with the default "PNG-8 (dithered)" preset, & then twice more, using the "More" button to set the Palette to "Automatic" & "Colors" to 4 & to 8, like this:

more.png.12159402bef5587d9bbfde5382be6f47.png

I also tried the Palettized > "Custom" palette setting but that has always produced an error with any document & this one is no exception.

 

Anyway, the three exports are shown below. The 8 bit dithered default is 7 kb; the auto4 is 8 kb; & the auto8 is 4 kb. The auto4 version is the largest & has noticeable dithering in the grey rectangles, while the smallest is the auto8 version & its dithering (or anti-aliasing, I can't tell which it is) is minor. The default 8 bit dithered version looks best, with just a minimum of anti-aliasing on the text & circles.

 

There is not much I can conclude from this, other than the Automatic palette settings that use less than 256 colors are not very efficient at reducing file size.

test table 8bit default.png

test table auto 4.png

test table auto 8.png

All 3 1.10.8, & all 3 V2.4.1 Mac apps; 2020 iMac 27"; 3.8GHz i7, Radeon Pro 5700, 32GB RAM; macOS 10.15.7
Affinity Photo 
1.10.8; Affinity Designer 1.108; & all 3 V2 apps for iPad; 6th Generation iPad 32 GB; Apple Pencil; iPadOS 15.7

Link to comment
Share on other sites

Thank you Stokerg. Attached is my test AFDESIGN file.

 

I have a conceptual understanding of dithering (adding "noise" to smooth out the colour differences between pixels), but not a technical one. I assumed that PNG-24 is a non-dithered preset, hence the PNG-24 output file is smaller in size than the file produced by the PNG-8 Dithered preset. But maybe that is unsound thinking. Also attached is what I see when I do Get Info on the PNG files.

 

Appreciate your help.

 

Screen Shot 2018-04-27 at 07.15.09.png

Test - Image.afdesign

Link to comment
Share on other sites

22 minutes ago, pomme27 said:

I have a conceptual understanding of dithering (adding "noise" to smooth out the colour differences between pixels), but not a technical one.

 

Dithering can be used to smooth out banding, but it doesn't smooth out (i.e. reduce) noise: on the contrary, it could be considered to add noise. What dithering actually does is use small dots side by side to simulate colours which are not included in a limited palette, and compression in the file is going to be relatively inefficient because of the swapping back and forth between different colour values. If you use PNG-24 you'll have a much bigger palette, but large areas of solid colour will be very efficiently compressed in the file.

Alfred spacer.png
Affinity Designer/Photo/Publisher 2 for Windows • Windows 10 Home/Pro
Affinity Designer/Photo/Publisher 2 for iPad • iPadOS 17.4.1 (iPad 7th gen)

Link to comment
Share on other sites

Thank you Alfred. Let me restate what you said to make sure I understand it. PNG-8 uses a limited color palette, so it adds dithering (adds the small dots) to smooth out colour differences between pixels. PNG-24 uses a much larger colour palette, so does not suffer as much from color differences between pixels, so does not need to use dithering. So PNG-24 is a non-dithered preset.  Sound right?

Link to comment
Share on other sites

No, PNG-8 uses a limited palette, so to represent the very many colours not included in the palette it needs to use dithering to synthesize the missing colours; it's similar to the way your LCD or LED screen only has red, green and blue pixels, but it displays what you perceive as thousands of different colours by lighting up the appropriate combination of adjacent pixels (e.g. red and green at full intensity for yellow, or at lower intensity for brown). PNG-24 offers many more bits per pixel, so it doesn't need to resort to such trickery.

Alfred spacer.png
Affinity Designer/Photo/Publisher 2 for Windows • Windows 10 Home/Pro
Affinity Designer/Photo/Publisher 2 for iPad • iPadOS 17.4.1 (iPad 7th gen)

Link to comment
Share on other sites

PNG-24 means there are 24 bits of color info available per pixel(8 bits for each of the 3 RGB color channels), for a total range of 224 or 16,777,216 possible colors in the image. PNG-8 (dithered) means there are 8 bits of indexed color info for the entire image, or up to 256 total colors. The automatic palletized options for less than 256 indexed colors apparently just use fewer of those 8 bits to force every pixel into a smaller number of indexed colors, but for good results the number of indexed colors should still be larger than the number of colors in the document where possible.

All 3 1.10.8, & all 3 V2.4.1 Mac apps; 2020 iMac 27"; 3.8GHz i7, Radeon Pro 5700, 32GB RAM; macOS 10.15.7
Affinity Photo 
1.10.8; Affinity Designer 1.108; & all 3 V2 apps for iPad; 6th Generation iPad 32 GB; Apple Pencil; iPadOS 15.7

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
×
×
  • Create New...

Important Information

Terms of Use | Privacy Policy | Guidelines | We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.