<html><head></head><body><div style="color:#000; background-color:#fff; font-family:HelveticaNeue, Helvetica Neue, Helvetica, Arial, Lucida Grande, sans-serif;font-size:14px"><div id="yiv4277990529"><div id="yui_3_16_0_ym19_1_1485187184173_7034"><div style="color:#000;background-color:#fff;font-family:HelveticaNeue, Helvetica Neue, Helvetica, Arial, Lucida Grande, sans-serif;font-size:14px;" id="yui_3_16_0_ym19_1_1485187184173_7033" dir="ltr">You are probably referring to the MAP level UNITS object.... Yes, I've already set that in meters. I've also set the</div><div style="color:#000;background-color:#fff;font-family:HelveticaNeue, Helvetica Neue, Helvetica, Arial, Lucida Grande, sans-serif;font-size:14px;" id="yui_3_16_0_ym19_1_1485187184173_7033" dir="ltr">   PROJECTION</div><div style="color:#000;background-color:#fff;font-family:HelveticaNeue, Helvetica Neue, Helvetica, Arial, Lucida Grande, sans-serif;font-size:14px;" id="yui_3_16_0_ym19_1_1485187184173_7033" dir="ltr">         "init:epsg=2100"</div><div style="color:#000;background-color:#fff;font-family:HelveticaNeue, Helvetica Neue, Helvetica, Arial, Lucida Grande, sans-serif;font-size:14px;" id="yui_3_16_0_ym19_1_1485187184173_7033" dir="ltr">  END</div><div style="color:#000;background-color:#fff;font-family:HelveticaNeue, Helvetica Neue, Helvetica, Arial, Lucida Grande, sans-serif;font-size:14px;" id="yui_3_16_0_ym19_1_1485187184173_7033" dir="ltr">in both the MAP level and the LAYER level. My extent is in meters too, obtained from the ogrinfo -al -so command. </div><div style="color:#000;background-color:#fff;font-family:HelveticaNeue, Helvetica Neue, Helvetica, Arial, Lucida Grande, sans-serif;font-size:14px;" id="yui_3_16_0_ym19_1_1485187184173_7033" dir="ltr"><br></div><div style="color:#000;background-color:#fff;font-family:HelveticaNeue, Helvetica Neue, Helvetica, Arial, Lucida Grande, sans-serif;font-size:14px;" id="yui_3_16_0_ym19_1_1485187184173_7033" dir="ltr">but still..... the same effect......<div class="yiv4277990529qtdSeparateBR" id="yui_3_16_0_ym19_1_1485187184173_7055"><br clear="none"></div><div class="yiv4277990529yqt9903525982" id="yiv4277990529yqt22836"></div></div></div></div><div class=".yiv4277990529yahoo_quoted"> <div style="font-family:HelveticaNeue, Helvetica Neue, Helvetica, Arial, Lucida Grande, sans-serif;font-size:14px;"> <div style="font-family:HelveticaNeue, Helvetica Neue, Helvetica, Arial, Lucida Grande, sans-serif;font-size:16px;"> <div dir="ltr"><font size="2" face="Arial"> Στις 5:11 π.μ. Δευτέρα, 23 Ιανουαρίου 2017, ο/η Stephen Woodbridge <woodbri@swoodbridge.com> έγραψε:<br clear="none"></font></div>  <br clear="none"><br clear="none"> <div class="yiv4277990529y_msg_container">On 1/22/2017 6:33 PM, Stefanos Anastasiou wrote:<br clear="none">> Thank you for the replies.<br clear="none">><br clear="none">>      This means that regardless of the layer's CLASS hierachy, the<br clear="none">> attributes will be rendered according to the sorting rule, which is<br clear="none">> predefined in your data. If the data are not sorted in advance, the<br clear="none">> rendering will never be right. Correct?<br clear="none">> If this is the case, then  +1 for the sortshp. It worked out well in my<br clear="none">> mapfile and roads are rendered properly.<br clear="none">>     However it appears that in PostGIS data,  the sorting happens in the<br clear="none">> DATA section of the mapfile, and the data need not  be pre-sorted. It<br clear="none">> works this way here, at least with the following rule:<br clear="none">>               DATA 'geom from (SELECT * FROM roads ORDER BY category<br clear="none">> desc) AS foo using unique id using srid=2100'<br clear="none">>    On the other hand, I didn't quite catch the z-index part in Simon's<br clear="none">> tutorial. I don't have have z values...<br clear="none"><br clear="none">Yes this all correct.<br clear="none"><br clear="none">> I'm also curious for one more thing.  As more as I zoom in on my map,<br clear="none">> the roads are getting smaller instead of getting bigger. Imagine a<br clear="none">> highway looking pretty wide and as you zoom in the width is reducing.<br clear="none">> I've only set color and width in STYLE object of my mapfile.   Am I<br clear="none">> missing any configuration ?<br clear="none"><br clear="none">By default units are in pixels, so a road 12 pixels width is 12 pixels <br clear="none">wide regardless of zoom level. Set UNITS meter and now you road width <br clear="none">will be in ground units and get width on the map as you zoom in. Youcan <br clear="none">also use MINSIZE and MAXSIZE to limit the width of the roads to some <br clear="none">number of pixels.<br clear="none"><br clear="none">-Steve<br clear="none"><br clear="none">> This blog entry from Simon Mercier describes how this works.<br clear="none">><br clear="none">> <a rel="nofollow" shape="rect" target="_blank" href="http://www.mapgears.com/en/blog/archive/2013-03-05-roads_network_mapping">http://www.mapgears.com/en/blog/archive/2013-03-05-roads_network_mapping</a><br clear="none">><br clear="none">> Lars S.<br clear="none">><br clear="none">> -----Originalmeddelande-----<br clear="none">>> Från: "Stephen Woodbridge" <<a rel="nofollow" shape="rect" ymailto="mailto:woodbri@swoodbridge.com" target="_blank" href="mailto:woodbri@swoodbridge.com">woodbri@swoodbridge.com</a><br clear="none">> <mailto:<a rel="nofollow" shape="rect" ymailto="mailto:woodbri@swoodbridge.com" target="_blank" href="mailto:woodbri@swoodbridge.com">woodbri@swoodbridge.com</a>>><br clear="none">>> Till: <a rel="nofollow" shape="rect" ymailto="mailto:mapserver-users@lists.osgeo.org" target="_blank" href="mailto:mapserver-users@lists.osgeo.org">mapserver-users@lists.osgeo.org</a><br clear="none">> <mailto:<a rel="nofollow" shape="rect" ymailto="mailto:mapserver-users@lists.osgeo.org" target="_blank" href="mailto:mapserver-users@lists.osgeo.org">mapserver-users@lists.osgeo.org</a>><br clear="none">>> Datum: 2017-01-22 05:35<br clear="none">>> Ämne: Re: [mapserver-users] Mapfile CLASS hierarchy<br clear="none">>><br clear="none">>> Oh, and I forgot to mention that if you want objects rendered in a<br clear="none">>> particular order, then your should sort the data in the sources in that<br clear="none">>> order. You can do this with order by clause on SQL based data sources<br clear="none">>> and using shpsort for shapefiles, ogr2ogr and also sort data.<br clear="none">>><br clear="none">>> On 1/21/2017 10:03 PM, Stephen Woodbridge wrote:<br clear="none">>> > Within a layer objects are always drawn in the order they are delivered<br clear="none">>> > from the datasource. Think of the CLASSes are an IF-ELSEIF-BLOCK, when<br clear="none">>> > an object is presented each CLASS is tested and the first one the<br clear="none">>> > accepts the object renders it.<br clear="none">>> ><br clear="none">>> > I often up a default class at then end that has no expression ans render<br clear="none">>> > it in red just so I can see if I missed any cases, but remove it when<br clear="none">>> > I'm done developing the mapfile.<br clear="none">>> ><br clear="none">>> > -Steve W<br clear="none">>> ><br clear="none">>> > On 1/21/2017 8:48 PM, Stefanos Anastasiou wrote:<br clear="none">>> >> Hi list,<br clear="none">>> >>    according to the documentation, the first layer in the mapfile is<br clear="none">>> >> drawn first, and the second is drawn on top of that and so on... I was<br clear="none">>> >> wondering if the same principle applies to the CLASS object as<br clear="none">> well. For<br clear="none">>> >> example: I have a "Roads" layer stored in PostGIS with a "Category"<br clear="none">>> >> column representing the different types of roads. So a category 3 is<br clear="none">>> >> very small roads, category 2 is city roads, 1 is major roads and 0 is<br clear="none">>> >> highways and on the same layers I create four CLASS objects with<br clear="none">>> >> different styles for each Road category. But regardless the order<br clear="none">> of the<br clear="none">>> >> classes (either I draw the small roads first or the highways) the same<br clear="none">>> >> effect insists: the small roads are drawn over the highways.    So what<br clear="none">>> >> is the solution here? Create different layers of the same dataset<br clear="none">>> >> representing the various values of the "Category" column ??<br clear="none">>> >><br clear="none">>> >><br clear="none">>> >> Regards,<br clear="none">>> >> -Stefanos<br clear="none">>> >><br clear="none">>> >><br clear="none">>> >> _______________________________________________<br clear="none">>> >> mapserver-users mailing list<br clear="none">>> >> <a rel="nofollow" shape="rect" ymailto="mailto:mapserver-users@lists.osgeo.org" target="_blank" href="mailto:mapserver-users@lists.osgeo.org">mapserver-users@lists.osgeo.org</a><br clear="none">> <mailto:<a rel="nofollow" shape="rect" ymailto="mailto:mapserver-users@lists.osgeo.org" target="_blank" href="mailto:mapserver-users@lists.osgeo.org">mapserver-users@lists.osgeo.org</a>><br clear="none">>> >> <a rel="nofollow" shape="rect" target="_blank" href="https://lists.osgeo.org/mailman/listinfo/mapserver-users">https://lists.osgeo.org/mailman/listinfo/mapserver-users</a><br clear="none">>> >><br clear="none">>> ><br clear="none">>> ><br clear="none">>> > ---<br clear="none">>> > This email has been checked for viruses by Avast antivirus software.<br clear="none">>> > <a rel="nofollow" shape="rect" target="_blank" href="https://www.avast.com/antivirus">https://www.avast.com/antivirus</a><br clear="none">>> ><br clear="none">>> > _______________________________________________<br clear="none">>> > mapserver-users mailing list<br clear="none">>> > <a rel="nofollow" shape="rect" ymailto="mailto:mapserver-users@lists.osgeo.org" target="_blank" href="mailto:mapserver-users@lists.osgeo.org">mapserver-users@lists.osgeo.org</a> <mailto:<a rel="nofollow" shape="rect" ymailto="mailto:mapserver-users@lists.osgeo.org" target="_blank" href="mailto:mapserver-users@lists.osgeo.org">mapserver-users@lists.osgeo.org</a>><br clear="none">>> > <a rel="nofollow" shape="rect" target="_blank" href="https://lists.osgeo.org/mailman/listinfo/mapserver-users">https://lists.osgeo.org/mailman/listinfo/mapserver-users</a><br clear="none">>><br clear="none">>><br clear="none">>> ---<br clear="none">>> This email has been checked for viruses by Avast antivirus software.<br clear="none">>> <a rel="nofollow" shape="rect" target="_blank" href="https://www.avast.com/antivirus">https://www.avast.com/antivirus</a><br clear="none">>><br clear="none">>> _______________________________________________<br clear="none">>> mapserver-users mailing list<br clear="none">>> <a rel="nofollow" shape="rect" ymailto="mailto:mapserver-users@lists.osgeo.org" target="_blank" href="mailto:mapserver-users@lists.osgeo.org">mapserver-users@lists.osgeo.org</a> <mailto:<a rel="nofollow" shape="rect" ymailto="mailto:mapserver-users@lists.osgeo.org" target="_blank" href="mailto:mapserver-users@lists.osgeo.org">mapserver-users@lists.osgeo.org</a>><br clear="none">>> <a rel="nofollow" shape="rect" target="_blank" href="https://lists.osgeo.org/mailman/listinfo/mapserver-users">https://lists.osgeo.org/mailman/listinfo/mapserver-users</a><br clear="none">><br clear="none">><br clear="none">> --<br clear="none">><br clear="none">> _______________________________________________<br clear="none">> mapserver-users mailing list<br clear="none">> <a rel="nofollow" shape="rect" ymailto="mailto:mapserver-users@lists.osgeo.org" target="_blank" href="mailto:mapserver-users@lists.osgeo.org">mapserver-users@lists.osgeo.org</a> <mailto:<a rel="nofollow" shape="rect" ymailto="mailto:mapserver-users@lists.osgeo.org" target="_blank" href="mailto:mapserver-users@lists.osgeo.org">mapserver-users@lists.osgeo.org</a>><br clear="none">> <a rel="nofollow" shape="rect" target="_blank" href="https://lists.osgeo.org/mailman/listinfo/mapserver-users">https://lists.osgeo.org/mailman/listinfo/mapserver-users</a><br clear="none">><br clear="none">> Στις 12:25 μ.μ. Κυριακή, 22 Ιανουαρίου 2017, ο/η<br clear="none">> "<a rel="nofollow" shape="rect" ymailto="mailto:lars.schylberg@blixtmail.se" target="_blank" href="mailto:lars.schylberg@blixtmail.se">lars.schylberg@blixtmail.se</a>" <<a rel="nofollow" shape="rect" ymailto="mailto:lars.schylberg@blixtmail.se" target="_blank" href="mailto:lars.schylberg@blixtmail.se">lars.schylberg@blixtmail.se</a>> έγραψε:<div class="yiv4277990529yqt9200030455" id="yiv4277990529yqtfd79072"><br clear="none">><br clear="none">><br clear="none">><br clear="none">><br clear="none">> _______________________________________________<br clear="none">> mapserver-users mailing list<br clear="none">> <a rel="nofollow" shape="rect" ymailto="mailto:mapserver-users@lists.osgeo.org" target="_blank" href="mailto:mapserver-users@lists.osgeo.org">mapserver-users@lists.osgeo.org</a><br clear="none">> <a rel="nofollow" shape="rect" target="_blank" href="https://lists.osgeo.org/mailman/listinfo/mapserver-users">https://lists.osgeo.org/mailman/listinfo/mapserver-users</a><br clear="none">><br clear="none"><br clear="none"><br clear="none">---<br clear="none">This email has been checked for viruses by Avast antivirus software.<br clear="none"><a rel="nofollow" shape="rect" target="_blank" href="https://www.avast.com/antivirus">https://www.avast.com/antivirus</a><br clear="none"><br clear="none">_______________________________________________<br clear="none">mapserver-users mailing list<br clear="none"><a rel="nofollow" shape="rect" ymailto="mailto:mapserver-users@lists.osgeo.org" target="_blank" href="mailto:mapserver-users@lists.osgeo.org">mapserver-users@lists.osgeo.org</a><br clear="none"><a rel="nofollow" shape="rect" target="_blank" href="https://lists.osgeo.org/mailman/listinfo/mapserver-users">https://lists.osgeo.org/mailman/listinfo/mapserver-users</a></div><br clear="none"><br clear="none"></div>  </div> </div>  </div></div></body></html>