<div dir="ltr">If you don't care about quality then JPEG is an option... ;-) I also wonder if there are ways to create true 8-bit output in other ways. No way GD comes back.</div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Tue, May 18, 2021 at 1:12 PM Richard Greenwood <<a href="mailto:richard.greenwood@gmail.com">richard.greenwood@gmail.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr">Oops - typo there, reducing the colors from 256 to <b>125</b> reduced the image size by about 15%.</div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Tue, May 18, 2021 at 12:11 PM Richard Greenwood <<a href="mailto:richard.greenwood@gmail.com" target="_blank">richard.greenwood@gmail.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr">Bob - I think GD was quite unpopular with the developers. Thomas Bonfort was pretty adamant about removing it. I'm hoping that there may be options in AGG.<div><br><div>Seth - FORMATOPTION "COMPRESSION=9" only reduced the size by about 3% in my lines and text test case.</div><div><br></div><div>Even - the default AGG/PNG8 has QUANTIZE_FORCE=on and QUANTIZE_COLORS=256. I think I remember you saying somewhere that reducing the number of colors mostly just reduced the pallet size and that's pretty much what I see. e.g. reducing the pallet from 256 to 15 colors reduces the image size by about 15% in my lines and text test.</div><div><br></div><div>Thanks all for the suggestions.</div><div>Rich</div><div><br></div></div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Tue, May 18, 2021 at 11:49 AM Even Rouault <<a href="mailto:even.rouault@spatialys.com" target="_blank">even.rouault@spatialys.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">
<div>
<pre>Forcing paletted images using QUANTIZE_FORCE=on and decreasing the number of colors with QUANTIZE_COLORS can also help:
FORMATOPTION "QUANTIZE_FORCE=on"
FORMATOPTION "QUANTIZE_COLORS=200"
<span>
</span></pre>
<div>Le 18/05/2021 à 19:30, Seth G a écrit :<br>
</div>
<blockquote type="cite">
<div>I've not used it but the following might help for the AGG/PNG
driver:<br>
</div>
<div><br>
</div>
<div>FORMATOPTION "COMPRESSION=9"<br>
</div>
<div><br>
</div>
<div><a href="https://mapserver.org/mapfile/outputformat.html" target="_blank">https://mapserver.org/mapfile/outputformat.html</a><br>
</div>
<div><br>
</div>
<div>The default is 6. <br>
</div>
<div><br>
</div>
<div id="gmail-m_2850054942297140456gmail-m_3556605903773146303gmail-m_8571141354921375954sig62266145">
<div>--<br>
</div>
<div>web:<a href="http://geographika.co.uk" target="_blank">http://geographika.co.uk</a><br>
</div>
<div>twitter: @geographika<br>
</div>
</div>
<div><br>
</div>
<div><br>
</div>
<div>On Tue, May 18, 2021, at 7:16 PM, Basques, Bob (CI-StPaul)
wrote:<br>
</div>
<blockquote type="cite" id="gmail-m_2850054942297140456gmail-m_3556605903773146303gmail-m_8571141354921375954qt">
<div>
<p>All,<br>
</p>
<p> <br>
</p>
<p>I know the GD stuff has been a long
running conversation in the MapServer realm, but does this
indicate that maybe discussing something on adding GD back
in might be prudent? Or are there methods to get down to
these previous files sizes with the newer approaches?<br>
</p>
<p> <br>
</p>
<p>I have the same concerns related to
image size from the performance side, and running on Mobile
in our case.<br>
</p>
<p> <br>
</p>
<p>Bobb<br>
</p>
<p> <br>
</p>
<p> <br>
</p>
<div style="border-color:rgb(181,196,223) currentcolor currentcolor;border-style:solid none none;border-width:1pt medium medium;padding:3pt 0in 0in">
<p style="margin-left:0.5in"><b><span style="color:black"><span style="font-size:12pt">From: </span></span></b><span style="color:black"><span style="font-size:12pt">mapserver-users
<a href="mailto:mapserver-users-bounces@lists.osgeo.org" target="_blank"><mapserver-users-bounces@lists.osgeo.org></a> on
behalf of Richard Greenwood
<a href="mailto:richard.greenwood@gmail.com" target="_blank"><richard.greenwood@gmail.com></a><br>
<b>Date: </b>Tuesday, May 18, 2021 at 11:50 AM<br>
<b>To: </b><a href="mailto:mapserver-users@lists.osgeo.org" target="_blank">"mapserver-users@lists.osgeo.org"</a>
<a href="mailto:mapserver-users@lists.osgeo.org" target="_blank"><mapserver-users@lists.osgeo.org></a><br>
<b>Subject: </b>[mapserver-users] anti-aliasing (was
differing image size with different mapserver
versions)</span></span></p>
</div>
<div>
<p style="margin-left:0.5in"> <br>
</p>
</div>
<table style="margin-left:0.5in;background-color:rgb(226,247,0);background-repeat:repeat;background-image:none;background-size:auto;background-origin:padding-box;background-clip:border-box;border-color:black;border-style:solid;border-width:1pt" cellpadding="0" border="1">
<tbody>
<tr>
<td style="border-color:currentcolor;border-style:none;border-width:medium;padding:0.75pt">
<p><b><span style="color:rgb(255,51,51)"><span style="font-family:Calibri,sans-serif">Think Before You Click: </span></span></b><span style="color:black">This email originated <b><span><span style="font-family:Calibri,sans-serif">outside </span></span></b>our
organization.</span><br>
</p>
</td>
</tr>
</tbody>
</table>
<p style="margin-left:0.5in"> <br>
</p>
<div>
<div>
<p style="margin-left:0.5in">Thanks
to several helpful replies to my previous thread I know
that the increased image size between MapServer 6 with
the GD driver and MapServer 7 with the AGG driver is
due to differences in anti-aliasing (and lack of) in the
two drivers. (AGG <a href="https://en.wikipedia.org/wiki/Anti-Grain_Geometry" target="_blank"> features anti-aliasing and
sub-pixel resolution</a>).<br>
</p>
<div>
<p style="margin-left:0.5in"> <br>
</p>
</div>
<div>
<p style="margin-left:0.5in">Gamma
setting from 0-1 affects the size of a filled polygon
layer by a factor of almost 3x. But gamma has no
effect on text, lines, and polygon outlines. So images
comprised of these types of features are approximately
2x larger with the AGG/PNG8 driver than with the
GD/GIF driver. <br>
</p>
</div>
<div>
<p style="margin-left:0.5in"> <br>
</p>
</div>
<div>
<p style="margin-left:0.5in">Where
else should I be looking to reduce my images sizes? I
serve rural areas with poor internet so in my case,
smaller image sizes are more important than
higher quality images.<br>
</p>
</div>
<div>
<p style="margin-left:0.5in"> <br>
</p>
</div>
<div>
<p style="margin-left:0.5in">Thanks,<br>
</p>
</div>
<div>
<p style="margin-left:0.5in">Rich<br>
</p>
</div>
<div>
<div>
<p style="margin-left:0.5in"> <br>
</p>
</div>
<p style="margin-left:0.5in">--<br>
</p>
<div>
<div>
<p style="margin-left:0.5in"><br>
</p>
<div>Richard W. Greenwood, PLS<br>
</div>
<div> <a href="http://www.greenwoodmap.com" target="_blank">www.greenwoodmap.com</a><br>
</div>
<p><br>
</p>
</div>
</div>
</div>
</div>
</div>
</div>
<div>_______________________________________________<br>
</div>
<div>mapserver-users mailing list<br>
</div>
<div><a href="mailto:mapserver-users%40lists.osgeo.org" target="_blank">mapserver-users@lists.osgeo.org</a><br>
</div>
<div><a href="https://lists.osgeo.org/mailman/listinfo/mapserver-users" target="_blank">https://lists.osgeo.org/mailman/listinfo/mapserver-users</a><br>
</div>
<div><br>
</div>
</blockquote>
<div><br>
</div>
<br>
<fieldset></fieldset>
<pre>_______________________________________________
mapserver-users mailing list
<a href="mailto:mapserver-users@lists.osgeo.org" target="_blank">mapserver-users@lists.osgeo.org</a>
<a href="https://lists.osgeo.org/mailman/listinfo/mapserver-users" target="_blank">https://lists.osgeo.org/mailman/listinfo/mapserver-users</a>
</pre>
</blockquote>
<pre cols="72">--
<a href="http://www.spatialys.com" target="_blank">http://www.spatialys.com</a>
My software is free, but my time generally not.</pre>
</div>
_______________________________________________<br>
mapserver-users mailing list<br>
<a href="mailto:mapserver-users@lists.osgeo.org" target="_blank">mapserver-users@lists.osgeo.org</a><br>
<a href="https://lists.osgeo.org/mailman/listinfo/mapserver-users" rel="noreferrer" target="_blank">https://lists.osgeo.org/mailman/listinfo/mapserver-users</a><br>
</blockquote></div><br clear="all"><div><br></div>-- <br><div dir="ltr"><div dir="ltr">Richard W. Greenwood, PLS<br><a href="http://www.greenwoodmap.com" target="_blank">www.greenwoodmap.com</a></div></div>
</blockquote></div><br clear="all"><div><br></div>-- <br><div dir="ltr"><div dir="ltr">Richard W. Greenwood, PLS<br><a href="http://www.greenwoodmap.com" target="_blank">www.greenwoodmap.com</a></div></div>
_______________________________________________<br>
mapserver-users mailing list<br>
<a href="mailto:mapserver-users@lists.osgeo.org" target="_blank">mapserver-users@lists.osgeo.org</a><br>
<a href="https://lists.osgeo.org/mailman/listinfo/mapserver-users" rel="noreferrer" target="_blank">https://lists.osgeo.org/mailman/listinfo/mapserver-users</a><br>
</blockquote></div>