[prev in list] [next in list] [prev in thread] [next in thread] 

List:       mapserver-users
Subject:    Re: [mapserver-users] using MINSIZE and MAXSIZE with ANCHORPOINT
From:       Richard Greenwood <richard.greenwood () gmail ! com>
Date:       2016-10-09 14:39:41
Message-ID: CAHBySPYOqNKto1SAypaepo9=k=0EVFGKKAbYRH30cfCX_mwACQ () mail ! gmail ! com
[Download RAW message or body]

[Attachment #2 (multipart/alternative)]


Hello Havard,

Thank you so much for taking the time to create such a great example. It
helped me find my problem. I was missing SIZE. When I specified MINSIZE and
MAXSIZE I had left out SIZE.

I would not have found my mistake without your help, so thank you very much.

Best regards,
Rich


On Thu, Oct 6, 2016 at 6:08 AM, Havard Tveite <havard.tveite@nmbu.no> wrote:

> Hi,
>
> I can't see any mistakes.
>
> I tried to test this on with 6.4.2 and 7.0.1 (sorry I have not
> installed 7.0.2 yet), and am not able to reproduce the behaviour
> that you describe.  ANCHORPOINT seems to work as expected.
> Which Mapserver version are you using?
>
> I have run it using shp2img -m
>
> I attach the resulting images (the last number in the file name
> reflects the symbolscaledenominator that has been used).
>
> Here is my complete mapfile:
>
> MAP
>   SIZE 100 100
>   EXTENT 0 0 100 100
>   SYMBOL
>     NAME "arrowv"
>     TYPE vector
>     ANCHORPOINT 0.5 1
>     POINTS
>       0 2
>       1 0
>       2 2
>       -99 -99
>       1 0
>       1 3
>     END
>   END
>   SYMBOL
>     NAME "circle"
>     TYPE ellipse
>     POINTS
>       1 1
>     END
>     FILLED TRUE
>   END
>   LAYER
>     NAME "arrows"
>     TYPE POINT
>     STATUS DEFAULT
>     PROCESSING "Items=angle"
>     #SYMBOLSCALEDENOM 20000
>     #SYMBOLSCALEDENOM 10000
>     SYMBOLSCALEDENOM 4000
>     FEATURE
>       POINTS
>         50 20
>       END # Points
>       ITEMS "90"
>     END # Feature
>     FEATURE
>       POINTS
>         10 90
>       END # Points
>       ITEMS "-135"
>     END # Feature
>     CLASS
>       NAME "vector"
>       STYLE
>         SYMBOL "arrowv"
>         MINSIZE 5
>         SIZE 10
>         MAXSIZE 40
>         MINWIDTH 1
>         MAXWIDTH 1
>         COLOR 0 0 255
>         ANGLE [angle]
>       END # STYLE
>       STYLE
>         SYMBOL "circle"
>         COLOR 255 0 0
>         MINSIZE 3
>         SIZE 3
>         MAXSIZE 3
>       END # STYLE
>     END #class
>   END #layer
> END # Map file
>
>
> On 23. sep. 2016 19:20, Richard Greenwood wrote:
>
>> It seems like my symbol's ANCHORPOINT is not being scaled when my style
>> definition uses MINSIZE, MAXSIZE and MAXSCALEDENOM.
>>
>> Here's my symbol definition:
>>
>> SYMBOL
>>   NAME "arrowv"
>>   TYPE vector
>>   ANCHORPOINT 0.5 1
>>   POINTS
>>     0 2
>>     1 0
>>     2 2
>>     -99 -99
>>     1 0
>>     1 3
>>   END
>> END
>>
>> and my style definition:
>>
>>     STYLE
>>       SYMBOL "arrowv"
>>       SIZE 40
>>       COLOR 0 0 255
>>       ANGLE [angle]
>>     END
>>
>> Which produces what I want:
>>
>> (​The red dot is the map x, y insertion point)
>> but when I add SYMBOLSCALEDENOM and change my symbol definition to:
>>
>>     STYLE
>>       SYMBOL "arrowv"
>>       MINSIZE 15
>>       MAXSIZE 40
>>       COLOR 0 0 255
>>       MINWIDTH 1
>>       MAXWIDTH 1
>>       ANGLE [angle]
>>     END
>>
>> I get:
>>
>> The ANCHORPOINT is not scaled along with the symbol. A little hard to
>> see in these two, but the ANCHORPOINT is being used, just not scaled:
>>
>> ANCHORPOINT 0 0
>>
>> ANCHORPOINT 1 1
>>
>> ​
>> ​Am I doing something wrong?
>>
>> Thanks,
>> Rich
>>
>> --
>> Richard W. Greenwood, PLS
>> www.greenwoodmap.com <http://www.greenwoodmap.com>
>>
>>
>> _______________________________________________
>> mapserver-users mailing list
>> mapserver-users@lists.osgeo.org
>> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>>
>>
> --
> Håvard Tveite
> Department of Mathematical Sciences and Technology, NMBU
> Drøbakveien 31, POBox 5003, N-1432 Ås, NORWAY
> Phone: +47 67231548 Fax: +47 64965401 http://www.nmbu.no/imt/
>
> _______________________________________________
> mapserver-users mailing list
> mapserver-users@lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>



-- 
Richard W. Greenwood, PLS
www.greenwoodmap.com

[Attachment #5 (text/html)]

<div dir="ltr"><div><div><div><div>Hello Havard,<br><br></div>Thank you so much for \
taking the time to create such a great example. It helped me find my problem. I was \
missing SIZE. When I specified MINSIZE and MAXSIZE I had left out SIZE. \
<br><br></div>I would not have found my mistake without your help, so thank you very \
much.<br><br></div>Best regards,<br></div>Rich<br><br></div><div \
class="gmail_extra"><br><div class="gmail_quote">On Thu, Oct 6, 2016 at 6:08 AM, \
Havard Tveite <span dir="ltr">&lt;<a href="mailto:havard.tveite@nmbu.no" \
target="_blank">havard.tveite@nmbu.no</a>&gt;</span> wrote:<br><blockquote \
class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc \
solid;padding-left:1ex">Hi,<br> <br>
I can&#39;t see any mistakes.<br>
<br>
I tried to test this on with 6.4.2 and 7.0.1 (sorry I have not<br>
installed 7.0.2 yet), and am not able to reproduce the behaviour<br>
that you describe.   ANCHORPOINT seems to work as expected.<br>
Which Mapserver version are you using?<br>
<br>
I have run it using shp2img -m<br>
<br>
I attach the resulting images (the last number in the file name<br>
reflects the symbolscaledenominator that has been used).<br>
<br>
Here is my complete mapfile:<br>
<br>
MAP<br>
   SIZE 100 100<br>
   EXTENT 0 0 100 100<span class=""><br>
   SYMBOL<br>
      NAME &quot;arrowv&quot;<br>
      TYPE vector<br>
      ANCHORPOINT 0.5 1<br>
      POINTS<br>
         0 2<br>
         1 0<br>
         2 2<br>
         -99 -99<br>
         1 0<br>
         1 3<br>
      END<br>
   END<br></span>
   SYMBOL<br>
      NAME &quot;circle&quot;<br>
      TYPE ellipse<br>
      POINTS<br>
         1 1<br>
      END<br>
      FILLED TRUE<br>
   END<br>
   LAYER<br>
      NAME &quot;arrows&quot;<br>
      TYPE POINT<br>
      STATUS DEFAULT<br>
      PROCESSING &quot;Items=angle&quot;<br>
      #SYMBOLSCALEDENOM 20000<br>
      #SYMBOLSCALEDENOM 10000<br>
      SYMBOLSCALEDENOM 4000<br>
      FEATURE<br>
         POINTS<br>
            50 20<br>
         END # Points<br>
         ITEMS &quot;90&quot;<br>
      END # Feature<br>
      FEATURE<br>
         POINTS<br>
            10 90<br>
         END # Points<br>
         ITEMS &quot;-135&quot;<br>
      END # Feature<br>
      CLASS<br>
         NAME &quot;vector&quot;<br>
         STYLE<br>
            SYMBOL &quot;arrowv&quot;<br>
            MINSIZE 5<br>
            SIZE 10<br>
            MAXSIZE 40<br>
            MINWIDTH 1<br>
            MAXWIDTH 1<span class=""><br>
            COLOR 0 0 255<br>
            ANGLE [angle]<br></span>
         END # STYLE<br>
         STYLE<br>
            SYMBOL &quot;circle&quot;<br>
            COLOR 255 0 0<br>
            MINSIZE 3<br>
            SIZE 3<br>
            MAXSIZE 3<br>
         END # STYLE<br>
      END #class<br>
   END #layer<br>
END # Map file<div><div class="h5"><br>
<br>
On 23. sep. 2016 19:20, Richard Greenwood wrote:<br>
</div></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px \
#ccc solid;padding-left:1ex"><div><div class="h5"> It seems like my symbol&#39;s \
ANCHORPOINT is not being scaled when my style<br> definition uses MINSIZE, MAXSIZE \
and MAXSCALEDENOM.<br> <br>
Here&#39;s my symbol definition:<br>
<br>
SYMBOL<br>
   NAME &quot;arrowv&quot;<br>
   TYPE vector<br>
   ANCHORPOINT 0.5 1<br>
   POINTS<br>
      0 2<br>
      1 0<br>
      2 2<br>
      -99 -99<br>
      1 0<br>
      1 3<br>
   END<br>
END<br>
<br>
and my style definition:<br>
<br>
      STYLE<br>
         SYMBOL &quot;arrowv&quot;<br>
         SIZE 40<br>
         COLOR 0 0 255<br>
         ANGLE [angle]<br>
      END<br>
<br>
Which produces what I want:<br>
<br></div></div><span class="">
(​The red dot is the map x, y insertion point)<br>
but when I add SYMBOLSCALEDENOM and change my symbol definition to:<br>
<br>
      STYLE<br>
         SYMBOL &quot;arrowv&quot;<br>
         MINSIZE 15<br>
         MAXSIZE 40<br>
         COLOR 0 0 255<br>
         MINWIDTH 1<br>
         MAXWIDTH 1<br>
         ANGLE [angle]<br>
      END<br>
<br>
I get:<br>
<br></span><span class="">
The ANCHORPOINT is not scaled along with the symbol. A little hard to<br>
see in these two, but the ANCHORPOINT is being used, just not scaled:<br>
<br>
ANCHORPOINT 0 0<br>
<br></span>
ANCHORPOINT 1 1<span class=""><br>
<br>
​<br>
​Am I doing something wrong?<br>
<br>
Thanks,<br>
Rich<br>
<br>
--<br>
Richard W. Greenwood, PLS<br>
</span><a href="http://www.greenwoodmap.com" rel="noreferrer" \
target="_blank">www.greenwoodmap.com</a> &lt;<a href="http://www.greenwoodmap.com" \
rel="noreferrer" target="_blank">http://www.greenwoodmap.com</a>&gt;<br> <br>
<br>
______________________________<wbr>_________________<br>
mapserver-users mailing list<br>
<a href="mailto:mapserver-users@lists.osgeo.org" \
target="_blank">mapserver-users@lists.osgeo.or<wbr>g</a><br> <a \
href="http://lists.osgeo.org/mailman/listinfo/mapserver-users" rel="noreferrer" \
target="_blank">http://lists.osgeo.org/mailman<wbr>/listinfo/mapserver-users</a><br> \
<br><span class="HOEnZb"><font color="#888888"> </font></span></blockquote><span \
class="HOEnZb"><font color="#888888"> <br>
-- <br>
Håvard Tveite<br>
Department of Mathematical Sciences and Technology, NMBU<br>
Drøbakveien 31, POBox 5003, N-1432 Ås, NORWAY<br>
Phone: <a href="tel:%2B47%2067231548" value="+4767231548" target="_blank">+47 \
67231548</a> Fax: <a href="tel:%2B47%2064965401" value="+4764965401" \
target="_blank">+47 64965401</a> <a href="http://www.nmbu.no/imt/" rel="noreferrer" \
target="_blank">http://www.nmbu.no/imt/</a><br> \
</font></span><br>______________________________<wbr>_________________<br> \
mapserver-users mailing list<br> <a \
href="mailto:mapserver-users@lists.osgeo.org">mapserver-users@lists.osgeo.<wbr>org</a><br>
 <a href="http://lists.osgeo.org/mailman/listinfo/mapserver-users" rel="noreferrer" \
target="_blank">http://lists.osgeo.org/<wbr>mailman/listinfo/mapserver-<wbr>users</a><br></blockquote></div><br><br \
clear="all"><br>-- <br><div class="gmail_signature" \
data-smartmail="gmail_signature"><div dir="ltr">Richard W. Greenwood, PLS<br><a \
href="http://www.greenwoodmap.com" \
target="_blank">www.greenwoodmap.com</a></div></div> </div>


[Attachment #6 (text/plain)]

_______________________________________________
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users

[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic