Resent without the .log attachment as it seems this is being blocked to mapserver users.<br><br>
<div class="gmail_quote">On Thu, May 12, 2011 at 11:03 AM, Jon-Paul Dobson <span dir="ltr">&lt;<a href="mailto:jpdobson40@gmail.com">jpdobson40@gmail.com</a>&gt;</span> wrote:<br>
<blockquote style="BORDER-LEFT: #ccc 1px solid; MARGIN: 0px 0px 0px 0.8ex; PADDING-LEFT: 1ex" class="gmail_quote">
<div>Hi Thomas,</div>
<div> </div>
<div>Thanks for looking into this. I&#39;m using plain old File Monitor to see that the .TTF file is being accessed hundreds of times. I&#39;ve attached the output I&#39;m receiving with this mail.</div>
<div> </div>
<div>I&#39;m actually using the c# mapscript API in order to make use of MapServer. Could that have anything to do with this? Presumably this is just a wrapper around core MapServer functionality in any case?</div>
<div> </div>
<div>I notice you mention AGG. How do you configure MapServer to use AGG rather than GD? (Maybe a naive question but I&#39;m new to this!)</div>
<div> </div>
<div>Regards,</div>
<div>Jon-Paul.<font color="#888888"><br><br></font></div>
<div>
<div></div>
<div class="h5">
<div class="gmail_quote">On Thu, May 12, 2011 at 10:43 AM, thomas bonfort <span dir="ltr">&lt;<a href="mailto:thomas.bonfort@gmail.com" target="_blank">thomas.bonfort@gmail.com</a>&gt;</span> wrote:<br>
<blockquote style="BORDER-LEFT: #ccc 1px solid; MARGIN: 0px 0px 0px 0.8ex; PADDING-LEFT: 1ex" class="gmail_quote">
<div>On Thu, May 12, 2011 at 10:57, Jon-Paul Dobson &lt;<a href="mailto:jpdobson40@gmail.com" target="_blank">jpdobson40@gmail.com</a>&gt; wrote:<br>&gt; Hi,<br>&gt;<br>&gt; I just tried creating a qix file as suggested and found that the Shape file<br>
&gt; now renders 22 times faster! Fantastic advice guys. Many thanks.<br>&gt;<br>&gt; If only there was a way to prevent the TTF file being continuously accessed<br>&gt; when displaying a symbol using a truetype font. Any further ideas at all? It<br>
&gt; kind of makes a TTF unusable.<br></div>I&#39;ve just straced and ltraced the access to the font file, and<br>mapserver/agg/freetype does *not* continually access the font file. By<br>default, agg maintains a cache of the last 32 glyphs that were<br>
accessed, so access to the font file only occurs if the the current<br>glyph is not in one of the last 32 to be requested.<br>what tool are you using indicating that the font file is accessed<br>multiple times?<br><br>--<br>
<font color="#888888">thomas<br></font>
<div>
<div></div>
<div><br><br>&gt;<br>&gt; Best regards,<br>&gt; Jon-Paul.<br>&gt;<br>&gt; On Thu, May 12, 2011 at 7:52 AM, Rahkonen Jukka &lt;<a href="mailto:Jukka.Rahkonen@mmmtike.fi" target="_blank">Jukka.Rahkonen@mmmtike.fi</a>&gt;<br>
&gt; wrote:<br>&gt;&gt;<br>&gt;&gt; Hi,<br>&gt;&gt;<br>&gt;&gt; For clarification, it used to be rather a long time ago that the index<br>&gt;&gt; file (.qix) was not utilised even it was present in the data folder if the<br>
&gt;&gt; LAYER DATA was given as<br>&gt;&gt; DATA &quot;C:\Data\WMS_DATA.shp&quot;<br>&gt;&gt;<br>&gt;&gt; Index was used only if the LAYER DATA was like<br>&gt;&gt; DATA &quot;C:\Data\WMS_DATA&quot;<br>&gt;&gt;<br>&gt;&gt; However, this in old knowledge and both WMS_DATA.shp and WMS_DATA are<br>
&gt;&gt; utilising the index nowadays.<br>&gt;&gt;<br>&gt;&gt; Gdal is using the same .qix index file system and therefore also QGIS.<br>&gt;&gt; There is more info about gdal shapefile spatial index in<br>&gt;&gt; <a href="http://www.gdal.org/ogr/drv_shapefile.html" target="_blank">http://www.gdal.org/ogr/drv_shapefile.html</a><br>
&gt;&gt; The page tells also that native ESRI spatial index files (.sbn/ .sbx)  are<br>&gt;&gt; not supported.<br>&gt;&gt;<br>&gt;&gt; -Jukka Rahkonen-<br>&gt;&gt;<br>&gt;&gt;<br>&gt;&gt;<br>&gt;&gt; ________________________________<br>
&gt;&gt; Lähettäjä: <a href="mailto:mapserver-users-bounces@lists.osgeo.org" target="_blank">mapserver-users-bounces@lists.osgeo.org</a><br>&gt;&gt; [mailto:<a href="mailto:mapserver-users-bounces@lists.osgeo.org" target="_blank">mapserver-users-bounces@lists.osgeo.org</a>] Puolesta Ben Madin<br>
&gt;&gt; Lähetetty: 12. toukokuuta 2011 4:00<br>&gt;&gt; Vastaanottaja: <a href="mailto:mapserver-users@lists.osgeo.org" target="_blank">mapserver-users@lists.osgeo.org</a><br>&gt;&gt; Aihe: Re: [mapserver-users] Layer rendering performance problem<br>
&gt;&gt;<br>&gt;&gt; I&#39;m not sure whether it is still the case, but it used also to be that if<br>&gt;&gt; you wanted to use the index, you need to name the shapefile without the .shp<br>&gt;&gt; extension. If you used the .shp extension it wouldn&#39;t use the .qix index.<br>
&gt;&gt; So maybe this is a question - Is that still the case?<br>&gt;&gt; On a similar note, does anyone know ... is the index created with shptree<br>&gt;&gt; the same as the one created by QGIS (also a .qix file)?<br>&gt;&gt; cheers<br>
&gt;&gt; Ben<br>&gt;&gt;<br>&gt;&gt;<br>&gt;&gt; On 12/05/2011, at 10:45 AM, <a href="mailto:mapserver-users-request@lists.osgeo.org" target="_blank">mapserver-users-request@lists.osgeo.org</a> wrote:<br>&gt;&gt;<br>&gt;&gt; From: Stephen Woodbridge &lt;<a href="mailto:woodbri@swoodbridge.com" target="_blank">woodbri@swoodbridge.com</a>&gt;<br>
&gt;&gt; Date: 11 May 2011 11:53:34 PM AWST<br>&gt;&gt; To: <a href="mailto:mapserver-users@lists.osgeo.org" target="_blank">mapserver-users@lists.osgeo.org</a><br>&gt;&gt; Subject: Re: [mapserver-users] Layer rendering performance problem<br>
&gt;&gt;<br>&gt;&gt;<br>&gt;&gt; look at the mapserver utilities:<br>&gt;&gt;<br>&gt;&gt; shptree myshapefile<br>&gt;&gt;<br>&gt;&gt; This creates a spatial index (*.qix) and you should create one for every<br>&gt;&gt; shapefile you are using.<br>
&gt;&gt;<br>&gt;&gt; On Linux this will do the trick:<br>&gt;&gt;<br>&gt;&gt; find /path/data -name \*.shp -exec shptree {} \;<br>&gt;&gt;<br>&gt;&gt; If the .qix file is missing on every draw mapserver must create one on the<br>
&gt;&gt; fly in memory and the it throws it away.<br>&gt;&gt;<br>&gt;&gt; -Steve W<br>&gt;&gt;<br>&gt;&gt; On 5/11/2011 11:47 AM, Jon-Paul Dobson wrote:<br>&gt;&gt;<br>&gt;&gt; Hi Jukka,<br>&gt;&gt;<br>&gt;&gt; Thanks for getting back to me so quickly. No I haven&#39;t tried this. How<br>
&gt;&gt;<br>&gt;&gt; is this done and what is the benefit? Aren&#39;t Shape files already indexed?<br>&gt;&gt;<br>&gt;&gt; Regards,<br>&gt;&gt;<br>&gt;&gt; Jon-Paul.<br>&gt;&gt;<br>&gt;&gt; On Wed, May 11, 2011 at 4:41 PM, Rahkonen Jukka<br>
&gt;&gt;<br>&gt;&gt; &lt;<a href="mailto:Jukka.Rahkonen@mmmtike.fi" target="_blank">Jukka.Rahkonen@mmmtike.fi</a> &lt;mailto:<a href="mailto:Jukka.Rahkonen@mmmtike.fi" target="_blank">Jukka.Rahkonen@mmmtike.fi</a>&gt;&gt; wrote:<br>
&gt;&gt;<br>&gt;&gt;    Hi,<br>&gt;&gt;<br>&gt;&gt;    No answers but a question back. Have you created spatial index<br>&gt;&gt;<br>&gt;&gt;    (.qix) for your shapefiles with shptree?<br>&gt;&gt;<br>&gt;&gt;    -Jukka Rahkonen-<br>
&gt;&gt;<br>&gt;&gt;    Jon-Paul Dobson wrote:<br>&gt;&gt;<br>&gt;&gt;     &gt; Hi,<br>&gt;&gt;<br>&gt;&gt;<br>&gt;&gt;<br>&gt;&gt;     &gt; Whenever I display a layer based on a Shape file I notice that<br>&gt;&gt;<br>&gt;&gt;    the Shape<br>
&gt;&gt;<br>&gt;&gt;    file is accessed constantly. This makes rendering extremely slow when<br>&gt;&gt;<br>&gt;&gt;    compared to, for example, ESRI ArcIMS which appears to cache the<br>&gt;&gt;<br>&gt;&gt;    Shape file.<br>
&gt;&gt;<br>&gt;&gt;    Is there an equivalent caching mechanism for Map Server? ArcIMS seems<br>&gt;&gt; to<br>&gt;&gt;<br>&gt;&gt;    render an order of magnitude faster when the number of symbols runs<br>&gt;&gt;<br>&gt;&gt;    into the<br>
&gt;&gt;<br>&gt;&gt;    1000s<br>&gt;&gt;<br>&gt;&gt;<br>&gt;&gt;<br>&gt;&gt;     &gt; Similarly, whenever I display layer symbols using a truetype font<br>&gt;&gt;<br>&gt;&gt;    I notice<br>&gt;&gt;<br>&gt;&gt;    that the .ttf file is accessed for every symbol. This makes rendering<br>
&gt;&gt;<br>&gt;&gt;    appallingly slow. Is there also any caching mechanism to prevent this?<br>&gt;&gt;<br>&gt;&gt;<br>&gt;&gt;<br>&gt;&gt;     &gt; Any insight anyone can give would be much appreciated.<br>&gt;&gt;<br>
&gt;&gt;<br>&gt;&gt;    Best regards,<br>&gt;&gt;<br>&gt;&gt;    Jon-Paul.<br>&gt;&gt;<br>&gt;&gt;<br>&gt;&gt;<br>&gt;&gt;<br>&gt;&gt; _______________________________________________<br>&gt;&gt;<br>&gt;&gt; mapserver-users mailing list<br>
&gt;&gt;<br>&gt;&gt; <a href="mailto:mapserver-users@lists.osgeo.org" target="_blank">mapserver-users@lists.osgeo.org</a><br>&gt;&gt;<br>&gt;&gt; <a href="http://lists.osgeo.org/mailman/listinfo/mapserver-users" target="_blank">http://lists.osgeo.org/mailman/listinfo/mapserver-users</a><br>
&gt;&gt;<br>&gt;&gt;<br>&gt;&gt;<br>&gt;&gt; _______________________________________________<br>&gt;&gt; mapserver-users mailing list<br>&gt;&gt; <a href="mailto:mapserver-users@lists.osgeo.org" target="_blank">mapserver-users@lists.osgeo.org</a><br>
&gt;&gt; <a href="http://lists.osgeo.org/mailman/listinfo/mapserver-users" target="_blank">http://lists.osgeo.org/mailman/listinfo/mapserver-users</a><br>&gt;&gt;<br>&gt;<br>&gt;<br>&gt; _______________________________________________<br>
&gt; mapserver-users mailing list<br>&gt; <a href="mailto:mapserver-users@lists.osgeo.org" target="_blank">mapserver-users@lists.osgeo.org</a><br>&gt; <a href="http://lists.osgeo.org/mailman/listinfo/mapserver-users" target="_blank">http://lists.osgeo.org/mailman/listinfo/mapserver-users</a><br>
&gt;<br>&gt;<br></div></div></blockquote></div><br></div></div></blockquote></div><br>