Re: [mapserver-users] Arrowhead in Mapserver 6.0

2011-05-06 Thread thomas bonfort
vector symbols are ill-defined by nature in mapserver, especially if
you are using negative values and single points like you are.

more precisely, you should *never* use
-99 -99
x y
-99 -99
as in that case you are drawing a line with a single point which will
be rightfully discarded by cairo and agg, whereas gd will render a
single pixel.

A vector symbol that should work should be

POINTS
0 0
1 0.5
0 1
END

But I would strongly recommend that you use a truetype symbol for arrowheads:

SYMBOL
  TYPE TRUETYPE
  FONT sans
  CHARACTER '>'
  NAME "to"
END

SYMBOL
  TYPE TRUETYPE
  FONT sans
  CHARACTER '<'
  NAME "from"
END

regards,
thomas

On Fri, May 6, 2011 at 06:59, Makoto Niwa  wrote:
> Hi,list
>
> I tried new MapServer 6.0(rc2).
>
> I got diffrent images GD/PNG and CAIRO renderes for arrowhead symbols.
>
> Attached images are
> ms6_gd.gif : render by GD/GIF
> ms6_aggpng8.png : render by AGG/PNG
>
> CAIRO renderer image is as same as AGG.
> CARIO/AGG renderer has incorrect ofsset for arrowhead symbols.
> I used vcetor type symbols for arrowhead symbols.
>
> But I got same results both AGG and GD in MapSever 5.6
>
> Is this behavior correct in MapServer 6 ?
>
> regards,
>
> makoto.
>
> ---
> Symbol definition:
>  SYMBOL
>    NAME "from"
>    TYPE vector
>    POINTS
>      0 10
>      -20 0
>      0 -10
>      -99 -99
>      -40 10
>      -99 -99
>      -40 -10
>    END
>  END
>
>  SYMBOL
>    NAME "to"
>    TYPE vector
>    POINTS
>      0 10
>      20 0
>      0 -10
>      -99 -99
>      40 10
>      -99 -99
>      40 -10
>    END
>  END
>
> Style in the layer:
>      STYLE
>        ANGLE AUTO
>        GEOMTRANSFORM "start"
>        SYMBOL "from"
>        COLOR 255 20 20
>        WIDTH 2
>      END
>      STYLE
>        ANGLE AUTO
>        GEOMTRANSFORM "end"
>        SYMBOL "to"
>        COLOR 20 20 255
>        WIDTH 2
>      END
>
> ---
> Makoto Niwa Orkney,Inc.
> Queen's Tower C 12F
> 2-3-5 Minatomirai, Nishi, Yokohama, Japan
> TEL.81-45-228-3320  FAX.81-45-228-3321
> E-mail n...@orkney.co.jp http://www.orkney.co.jp
>
> ___
> mapserver-users mailing list
> mapserver-users@lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>
>
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] Rendering Challenges

2011-05-10 Thread thomas bonfort
Brent,

those are interesting questions

On Mon, May 9, 2011 at 21:51, Brent Fraser  wrote:
>  While testing v6, I can up with the following list of things I couldn't do
> (see http://i56.tinypic.com/8vvprn.png for a graphic):
>
> 1. Render lines inside polygon boundary (with or without opacity)
Along with Steve's buffer proposition, you can already more or less do
that with OFFSET , except you don't have the notion of inside/outside,
but left/right. If all your polygons are digitized in the same
direction (i.e. clockwise or anticlockwise) this can be done with:

STYLE
  #FILL
END
STYLE
   OUTLINECOLOR r g b
   OFFSET 1.5 -99
   WIDTH 3
   OPACITY 50
END



> 2. Place polygon annotation on/inside boundary line
> (http://trac.osgeo.org/mapserver/ticket/1592 point 8.)
not possible in a single step, but by using the polygon layer a second
time in a TYPE LINE layer for labelling should get you close.

> 3. Rotate anno if required to fit inside a polygon
would be a nice addition, ANGLE AUTO for polygon labels. We should
probably give some way to define if the label should always follow the
longest polygon diagonal, or if it should be first placed horizontally
and fall back to automatic angling only if the horizontal one does not
fit.

> 4. Place polygon annotation outside polygon if anno doesn't fit inside
The fine tuning on how to place the label text compared to the feature
would require new mapfile keywords, but that would seem possible to
implement. I'm not sure these kind of automatic adjustments would
really enhance the rendered quality though.

> 5. Place line anno above (or below) when using ANGLE FOLLOW
This is something I would like to add to. There's a paper detailing
the underlying algorithm here:
http://citeseerx.ist.psu.edu/viewdoc/summary?doi=10.1.1.24.6970

> 6. Rotate vector symbols to follow lines (a font might work but is a pain to
> create)
how is this different than what we already have with a negative GAP?
On a side note, vector symbols are currently rather ill-defined in
mapserver and would need to be tightened up before being able to use
them for precise symbol placement like here.

> 7. User specified character spacing
SIZE AUTO for labels in polygon layers would be a nice addition. We'd
have to be able to define how the size of the font varies in
accordance with the spacing that is applied between characters.
Before going down that road, we shall have to implement the
refactoring proposed in http://trac.osgeo.org/mapserver/ticket/3611 so
as not to clutter the glyph rendering functions of each renderer.


> 8. Erase lines (but not other objects) under annotation
This seems rather involved. It would be difficult to keep the ordering
of layers, as the modified feature could only be drawn during the
labelcache phase, i.e. after all other features in the map.

>
>  My goal was to use the published shp files
> (http://ftp2.cits.rncan.gc.ca/pub/canvec/50k_shp/092/h/canvec_092h06_shp.zip)
> without modification and see how close I could get to the published PDF
> (http://ftp2.cits.rncan.gc.ca/pub/cantopo/50k_geopdf/092/h/cantopo_092h06_geopdf.zip).
>
>  Any suggested rendering techniques are appreciated.  I'll file tickets for
> those problems deemed worthy.

So, most of these enhancements seem possible, some were already on my
laundry-list of rendering enhancements I'd like to tackle. Creating
enhancement tickets for those features is a first step, and funding
them is the second ;)

regards,

thomas

>
> --
> Best Regards,
> Brent Fraser
>
>
> ___
> mapserver-users mailing list
> mapserver-users@lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] Rendering Challenges

2011-05-10 Thread thomas bonfort
Yes, offset is intended for lines, using it on polygons is abusing it.
the buffer+difference method is probably the way to go.

note to myself and steve: the OFFSET keyword should be moved into a
GEOMTRANSFORM instead of residing in a keyword of its own.

--
thomas

On Tue, May 10, 2011 at 16:21, Brent Fraser  wrote:
> Thomas,
>
>  Interesting. I suspect all the polygons are digitized the same was as I
> think this is a requirement for shapefiles.  The result of using:
>
>      STYLE
>        OUTLINECOLOR 255 211 127
>        OFFSET 1.5 -99
>        WIDTH 3
>      END
>
> results in http://i54.tinypic.com/25a22k4.jpg  Close, but notice the "bleed"
> outside the polygon at the sharp corners.
>
> Thanks!
>
> Best Regards,
> Brent Fraser
>
>
> On 5/10/2011 1:38 AM, thomas bonfort wrote:
>>
>> Brent,
>>
>> those are interesting questions
>>
>> On Mon, May 9, 2011 at 21:51, Brent Fraser
>>  wrote:
>>>
>>>  While testing v6, I can up with the following list of things I couldn't
>>> do
>>> (see http://i56.tinypic.com/8vvprn.png for a graphic):
>>>
>>> 1. Render lines inside polygon boundary (with or without opacity)
>>
>> Along with Steve's buffer proposition, you can already more or less do
>> that with OFFSET , except you don't have the notion of inside/outside,
>> but left/right. If all your polygons are digitized in the same
>> direction (i.e. clockwise or anticlockwise) this can be done with:
>>
>> STYLE
>>   #FILL
>> END
>> STYLE
>>    OUTLINECOLOR r g b
>>    OFFSET 1.5 -99
>>    WIDTH 3
>>    OPACITY 50
>> END
>>
>>
>>
>>> 2. Place polygon annotation on/inside boundary line
>>> (http://trac.osgeo.org/mapserver/ticket/1592 point 8.)
>>
>> not possible in a single step, but by using the polygon layer a second
>> time in a TYPE LINE layer for labelling should get you close.
>>
>>> 3. Rotate anno if required to fit inside a polygon
>>
>> would be a nice addition, ANGLE AUTO for polygon labels. We should
>> probably give some way to define if the label should always follow the
>> longest polygon diagonal, or if it should be first placed horizontally
>> and fall back to automatic angling only if the horizontal one does not
>> fit.
>>
>>> 4. Place polygon annotation outside polygon if anno doesn't fit inside
>>
>> The fine tuning on how to place the label text compared to the feature
>> would require new mapfile keywords, but that would seem possible to
>> implement. I'm not sure these kind of automatic adjustments would
>> really enhance the rendered quality though.
>>
>>> 5. Place line anno above (or below) when using ANGLE FOLLOW
>>
>> This is something I would like to add to. There's a paper detailing
>> the underlying algorithm here:
>> http://citeseerx.ist.psu.edu/viewdoc/summary?doi=10.1.1.24.6970
>>
>>> 6. Rotate vector symbols to follow lines (a font might work but is a pain
>>> to
>>> create)
>>
>> how is this different than what we already have with a negative GAP?
>> On a side note, vector symbols are currently rather ill-defined in
>> mapserver and would need to be tightened up before being able to use
>> them for precise symbol placement like here.
>>
>>> 7. User specified character spacing
>>
>> SIZE AUTO for labels in polygon layers would be a nice addition. We'd
>> have to be able to define how the size of the font varies in
>> accordance with the spacing that is applied between characters.
>> Before going down that road, we shall have to implement the
>> refactoring proposed in http://trac.osgeo.org/mapserver/ticket/3611 so
>> as not to clutter the glyph rendering functions of each renderer.
>>
>>
>>> 8. Erase lines (but not other objects) under annotation
>>
>> This seems rather involved. It would be difficult to keep the ordering
>> of layers, as the modified feature could only be drawn during the
>> labelcache phase, i.e. after all other features in the map.
>>
>>>  My goal was to use the published shp files
>>>
>>> (http://ftp2.cits.rncan.gc.ca/pub/canvec/50k_shp/092/h/canvec_092h06_shp.zip)
>>> without modification and see how close I could get to the published PDF
>>>
>>> (http://ftp2.cits.rncan.gc.ca/pub/cantopo/50k_geopdf/092/h/cantopo_092h06_geopdf.zip).
>>>
>>>  Any suggested rendering techniques are appreciated.  I'll file tickets
>>> for
>>> those problems deemed worthy.
>>
>> So, most of these enhancements seem possible, some were already on my
>> laundry-list of rendering enhancements I'd like to tackle. Creating
>> enhancement tickets for those features is a first step, and funding
>> them is the second ;)
>>
>> regards,
>>
>> thomas
>>
>>> --
>>> Best Regards,
>>> Brent Fraser
>>>
>>>
>>> ___
>>> mapserver-users mailing list
>>> mapserver-users@lists.osgeo.org
>>> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>>>
>
>
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] Rendering line crossing iteslf

2011-05-11 Thread thomas bonfort
An undocumented and "not guaranteed to work in future versions" is to
trick mapserver in not drawing the cached base style for bridge lines.
As you are avoiding the line caching mechanism, you have to tweak the
linecaps for the base style.

CLASS
   EXPRESSION ([bridge]=1)
   STYLE
   END
   STYLE
  color black
  width 5
  linecap butt
   END
   STYLE
  color yellow
  width 3
  linecap round
   END
   STYLE
  color black
  width 1
   END
END

I haven't tested this recently, so please keep in touch if this solves
your problem or not.

regards,
thomas

On Wed, May 11, 2011 at 11:40, Niels-Peter Jensen  wrote:
> Hi users
>
> We have a problem in rendering a route based on a line feature.
>
> When we use the common way to do that, by using two styles, with a thick
> black line that defines an outline, and a thinner defying the road center,
> we will not get the desired result.
>
> But I want to show where routes cross ("bridge" intersection), and not as a
> "normal" intersection, see the attached examples.
>
> As there is no outline definition on linefeatures I can't se how that can be
> done in a simple way.
>
>
> Niels-Peter
> I-GIS
>
> ___
> mapserver-users mailing list
> mapserver-users@lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>
>
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] Rendering line crossing iteslf

2011-05-11 Thread thomas bonfort
-- Forwarded message --
From: thomas bonfort 
Date: Wed, May 11, 2011 at 16:03
Subject: Re: SV: [mapserver-users] Rendering line crossing iteslf
To: Stephen Woodbridge 


Steve,
That isn't the case. The first style of all the features are rendered
in a first phase, and the following ones are rendered in a second
phase, so the order is

feature1->style1
feature2->style1
...
featuren->style1
feature1->style2
...
featuren->style2
...
...
feature1->stylem
featuren->stylem

without that, you'd get artifacts on road intersections.

--
thomas



On Wed, May 11, 2011 at 15:47, Stephen Woodbridge
 wrote:
> Niels-Peter,
>
> I believe that you will need to split the line at the intersection into
> multiple lines to get the display that you want. Because you line just
> crosses itself there is no intersection there. If you split the line into
> multiple segments that there will be an intersection and mapserver should
> render it is desired.
>
> -Steve W
>
> On 5/11/2011 8:18 AM, Niels-Peter Jensen wrote:
>>
>> Hi Thomas
>>
>> The bridge was used as an anology. In fact, the line feature is a bus
>> route
>> that crosses itself, and we just want to show where the route passes
>> through
>> an intersection.
>>
>> Niels-Peter
>>
>>
>> -Oprindelig meddelelse-
>> Fra: thomas bonfort [mailto:thomas.bonf...@gmail.com]
>> Sendt: 11. maj 2011 13:56
>> Til: Niels-Peter Jensen
>> Emne: Re: [mapserver-users] Rendering line crossing iteslf
>>
>>
>> On Wed, May 11, 2011 at 13:51, Niels-Peter Jensen  wrote:
>>>
>>> Hi Thomas
>>>
>>> Thanks for the quick answer.
>>>
>>> We cannot make the style work in the mapfile and have to place it in
>>> the symbol file. By the way, we are using Mapserver 5.4.2.
>>>
>>> But anyway, I don't think it solves our problem.
>>> We don't have any "bridge" in our line data, it is just a single line
>>> feature that crosses itself.
>>
>> then how can you distinguish the case of the bridge with the case of the
>> intersection ? applying the solution I proposed on all lines will give
>> incorrect cases everywhere you don't have a bridge, so it would not be a
>> possible solution.
>>
>> --
>> thomas
>>
>>>
>>> Regards
>>> Niels-Peter
>>>
>>>
>>> -Oprindelig meddelelse-
>>> Fra: thomas bonfort [mailto:thomas.bonf...@gmail.com]
>>> Sendt: 11. maj 2011 12:14
>>> Til: Niels-Peter Jensen
>>> Cc: mapserver-users@lists.osgeo.org
>>> Emne: Re: [mapserver-users] Rendering line crossing iteslf
>>>
>>>
>>> An undocumented and "not guaranteed to work in future versions" is to
>>> trick mapserver in not drawing the cached base style for bridge lines.
>>> As you are avoiding the line caching mechanism, you have to tweak the
>>> linecaps for the base style.
>>>
>>> CLASS
>>>   EXPRESSION ([bridge]=1)
>>>   STYLE
>>>   END
>>>   STYLE
>>>      color black
>>>      width 5
>>>      linecap butt
>>>   END
>>>   STYLE
>>>      color yellow
>>>      width 3
>>>      linecap round
>>>   END
>>>   STYLE
>>>      color black
>>>      width 1
>>>   END
>>> END
>>>
>>> I haven't tested this recently, so please keep in touch if this solves
>>> your problem or not.
>>>
>>> regards,
>>> thomas
>>>
>>> On Wed, May 11, 2011 at 11:40, Niels-Peter Jensen
>>> wrote:
>>>>
>>>> Hi users
>>>>
>>>> We have a problem in rendering a route based on a line feature.
>>>>
>>>> When we use the common way to do that, by using two styles, with a
>>>> thick black line that defines an outline, and a thinner defying the
>>>> road center, we will not get the desired result.
>>>>
>>>> But I want to show where routes cross ("bridge" intersection), and
>>>> not as a "normal" intersection, see the attached examples.
>>>>
>>>> As there is no outline definition on linefeatures I can't se how that
>>>> can be done in a simple way.
>>>>
>>>>
>>>> Niels-Peter
>>>> I-GIS
>>>>
>>>> ___
>>>> mapserver-users mailing list
>>>> mapserver-users@lists.osgeo.org
>>>> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>>>>
>>>>
>>>
>>>
>>
>> ___
>> mapserver-users mailing list
>> mapserver-users@lists.osgeo.org
>> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>
> ___
> mapserver-users mailing list
> mapserver-users@lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] Layer rendering performance problem

2011-05-11 Thread thomas bonfort
what mapserver version and renderer/driver are you using?

AGG should'nt be accessing the font file unless a new character is
encountered. For GD I don't know.

--
thomas

On Wed, May 11, 2011 at 18:00, Jon-Paul Dobson  wrote:
> Thanks guys. I will give this ago. Any ideas about poor performance when
> using a true type font? Why does MapServer need to load the .ttf file each
> time to draw a symbol. Surely the ttf file should be cached?
>
> Rgards,
> Jon-Paul.
>
> On Wed, May 11, 2011 at 4:54 PM, Jeff McKenna
>  wrote:
>>
>> On 11-05-11 12:47 PM, Jon-Paul Dobson wrote:
>>>
>>> Hi Jukka,
>>> Thanks for getting back to me so quickly. No I haven't tried this. How
>>> is this done and what is the benefit? Aren't Shape files already indexed?
>>> Regards,
>>> Jon-Paul.
>>
>> Jukka is right, always make sure to run the shptree commandline utility on
>> all of your ESRI shapefiles before using them in MapServer
>> (http://mapserver.org/utilities/shptree.html).  You'll see huge speed
>> differences.
>>
>> -jeff
>>
>>
>> --
>> Jeff McKenna
>> MapServer Consulting and Training Services
>> http://www.gatewaygeomatics.com/
>>
>>
>> ___
>> mapserver-users mailing list
>> mapserver-users@lists.osgeo.org
>> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>
>
> ___
> mapserver-users mailing list
> mapserver-users@lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>
>
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] opacity and outputformat

2011-05-12 Thread thomas bonfort
Opacity is set as a single integer between 0 and 100 on the layer level.
There are no limitations on setting it on multiple layers, but in that
case the opacity adds up, so if you have two layers with opacity 50,
the final opacity of the image ends up being 75.

If your final images end up with no opacity, this could be because
your are also including a layer with full opacity, or because you are
using a format which does not support an alpha channel (i.e. jpeg)

regards,
thomas

On Mon, May 9, 2011 at 19:18, Marc-André Trottier
 wrote:
> hi!
> how can i get a output with opacity on 2 or more layers.
> with only 1 layer it's working fine but not with 2 or more.
>
> How should be written OPACITY when using IMAGEMODE RGBA ? (ALPHA)
> i tried something like OPACITY 22,22,22,22 but looks bad
>
> in all my tests, all i got was my 2 layers with full opacity (100) ...
>
> here is my mapfile :
>
>  MAP
>   EXTENT -8146324.306063 5632144.09953312 -8137075.425642 5638229.88815488
>   FONTSET "fonts"
>   IMAGECOLOR 255 255 255
>   IMAGETYPE AGGA
>   SIZE 732 482
>   STATUS ON
>   UNITS METERS
>   NAME "MS"
>
>  OUTPUTFORMAT
>  NAME 'AGGA'
>  DRIVER AGG/PNG
>  IMAGEMODE RGBA
>  TRANSPARENT TRUE
> END
>
>   PROJECTION
>     "init=epsg:900913"
>   END
>   LEGEND
>     IMAGECOLOR 255 255 255
>     KEYSIZE 20 10
>     KEYSPACING 5 5
>     LABEL
>   ANGLE 0.00
>   ANTIALIAS TRUE
>   FONT "arial"
>   MAXSIZE 256
>   MINSIZE 4
>   SIZE 10
>   TYPE TRUETYPE
>   BUFFER 0
>   COLOR 255 255 255
>   FORCE FALSE
>   MINDISTANCE -1
>   MINFEATURESIZE -1
>   OFFSET 0 0
>   PARTIALS TRUE
>     END
>     OUTLINECOLOR 0 0 0
>     POSITION LR
>     POSTLABELCACHE TRUE
>     STATUS EMBED
>     TRANSPARENT FALSE
>   END
>
>   QUERYMAP
>     COLOR 255 255 0
>     SIZE -1 -1
>     STATUS OFF
>     STYLE HILITE
>   END
>
>   SCALEBAR
>     ALIGN CENTER
>     COLOR 0 0 0
>     IMAGECOLOR 255 255 255
>     INTERVALS 4
>     LABEL
>   SIZE MEDIUM
>   TYPE BITMAP
>   BUFFER 0
>   COLOR 0 0 0
>   FORCE FALSE
>   MINDISTANCE -1
>   MINFEATURESIZE -1
>   OFFSET 0 0
>   PARTIALS TRUE
>   POSITION CR
>     END
>     OUTLINECOLOR 0 0 0
>     POSITION LL
>     SIZE 200 3
>     STATUS EMBED
>     STYLE 0
>     UNITS METERS
>   END
>
>   WEB
>     IMAGEPATH "path"
>     IMAGEURL ""
>     QUERYFORMAT text/html
>     LEGENDFORMAT text/html
>     BROWSEFORMAT text/html
>   END
>
>   LAYER
>     CONNECTION "PATATE3"
>     CONNECTIONTYPE WMS
>     DEBUG 5
>     METADATA
>   "wms_srs"    "EPSG:900913"
>   "wms_name"    "PATATE3"
>   "wms_format"    "image/png"
>   "wms_server_version"    "1.1.1"
>     END
>     NAME "Carte"
>     PROCESSING "CLOSE_CONNECTION=NORMAL"
>     PROJECTION
>   "init=epsg:900913"
>     END
>     STATUS ON
>     TRANSFORM FALSE
>     TYPE RASTER
>     UNITS METERS
>   END
>
>   LAYER
>     CONNECTION "PATATE2"
>     CONNECTIONTYPE WMS
>     DEBUG 5
>     METADATA
>   "wms_srs"    "EPSG:900913"
>   "opacity"    "100"
>   "wms_name"    "PATATE2"
>   "wms_format"    "image/png"
>   "wms_server_version"    "1.1.1"
>     END
>     NAME "PATATE2"
>     PROCESSING "CLOSE_CONNECTION=NORMAL"
>     PROJECTION
>   "init=epsg:900913"
>     END
>     STATUS ON
>     TRANSFORM FALSE
>     TYPE RASTER
>     UNITS METERS
>   END
>
>   LAYER
>     CONNECTION "PATATE"
>     CONNECTIONTYPE WMS
>     DEBUG 5
>     METADATA
>   "wms_srs"    "EPSG:900913"
>   "opacity"    "40"
>   "wms_name"    "PATATE"
>   "wms_format"    "image/png"
>   "wms_server_version"    "1.1.1"
>     END
>     NAME "PATATE"
>     PROJECTION
>   "init=epsg:900913"
>     END
>     STATUS ON
>     OPACITY 40
>     TYPE RASTER
>     UNITS METERS
>   END
>
> END
>
>
> ___
> mapserver-users mailing list
> mapserver-users@lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>
>
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] Reference Map must be a GIF????

2011-05-12 Thread thomas bonfort
looking through the code, both GD and the other renderers should
support loading GIF and PNG images. (This also concerns pixmap
symbols, legend icons, etc... i.e. anything which requires loading an
image file outside of GDAL)

Can you supply the and the reference image you are using ?

regards,
thomas

On Fri, May 6, 2011 at 20:18, Worth Lutz  wrote:
> When did the restriction, “the Reference Map base image must be a .gif”,
> start being enforced?
>
>
>
> I now see it in my old printed copy (version 5.2) of the documentation.  I
> checked there to see if this was new to MapServer version 6 as I found it
> first in the online documentation.  Obviously I had never read the
> documentation closely in this area.
>
>
>
> All my reference maps are “png” drawn with Mapserver (aggpng I think) and
> work in version 5.6.
>
>
>
> When my try/catch throws an exception trying to draw this reference map, the
> exception message is an empty string.
>
>
>
> Through testing and looking at the apache logs, I find that there are
> MapServer Errors in the MapServer errorObj and PHP Notices and Warning.
> These are:
>
>
>
> [Mapserver Error] msDrawREferenceMap() : error loading reference image
> /data/mapfiles/ref_maps/…
>
> [MapServer Error] readImage(): unsupported pixmap format/n in …
>
>
>
> Is this truly a change in the image type restriction for Reference Maps or
> is it just an change in the checking for errors when the MapScriptException
> was added?
>
>
>
> Was I just lucky my “.png” reference maps worked in the past?  Am I the only
> one to try this?  I don’t have many to convert but wanted to point this out
> so it could be added to the Migration Guide if it must remain a restriction.
>
> ___
> mapserver-users mailing list
> mapserver-users@lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>
>
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] Layer rendering performance problem

2011-05-12 Thread thomas bonfort
On Thu, May 12, 2011 at 10:57, Jon-Paul Dobson  wrote:
> Hi,
>
> I just tried creating a qix file as suggested and found that the Shape file
> now renders 22 times faster! Fantastic advice guys. Many thanks.
>
> If only there was a way to prevent the TTF file being continuously accessed
> when displaying a symbol using a truetype font. Any further ideas at all? It
> kind of makes a TTF unusable.
I've just straced and ltraced the access to the font file, and
mapserver/agg/freetype does *not* continually access the font file. By
default, agg maintains a cache of the last 32 glyphs that were
accessed, so access to the font file only occurs if the the current
glyph is not in one of the last 32 to be requested.
what tool are you using indicating that the font file is accessed
multiple times?

--
thomas


>
> Best regards,
> Jon-Paul.
>
> On Thu, May 12, 2011 at 7:52 AM, Rahkonen Jukka 
> wrote:
>>
>> Hi,
>>
>> For clarification, it used to be rather a long time ago that the index
>> file (.qix) was not utilised even it was present in the data folder if the
>> LAYER DATA was given as
>> DATA "C:\Data\WMS_DATA.shp"
>>
>> Index was used only if the LAYER DATA was like
>> DATA "C:\Data\WMS_DATA"
>>
>> However, this in old knowledge and both WMS_DATA.shp and WMS_DATA are
>> utilising the index nowadays.
>>
>> Gdal is using the same .qix index file system and therefore also QGIS.
>> There is more info about gdal shapefile spatial index in
>> http://www.gdal.org/ogr/drv_shapefile.html
>> The page tells also that native ESRI spatial index files (.sbn/ .sbx)  are
>> not supported.
>>
>> -Jukka Rahkonen-
>>
>>
>>
>> 
>> Lähettäjä: mapserver-users-boun...@lists.osgeo.org
>> [mailto:mapserver-users-boun...@lists.osgeo.org] Puolesta Ben Madin
>> Lähetetty: 12. toukokuuta 2011 4:00
>> Vastaanottaja: mapserver-users@lists.osgeo.org
>> Aihe: Re: [mapserver-users] Layer rendering performance problem
>>
>> I'm not sure whether it is still the case, but it used also to be that if
>> you wanted to use the index, you need to name the shapefile without the .shp
>> extension. If you used the .shp extension it wouldn't use the .qix index.
>> So maybe this is a question - Is that still the case?
>> On a similar note, does anyone know ... is the index created with shptree
>> the same as the one created by QGIS (also a .qix file)?
>> cheers
>> Ben
>>
>>
>> On 12/05/2011, at 10:45 AM, mapserver-users-requ...@lists.osgeo.org wrote:
>>
>> From: Stephen Woodbridge 
>> Date: 11 May 2011 11:53:34 PM AWST
>> To: mapserver-users@lists.osgeo.org
>> Subject: Re: [mapserver-users] Layer rendering performance problem
>>
>>
>> look at the mapserver utilities:
>>
>> shptree myshapefile
>>
>> This creates a spatial index (*.qix) and you should create one for every
>> shapefile you are using.
>>
>> On Linux this will do the trick:
>>
>> find /path/data -name \*.shp -exec shptree {} \;
>>
>> If the .qix file is missing on every draw mapserver must create one on the
>> fly in memory and the it throws it away.
>>
>> -Steve W
>>
>> On 5/11/2011 11:47 AM, Jon-Paul Dobson wrote:
>>
>> Hi Jukka,
>>
>> Thanks for getting back to me so quickly. No I haven't tried this. How
>>
>> is this done and what is the benefit? Aren't Shape files already indexed?
>>
>> Regards,
>>
>> Jon-Paul.
>>
>> On Wed, May 11, 2011 at 4:41 PM, Rahkonen Jukka
>>
>> mailto:jukka.rahko...@mmmtike.fi>> wrote:
>>
>>    Hi,
>>
>>    No answers but a question back. Have you created spatial index
>>
>>    (.qix) for your shapefiles with shptree?
>>
>>    -Jukka Rahkonen-
>>
>>    Jon-Paul Dobson wrote:
>>
>> > Hi,
>>
>>
>>
>> > Whenever I display a layer based on a Shape file I notice that
>>
>>    the Shape
>>
>>    file is accessed constantly. This makes rendering extremely slow when
>>
>>    compared to, for example, ESRI ArcIMS which appears to cache the
>>
>>    Shape file.
>>
>>    Is there an equivalent caching mechanism for Map Server? ArcIMS seems
>> to
>>
>>    render an order of magnitude faster when the number of symbols runs
>>
>>    into the
>>
>>    1000s
>>
>>
>>
>> > Similarly, whenever I display layer symbols using a truetype font
>>
>>    I notice
>>
>>    that the .ttf file is accessed for every symbol. This makes rendering
>>
>>    appallingly slow. Is there also any caching mechanism to prevent this?
>>
>>
>>
>> > Any insight anyone can give would be much appreciated.
>>
>>
>>    Best regards,
>>
>>    Jon-Paul.
>>
>>
>>
>>
>> ___
>>
>> mapserver-users mailing list
>>
>> mapserver-users@lists.osgeo.org
>>
>> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>>
>>
>>
>> ___
>> mapserver-users mailing list
>> mapserver-users@lists.osgeo.org
>> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>>
>
>
> ___
> mapserver-users mailing list
> mapserver-users@lists.osgeo.org
> http://lists.o

Re: [mapserver-users] Problem rendering multiple layers

2011-05-13 Thread thomas bonfort
mixing the mode=map with a WMS request might be treated differently in
5.0 than 5.6. To be on the safe side, either do a mapserver style
mode=map request without the SERVICE and REQUEST params, or do some
pure wms requests without the mode=map (the second option seems to be
what you are trying to achieve)

i.e.: try
http://10.10.10.105/cgi-bin/mapserv?map=mapdata/ccc.map&LAYERS=county,water&TRANSPARENT=true&SERVICE=WMS&VERSION=1.1.1&REQUEST=GetMap&STYLES=&EXCEPTIONS=application%2Fvnd.ogc.se_inimage&FORMAT=image%2Fpng&SRS=EPSG%3A4326&BBOX=-122.41859552788569,37.48140447211431,-121.56140447211433,38.33859552788568&WIDTH=450&HEIGHT=

--
thomas

On Fri, May 13, 2011 at 19:16, Mark K. Zanfardino  wrote:
> I have created a simple map with two layers with shapefiles as the
> datasource. I have two servers I am using for testing in order to attempt to
> identify the source of a problem I am having when I attempt to render the
> two layers.
>
> Server A is running Ubuntu 9.04. It has been patched to the latest releases.
> I did *not* add the UbuntuGIS repo. I installed the package cgi-mapserver
> and mapserver-bin (along with the appropriate dependencies). MapServer
> version 5.0.3 OUTPUT=GIF OUTPUT=PNG OUTPUT=JPEG OUTPUT=WBMP OUTPUT=SVG
> SUPPORTS=PROJ SUPPORTS=AGG SUPPORTS=FREETYPE SUPPORTS=WMS_SERVER
> SUPPORTS=WMS_CLIENT SUPPORTS=WFS_SERVER SUPPORTS=WFS_CLIENT
> SUPPORTS=WCS_SERVER SUPPORTS=FASTCGI SUPPORTS=THREADS SUPPORTS=GEOS
> INPUT=EPPL7 INPUT=POSTGIS INPUT=OGR INPUT=GDAL INPUT=SHAPEFILE
>
> I then render my map from my browser (Firefox 3.6.17 and Chrome 11.0.696.65)
> with the following URL:
>
> http://10.10.10.86/cgi-bin/mapserv?mode=map&map=mapdata/ccc.map&LAYERS=county,water&TRANSPARENT=true&SERVICE=WMS&VERSION=1.1.0&REQUEST=GetMap&STYLES=&EXCEPTIONS=application%2Fvnd.ogc.se_inimage&FORMAT=image%2Fpng&SRS=EPSG%3A4326&BBOX=-122.41859552788569,37.48140447211431,-121.56140447211433,38.33859552788568&WIDTH=450&HEIGHT=450
> 
>
> The resulting image is rendered at 450x450 and displays both the county and
> water layers as expected.
>
> Server B is running Ubuntu 10.04. It has been patched to the latest
> releases. I *did* add the UbuntuGIS repo. I installed the same packages.
> MapServer version 5.6.6 OUTPUT=GIF OUTPUT=PNG OUTPUT=JPEG OUTPUT=WBMP
> OUTPUT=SWF OUTPUT=SVG SUPPORTS=PROJ SUPPORTS=AGG SUPPORTS=FREETYPE
> SUPPORTS=ICONV SUPPORTS=FRIBIDI SUPPORTS=WMS_SERVER SUPPORTS=WMS_CLIENT
> SUPPORTS=WFS_SERVER SUPPORTS=WFS_CLIENT SUPPORTS=WCS_SERVER
> SUPPORTS=SOS_SERVER SUPPORTS=FASTCGI SUPPORTS=THREADS SUPPORTS=GEOS
> SUPPORTS=RGBA_PNG INPUT=EPPL7 INPUT=POSTGIS INPUT=OGR INPUT=GDAL
> INPUT=SHAPEFILE
>
> I then render my map from the browser as before with the following URL:
>
> http://10.10.10.105/cgi-bin/mapserv?mode=map&map=mapdata/ccc.map&LAYERS=county,water&TRANSPARENT=true&SERVICE=WMS&VERSION=1.1.1&REQUEST=GetMap&STYLES=&EXCEPTIONS=application%2Fvnd.ogc.se_inimage&FORMAT=image%2Fpng&SRS=EPSG%3A4326&BBOX=-122.41859552788569,37.48140447211431,-121.56140447211433,38.33859552788568&WIDTH=450&HEIGHT=450
> 
>
> The resulting image is rendered at 740x400 and is a single white image (no
> layers rendered).
>
> If I only include one layer at a time the specified layer *does* render
> (again at 740x400 *not* 450x450 as specified in the URL). If I change the
> parameters &LAYERS to &LAYER (singular) and use two (one for county and one
> for water) the two layers render, again at the wrong resolution.
>
> I'm completely stumped. I've been using mapserver for a number of years now,
> but I hadn't upgraded to 5.6.6 as I'd been using it on my ubuntu 9.04
> server.  I'd love to take advantage of the changes available in 5.6.6 but
> right now I can't seem to get any of my maps to work. Help!
>
> I have enabled debugging for both servers. The output for Server A when
> requesting to render both county and water is:
>
> [Fri May 13 10:13:21 2011].721463 msSearchDiskTree(): Search returned no
> results. Unable to open spatial index for
> /usr/lib/cgi-bin/mapdata/./ccc_gis.county.qix. In most cases you can safely
> ignore this message, otherwise check file names and permissions.
> [Fri May 13 10:13:21 2011].723899 msDrawMap(): Layer 0 (county), 0.003s
> [Fri May 13 10:13:21 2011].724028 msSearchDiskTree(): Search returned no
> results. Unable to open spatial index for
> /

Re: [mapserver-users] compilation error about shp2img

2011-05-17 Thread thomas bonfort
what png library version are you using. if 1.5, try downgrading to 1.4

regards,
thomas

2011/5/17 ahmet temiz :
> hello
>
> when I tried to compile UMN_Mapsever (6.0), I encountered this error:
>
> -undefined reference to `png_set_longjmp_fn'-
> collect2: ld returned 1 exit status
> make: *** [shp2img] Error 1
>
> I am using ubuntu 10.1
>
> How can I solve the problem ?
>
> regards
>
>
> --
> Ahmet Temiz
> Jeoloji Müh.
> Afet ve Acil Durum Yönetimi Başkanlığı
> Planlama ve Zarar Azaltma Dairesi Başkanlığı
> Bilgi ve CBS grubu
> Eskişehir Yolu 10. km.
> Lodumlu / Ankara
> Tel : 0 312 2872680 / 1535
> 
>
> Ahmet Temiz
> Geological Eng.
> Information Systems - GIS Group
> Disaster and Emergency Management
> of Presidency
> ___
> mapserver-users mailing list
> mapserver-users@lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] Re: Is it posible to substitute a value from table for width of line

2011-06-01 Thread thomas bonfort
are you using the exact syntax of your first example, i.e. "WIDTH [gid]" ?

On Wed, Jun 1, 2011 at 10:27, prab.raja  wrote:
> But when I tried this mapserver gives error message as "getInteger(): Symbol
> definition error. Parsing error near (gid)".
> I am using MapServer version 5.2.1.
>
> On Wed, Jun 1, 2011 at 1:48 PM, Havard Tveite [via OSGeo.org] <[hidden
> email]> wrote:
>>
>> According to http://www.mapserver.org/mapfile/style.html >
>> that should be possible.
>>
>> Håvard
>>
>> On 6/1/2011 8:09 AM, prab.raja wrote:
>> > Hi,
>> > I would like to know if it's posible to draw line layer with variable
>> > width
>> > from database table.
>> >
>> > Something like this?
>> >
>> > LAYER
>> >        NAME line_layer
>> >        CONNECTIONTYPE postgis
>> >        CONNECTION "user=postgres password=** dbname=shpdb
>> > host=localhost
>> > port=5432"
>> >        DATA "the_geom FROM  (SELECT gid, the_geom FROM line_layer)
>> >           AS SUBQUERY using unique gid"
>> >        PROCESSING "CLOSE_CONNECTION=DEFER"
>> >        TYPE line
>> >        OPACITY 100
>> >        STATUS Off
>> >        CLASS
>> >           STYLE
>> >              COLOR 0 140 70
>> >              WIDTH [gid]
>> >           END
>> >        END
>> >     END
>> >
>> > --
>> > View this message in context:
>> > http://osgeo-org.1803224.n2.nabble.com/Is-it-posible-to-substitute-a-value-from-table-for-width-of-line-tp6425708p6425708.html
>> > Sent from the Mapserver - User mailing list archive at Nabble.com.
>> > ___
>> > mapserver-users mailing list
>> > [hidden email]
>> > http://lists.osgeo.org/mailman/listinfo/mapserver-users
>> >
>> --
>> Håvard Tveite
>> Department of Mathematical Sciences and Technology, UMB
>> Drøbakveien 31, POBox 5003, N-1432 Ås, NORWAY
>> Phone: +47 64965483 Fax: +47 64965401 http://www.umb.no/imt/
>> ___
>> mapserver-users mailing list
>> [hidden email]
>> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>>
>>
>> 
>> If you reply to this email, your message will be added to the discussion
>> below:
>>
>> http://osgeo-org.1803224.n2.nabble.com/Is-it-posible-to-substitute-a-value-from-table-for-width-of-line-tp6425708p6426034.html
>> To unsubscribe from Is it posible to substitute a value from table for
>> width of line, click here.
>
>
> --
> Regards,
> Prabu Raja
>
>
> 
> View this message in context: Re: Is it posible to substitute a value from
> table for width of line
> Sent from the Mapserver - User mailing list archive at Nabble.com.
>
> ___
> mapserver-users mailing list
> mapserver-users@lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>
>
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] Re: Is it posible to substitute a value from table for width of line

2011-06-01 Thread thomas bonfort
then make sure you are actually using 5.2.1 and not an older version

On Wed, Jun 1, 2011 at 10:47, prab.raja  wrote:
> yes.
> Below is the style copied from my Map file.
>         STYLE
>             COLOR 0 140 70
>             WIDTH [gid]
>          END
> On Wed, Jun 1, 2011 at 2:12 PM, thomas bonfort [via OSGeo.org] <[hidden
> email]> wrote:
>>
>> are you using the exact syntax of your first example, i.e. "WIDTH [gid]" ?
>>
>> On Wed, Jun 1, 2011 at 10:27, prab.raja <[hidden email]> wrote:
>> > But when I tried this mapserver gives error message as "getInteger():
>> > Symbol
>> > definition error. Parsing error near (gid)".
>> > I am using MapServer version 5.2.1.
>> >
>> > On Wed, Jun 1, 2011 at 1:48 PM, Havard Tveite [via OSGeo.org] <[hidden
>> > email]> wrote:
>> >>
>> >> According to > >> href="http://www.mapserver.org/mapfile/style.html ";>http://www.mapserver.org/mapfile/style.html >
>> >> that should be possible.
>> >>
>> >> Håvard
>> >>
>> >> On 6/1/2011 8:09 AM, prab.raja wrote:
>> >> > Hi,
>> >> > I would like to know if it's posible to draw line layer with variable
>> >> > width
>> >> > from database table.
>> >> >
>> >> > Something like this?
>> >> >
>> >> > LAYER
>> >> >        NAME line_layer
>> >> >        CONNECTIONTYPE postgis
>> >> >        CONNECTION "user=postgres password=** dbname=shpdb
>> >> > host=localhost
>> >> > port=5432"
>> >> >        DATA "the_geom FROM  (SELECT gid, the_geom FROM line_layer)
>> >> >           AS SUBQUERY using unique gid"
>> >> >        PROCESSING "CLOSE_CONNECTION=DEFER"
>> >> >        TYPE line
>> >> >        OPACITY 100
>> >> >        STATUS Off
>> >> >        CLASS
>> >> >           STYLE
>> >> >              COLOR 0 140 70
>> >> >              WIDTH [gid]
>> >> >           END
>> >> >        END
>> >> >     END
>> >> >
>> >> > --
>> >> > View this message in context:
>> >> >
>> >> > http://osgeo-org.1803224.n2.nabble.com/Is-it-posible-to-substitute-a-value-from-table-for-width-of-line-tp6425708p6425708.html
>> >> > Sent from the Mapserver - User mailing list archive at Nabble.com.
>> >> > ___
>> >> > mapserver-users mailing list
>> >> > [hidden email]
>> >> > http://lists.osgeo.org/mailman/listinfo/mapserver-users
>> >> >
>> >> --
>> >> Håvard Tveite
>> >> Department of Mathematical Sciences and Technology, UMB
>> >> Drøbakveien 31, POBox 5003, N-1432 Ås, NORWAY
>> >> Phone: +47 64965483 Fax: +47 64965401 http://www.umb.no/imt/
>> >> ___
>> >> mapserver-users mailing list
>> >> [hidden email]
>> >> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>> >>
>> >>
>> >> 
>> >> If you reply to this email, your message will be added to the
>> >> discussion
>> >> below:
>> >>
>> >>
>> >> http://osgeo-org.1803224.n2.nabble.com/Is-it-posible-to-substitute-a-value-from-table-for-width-of-line-tp6425708p6426034.html
>> >> To unsubscribe from Is it posible to substitute a value from table for
>> >> width of line, click here.
>> >
>> >
>> > --
>> > Regards,
>> > Prabu Raja
>> >
>> >
>> > 
>> > View this message in context: Re: Is it posible to substitute a value
>> > from
>> > table for width of line
>> > Sent from the Mapserver - User mailing list archive at Nabble.com.
>> >
>> > ___
>> > mapserver-users mailing list
>> > [hidden email]
>> > http://lists.osgeo.org/mailman/listinfo/mapserver-users
>> >
>> >
>> ___
>> mapserver-users mailing list
>> [hidden email]
>> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>>
>>
>> 
>> If you reply to this email, your message will be added to the discussion
>> below:
>>
>> http://osgeo-org.1803224.n2.nabble.com/Is-it-posible-to-substitute-a-value-from-table-for-width-of-line-tp6425708p6426084.html
>> To unsubscribe from Is it posible to substitute a value from table for
>> width of line, click here.
>
>
> --
> Regards,
> Prabu Raja
>
>
> 
> View this message in context: Re: Is it posible to substitute a value from
> table for width of line
> Sent from the Mapserver - User mailing list archive at Nabble.com.
>
> ___
> mapserver-users mailing list
> mapserver-users@lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>
>
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] Re: HTTP request error. CURLOPT_PROXYAUTH not supported. Requires Curl 7.10.7 and up

2011-06-01 Thread thomas bonfort
first check that comes to mind: is your curl version > to  7.10.7 ?

On Wed, Jun 1, 2011 at 10:55, sulu  wrote:
> Update.
>
> Am i doing something wrong here?
>
> There is the same problem when i use the ms4w-windows-mapserver (5.6.6)
>
> It also complains about
> CURLOPT_PROXYAUTH not supported. Requires Curl 7.10.7 and up
>
> Maybe there is something amiss in the mapefile.
> 
>                        "wms_proxy_auth_type" "ntlm"
>                        "wms_proxy_type" "http"
>                        "wms_proxy_host" "that_proxy_of_ours"
>                        "wms_proxy_port" "8080"
>                        "wms_proxy_username" "xxx"
>                        "wms_proxy_password" "yy"
> 
>
> Cheers
> Andy
>
>
>
>
> --
> View this message in context: 
> http://osgeo-org.1803224.n2.nabble.com/HTTP-request-error-CURLOPT-PROXYAUTH-not-supported-Requires-Curl-7-10-7-and-up-tp6421746p6426115.html
> Sent from the Mapserver - User mailing list archive at Nabble.com.
> ___
> mapserver-users mailing list
> mapserver-users@lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] Re: Is it posible to substitute a value from table for width of line

2011-06-01 Thread thomas bonfort
ok. the docs are wrong. WIDTH binding is available since mapserver 5.4.0.

On Wed, Jun 1, 2011 at 10:58, prab.raja  wrote:
> Below is the mapserv.exe -v output.
> It shows MapServer version 5.2.1 only.
> MapServer version 5.2.1 OUTPUT=GIF OUTPUT=PNG OUTPUT=JPEG OUTPUT=WBMP
> OUTPUT=PDF
>  OUTPUT=SWF OUTPUT=SVG SUPPORTS=PROJ SUPPORTS=AGG SUPPORTS=FREETYPE
> SUPPORTS=ICO
> NV SUPPORTS=FRIBIDI SUPPORTS=WMS_SERVER SUPPORTS=WMS_CLIENT
> SUPPORTS=WFS_SERVER
> SUPPORTS=WFS_CLIENT SUPPORTS=WCS_SERVER SUPPORTS=SOS_SERVER SUPPORTS=FASTCGI
> SUP
> PORTS=THREADS SUPPORTS=GEOS SUPPORTS=RGBA_PNG INPUT=JPEG INPUT=POSTGIS
> INPUT=OGR
>  INPUT=GDAL INPUT=SHAPEFILE
> On Wed, Jun 1, 2011 at 2:24 PM, thomas bonfort [via OSGeo.org] <[hidden
> email]> wrote:
>>
>> then make sure you are actually using 5.2.1 and not an older version
>>
>> On Wed, Jun 1, 2011 at 10:47, prab.raja <[hidden email]> wrote:
>> > yes.
>> > Below is the style copied from my Map file.
>> >         STYLE
>> >             COLOR 0 140 70
>> >             WIDTH [gid]
>> >          END
>> > On Wed, Jun 1, 2011 at 2:12 PM, thomas bonfort [via OSGeo.org] <[hidden
>> > email]> wrote:
>> >>
>> >> are you using the exact syntax of your first example, i.e. "WIDTH
>> >> [gid]" ?
>> >>
>> >> On Wed, Jun 1, 2011 at 10:27, prab.raja <[hidden email]> wrote:
>> >> > But when I tried this mapserver gives error message as "getInteger():
>> >> > Symbol
>> >> > definition error. Parsing error near (gid)".
>> >> > I am using MapServer version 5.2.1.
>> >> >
>> >> > On Wed, Jun 1, 2011 at 1:48 PM, Havard Tveite [via OSGeo.org]
>> >> > <[hidden
>> >> > email]> wrote:
>> >> >>
>> >> >> According to > >> >> href="> >> >> href="http://www.mapserver.org/mapfile/style.html ";>http://www.mapserver.org/mapfile/style.html ";>> >> >> href="http://www.mapserver.org/mapfile/style.html ";>http://www.mapserver.org/mapfile/style.html >
>> >> >> that should be possible.
>> >> >>
>> >> >> Håvard
>> >> >>
>> >> >> On 6/1/2011 8:09 AM, prab.raja wrote:
>> >> >> > Hi,
>> >> >> > I would like to know if it's posible to draw line layer with
>> >> >> > variable
>> >> >> > width
>> >> >> > from database table.
>> >> >> >
>> >> >> > Something like this?
>> >> >> >
>> >> >> > LAYER
>> >> >> >        NAME line_layer
>> >> >> >        CONNECTIONTYPE postgis
>> >> >> >        CONNECTION "user=postgres password=** dbname=shpdb
>> >> >> > host=localhost
>> >> >> > port=5432"
>> >> >> >        DATA "the_geom FROM  (SELECT gid, the_geom FROM line_layer)
>> >> >> >           AS SUBQUERY using unique gid"
>> >> >> >        PROCESSING "CLOSE_CONNECTION=DEFER"
>> >> >> >        TYPE line
>> >> >> >        OPACITY 100
>> >> >> >        STATUS Off
>> >> >> >        CLASS
>> >> >> >           STYLE
>> >> >> >              COLOR 0 140 70
>> >> >> >              WIDTH [gid]
>> >> >> >           END
>> >> >> >        END
>> >> >> >     END
>> >> >> >
>> >> >> > --
>> >> >> > View this message in context:
>> >> >> >
>> >> >> >
>> >> >> > http://osgeo-org.1803224.n2.nabble.com/Is-it-posible-to-substitute-a-value-from-table-for-width-of-line-tp6425708p6425708.html
>> >> >> > Sent from the Mapserver - User mailing list archive at Nabble.com.
>> >> >> > ___
>> >> >> > mapserver-users mailing list
>> >> >> > [hidden email]
>> >> >> > http://lists.osgeo.org/mailman/listinfo/mapserver-users
>> >> >> >
>> >> >> --
>> >> >> Håvard Tveite
>> >> >> Department of Mathema

Re: [mapserver-users] Re: HTTP request error. CURLOPT_PROXYAUTH not supported. Requires Curl 7.10.7 and up

2011-06-01 Thread thomas bonfort
looking at the code, it seems the only reason on unix you'd get that
message is because the curl library is too old. On ms4w it might be
because the maintainer has not set the USE_CURLOPT_PROXYAUTH #define.

--
thomas

On Wed, Jun 1, 2011 at 11:26, sulu  wrote:
> Hi Jukka.
>
> Thanks for answering.
>
> If i use only wms_proxy_host and wms_proxy_port parameter in the
> Layer/Metadata i get a plain old 407 because of missing credentials.
> But if wms_proxy_password comes into use the "CURLOPT_PROXYAUTH not
> supported"-error shows up.
>
> --
> View this message in context: 
> http://osgeo-org.1803224.n2.nabble.com/HTTP-request-error-CURLOPT-PROXYAUTH-not-supported-Requires-Curl-7-10-7-and-up-tp6421746p6426206.html
> Sent from the Mapserver - User mailing list archive at Nabble.com.
> ___
> mapserver-users mailing list
> mapserver-users@lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] ANGLE FOLLOW and Label Offset (v. 5.6.6)

2011-06-06 Thread thomas bonfort
The status has not changed: label follow with offset is not supported.

regards,
thomas

On Mon, Jun 6, 2011 at 15:33, uvg  wrote:
> Hi all!
> Sorry for my bad English.
>
> I am trying to achieve is a label that follows the rivers that is also
> OFFSET so that
> the label does not  'above' on the line for the river.
>
> Sample code of mapfile:
>
>  LABEL
>          COLOR 0 40 255
>          FONT  "arial-italic"
>          TYPE truetype
>          SIZE 7
>          OFFSET 5 0
>          ANGLE FOLLOW
>          POSITION LC
>          FORCE true
>          PARTIALS FALSE
>
>      END
>
> "OFFSET"  does not work.
> How can I offset a label?
>
> I found a message posted for a long time:
> http://osgeo-org.1803224.n2.nabble.com/label-FOLLOW-and-OFFSET-td2251280.html
>
> Maybe this problem is already solved?
>
> --
> View this message in context: 
> http://osgeo-org.1803224.n2.nabble.com/ANGLE-FOLLOW-and-Label-Offset-v-5-6-6-tp6445138p6445138.html
> Sent from the Mapserver - User mailing list archive at Nabble.com.
> ___
> mapserver-users mailing list
> mapserver-users@lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] Re: ANGLE FOLLOW and Label Offset (v. 5.6.6)

2011-06-06 Thread thomas bonfort
There are two problems with the solution you propose:
- if you offset the geometry in postgis, the distance of the offset
will be in geographical units, i.e. it will not give correct results
at all scales when rendered with mapserver (what you basically want is
to offset the line by a number of pixels roughly equal to the size of
the font used for labelling)
- angle follow on offset line should probably be done on a
simplified/smoothed geometry. see
http://citeseerx.ist.psu.edu/viewdoc/summary?doi=10.1.1.24.6970 .
Ideally someone will want the feature badly enough to fund it :)

--
thomas



On Mon, Jun 6, 2011 at 16:02, Stephen Woodbridge
 wrote:
> There was some recent discussion on the dev list about potentially using the
> GEOMTRANSFORM to do something like a single sided offset then using that to
> apply the label to. BUT I do not think that has been implemented yet in
> mapserver.
>
> Google for "mapserver geomtransform" also look at "geoprocessing" for some
> other ideas.
>
> Anyway, you might be able to do what you want if you:
>
> 1. import your data into PostGIS
> 2. create offset geometry in another table
> 3. export that table to a shapefile
> 4. then label that as an annotation layer so you do not draw the geometry
> only the label and use the original data to draw the grometry ie: two
> layers.
>
> I have not tried this, but it might solve your problem.
>
> -Steve W
>
> On 6/6/2011 9:48 AM, uvg wrote:
>>
>> Thank you, Thomas.
>> Are there any workarounds for this problem?
>> Is there 'best practices' for the problem?
>> Maybe unvisible layer or other?
>> 06.06.2011, 17:35, "thomas bonfort [via OSGeo.org]" <[hidden email]
>> >:
>>
>>    The status has not changed: label follow with offset is not supported.
>>
>>    regards,
>>    thomas
>>
>>    On Mon, Jun 6, 2011 at 15:33, uvg <[hidden email]> wrote:
>>
>>     > Hi all!
>>     > Sorry for my bad English.
>>     >
>>     > I am trying to achieve is a label that follows the rivers that is
>>    also
>>     > OFFSET so that
>>     > the label does not 'above' on the line for the river.
>>     >
>>     > Sample code of mapfile:
>>     >
>>     > LABEL
>>     > COLOR 0 40 255
>>     > FONT "arial-italic"
>>     > TYPE truetype
>>     > SIZE 7
>>     > OFFSET 5 0
>>     > ANGLE FOLLOW
>>     > POSITION LC
>>     > FORCE true
>>     > PARTIALS FALSE
>>     >
>>     > END
>>     >
>>     > "OFFSET" does not work.
>>     > How can I offset a label?
>>     >
>>     > I found a message posted for a long time:
>>     > click here.
>>
>>
>> View this message in context: Re: ANGLE FOLLOW and Label Offset (v.
>> 5.6.6)
>>
>> <http://osgeo-org.1803224.n2.nabble.com/ANGLE-FOLLOW-and-Label-Offset-v-5-6-6-tp6445138p6445194.html>
>> Sent from the Mapserver - User mailing list archive
>> <http://osgeo-org.1803224.n2.nabble.com/Mapserver-User-f1969211.html> at
>> Nabble.com.
>>
>>
>>
>> ___
>> mapserver-users mailing list
>> mapserver-users@lists.osgeo.org
>> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>
> ___
> mapserver-users mailing list
> mapserver-users@lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] Re: ANGLE FOLLOW and Label Offset (v. 5.6.6)

2011-06-06 Thread thomas bonfort
Yes, the resulting shape seems like a nice candidate for offseting
labels, but the problem with buffer is you will have more difficulty
in deciding what is to the left from what is to the right of the line.
We'd also have to make sure that the buffer operation is not too
costly on cpu cycles.
Anyways, until geomtransform is not applied at the layer level, there
is no way to use this method as the label does not operate on the
transformed geometry.

On Mon, Jun 6, 2011 at 17:30, Brent Fraser  wrote:
> Steve,
>
>  I think just buffering the line would apply a type of smoothing (see
> attached image).  Using the resulting buffer line (or perhaps doing some
> simple line smoothing on it) for labeling would be good enough.
>
> Best Regards,
> Brent Fraser
>
>
> On 6/6/2011 9:04 AM, Stephen Woodbridge wrote:
>>
>> Duh! you are correct, I always forget this point until I after my second
>> cup of coffee has kicked in :)
>>
>> That article looks very interesting, I have to read up on that.
>>
>> In a past career in computer aided design and manufacturing, we used the
>> idea of a rolling ball offset because it modeled a milling machine. The
>> rolling ball offset is defined as the curve traced by the center of a ball
>> of a given radius as you roll it along a curve. The circumference of the
>> ball can not cross over the original curve so for tight "S" curves if the
>> diameter of the ball is larger than the gap in the "S" then the ball does
>> not enter the gap but floats over it. This same concept would make for well
>> behaved and good looking labels along tight twisty paths like rivers and
>> roads.
>>
>> Another idea for smoothing out curves for labeling might be to apply an N
>> point moving average and allow that to be the label path. I don't think this
>> has been mentioned as an option in the past.
>>
>> -Steve W
>>
>> On 6/6/2011 10:20 AM, thomas bonfort wrote:
>>>
>>> There are two problems with the solution you propose:
>>> - if you offset the geometry in postgis, the distance of the offset
>>> will be in geographical units, i.e. it will not give correct results
>>> at all scales when rendered with mapserver (what you basically want is
>>> to offset the line by a number of pixels roughly equal to the size of
>>> the font used for labelling)
>>> - angle follow on offset line should probably be done on a
>>> simplified/smoothed geometry. see
>>> http://citeseerx.ist.psu.edu/viewdoc/summary?doi=10.1.1.24.6970 .
>>> Ideally someone will want the feature badly enough to fund it :)
>>>
>>> --
>>> thomas
>>>
>>>
>>>
>>> On Mon, Jun 6, 2011 at 16:02, Stephen Woodbridge
>>>   wrote:
>>>>
>>>> There was some recent discussion on the dev list about potentially using
>>>> the
>>>> GEOMTRANSFORM to do something like a single sided offset then using that
>>>> to
>>>> apply the label to. BUT I do not think that has been implemented yet in
>>>> mapserver.
>>>>
>>>> Google for "mapserver geomtransform" also look at "geoprocessing" for
>>>> some
>>>> other ideas.
>>>>
>>>> Anyway, you might be able to do what you want if you:
>>>>
>>>> 1. import your data into PostGIS
>>>> 2. create offset geometry in another table
>>>> 3. export that table to a shapefile
>>>> 4. then label that as an annotation layer so you do not draw the
>>>> geometry
>>>> only the label and use the original data to draw the grometry ie: two
>>>> layers.
>>>>
>>>> I have not tried this, but it might solve your problem.
>>>>
>>>> -Steve W
>>>>
>>>> On 6/6/2011 9:48 AM, uvg wrote:
>>>>>
>>>>> Thank you, Thomas.
>>>>> Are there any workarounds for this problem?
>>>>> Is there 'best practices' for the problem?
>>>>> Maybe unvisible layer or other?
>>>>> 06.06.2011, 17:35, "thomas bonfort [via OSGeo.org]"<[hidden email]
>>>>> >:
>>>>>
>>>>>    The status has not changed: label follow with offset is not
>>>>> supported.
>>>>>
>>>>>    regards,
>>>>>    thomas
>>>>>
>>>>>    On Mon, Jun 6, 2011 at 15:33, uvg<[hidden email]>  wrote:
>>>>>
>>>>> >  Hi all!
>

Re: [mapserver-users] Fixed labels for polygons

2011-06-08 Thread thomas bonfort
PROCESSING "LABEL_NO_CLIP=ON" on the polygon layer

--
thomas

On Wed, Jun 8, 2011 at 10:18, Ambrogio Foletti  wrote:
> Hi there,
>
> I just subscribed to the list so I want to say hello before posing my
> question ;-)
>
> And here's my problem: I have a lot of contiguous polygons who need to be
> labelled. In general this is no problem, but I need to generate the tiles
> for a WMTS service and the fact that the labels are not fixed but floating
> aroud, rearranging at every pan and zoom, is indeed an issue.
> I read the documentation but as I understand it the "POSITION" parameter
> only tells mapserver the priority and not the absolute emplacement of the
> label.
> Is there a way to tell MapServer to always draw the label at a fixed
> position (over the gravity centre?) on the polygon?
>
> Thanks for your help
> A.
> ___
> mapserver-users mailing list
> mapserver-users@lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>
>
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] symbol position moving when using angle

2011-06-21 Thread thomas bonfort
Bart,
What mapserver version, and which renderer?
Le 21 juin 2011 14:38, "Bart van den Eijnden (OSGIS)"  a
écrit :
> Hi list,
>
> hopefully someone can explain the following issue to me.
>
> I am using a vector symbol (ttf), and when using no angle, it is
> positioned correctly.
>
> However, when I use ANGLE on the STYLE (using an attribute in the
> dataset), things get weird and the symbol position changes.
>
> Image brous4.png (no rotation in Mapserver, red exclamation marks are
> Mapserver, black exclamation marks are ArcMap, blue dot is the same
> Mapserver layer using a circle symbol to display the location):
>
> http://www.osgis.nl/download/mapserver/brous4.png
>
> Image brous3.png, now we rotate the symbols in Mapserver, but their
> location is moving (a simple OFFSET does not seem to be a possible
> solution however):
>
> http://www.osgis.nl/download/mapserver/brous3.png
>
> TIA for any guidance.
>
> Best regards,
> Bart
>
> ___
> mapserver-users mailing list
> mapserver-users@lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/mapserver-users
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] symbol position moving when using angle

2011-06-21 Thread thomas bonfort
6.0 should be ok except for GD: have a look in
msautotest/renderers/point-truetype. I would guess a recent 5.x is ok with
agg to. Guetting it to work with GD is very low on my todo  list (i.e.
improbable without funding)
Le 21 juin 2011 20:02, "Bart van den Eijnden"  a écrit :
> Hi Thomas,
>
> I tested both 5.2 and 5.7 (i.e. trunk a few months after the 5.6 release).
>
> Renderer: my guess is GD but I would need to check on Thursday to be sure.
>
> Best regards,
> Bart
>
> Sent from my iPhone
>
> On Jun 21, 2011, at 7:52 PM, thomas bonfort 
wrote:
>
>> Bart,
>> What mapserver version, and which renderer?
>>
>> Le 21 juin 2011 14:38, "Bart van den Eijnden (OSGIS)" 
a écrit :
>> > Hi list,
>> >
>> > hopefully someone can explain the following issue to me.
>> >
>> > I am using a vector symbol (ttf), and when using no angle, it is
>> > positioned correctly.
>> >
>> > However, when I use ANGLE on the STYLE (using an attribute in the
>> > dataset), things get weird and the symbol position changes.
>> >
>> > Image brous4.png (no rotation in Mapserver, red exclamation marks are
>> > Mapserver, black exclamation marks are ArcMap, blue dot is the same
>> > Mapserver layer using a circle symbol to display the location):
>> >
>> > http://www.osgis.nl/download/mapserver/brous4.png
>> >
>> > Image brous3.png, now we rotate the symbols in Mapserver, but their
>> > location is moving (a simple OFFSET does not seem to be a possible
>> > solution however):
>> >
>> > http://www.osgis.nl/download/mapserver/brous3.png
>> >
>> > TIA for any guidance.
>> >
>> > Best regards,
>> > Bart
>> >
>> > ___
>> > mapserver-users mailing list
>> > mapserver-users@lists.osgeo.org
>> > http://lists.osgeo.org/mailman/listinfo/mapserver-users
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] LABELPOLY with increased padding

2011-06-23 Thread thomas bonfort
I agree this would be an important feature to have.
For now, you should be able to hack around it by specifying the width
of the outline as twice the value of the padding you want. You do
loose the possibility of having an outline of a different color than
the fill.

STYLE
  GEOMTRANSFORM 'labelpoly'
  COLOR 0 150 220
  OUTLINECOLOR 0 150 220
  WIDTH 7
END

Note that I have not tried this, please post back with your results...

--
thomas


On Thu, Jun 23, 2011 at 10:58, Dirk Raffel  wrote:
> Hi,
> the documentation for the STYLE element says that LABELPOLY creates a
> polygon that covers the label with 1 pixel padding.
> Unfortunately, 1 pixel padding doesn't look too good in my case, see this
> example
> image https://docs.google.com/leaf?id=0B6vp23tQ3ixPM2Y1Y2VhZTEtZDQ2MC00ODVkLWFiNzEtMzM3Y2FiZDY0OGQz&hl=en_US&authkey=CJ_72NMH
> STYLE
>   GEOMTRANSFORM 'labelpoly'
>   COLOR 0 150 220
>   OUTLINECOLOR 0 150 220
> END
> Does anyone know of any workarounds to achieve a bigger padding, other than
> hacking the mapserver source?
> Are there any plans to further improve label styling in future mapserver
> releases in a way that would solve issues like this?
> Thanks,
> Dirk
> ___
> mapserver-users mailing list
> mapserver-users@lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>
>
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] LABELPOLY with increased padding

2011-06-23 Thread thomas bonfort
On Thu, Jun 23, 2011 at 11:35, Jana Golinowski  wrote:
>> I agree this would be an important feature to have.
>> For now, you should be able to hack around it by specifying the width
>> of the outline as twice the value of the padding you want. You do
>> loose the possibility of having an outline of a different color than
>> the fill.
>
> It is possible to have different colors for fill and outline. You just have
> to use 2 styles with varying widths:
>
> LABEL
>  ...
>  STYLE
>    GEOMTRANSFORM LABELPOLY
>    COLOR 0 0 0
>    OUTLINECOLOR 0 0 0
>    WIDTH 10
>  END
>  STYLE
>    GEOMTRANSFORM LABELPOLY
>    COLOR 0 150 220
>    OUTLINECOLOR 0 150 220
>    WIDTH 8
>  END
> END

yeah, nice one !

>
> The problem is that you can't have a transparent fill with a small outline
> and this padding.

as said, this is just a hack for now. We definitely need to be able to
set the padding for the labelpoly. Opening a
bugreport/feature-enhancement for this would be the first step so we
don't forget it.

regards,

thomas

>
> Greetings, Jana.
> ___
> mapserver-users mailing list
> mapserver-users@lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] Re: Font rendering in MapServer 6.0

2011-07-07 Thread thomas bonfort
We've kept the GD renderer in 6.0 for some marginal use cases, but the
preferred way is to switch to AGG rendering (which is compiled in by
default): you can use the builtin png8 imagetype (mimetype: image/png;
mode=8bit) which does a quantization step if you need a 256 color
paletted image.

The easy solution is to remove all your outputformat blocks from your
mapfile, and call your server with FORMAT=image/png or image/png;
mode=8bit , and setting your map imagetype to png or png8.

As for this GD rendering bug, the easy first step is be to open a
bug-report. The harder second step is to get someone motivated to look
into it if you cannot provide a patch.

regards,
thomas

On Thu, Jul 7, 2011 at 20:07, Brad Posthumus  wrote:
> I've narrowed it down further to the OUTPUTFORMAT section of the mapfile,
> which currently is:
>
>  OUTPUTFORMAT
>    NAME png
>    DRIVER "GD/PNG"
>    MIMETYPE "image/png"
>    IMAGEMODE PC256
>    FORMATOPTION "INTERLACE=OFF"
>    EXTENSION png
>    TRANSPARENT ON
>  END
>
> It appears to be a problem with having a combination of GD/PNG, PC256, and
> transparency. Turning transparency off renders a clean image, changing PC256
> to RGBA renders a clean image, changing PNG to GIF (at all locations)
> renders a clean image
>
> This setup was working in 5.4 and 5.6 so I'll assume it's a bug I should
> report for 6.0.
>
> --
> View this message in context: 
> http://osgeo-org.1803224.n2.nabble.com/Font-rendering-in-MapServer-6-0-tp6555935p6559374.html
> Sent from the Mapserver - User mailing list archive at Nabble.com.
> ___
> mapserver-users mailing list
> mapserver-users@lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] defresolution and resolution issues in Mapserver 6

2011-07-18 Thread thomas bonfort
Mike,
I am not able to reproduce with the msautotest tests:

These are the steps I have taken, in msautotest/renderers
- mapserv -nh 
QUERY_STRING='map=point_ellipse.map&mode=map&map_resolution=144&map_size=800+600'
> result/point_ellipse.png.png
- convert -scale 50% result/point_ellipse.png.png result/point_ellipse.png.png
- compare visually expected/point_ellipse.png.png
result/point_ellipse.png.png which should be nearly identical

ps: I've added the labels-anno.map test in case the problem you werre
having only affects annotation layers, but that does not seem to be
the case.

--
thomas

On Mon, Jul 18, 2011 at 16:49, Smith, Michael ERDC-CRREL-NH
 wrote:
> All,
> I'm seeing symbol scaling and label size/placement issues (see images and
> pdfs for differences) when trying to scale up for higher resolution output.
> Font size is scaling properly but the symbols are larger at higher dpi than
> it should be and labels are not being displayed (perhaps due to label buffer
> issues) at the higher dpi.
> Are there additional settings I should be making beyond setting resolution
> and defresolution?
> Example URLs
> http://localgost/cgi-bin/mapserv6?TRANSPARENT=true&map_resolution=72&MAP_IMAGETYPE=png&MAPEXT=-8043793.5+5411335.5+-8041721.0+5413610.5&map_defresolution=72&MAP_SIZE=440+483&LAYERS=watersmap&MODE=map&MAP=cm2_test.map
> http://localhost/cgi-bin/mapserv6?TRANSPARENT=true&map_resolution=144&MAP_IMAGETYPE=png&MAPEXT=-8043793.5+5411335.5+-8041721.0+5413610.5&map_defresolution=72&MAP_SIZE=880+966&LAYERS=watersmap&MODE=map&MAP=cm2_test.map
> Mike
> --
> Michael Smith
> Remote Sensing/GIS Center
> US Army Corps of Engineers
>
>
>
> ___
> mapserver-users mailing list
> mapserver-users@lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>
>
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] defresolution & resolution in 6.0

2011-07-18 Thread thomas bonfort
Richard,
I was also unable to reproduce your issue (see the similar titled
thread initiated by Mike Smith), using the
msautotest/renderers/polygon-as-line.map

please submit a self-contained test-case where the issue can be reproduced.

thanks,
thomas

On Sun, Jul 17, 2011 at 21:35, Richard Greenwood
 wrote:
> When I use defresolution & resolution in MapServer 6.0 on lines with a
> width of 1 nothing is displayed. Specifically I am using:
>   map.defresolution=96&map.resolution=144
> on a polygon layer defined as:
>
>  CLASS
>    NAME "Lot and Parcel Lines"
>    STYLE
>      OUTLINECOLOR 255 0 0
>      WIDTH 1
>    END
>  END
>
> Example (works):
>
> http://maps.hscounty.com/cgi-bin/mapserv.exe?map=MAP_15_MAIN&layers=ownership&mode=map
>
> Example, with defresolution & resolution doesn't work:
>
> http://maps.hscounty.com/cgi-bin/mapserv.exe?map=MAP_15_MAIN&layers=ownership&mode=map&map.defresolution=96&map.resolution=144
>
> Any insight would be appreciated.
>
> Thanks,
> Rich
>
> --
> Richard Greenwood
> richard.greenw...@gmail.com
> www.greenwoodmap.com
> ___
> mapserver-users mailing list
> mapserver-users@lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] defresolution & resolution in 6.0

2011-07-18 Thread thomas bonfort
On Mon, Jul 18, 2011 at 21:31, Richard Greenwood
 wrote:
> thomas,
>
> Thank you for your reply. This link should produce an image with lines 
> rendered:
>
> http://maps.hscounty.com/cgi-bin/mapserv.exe?map=MAP_15_MAIN&layers=ownership&mode=map&map.defresolution=72&map.resolution=144
>
> This is the same except with map.resolution=100 and lines are not
> rendered, image is blank:
>
> http://maps.hscounty.com/cgi-bin/mapserv.exe?map=MAP_15_MAIN&layers=ownership&mode=map&map.defresolution=72&map.resolution=100
>
> When map.defresolution=72, any value for map.resolution between 73 and
> 143 fails to render lines. Similarly when map.defresolution=10, any
> value for map.resolution between 11 and 19 fails to render lines.
>
> You can easily change defresolution and resolution in the URL yourself
> to see the behavior.
>
> If you consider this a bug I am happy to file a ticket, but I'd like
> another set of eyes on it before I do so.
This definitely seems like a bug, go ahead and file a ticket !

thanks,
thomas

>
> Thank you,
> Rich
>
> On Mon, Jul 18, 2011 at 11:52 AM, thomas bonfort
>  wrote:
>> Richard,
>> I was also unable to reproduce your issue (see the similar titled
>> thread initiated by Mike Smith), using the
>> msautotest/renderers/polygon-as-line.map
>>
>> please submit a self-contained test-case where the issue can be reproduced.
>>
>> thanks,
>> thomas
>>
>> On Sun, Jul 17, 2011 at 21:35, Richard Greenwood
>>  wrote:
>>> When I use defresolution & resolution in MapServer 6.0 on lines with a
>>> width of 1 nothing is displayed. Specifically I am using:
>>>   map.defresolution=96&map.resolution=144
>>> on a polygon layer defined as:
>>>
>>>  CLASS
>>>    NAME "Lot and Parcel Lines"
>>>    STYLE
>>>      OUTLINECOLOR 255 0 0
>>>      WIDTH 1
>>>    END
>>>  END
>>>
>>> Example (works):
>>>
>>> http://maps.hscounty.com/cgi-bin/mapserv.exe?map=MAP_15_MAIN&layers=ownership&mode=map
>>>
>>> Example, with defresolution & resolution doesn't work:
>>>
>>> http://maps.hscounty.com/cgi-bin/mapserv.exe?map=MAP_15_MAIN&layers=ownership&mode=map&map.defresolution=96&map.resolution=144
>>>
>>> Any insight would be appreciated.
>>>
>>> Thanks,
>>> Rich
>>>
>>> --
>>> Richard Greenwood
>>> richard.greenw...@gmail.com
>>> www.greenwoodmap.com
>>> ___
>>> mapserver-users mailing list
>>> mapserver-users@lists.osgeo.org
>>> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>>>
>>
>
>
>
> --
> Richard Greenwood
> richard.greenw...@gmail.com
> www.greenwoodmap.com
>
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] defresolution & resolution in 6.0

2011-07-19 Thread thomas bonfort
I still haven't been able to reproduce the issue with my simple
testcase, so please attach the complete mapfile that triggers this to
the bugreport.

--
thomas

On Tue, Jul 19, 2011 at 08:37, thomas bonfort  wrote:
> On Mon, Jul 18, 2011 at 21:31, Richard Greenwood
>  wrote:
>> thomas,
>>
>> Thank you for your reply. This link should produce an image with lines 
>> rendered:
>>
>> http://maps.hscounty.com/cgi-bin/mapserv.exe?map=MAP_15_MAIN&layers=ownership&mode=map&map.defresolution=72&map.resolution=144
>>
>> This is the same except with map.resolution=100 and lines are not
>> rendered, image is blank:
>>
>> http://maps.hscounty.com/cgi-bin/mapserv.exe?map=MAP_15_MAIN&layers=ownership&mode=map&map.defresolution=72&map.resolution=100
>>
>> When map.defresolution=72, any value for map.resolution between 73 and
>> 143 fails to render lines. Similarly when map.defresolution=10, any
>> value for map.resolution between 11 and 19 fails to render lines.
>>
>> You can easily change defresolution and resolution in the URL yourself
>> to see the behavior.
>>
>> If you consider this a bug I am happy to file a ticket, but I'd like
>> another set of eyes on it before I do so.
> This definitely seems like a bug, go ahead and file a ticket !
>
> thanks,
> thomas
>
>>
>> Thank you,
>> Rich
>>
>> On Mon, Jul 18, 2011 at 11:52 AM, thomas bonfort
>>  wrote:
>>> Richard,
>>> I was also unable to reproduce your issue (see the similar titled
>>> thread initiated by Mike Smith), using the
>>> msautotest/renderers/polygon-as-line.map
>>>
>>> please submit a self-contained test-case where the issue can be reproduced.
>>>
>>> thanks,
>>> thomas
>>>
>>> On Sun, Jul 17, 2011 at 21:35, Richard Greenwood
>>>  wrote:
>>>> When I use defresolution & resolution in MapServer 6.0 on lines with a
>>>> width of 1 nothing is displayed. Specifically I am using:
>>>>   map.defresolution=96&map.resolution=144
>>>> on a polygon layer defined as:
>>>>
>>>>  CLASS
>>>>    NAME "Lot and Parcel Lines"
>>>>    STYLE
>>>>      OUTLINECOLOR 255 0 0
>>>>      WIDTH 1
>>>>    END
>>>>  END
>>>>
>>>> Example (works):
>>>>
>>>> http://maps.hscounty.com/cgi-bin/mapserv.exe?map=MAP_15_MAIN&layers=ownership&mode=map
>>>>
>>>> Example, with defresolution & resolution doesn't work:
>>>>
>>>> http://maps.hscounty.com/cgi-bin/mapserv.exe?map=MAP_15_MAIN&layers=ownership&mode=map&map.defresolution=96&map.resolution=144
>>>>
>>>> Any insight would be appreciated.
>>>>
>>>> Thanks,
>>>> Rich
>>>>
>>>> --
>>>> Richard Greenwood
>>>> richard.greenw...@gmail.com
>>>> www.greenwoodmap.com
>>>> ___
>>>> mapserver-users mailing list
>>>> mapserver-users@lists.osgeo.org
>>>> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>>>>
>>>
>>
>>
>>
>> --
>> Richard Greenwood
>> richard.greenw...@gmail.com
>> www.greenwoodmap.com
>>
>
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] mapserver publish road

2011-07-19 Thread thomas bonfort
I don't think there's a way to do this, as when rendering roads the
mapserver method is usually what is desired.
You might want to file an enhancement ticket so that this behavior can be
configured with a mapfile keyword.
On a side note, cartolines in mapserver are deprecated since version 5.0 and
completely unsupported sincce 6.0, so you should not be using them for a new
project: use the agg outputformat and STYLE->WIDTH for thick lines.

--
thomas

2011/7/19 赫玄惠 

> I encounter a question. use one  same shape file, when I use it in
> mapserver it like
>
> but in udig it like
>
> when two street intersect together, udig can paint map with the black
> border,but mapserver can't. Anyone know why?
> my mapfile is this:
> MAP
>   SIZE 800 450
>   EXTENT -200 0 200 100
>   IMAGECOLOR 180 180 250
>   UNITS DD
>   debug 5
>   CONFIG "MS_ERRORFILE" "\ms4w\tmp\ms_error.txt"
>   FONTSET "D:\ms4w\apps\fonts\fonts.list"
> PROJECTION
> "init=epsg:4326"
> END
> OUTPUTFORMAT
> NAME png24#AGG
> DRIVER "GD/PNG" #AGG/PNG*IMAGEMODE RGB
> MIMETYPE IMAGE/PNG
> EXTENSION PNG
> #FORMATOPTION TRANSPARENT=ON
> #FORMATOPTION INTERLANCE=OFF
> END
> IMAGETYPE png24 #AGG
> WEB
> IMAGEPATH "\ms4w\Apache\htdocs\tmp\"
> IMAGEURL "\tmp\"
> END
>
> SYMBOL
>   NAME 'cartoline'
>   TYPE CARTOLINE
>   LINECAP  butt
>LINEJOIN  bevel
>LINEJOINMAXSIZE 3
> END
>
> LAYER
> NAME 01
> TYPE LINE
> debug 5
> STATUS on
> TRANSPARENCY alpha
> CONNECTIONTYPE postgis
> CONNECTION "user=* dbname=* host=* port=* password=* "
> DATA "the_geom from *** using unique gid"
> processing "slose_connection=defer"
> DUMP TRUE
> CLASS
>   STYLE
>COLOR 0 0 0
>SYMBOL 'cartoline'
>ANTIALIAS TRUE
> SIZE 10
> END
>  STYLE
>COLOR 255 255 0
>SYMBOL 'cartoline'
>ANTIALIAS TRUE
>  &nbs p;  SIZE 8
> END
> END
> END
> END
>
> *
>
>
>
> ___
> mapserver-users mailing list
> mapserver-users@lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>
>
<<22.png>><<11.png>>___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] mapserver publish road

2011-07-19 Thread thomas bonfort
2011/7/19 Rahkonen Jukka :
> Hi,
>
> I believe that most cartographers would say that the uDig way to to draw the 
> outlines is ugly and the Mapserver way looks better but it is partly a matter 
> of taste.  However, at least for me the continuous black lines also give a 
> feeling that it is not possible or allowed to drive from one street to 
> another.
>
> I would try to draw the streets as two separate layers with own styels 
> instead of a single layer with two styles, perhaps that would lead to 
> continuos black outlines.

Doing so this way would also result in the black lines disappearing.

--
thomas

>
> -Jukka Rahkonen-
>
>
>  赫玄惠 [xiaoshitou1986...@126.com] wrote:
>
>> I encounter a question. use one  same shape file, when I use it in mapserver 
>> it like
> [cid:752891ff$1$13140d5bf06$Coremail$xiaoshitou1986...@126.com]
> but in udig it like
> [cid:3a893870$2$13140d5bf06$Coremail$xiaoshitou1986...@126.com]
> when two street intersect together, udig can paint map with the black 
> border,but mapserver can't. Anyone know why?
> my mapfile is this:
> MAP
>  SIZE 800 450
>  EXTENT -200 0 200 100
>  IMAGECOLOR 180 180 250
>  UNITS DD
>  debug 5
>  CONFIG "MS_ERRORFILE" "\ms4w\tmp\ms_error.txt"
>  FONTSET "D:\ms4w\apps\fonts\fonts.list"
> PROJECTION
>    "init=epsg:4326"
> END
> OUTPUTFORMAT
>    NAME png24#AGG
>    DRIVER "GD/PNG" #AGG/PNG    IMAGEMODE RGB
>    MIMETYPE IMAGE/PNG
>    EXTENSION PNG
>    #FORMATOPTION TRANSPARENT=ON
>    #FORMATOPTION INTERLANCE=OFF
> END
> IMAGETYPE png24 #AGG
> WEB
>    IMAGEPATH "\ms4w\Apache\htdocs\tmp\"
>    IMAGEURL "\tmp\"
> END
>
> SYMBOL
>  NAME 'cartoline'
>  TYPE CARTOLINE
>  LINECAP  butt
>   LINEJOIN  bevel
>   LINEJOINMAXSIZE 3
> END
>
> LAYER
>    NAME 01
>    TYPE LINE
>    debug 5
>    STATUS on
>    TRANSPARENCY alpha
>    CONNECTIONTYPE postgis
>    CONNECTION "user=* dbname=* host=* port=* password=* "
>    DATA "the_geom from *** using unique gid"
>    processing "slose_connection=defer"
>    DUMP TRUE
>    CLASS
>      STYLE
>           COLOR 0 0 0
>           SYMBOL 'cartoline'
>           ANTIALIAS TRUE
>        SIZE 10
>        END
>         STYLE
>           COLOR 255 255 0
>           SYMBOL 'cartoline'
>           ANTIALIAS TRUE
>  &nbs p;      SIZE 8
>        END
>    END
> END
> END
>
>
>
> ___
> mapserver-users mailing list
> mapserver-users@lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] wms time problem

2011-07-21 Thread thomas bonfort
have a look at http://mapserver.org/cgi/runsub.html

regards,
thomas

On Thu, Jul 21, 2011 at 15:19, Luana Valentini
 wrote:
> Dear all,
>
> I'm using MapServer to serve a building shapefile, in which ? have stored
> in the attribute table a 'date of construction' and a 'date of
> demolition'.
> At the client side we have OpenLayers and some Javascript to let the
> user chose a certain year and see only those buildings that have a
> 'date of construction' <= t and 'date of demolition' > t.
> This cannot be done using only wms with time support because I cannot
> compare the chosen year with both the 'date of construction' and the
> 'date of demolition' at the same time.
> As I can see, it can be easily done with a CQL filter in GeoServer and
> I'm wondering if it possible to solve this problem also in
> MapServer...
> Is it possible to overcome the problem only using wfs filtering?
>
> Thank you very much!
>
> Luana
> ___
> mapserver-users mailing list
> mapserver-users@lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>
>
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] expressions in a chart layer

2011-08-08 Thread thomas bonfort
There is no such functionality for the time being. You can either
filter out the data at the DATA level (i.e. postgis query with "where
year=xxx") or fund the addition of expressions to the chart type
layers.

regards,
thomas

On Mon, Aug 8, 2011 at 11:39, Mario Basa  wrote:
> Hello.
>
> Do EXPRESSIONS work in a chart layer? I have been trying something
> like the one below, and the postgis layer only has 2010 and 2011 data
> and yet the 2012 portion of the chart keeps on appearing. If
> Expressions do not work, is there any other method of filtering the
> data before creating the pie char.    Thanks!
>
>
> TYPE CHART
> PROCESSING "CHART_SIZE=20"
> PROCESSING "CHART_TYPE=PIE"
>
> CLASS
>        NAME "2010"
>        EXPRESSION ([obj_]=2010)
>        STYLE
>            SIZE 5
>            COLOR 234 192 156
>            OUTLINECOLOR 10 10 10
>        END
>    END
>    CLASS
>        NAME "2011"
>        EXPRESSION ([obj_]=2011)
>        STYLE
>            SIZE 20
>            COLOR 112 78 221
>            OUTLINECOLOR 10 10 10
>        END
>    END
>    CLASS
>        NAME "2012"
>        EXPRESSION ([obj_]=2012)
>        STYLE
>            SIZE 60
>            COLOR 133 178 199
>            OUTLINECOLOR 10 10 10
>        END
>    END
> ___
> mapserver-users mailing list
> mapserver-users@lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] googleMap as a base layer

2011-08-11 Thread thomas bonfort
no, the google maps terms of service explicitely deny this kind of
usage (this limitation is probably raised if you get an enterprise
license)

--
thomas

2011/8/11 ahmet temiz :
> hello
>
> I was wondering if it was possible to integrate googlemap to mapserver a 
> layer ?
>
> regards
>
> --
> Ahmet Temiz
> Jeoloji Müh.
> Afet ve Acil Durum Yönetimi Başkanlığı
> Planlama ve Zarar Azaltma Dairesi Başkanlığı
> Bilgi ve CBS grubu
> Eskişehir Yolu 10. km.
> Lodumlu / Ankara
> Tel : 0 312 2872680 / 1535
> 
>
> Ahmet Temiz
> Geological Eng.
> Information Systems - GIS Group
> Disaster and Emergency Management
> of Presidency
> ___
> mapserver-users mailing list
> mapserver-users@lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] Invalid pdf file from WMS

2011-08-17 Thread thomas bonfort
the second one is incomplete, the request seems to be failing.

can you run the request locally to see if it segfaults, and if so
provide a backtrace:

/path/to/mapserver-cgi
QUERY_STRING='map=/path/to/map&REQUEST=GetMap&SERVICE=WMS&VERSION=1.1.1&WIDTH=864&HEIGHT=662&LAYERS=default&TRANSPARENT=TRUE&FORMAT=application/x-pdf&BBOX=3409763.750050978,6956187.032331026,3411904.266676571,6957827.104097395&SRS=EPSG:2393&STYLES='

--
thomas

On Wed, Aug 17, 2011 at 15:40, Rahkonen Jukka  wrote:
> Hi,
>
> This request from Mapserver 6.0 gives me a nice pdf file:
> http://188.64.1.61/cgi-bin/osm-mapserver_i?REQUEST=GetMap&SERVICE=WMS&VERSION=1.1.1&WIDTH=864&HEIGHT=662&LAYERS=default&TRANSPARENT=TRUE&FORMAT=application/x-pdf&BBOX=3409763.750050978,6956187.032331026,3411904.266676571,6957827.104097395&SRS=EPSG:2393&STYLES=
>
> However, if I double the bounding box the resulting pdf cannot be opened by 
> Acrobat reader.
> http://188.64.1.61/cgi-bin/osm-mapserver_i?REQUEST=GetMap&SERVICE=WMS&VERSION=1.1.1&WIDTH=1728&HEIGHT=1324&LAYERS=default&TRANSPARENT=TRUE&FORMAT=application/x-pdf&BBOX=3409763.750050978,6956187.032331026,3411904.266676571,6957827.104097395&SRS=EPSG:2393&STYLES=
>
> The latter gives fine image with format=image/png. Any idea about what is 
> going wrong?
>
> -Jukka Rahkonen-___
> mapserver-users mailing list
> mapserver-users@lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] Invalid pdf file from WMS

2011-08-17 Thread thomas bonfort
if gdb is installed on the system, you do:

gdb /path/to/mapserv
$ run QUERY_STRING='map=...&'
(...program runs and spits out the beginning of the pdf..., then segfaults)
$ bt

--
thomas

On Wed, Aug 17, 2011 at 21:36, Rahkonen Jukka  wrote:
> Hi,
>
> Command with big BBOX does lead into segmantation fault.  Unfortunately I am 
> just an amateur and I have no idea about what is a backtrace and how I could 
> provide it to you. The server is a virtual Linux box (Ubuntu).
>
> -Jukka Rahkonen-
>
> thomas bonfort wrote:
>
>> the second one is incomplete, the request seems to be failing.
>
>> can you run the request locally to see if it segfaults, and if so
> provide a backtrace:
>
>> /path/to/mapserver-cgi
> QUERY_STRING='map=/path/to/map&REQUEST=GetMap&SERVICE=WMS&VERSION=1.1.1&WIDTH=864&HEIGHT=662&LAYERS=default&TRANSPARENT=TRUE&FORMAT=application/x-pdf&BBOX=3409763.750050978,6956187.032331026,3411904.266676571,6957827.104097395&SRS=EPSG:2393&STYLES='
>
> --
> thomas
>
> On Wed, Aug 17, 2011 at 15:40, Rahkonen Jukka  
> wrote:
>> Hi,
>>
>>> This request from Mapserver 6.0 gives me a nice pdf file:
>>> http://188.64.1.61/cgi-bin/osm-mapserver_i?REQUEST=GetMap&SERVICE=WMS&VERSION=1.1.1&WIDTH=864&HEIGHT=662&LAYERS=default&TRANSPARENT=TRUE&FORMAT=application/x-pdf&BBOX=3409763.750050978,6956187.032331026,3411904.266676571,6957827.104097395&SRS=EPSG:2393&STYLES=
>>
>> However, if I double the bounding box the resulting pdf cannot be opened by 
>> Acrobat reader.
>> http://188.64.1.61/cgi-bin/osm-mapserver_i?REQUEST=GetMap&SERVICE=WMS&VERSION=1.1.1&WIDTH=1728&HEIGHT=1324&LAYERS=default&TRANSPARENT=TRUE&FORMAT=application/x-pdf&BBOX=3409763.750050978,6956187.032331026,3411904.266676571,6957827.104097395&SRS=EPSG:2393&STYLES=
>>
>> The latter gives fine image with format=image/png. Any idea about what is 
>> going wrong?
>>
>> -Jukka Rahkonen-___
>> mapserver-users mailing list
>> mapserver-users@lists.osgeo.org
>> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>>
>
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] Invalid pdf file from WMS

2011-08-18 Thread thomas bonfort
this seems to be a cairo/pdf issue, as the cairo/png works fine:
http://188.64.1.61/cgi-bin/osm-mapserver_i?REQUEST=GetMap&SERVICE=WMS&VERSION=1.1.1&WIDTH=1728&HEIGHT=1324&LAYERS=default&TRANSPARENT=TRUE&FORMAT=cairopng&BBOX=3409763.750050978,6956187.032331026,3411904.266676571,6957827.104097395&SRS=EPSG:2393&STYLES=

what cairo version are you using? can you upgrade it?

--
thomas

On Wed, Aug 17, 2011 at 22:46, Rahkonen Jukka  wrote:
> Hi,
>
> Amazing. I got this
>
> (gdb) bt
> #0  0x0013a258 in FT_Done_Face () from /usr/lib/libfreetype.so.6
> #1  0x00f447c3 in ?? () from /usr/lib/libcairo.so.2
> #2  0x00f4ba19 in cairo_font_face_destroy () from /usr/lib/libcairo.so.2
> #3  0x0813a8b4 in ?? ()
> #4  0x0813a9c8 in cleanupCairo ()
> #5  0x080c5aee in ?? ()
> #6  0x0810b406 in ?? ()
> #7  0x0807207d in ?? ()
> #8  0x0805c2f4 in ?? ()
> #9  0x00fefbd6 in __libc_start_main () from /lib/tls/i686/cmov/libc.so.6
> #10 0x08057881 in ?? ()
>
> -Jukka-
> 
> Lähettäjä: thomas bonfort [thomas.bonf...@gmail.com]
> Lähetetty: 17. elokuuta 2011 22:56
> Vastaanottaja: Rahkonen Jukka
> Kopio: mapserver-users@lists.osgeo.org
> Aihe: Re: [mapserver-users] Invalid pdf file from WMS
>
> if gdb is installed on the system, you do:
>
> gdb /path/to/mapserv
> $ run QUERY_STRING='map=...&'
> (...program runs and spits out the beginning of the pdf..., then segfaults)
> $ bt
>
> --
> thomas
>
> On Wed, Aug 17, 2011 at 21:36, Rahkonen Jukka  
> wrote:
>> Hi,
>>
>> Command with big BBOX does lead into segmantation fault.  Unfortunately I am 
>> just an amateur and I have no idea about what is a backtrace and how I could 
>> provide it to you. The server is a virtual Linux box (Ubuntu).
>>
>> -Jukka Rahkonen-
>>
>> thomas bonfort wrote:
>>
>>> the second one is incomplete, the request seems to be failing.
>>
>>> can you run the request locally to see if it segfaults, and if so
>> provide a backtrace:
>>
>>> /path/to/mapserver-cgi
>> QUERY_STRING='map=/path/to/map&REQUEST=GetMap&SERVICE=WMS&VERSION=1.1.1&WIDTH=864&HEIGHT=662&LAYERS=default&TRANSPARENT=TRUE&FORMAT=application/x-pdf&BBOX=3409763.750050978,6956187.032331026,3411904.266676571,6957827.104097395&SRS=EPSG:2393&STYLES='
>>
>> --
>> thomas
>>
>> On Wed, Aug 17, 2011 at 15:40, Rahkonen Jukka  
>> wrote:
>>> Hi,
>>>
>>>> This request from Mapserver 6.0 gives me a nice pdf file:
>>>> http://188.64.1.61/cgi-bin/osm-mapserver_i?REQUEST=GetMap&SERVICE=WMS&VERSION=1.1.1&WIDTH=864&HEIGHT=662&LAYERS=default&TRANSPARENT=TRUE&FORMAT=application/x-pdf&BBOX=3409763.750050978,6956187.032331026,3411904.266676571,6957827.104097395&SRS=EPSG:2393&STYLES=
>>>
>>> However, if I double the bounding box the resulting pdf cannot be opened by 
>>> Acrobat reader.
>>> http://188.64.1.61/cgi-bin/osm-mapserver_i?REQUEST=GetMap&SERVICE=WMS&VERSION=1.1.1&WIDTH=1728&HEIGHT=1324&LAYERS=default&TRANSPARENT=TRUE&FORMAT=application/x-pdf&BBOX=3409763.750050978,6956187.032331026,3411904.266676571,6957827.104097395&SRS=EPSG:2393&STYLES=
>>>
>>> The latter gives fine image with format=image/png. Any idea about what is 
>>> going wrong?
>>>
>>> -Jukka Rahkonen-___
>>> mapserver-users mailing list
>>> mapserver-users@lists.osgeo.org
>>> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>>>
>>
>
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] Invalid pdf file from WMS

2011-08-19 Thread thomas bonfort
Worth,
a bugreport with a self contained test case is the correct next step.
please try to take php out of the loop, a shp2img call causing the
crash would be ideal.

thanks,
thomas

On Fri, Aug 19, 2011 at 01:43, Worth Lutz  wrote:
> I can get php MapScript to segfault drawing PDF maps when the same PNG map
> works fine.  I had to crank up the allowed memory and allowed time in PHP to
> get my maps to work.  I will submit a bug report and test case when I
> understand the problem better.  I am trying to develop a method of creating
> a large set of PDF maps dynamically with PHP and and am finally figuring it
> out.
>
> Worth Lutz
>
>
>
> -Original Message-
> From: mapserver-users-boun...@lists.osgeo.org
> [mailto:mapserver-users-boun...@lists.osgeo.org] On Behalf Of thomas bonfort
> Sent: Thursday, August 18, 2011 3:11 AM
> To: Rahkonen Jukka
> Cc: mapserver-users@lists.osgeo.org
> Subject: Re: [mapserver-users] Invalid pdf file from WMS
>
> this seems to be a cairo/pdf issue, as the cairo/png works fine:
> http://188.64.1.61/cgi-bin/osm-mapserver_i?REQUEST=GetMap&SERVICE=WMS&VERSIO
> N=1.1.1&WIDTH=1728&HEIGHT=1324&LAYERS=default&TRANSPARENT=TRUE&FORMAT=cairop
> ng&BBOX=3409763.750050978,6956187.032331026,3411904.266676571,6957827.104097
> 395&SRS=EPSG:2393&STYLES=
>
> what cairo version are you using? can you upgrade it?
>
> --
> thomas
>
> On Wed, Aug 17, 2011 at 22:46, Rahkonen Jukka 
> wrote:
>> Hi,
>>
>> Amazing. I got this
>>
>> (gdb) bt
>> #0  0x0013a258 in FT_Done_Face () from /usr/lib/libfreetype.so.6
>> #1  0x00f447c3 in ?? () from /usr/lib/libcairo.so.2
>> #2  0x00f4ba19 in cairo_font_face_destroy () from /usr/lib/libcairo.so.2
>> #3  0x0813a8b4 in ?? ()
>> #4  0x0813a9c8 in cleanupCairo ()
>> #5  0x080c5aee in ?? ()
>> #6  0x0810b406 in ?? ()
>> #7  0x0807207d in ?? ()
>> #8  0x0805c2f4 in ?? ()
>> #9  0x00fefbd6 in __libc_start_main () from /lib/tls/i686/cmov/libc.so.6
>> #10 0x08057881 in ?? ()
>>
>> -Jukka-
>> 
>> Lähettäjä: thomas bonfort [thomas.bonf...@gmail.com]
>> Lähetetty: 17. elokuuta 2011 22:56
>> Vastaanottaja: Rahkonen Jukka
>> Kopio: mapserver-users@lists.osgeo.org
>> Aihe: Re: [mapserver-users] Invalid pdf file from WMS
>>
>> if gdb is installed on the system, you do:
>>
>> gdb /path/to/mapserv
>> $ run QUERY_STRING='map=...&'
>> (...program runs and spits out the beginning of the pdf..., then
> segfaults)
>> $ bt
>>
>> --
>> thomas
>>
>> On Wed, Aug 17, 2011 at 21:36, Rahkonen Jukka 
> wrote:
>>> Hi,
>>>
>>> Command with big BBOX does lead into segmantation fault.  Unfortunately I
> am just an amateur and I have no idea about what is a backtrace and how I
> could provide it to you. The server is a virtual Linux box (Ubuntu).
>>>
>>> -Jukka Rahkonen-
>>>
>>> thomas bonfort wrote:
>>>
>>>> the second one is incomplete, the request seems to be failing.
>>>
>>>> can you run the request locally to see if it segfaults, and if so
>>> provide a backtrace:
>>>
>>>> /path/to/mapserver-cgi
>>>
> QUERY_STRING='map=/path/to/map&REQUEST=GetMap&SERVICE=WMS&VERSION=1.1.1&WIDT
> H=864&HEIGHT=662&LAYERS=default&TRANSPARENT=TRUE&FORMAT=application/x-pdf&BB
> OX=3409763.750050978,6956187.032331026,3411904.266676571,6957827.104097395&S
> RS=EPSG:2393&STYLES='
>>>
>>> --
>>> thomas
>>>
>>> On Wed, Aug 17, 2011 at 15:40, Rahkonen Jukka 
> wrote:
>>>> Hi,
>>>>
>>>>> This request from Mapserver 6.0 gives me a nice pdf file:
>>>>>
> http://188.64.1.61/cgi-bin/osm-mapserver_i?REQUEST=GetMap&SERVICE=WMS&VERSIO
> N=1.1.1&WIDTH=864&HEIGHT=662&LAYERS=default&TRANSPARENT=TRUE&FORMAT=applicat
> ion/x-pdf&BBOX=3409763.750050978,6956187.032331026,3411904.266676571,6957827
> .104097395&SRS=EPSG:2393&STYLES=
>>>>
>>>> However, if I double the bounding box the resulting pdf cannot be opened
> by Acrobat reader.
>>>>
> http://188.64.1.61/cgi-bin/osm-mapserver_i?REQUEST=GetMap&SERVICE=WMS&VERSIO
> N=1.1.1&WIDTH=1728&HEIGHT=1324&LAYERS=default&TRANSPARENT=TRUE&FORMAT=applic
> ation/x-pdf&BBOX=3409763.750050978,6956187.032331026,3411904.266676571,69578
> 27.104097395&SRS=EPSG:2393&STYLES=
>>>>
>>>> The latter gives fine image with format=image/png. Any idea about what
> is going wrong?
>>>>
>>>> -Jukka Rahkonen-___
>>>> mapserver-users mailing list
>>>> mapserver-users@lists.osgeo.org
>>>> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>>>>
>>>
>>
> ___
> mapserver-users mailing list
> mapserver-users@lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/mapserver-users
> -
> No virus found in this message.
> Checked by AVG - www.avg.com
> Version: 10.0.1392 / Virus Database: 1520/3841 - Release Date: 08/17/11
>
>
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] create hatch symbol with python mapscript?

2011-09-01 Thread thomas bonfort
You should also set the style size which is the spacing between hatches. It
should be larger than the style width.
Thomas
Le 1 sept. 2011 17:11, "Michael Schulz"  a
écrit :
> Hi,
>
> I just tried to create a hatch type symbol only thru python mapscript,
> but failed. Could someone have a quick look and discover what I might
> be missing?
>
> ...
> hatch = mapscript.symbolObj("hatch")
> hatch.type = mapscript.MS_SYMBOL_HATCH
> sindex = m.symbolset.appendSymbol(hatch)
> stylePoly.symbol = sindex
> stylePoly.width = 5
> stylePoly.angle = 45
> stylePoly.outlinecolor.setRGB(255,0,0)
> stylePoly.color.setRGB(0,255,0)
> lp.opacity = 50
> ...
>
> The layer is drawn with a complete fill at 50% opacity in green, but
> no hatching.
>
> Thanks, Michael
>
> --
> ---
> Michael Schulz
> ___
> mapserver-users mailing list
> mapserver-users@lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/mapserver-users
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] Crash on Labeling

2011-09-07 Thread thomas bonfort
Stuart,
please open a ticket and attach a minimal mapfile/testcase that
reproduces the issue.

--
thomas

On Wed, Sep 7, 2011 at 22:30,   wrote:
> I am labeling roads.  I have a class using the TEXT directive like so:
>
> TEXT 'Bus [NAME]'
>
> This is for a business loop and labels in the map correctly with the highway
> name in the place of [NAME].  I also have other "Loop"s.  I tried this for
> the other loops:
>
> TEXT 'Loop [NAME]'
>
> ...and I get the following label in the map:
>
> Loop [NAME]
>
> ...just like you see it, with brackets and all.  Then I did some
> experimenting.  When I try this in the config file:
>
> TEXT 'q [NAME]'
>
> ...the entire process crashes.  Yes, that's simply a 'q'.  Are there
> labeling issues in MapServer 6.0.1?  Because, I think I may have found some.
>  I'm using a custom built binary (MSVC 10) on Windows 7.
>
> Stuart Harlan
> ___
> mapserver-users mailing list
> mapserver-users@lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>
>
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] Re: MapScript WMS request

2011-09-08 Thread thomas bonfort
it goes in map->web->metadata


On Thu, Sep 8, 2011 at 19:48, Mr. Puneet Kishor  wrote:
> a bit more investigation on producing a WMS response via Perl MapScript 
> reveals the following error
>
>  
>   "http://schemas.opengis.net/wms/1.1.0/exception_1_1_0.dtd";>
>  
>  
>  msWMSDispatch(): WMS server error. WMS request not enabled. Check 
> wms/ows_enable_request settings.
>  
>  
>
> So, it seems I have to somehow, somewhere enable 'ows_enable_request'. 
> Looking at the documentation, seems like if I had a map file, I could add the 
> following line to do so
>
>  ows_enable_request '*'
>
> However, I am not using a map file at all. Not finding any documentation on 
> this setting, I tried the following to no avail
>
>  $map->{ows_enable_request} = '*';
>
>
> Suggestions, anyone?
>
>
> On Sep 7, 2011, at 10:18 PM, Mr. Puneet Kishor wrote:
>
>> I would really appreciate insight from someone well-versed in the ins and 
>> outs of WMS via MapScript. Looking at the discussion at 
>> [http://trac.osgeo.org/mapserver/ticket/670], the `img = wms_map.draw()` 
>> step seems to be a crucial part of drawing the image.
>>
>> So, I added `my $img = $map->draw();` to my code below, and indeed, the 
>> image was drawn and sent back to the browser.
>>
>> Is this something that should be added to the examples in the documentation? 
>> Is this the right way to do things? In any case, I am not write to STDOUT, 
>> and sending the buffer directly. Instead, my code is very much like a 
>> regular request (and it works) --
>>
>>    my $new_extent = $map->{extent};
>>
>>    my $req = new mapscript::OWSRequest();
>>    $req->setParameter( "SERVICE", "WMS" );
>>    $req->setParameter( "VERSION", "1.1.0" );
>>    $req->setParameter( "REQUEST", "GetMap" );
>>    $req->setParameter( "BBOX", "-180,-90,180,90" );
>>    $req->setParameter( "LAYERS", "layer_name");
>>    $req->setParameter( "SRS", "-1");
>>    $req->setParameter( "WIDTH", "1200");
>>    $req->setParameter( "HEIGHT", "600");
>>
>>    my $dispatch_out = $map->OWSDispatch( $req );
>>    my $img = $map->draw();
>>    my $map_img = 'test_' . sprintf("%0.10d", rand(10)) . '.png';
>>    $img->save("/path/to/$map_img");
>>    return send_file("/path/to/$map_img");
>>
>>
>> Comments? Corrections?
>>
>>
>> On Sep 7, 2011, at 6:12 PM, Mr. Puneet Kishor wrote:
>>
>>>
>>> On Sep 7, 2011, at 5:49 PM, Mr. Puneet Kishor wrote:
>>>
 I am trying to convert my MapScript program to a WMS responder. I create 
 my $map where I set all the layers and classes and colors, etc, just like 
 for a normal, non-WMS request that works perfectly correctly.

 my $map = undef;
 $map = mapObj(name => 'mymap') unless defined $map;

 my $req = new mapscript::OWSRequest();
 $req->setParameter( "SERVICE", "WMS" );
 $req->setParameter( "VERSION", "1.1.0" );
 $req->setParameter( "REQUEST", "GetCapabilities" );
>>>
>>> I changed the above line to
>>>
>>>  $req->setParameter( "REQUEST", "GetMap");
>>>
>>> but, still no improvement.
>>>
>>>

 mapscript::msIO_installStdoutToBuffer();
 my $dispatch_out = $map->OWSDispatch( $req );
 printf "%s\n", mapscript::msIO_getStdoutBufferString();

 Except, the above doesn't really do anything for me. I get nothing in my 
 browser. Suggestions?


 --
 Puneet Kishor
>>>
>>
>
> ___
> mapserver-users mailing list
> mapserver-users@lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] Re: MapScript WMS request

2011-09-08 Thread thomas bonfort
someone else might, I don't use mapscript

On Thu, Sep 8, 2011 at 20:05, Mr. Puneet Kishor  wrote:
>
> On Sep 8, 2011, at 1:03 PM, thomas bonfort wrote:
>
>> it goes in map->web->metadata
>>
>
> I guessed as much, but I can't fathom the syntax. The webObj doesn't seem to 
> have any constructor, and I don't see any documentation. Could you please 
> point me to an example?
>
>
>
>>
>> On Thu, Sep 8, 2011 at 19:48, Mr. Puneet Kishor  wrote:
>>> a bit more investigation on producing a WMS response via Perl MapScript 
>>> reveals the following error
>>>
>>>  
>>>  >> "http://schemas.opengis.net/wms/1.1.0/exception_1_1_0.dtd";>
>>>  
>>>  
>>>  msWMSDispatch(): WMS server error. WMS request not enabled. Check 
>>> wms/ows_enable_request settings.
>>>  
>>>  
>>>
>>> So, it seems I have to somehow, somewhere enable 'ows_enable_request'. 
>>> Looking at the documentation, seems like if I had a map file, I could add 
>>> the following line to do so
>>>
>>>  ows_enable_request '*'
>>>
>>> However, I am not using a map file at all. Not finding any documentation on 
>>> this setting, I tried the following to no avail
>>>
>>>  $map->{ows_enable_request} = '*';
>>>
>>>
>>> Suggestions, anyone?
>>>
>>>
>>> On Sep 7, 2011, at 10:18 PM, Mr. Puneet Kishor wrote:
>>>
>>>> I would really appreciate insight from someone well-versed in the ins and 
>>>> outs of WMS via MapScript. Looking at the discussion at 
>>>> [http://trac.osgeo.org/mapserver/ticket/670], the `img = wms_map.draw()` 
>>>> step seems to be a crucial part of drawing the image.
>>>>
>>>> So, I added `my $img = $map->draw();` to my code below, and indeed, the 
>>>> image was drawn and sent back to the browser.
>>>>
>>>> Is this something that should be added to the examples in the 
>>>> documentation? Is this the right way to do things? In any case, I am not 
>>>> write to STDOUT, and sending the buffer directly. Instead, my code is very 
>>>> much like a regular request (and it works) --
>>>>
>>>>    my $new_extent = $map->{extent};
>>>>
>>>>    my $req = new mapscript::OWSRequest();
>>>>    $req->setParameter( "SERVICE", "WMS" );
>>>>    $req->setParameter( "VERSION", "1.1.0" );
>>>>    $req->setParameter( "REQUEST", "GetMap" );
>>>>    $req->setParameter( "BBOX", "-180,-90,180,90" );
>>>>    $req->setParameter( "LAYERS", "layer_name");
>>>>    $req->setParameter( "SRS", "-1");
>>>>    $req->setParameter( "WIDTH", "1200");
>>>>    $req->setParameter( "HEIGHT", "600");
>>>>
>>>>    my $dispatch_out = $map->OWSDispatch( $req );
>>>>    my $img = $map->draw();
>>>>    my $map_img = 'test_' . sprintf("%0.10d", rand(10)) . '.png';
>>>>    $img->save("/path/to/$map_img");
>>>>    return send_file("/path/to/$map_img");
>>>>
>>>>
>>>> Comments? Corrections?
>>>>
>>>>
>>>> On Sep 7, 2011, at 6:12 PM, Mr. Puneet Kishor wrote:
>>>>
>>>>>
>>>>> On Sep 7, 2011, at 5:49 PM, Mr. Puneet Kishor wrote:
>>>>>
>>>>>> I am trying to convert my MapScript program to a WMS responder. I create 
>>>>>> my $map where I set all the layers and classes and colors, etc, just 
>>>>>> like for a normal, non-WMS request that works perfectly correctly.
>>>>>>
>>>>>> my $map = undef;
>>>>>> $map = mapObj(name => 'mymap') unless defined $map;
>>>>>>
>>>>>> my $req = new mapscript::OWSRequest();
>>>>>> $req->setParameter( "SERVICE", "WMS" );
>>>>>> $req->setParameter( "VERSION", "1.1.0" );
>>>>>> $req->setParameter( "REQUEST", "GetCapabilities" );
>>>>>
>>>>> I changed the above line to
>>>>>
>>>>>  $req->setParameter( "REQUEST", "GetMap");
>>>>>
>>>>> but, still no improvement.
>>>>>
>>>>>
>>>>>>
>>>>>> mapscript::msIO_installStdoutToBuffer();
>>>>>> my $dispatch_out = $map->OWSDispatch( $req );
>>>>>> printf "%s\n", mapscript::msIO_getStdoutBufferString();
>>>>>>
>>>>>> Except, the above doesn't really do anything for me. I get nothing in my 
>>>>>> browser. Suggestions?
>>>>>>
>>>>>>
>>>>>> --
>>>>>> Puneet Kishor
>>>>>
>>>>
>>>
>>> ___
>>> mapserver-users mailing list
>>> mapserver-users@lists.osgeo.org
>>> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>>>
>
>
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] Problem compiling MapServer 6.0.1 with libpng

2011-09-12 Thread thomas bonfort
Can you check you are linking against the same version libpng library
as the png.h header (i.e. check you don't have multiple png versions
installed)

2011/9/12 Dejan Gambin :
> Hi,
>
> I am still unable to compiče mapserver 6.0.1. I can't find this function 
> (png_set_longjmpfn) defined anywhere. Can someone give me a clue? I am almost 
> sure I am doing some stupid mistake, but for me seems unsolvable :-(
>
> Thanks very much
>
> regards, dejan
> On 8. ruj. 2011., at 12:12, Dejan Gambin wrote:
>
>> Hi,
>>
>> After many trials and missings, I am still unable to compile MapServer 6.0.1 
>> (6.0.0 also) on my Debian Lenny machine.
>>
>> Here is the error I get:
>>
>> ./libmapserver.a(mapimageio.o): In function `savePalettePNG':
>> /home/dgambin/mapserver-6.0.1/mapimageio.c:274: undefined reference to 
>> `png_set_longjmp_fn'
>> ./libmapserver.a(mapimageio.o): In function `saveAsPNG':
>> /home/dgambin/mapserver-6.0.1/mapimageio.c:461: undefined reference to 
>> `png_set_longjmp_fn'
>> ./libmapserver.a(mapimageio.o): In function `readPNG':
>> /home/dgambin/mapserver-6.0.1/mapimageio.c:738: undefined reference to 
>> `png_set_longjmp_fn'
>> collect2: ld returned 1 exit status
>>
>>
>> Here is my configure:
>>
>> ./configure --with-ogr=/usr/local/bin/gdal-config 
>> --with-gdal=/usr/local/bin/gda
>> l-config --with-wfs --with-wfsclient --with-wmsclient --enable-debug 
>> --with-curl
>> -config=/usr/bin/curl-config --with-proj=/usr --with-jpeg 
>> --with-freetype=/usr/b
>> in/ --with-postgis=/usr/bin/pg_config --with-mysql=/usr/bin/mysql_config 
>> --with-
>> libiconv=/usr --with-kml=yes --with-php=/usr/include/php5 
>> --with-png=/usr/local
>>
>> Since I have system libpng 1.2.27-2, I downloaded and installed 1.5.4 and 
>> put "--with-png=/usr/local" in my configure file. But seems like it doesn't 
>> help. I also tried with 1.4.8. Stiil the same issue. Also tried without 
>> "--with-png=/usr/local" (so it should use system libpng)...nothing
>>
>> I have compiled using newest gdal 1.8.1. GDAL compiled ok with libpng 1.5.4.
>>
>> Am I doing something wrong?
>>
>> Thank you very much for any useful info
>>
>> regards, dejan___
>> mapserver-users mailing list
>> mapserver-users@lists.osgeo.org
>> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>
> ___
> mapserver-users mailing list
> mapserver-users@lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] Problem compiling MapServer 6.0.1 with libpng

2011-09-12 Thread thomas bonfort
can you try modifying mapimageio.c and replace
#include 
by
#include "/usr/local/include/png.h"

if you have both png 1.4 and 1.5 in /usr/local, you're asking for
trouble, make sure this is not the case

2011/9/12 Dejan Gambin :
> Hi Thomas
>
> Thanks for the help. As I said, I have system libpng installed in /usr/lib:
>
> dgambin@coin:~/mapserver-6.0.1$ dpkg -l libpng*
> Desired=Unknown/Install/Remove/Purge/Hold
> | Status=Not/Inst/Cfg-files/Unpacked/Failed-cfg/Half-inst/trig-aWait/Trig-pend
> |/ Err?=(none)/Hold/Reinst-required/X=both-problems (Status,Err: 
> uppercase=bad)
> ||/ Name           Version        Description
> +++-==-==-
> un  libpng-dev              (no description available)
> ii  libpng12-0     1.2.27-2+lenny PNG library - runtime
> un  libpng12-0-dev          (no description available)
> ii  libpng12-dev   1.2.27-2+lenny PNG library - development
> un  libpng2                 (no description available)
> un  libpng2-dev             (no description available)
> un  libpng3-dev             (no description available)
>
> dgambin@coin:~/mapserver-6.0.1$ ls -l /usr/lib/libpng*
> -rw-r--r-- 1 root root 243004 2011-07-25 00:16 /usr/lib/libpng12.a
> lrwxrwxrwx 1 root root     18 2011-09-09 13:29 /usr/lib/libpng12.so -> 
> libpng12.so.0.27.0
> lrwxrwxrwx 1 root root     18 2011-08-08 20:07 /usr/lib/libpng12.so.0 -> 
> libpng12.so.0.27.0
> -rw-r--r-- 1 root root 153224 2011-07-25 00:15 /usr/lib/libpng12.so.0.27.0
> lrwxrwxrwx 1 root root     10 2011-09-09 13:29 /usr/lib/libpng.a -> libpng12.a
> lrwxrwxrwx 1 root root     11 2011-09-09 13:29 /usr/lib/libpng.so -> 
> libpng12.so
>
>
>
> And I have libpng-1.5.4 installed in /usr/local/lib:
>
> dgambin@coin:~/mapserver-6.0.1$ ls -l /usr/local/lib/libpng*
> -rw-r--r-- 1 root staff 1051610 2011-09-09 13:09 /usr/local/lib/libpng15.a
> -rwxr-xr-x 1 root staff     934 2011-09-09 13:09 /usr/local/lib/libpng15.la
> lrwxrwxrwx 1 root staff      18 2011-09-09 13:09 /usr/local/lib/libpng15.so 
> -> libpng15.so.15.4.0
> lrwxrwxrwx 1 root staff      18 2011-09-09 13:09 
> /usr/local/lib/libpng15.so.15 -> libpng15.so.15.5.0
> -rwxr-xr-x 1 root staff  597897 2011-09-09 13:09 
> /usr/local/lib/libpng15.so.15.4.0
> lrwxrwxrwx 1 root staff      10 2011-09-09 13:09 /usr/local/lib/libpng.a -> 
> libpng15.a
> lrwxrwxrwx 1 root staff      11 2011-09-09 13:09 /usr/local/lib/libpng.la -> 
> libpng15.la
> lrwxrwxrwx 1 root staff      11 2011-09-09 13:09 /usr/local/lib/libpng.so -> 
> libpng15.so
>
>
> I made configure with --with-png=/usr/local
>
> Make fails in this:
>
> dgambin@coin:~/mapserver-6.0.1$ make
> g++ -g  -fPIC -Wall     -DHAVE_VSNPRINTF -DNEED_STRLCPY -DNEED_STRLCAT 
> -DNEED_STRRSTR           -DUSE_WMS_LYR -DUSE_WFS_LYR  -DUSE_LIBXML2 
> -DUSE_CURL -DUSE_CURLOPT_PROXYAUTH -DUSE_KML  -DUSE_WFS_SVR -DUSE_WMS_SVR  
> -DUSE_MYSQL -DUSE_POSTGIS -DPOSTGIS_HAS_SERVER_VERSION -DUSE_GDAL -DUSE_OGR   
> -DUSE_PROJ -DUSE_AGG_SVG_SYMBOLS    -DUSE_GD_GIF -DUSE_GD_PNG -DUSE_GD_JPEG 
> -DUSE_GD_WBMP -DUSE_GD_FT -DGD_HAS_FTEX_XSHOW -DGD_HAS_GDIMAGEGIFPTR 
> -DGD_HAS_GETBITMAPFONTS -DGD_HAS_GET_TRUE_COLOR_PIXEL -DUSE_ICONV -DUSE_GIF 
> -DUSE_PNG -DUSE_ZLIB -DUSE_FREETYPE   -DDISABLE_CVSID 
> -I/usr/include/freetype2  -I/usr/local//include   -I/usr/include 
> -Irenderers/agg/include    -I/usr/include   -I/usr/local/include 
> -I/usr/include/postgresql -I/usr/include/mysql  -DBIG_JOINS=1 -fPIC    
> -I/usr/include   -I/usr/include/libxml2   shp2img.o  -L. -lmapserver 
> -lfreetype -lz -lgd -L/usr/lib64 -lgd -ljpeg -lfreetype -lz -L/usr/local//lib 
> -lpng -lz -lXpm -lX11  -lexpat   -L/usr/lib64 -lproj -ljpeg -L/usr/local//lib 
> -lpng -lgif  -L/usr/local/lib -lgdal -L/usr/lib -lpq -L/usr/lib/mysql 
> -lmysqlclient -lmysqlclient -lcurl    -L/usr/lib -lc    -lz -lxml2  -lm 
> -lstdc++    -o shp2img
> ./libmapserver.a(mapimageio.o): In function `savePalettePNG':
> /home/dgambin/mapserver-6.0.1/mapimageio.c:274: undefined reference to 
> `png_set_longjmp_fn'
> ./libmapserver.a(mapimageio.o): In function `saveAsPNG':
> /home/dgambin/mapserver-6.0.1/mapimageio.c:461: undefined reference to 
> `png_set_longjmp_fn'
> ./libmapserver.a(mapimageio.o): In function `readPNG':
> /home/dgambin/mapserver-6.0.1/mapimageio.c:738: undefined reference to 
> `png_set_longjmp_fn'
> collect2: ld returned 1 exit status
>
> Is there anything wrong here? I'll send you anything else if needed :-)
>
> Thanks very much
>
> regards, dejan
>
>
> On 12. ruj. 2011., at 10:31, thomas bonfort wrote:
>
>> Can you check you are linking against the same version libpng library
>> as the

Re: [mapserver-users] Problem compiling MapServer 6.0.1 with libpng

2011-09-12 Thread thomas bonfort
2011/9/12 Dejan Gambin :
> It doesn't help :-(
>
>
> Here is the part of make compile statement with mapimageio.c, maybe this can 
> help you:
>
> gcc -c -g  -fPIC -Wall     -DHAVE_VSNPRINTF -DNEED_STRLCPY -DNEED_STRLCAT 
> -DNEED_STRRSTR           -DUSE_WMS_LYR -DUSE_WFS_LYR  -DUSE_LIBXML2 
> -DUSE_CURL -DUSE_CURLOPT_PROXYAUTH -DUSE_KML  -DUSE_WFS_SVR -DUSE_WMS_SVR  
> -DUSE_MYSQL -DUSE_POSTGIS -DPOSTGIS_HAS_SERVER_VERSION -DUSE_GDAL -DUSE_OGR   
> -DUSE_PROJ -DUSE_AGG_SVG_SYMBOLS    -DUSE_GD_GIF -DUSE_GD_PNG -DUSE_GD_JPEG 
> -DUSE_GD_WBMP -DUSE_GD_FT -DGD_HAS_FTEX_XSHOW -DGD_HAS_GDIMAGEGIFPTR 
> -DGD_HAS_GETBITMAPFONTS -DGD_HAS_GET_TRUE_COLOR_PIXEL -DUSE_ICONV -DUSE_GIF 
> -DUSE_PNG -DUSE_ZLIB -DUSE_FREETYPE   -DDISABLE_CVSID 
> -I/usr/include/freetype2  -I/usr/local/include   -I/usr/include 
> -Irenderers/agg/include    -I/usr/include   -I/usr/local/include 
> -I/usr/include/postgresql -I/usr/include/mysql  -DBIG_JOINS=1 -fPIC    
> -I/usr/include   -I/usr/include/libxml2   mapimageio.c -o mapimageio.o
>
>
> regards, dejan
>
> BTW, I don't have 1.4 installed, just 1.5.4. And system libpng in /usr/lib
as you had stated you tried with 1.4 I just wanted to make sure.

ok, last step before opening a ticket:

- revert mapimageio.c to its original state
- check the output of

 gcc -c -g  -fPIC -Wall     -DHAVE_VSNPRINTF -DNEED_STRLCPY
-DNEED_STRLCAT -DNEED_STRRSTR           -DUSE_WMS_LYR -DUSE_WFS_LYR
-DUSE_LIBXML2 -DUSE_CURL -DUSE_CURLOPT_PROXYAUTH -DUSE_KML
-DUSE_WFS_SVR -DUSE_WMS_SVR  -DUSE_MYSQL -DUSE_POSTGIS
-DPOSTGIS_HAS_SERVER_VERSION -DUSE_GDAL -DUSE_OGR   -DUSE_PROJ
-DUSE_AGG_SVG_SYMBOLS    -DUSE_GD_GIF -DUSE_GD_PNG -DUSE_GD_JPEG
-DUSE_GD_WBMP -DUSE_GD_FT -DGD_HAS_FTEX_XSHOW -DGD_HAS_GDIMAGEGIFPTR
-DGD_HAS_GETBITMAPFONTS -DGD_HAS_GET_TRUE_COLOR_PIXEL -DUSE_ICONV
-DUSE_GIF -DUSE_PNG -DUSE_ZLIB -DUSE_FREETYPE   -DDISABLE_CVSID
-I/usr/include/freetype2  -I/usr/local/include   -I/usr/include
-Irenderers/agg/include    -I/usr/include   -I/usr/local/include
-I/usr/include/postgresql -I/usr/include/mysql  -DBIG_JOINS=1 -fPIC
-I/usr/include   -I/usr/include/libxml2   mapimageio.c -M

for the location of png.h

- if png.h comes from /usr/local/include, open a ticket and assign it to me


>
>
> On 12. ruj. 2011., at 11:17, thomas bonfort wrote:
>
>> can you try modifying mapimageio.c and replace
>> #include 
>> by
>> #include "/usr/local/include/png.h"
>>
>> if you have both png 1.4 and 1.5 in /usr/local, you're asking for
>> trouble, make sure this is not the case
>>
>> 2011/9/12 Dejan Gambin :
>>> Hi Thomas
>>>
>>> Thanks for the help. As I said, I have system libpng installed in /usr/lib:
>>>
>>> dgambin@coin:~/mapserver-6.0.1$ dpkg -l libpng*
>>> Desired=Unknown/Install/Remove/Purge/Hold
>>> | 
>>> Status=Not/Inst/Cfg-files/Unpacked/Failed-cfg/Half-inst/trig-aWait/Trig-pend
>>> |/ Err?=(none)/Hold/Reinst-required/X=both-problems (Status,Err: 
>>> uppercase=bad)
>>> ||/ Name           Version        Description
>>> +++-==-==-
>>> un  libpng-dev              (no description available)
>>> ii  libpng12-0     1.2.27-2+lenny PNG library - runtime
>>> un  libpng12-0-dev          (no description available)
>>> ii  libpng12-dev   1.2.27-2+lenny PNG library - development
>>> un  libpng2                 (no description available)
>>> un  libpng2-dev             (no description available)
>>> un  libpng3-dev             (no description available)
>>>
>>> dgambin@coin:~/mapserver-6.0.1$ ls -l /usr/lib/libpng*
>>> -rw-r--r-- 1 root root 243004 2011-07-25 00:16 /usr/lib/libpng12.a
>>> lrwxrwxrwx 1 root root     18 2011-09-09 13:29 /usr/lib/libpng12.so -> 
>>> libpng12.so.0.27.0
>>> lrwxrwxrwx 1 root root     18 2011-08-08 20:07 /usr/lib/libpng12.so.0 -> 
>>> libpng12.so.0.27.0
>>> -rw-r--r-- 1 root root 153224 2011-07-25 00:15 /usr/lib/libpng12.so.0.27.0
>>> lrwxrwxrwx 1 root root     10 2011-09-09 13:29 /usr/lib/libpng.a -> 
>>> libpng12.a
>>> lrwxrwxrwx 1 root root     11 2011-09-09 13:29 /usr/lib/libpng.so -> 
>>> libpng12.so
>>>
>>>
>>>
>>> And I have libpng-1.5.4 installed in /usr/local/lib:
>>>
>>> dgambin@coin:~/mapserver-6.0.1$ ls -l /usr/local/lib/libpng*
>>> -rw-r--r-- 1 root staff 1051610 2011-09-09 13:09 /usr/local/lib/libpng15.a
>>> -rwxr-xr-x 1 root staff     934 2011-09-09 13:09 /usr/local/lib/libpng15.la
>>> lrwxrwxrwx 1 root staff      18 2011-09-09 13:09 /usr/local/lib/libpng15.so 
>>> -> libpng15.

Re: [mapserver-users] Problem compiling MapServer 6.0.1 with libpng

2011-09-12 Thread thomas bonfort
make sure you remove the "-o mapimageio.o" from the call

2011/9/12 Dejan Gambin :
> I get no output, just mapimageio.o generatedI'll try again...maybe some 
> other option...
>
> dejan
> On 12. ruj. 2011., at 11:45, thomas bonfort wrote:
>
>> 2011/9/12 Dejan Gambin :
>>> It doesn't help :-(
>>>
>>>
>>> Here is the part of make compile statement with mapimageio.c, maybe this 
>>> can help you:
>>>
>>> gcc -c -g  -fPIC -Wall     -DHAVE_VSNPRINTF -DNEED_STRLCPY -DNEED_STRLCAT 
>>> -DNEED_STRRSTR           -DUSE_WMS_LYR -DUSE_WFS_LYR  -DUSE_LIBXML2 
>>> -DUSE_CURL -DUSE_CURLOPT_PROXYAUTH -DUSE_KML  -DUSE_WFS_SVR -DUSE_WMS_SVR  
>>> -DUSE_MYSQL -DUSE_POSTGIS -DPOSTGIS_HAS_SERVER_VERSION -DUSE_GDAL -DUSE_OGR 
>>>   -DUSE_PROJ -DUSE_AGG_SVG_SYMBOLS    -DUSE_GD_GIF -DUSE_GD_PNG 
>>> -DUSE_GD_JPEG -DUSE_GD_WBMP -DUSE_GD_FT -DGD_HAS_FTEX_XSHOW 
>>> -DGD_HAS_GDIMAGEGIFPTR -DGD_HAS_GETBITMAPFONTS 
>>> -DGD_HAS_GET_TRUE_COLOR_PIXEL -DUSE_ICONV -DUSE_GIF -DUSE_PNG -DUSE_ZLIB 
>>> -DUSE_FREETYPE   -DDISABLE_CVSID -I/usr/include/freetype2  
>>> -I/usr/local/include   -I/usr/include -Irenderers/agg/include    
>>> -I/usr/include   -I/usr/local/include -I/usr/include/postgresql 
>>> -I/usr/include/mysql  -DBIG_JOINS=1 -fPIC    -I/usr/include   
>>> -I/usr/include/libxml2   mapimageio.c -o mapimageio.o
>>>
>>>
>>> regards, dejan
>>>
>>> BTW, I don't have 1.4 installed, just 1.5.4. And system libpng in /usr/lib
>> as you had stated you tried with 1.4 I just wanted to make sure.
>>
>> ok, last step before opening a ticket:
>>
>> - revert mapimageio.c to its original state
>> - check the output of
>>
>> gcc -c -g  -fPIC -Wall     -DHAVE_VSNPRINTF -DNEED_STRLCPY
>> -DNEED_STRLCAT -DNEED_STRRSTR           -DUSE_WMS_LYR -DUSE_WFS_LYR
>> -DUSE_LIBXML2 -DUSE_CURL -DUSE_CURLOPT_PROXYAUTH -DUSE_KML
>> -DUSE_WFS_SVR -DUSE_WMS_SVR  -DUSE_MYSQL -DUSE_POSTGIS
>> -DPOSTGIS_HAS_SERVER_VERSION -DUSE_GDAL -DUSE_OGR   -DUSE_PROJ
>> -DUSE_AGG_SVG_SYMBOLS    -DUSE_GD_GIF -DUSE_GD_PNG -DUSE_GD_JPEG
>> -DUSE_GD_WBMP -DUSE_GD_FT -DGD_HAS_FTEX_XSHOW -DGD_HAS_GDIMAGEGIFPTR
>> -DGD_HAS_GETBITMAPFONTS -DGD_HAS_GET_TRUE_COLOR_PIXEL -DUSE_ICONV
>> -DUSE_GIF -DUSE_PNG -DUSE_ZLIB -DUSE_FREETYPE   -DDISABLE_CVSID
>> -I/usr/include/freetype2  -I/usr/local/include   -I/usr/include
>> -Irenderers/agg/include    -I/usr/include   -I/usr/local/include
>> -I/usr/include/postgresql -I/usr/include/mysql  -DBIG_JOINS=1 -fPIC
>> -I/usr/include   -I/usr/include/libxml2   mapimageio.c -M
>>
>> for the location of png.h
>>
>> - if png.h comes from /usr/local/include, open a ticket and assign it to me
>>
>>
>>>
>>>
>>> On 12. ruj. 2011., at 11:17, thomas bonfort wrote:
>>>
>>>> can you try modifying mapimageio.c and replace
>>>> #include 
>>>> by
>>>> #include "/usr/local/include/png.h"
>>>>
>>>> if you have both png 1.4 and 1.5 in /usr/local, you're asking for
>>>> trouble, make sure this is not the case
>>>>
>>>> 2011/9/12 Dejan Gambin :
>>>>> Hi Thomas
>>>>>
>>>>> Thanks for the help. As I said, I have system libpng installed in 
>>>>> /usr/lib:
>>>>>
>>>>> dgambin@coin:~/mapserver-6.0.1$ dpkg -l libpng*
>>>>> Desired=Unknown/Install/Remove/Purge/Hold
>>>>> | 
>>>>> Status=Not/Inst/Cfg-files/Unpacked/Failed-cfg/Half-inst/trig-aWait/Trig-pend
>>>>> |/ Err?=(none)/Hold/Reinst-required/X=both-problems (Status,Err: 
>>>>> uppercase=bad)
>>>>> ||/ Name           Version        Description
>>>>> +++-==-==-
>>>>> un  libpng-dev              (no description available)
>>>>> ii  libpng12-0     1.2.27-2+lenny PNG library - runtime
>>>>> un  libpng12-0-dev          (no description available)
>>>>> ii  libpng12-dev   1.2.27-2+lenny PNG library - development
>>>>> un  libpng2                 (no description available)
>>>>> un  libpng2-dev             (no description available)
>>>>> un  libpng3-dev             (no description available)
>>>>>
>>>>> dgambin@coin:~/mapserver-6.0.1$ ls -l /usr/lib/libpng*
>>>>> -rw-r--r-- 1 root root 243004 2011-07-25 00:16 /usr/lib/libpng12.a
>>>>> lrwxr

Re: [mapserver-users] Problem compiling MapServer 6.0.1 with libpng

2011-09-12 Thread thomas bonfort
One last check: can you run the linker command with the "-t" option
and post the output

2011/9/12 Dejan Gambin :
> Here is the ticket I created:
>
> http://trac.osgeo.org/mapserver/ticket/4019
>
> regards, dejan
> On 12. ruj. 2011., at 11:45, thomas bonfort wrote:
>
>> 2011/9/12 Dejan Gambin :
>>> It doesn't help :-(
>>>
>>>
>>> Here is the part of make compile statement with mapimageio.c, maybe this 
>>> can help you:
>>>
>>> gcc -c -g  -fPIC -Wall     -DHAVE_VSNPRINTF -DNEED_STRLCPY -DNEED_STRLCAT 
>>> -DNEED_STRRSTR           -DUSE_WMS_LYR -DUSE_WFS_LYR  -DUSE_LIBXML2 
>>> -DUSE_CURL -DUSE_CURLOPT_PROXYAUTH -DUSE_KML  -DUSE_WFS_SVR -DUSE_WMS_SVR  
>>> -DUSE_MYSQL -DUSE_POSTGIS -DPOSTGIS_HAS_SERVER_VERSION -DUSE_GDAL -DUSE_OGR 
>>>   -DUSE_PROJ -DUSE_AGG_SVG_SYMBOLS    -DUSE_GD_GIF -DUSE_GD_PNG 
>>> -DUSE_GD_JPEG -DUSE_GD_WBMP -DUSE_GD_FT -DGD_HAS_FTEX_XSHOW 
>>> -DGD_HAS_GDIMAGEGIFPTR -DGD_HAS_GETBITMAPFONTS 
>>> -DGD_HAS_GET_TRUE_COLOR_PIXEL -DUSE_ICONV -DUSE_GIF -DUSE_PNG -DUSE_ZLIB 
>>> -DUSE_FREETYPE   -DDISABLE_CVSID -I/usr/include/freetype2  
>>> -I/usr/local/include   -I/usr/include -Irenderers/agg/include    
>>> -I/usr/include   -I/usr/local/include -I/usr/include/postgresql 
>>> -I/usr/include/mysql  -DBIG_JOINS=1 -fPIC    -I/usr/include   
>>> -I/usr/include/libxml2   mapimageio.c -o mapimageio.o
>>>
>>>
>>> regards, dejan
>>>
>>> BTW, I don't have 1.4 installed, just 1.5.4. And system libpng in /usr/lib
>> as you had stated you tried with 1.4 I just wanted to make sure.
>>
>> ok, last step before opening a ticket:
>>
>> - revert mapimageio.c to its original state
>> - check the output of
>>
>> gcc -c -g  -fPIC -Wall     -DHAVE_VSNPRINTF -DNEED_STRLCPY
>> -DNEED_STRLCAT -DNEED_STRRSTR           -DUSE_WMS_LYR -DUSE_WFS_LYR
>> -DUSE_LIBXML2 -DUSE_CURL -DUSE_CURLOPT_PROXYAUTH -DUSE_KML
>> -DUSE_WFS_SVR -DUSE_WMS_SVR  -DUSE_MYSQL -DUSE_POSTGIS
>> -DPOSTGIS_HAS_SERVER_VERSION -DUSE_GDAL -DUSE_OGR   -DUSE_PROJ
>> -DUSE_AGG_SVG_SYMBOLS    -DUSE_GD_GIF -DUSE_GD_PNG -DUSE_GD_JPEG
>> -DUSE_GD_WBMP -DUSE_GD_FT -DGD_HAS_FTEX_XSHOW -DGD_HAS_GDIMAGEGIFPTR
>> -DGD_HAS_GETBITMAPFONTS -DGD_HAS_GET_TRUE_COLOR_PIXEL -DUSE_ICONV
>> -DUSE_GIF -DUSE_PNG -DUSE_ZLIB -DUSE_FREETYPE   -DDISABLE_CVSID
>> -I/usr/include/freetype2  -I/usr/local/include   -I/usr/include
>> -Irenderers/agg/include    -I/usr/include   -I/usr/local/include
>> -I/usr/include/postgresql -I/usr/include/mysql  -DBIG_JOINS=1 -fPIC
>> -I/usr/include   -I/usr/include/libxml2   mapimageio.c -M
>>
>> for the location of png.h
>>
>> - if png.h comes from /usr/local/include, open a ticket and assign it to me
>>
>>
>>>
>>>
>>> On 12. ruj. 2011., at 11:17, thomas bonfort wrote:
>>>
>>>> can you try modifying mapimageio.c and replace
>>>> #include 
>>>> by
>>>> #include "/usr/local/include/png.h"
>>>>
>>>> if you have both png 1.4 and 1.5 in /usr/local, you're asking for
>>>> trouble, make sure this is not the case
>>>>
>>>> 2011/9/12 Dejan Gambin :
>>>>> Hi Thomas
>>>>>
>>>>> Thanks for the help. As I said, I have system libpng installed in 
>>>>> /usr/lib:
>>>>>
>>>>> dgambin@coin:~/mapserver-6.0.1$ dpkg -l libpng*
>>>>> Desired=Unknown/Install/Remove/Purge/Hold
>>>>> | 
>>>>> Status=Not/Inst/Cfg-files/Unpacked/Failed-cfg/Half-inst/trig-aWait/Trig-pend
>>>>> |/ Err?=(none)/Hold/Reinst-required/X=both-problems (Status,Err: 
>>>>> uppercase=bad)
>>>>> ||/ Name           Version        Description
>>>>> +++-==-==-
>>>>> un  libpng-dev              (no description available)
>>>>> ii  libpng12-0     1.2.27-2+lenny PNG library - runtime
>>>>> un  libpng12-0-dev          (no description available)
>>>>> ii  libpng12-dev   1.2.27-2+lenny PNG library - development
>>>>> un  libpng2                 (no description available)
>>>>> un  libpng2-dev             (no description available)
>>>>> un  libpng3-dev             (no description available)
>>>>>
>>>>> dgambin@coin:~/mapserver-6.0.1$ ls -l /usr/lib/libpng*
>>>>> -rw-r--r-- 1 root root 243004 2011-07-25 00:16 /usr/lib/libpng12.a
>&g

Re: [mapserver-users] Problem compiling MapServer 6.0.1 with libpng

2011-09-12 Thread thomas bonfort
type (/usr/lib64/libfreetype.so)
> -lz (/usr/lib64/libz.so)
> -lgd (/usr/lib64/libgd.so)
> -lgd (/usr/lib64/libgd.so)
> -ljpeg (/usr/lib64/libjpeg.so)
> -lfreetype (/usr/lib64/libfreetype.so)
> -lz (/usr/lib64/libz.so)
> -lpng (/usr/lib64/libpng.so)
> -lz (/usr/lib64/libz.so)
> -lXpm (/usr/lib64/libXpm.so)
> -lX11 (/usr/lib64/libX11.so)
> -lexpat (/usr/lib64/libexpat.so)
> -lproj (/usr/lib64/libproj.so)
> -ljpeg (/usr/lib64/libjpeg.so)
> -lpng (/usr/lib64/libpng.so)
> -lgif (/usr/lib64/libgif.so)
> -lgdal (/usr/local/lib/libgdal.so)
> -lpq (/usr/lib64/libpq.so)
> -lmysqlclient (/usr/lib64/libmysqlclient.so)
> -lmysqlclient (/usr/lib64/libmysqlclient.so)
> -lcurl (/usr/lib64/libcurl.so)
> -lz (/usr/lib64/libz.so)
> -lxml2 (/usr/lib64/libxml2.so)
> -lstdc++ (/usr/lib/gcc/x86_64-linux-gnu/4.3.2/libstdc++.so)
> -lstdc++ (/usr/lib/gcc/x86_64-linux-gnu/4.3.2/libstdc++.so)
> -lm (/usr/lib64/libm.so)
> /lib/libc.so.6
> (/usr/lib/libc_nonshared.a)elf-init.oS
> (/usr/lib/libc_nonshared.a)stat.oS
> /lib/ld-linux-x86-64.so.2
> -lgcc_s (/usr/lib/gcc/x86_64-linux-gnu/4.3.2/libgcc_s.so)
> /lib/libc.so.6
> /lib/ld-linux-x86-64.so.2
> -lgcc_s (/usr/lib/gcc/x86_64-linux-gnu/4.3.2/libgcc_s.so)
> /usr/lib/gcc/x86_64-linux-gnu/4.3.2/crtend.o
> /usr/lib/gcc/x86_64-linux-gnu/4.3.2/../../../../lib/crtn.o
> ./libmapserver.a(mapimageio.o): In function `savePalettePNG':
> /home/dgambin/mapserver-6.0.1/mapimageio.c:274: undefined reference to 
> `png_set_longjmp_fn'
> ./libmapserver.a(mapimageio.o): In function `saveAsPNG':
> /home/dgambin/mapserver-6.0.1/mapimageio.c:461: undefined reference to 
> `png_set_longjmp_fn'
> ./libmapserver.a(mapimageio.o): In function `readPNG':
> /home/dgambin/mapserver-6.0.1/mapimageio.c:738: undefined reference to 
> `png_set_longjmp_fn'
> /usr/bin/ld: link errors found, deleting executable `shp2img'
> collect2: ld returned 1 exit status
>
>
>
> On 12. ruj. 2011., at 12:10, thomas bonfort wrote:
>
>> One last check: can you run the linker command with the "-t" option
>> and post the output
>>
>> 2011/9/12 Dejan Gambin :
>>> Here is the ticket I created:
>>>
>>> http://trac.osgeo.org/mapserver/ticket/4019
>>>
>>> regards, dejan
>>> On 12. ruj. 2011., at 11:45, thomas bonfort wrote:
>>>
>>>> 2011/9/12 Dejan Gambin :
>>>>> It doesn't help :-(
>>>>>
>>>>>
>>>>> Here is the part of make compile statement with mapimageio.c, maybe this 
>>>>> can help you:
>>>>>
>>>>> gcc -c -g  -fPIC -Wall     -DHAVE_VSNPRINTF -DNEED_STRLCPY -DNEED_STRLCAT 
>>>>> -DNEED_STRRSTR           -DUSE_WMS_LYR -DUSE_WFS_LYR  -DUSE_LIBXML2 
>>>>> -DUSE_CURL -DUSE_CURLOPT_PROXYAUTH -DUSE_KML  -DUSE_WFS_SVR -DUSE_WMS_SVR 
>>>>>  -DUSE_MYSQL -DUSE_POSTGIS -DPOSTGIS_HAS_SERVER_VERSION -DUSE_GDAL 
>>>>> -DUSE_OGR   -DUSE_PROJ -DUSE_AGG_SVG_SYMBOLS    -DUSE_GD_GIF -DUSE_GD_PNG 
>>>>> -DUSE_GD_JPEG -DUSE_GD_WBMP -DUSE_GD_FT -DGD_HAS_FTEX_XSHOW 
>>>>> -DGD_HAS_GDIMAGEGIFPTR -DGD_HAS_GETBITMAPFONTS 
>>>>> -DGD_HAS_GET_TRUE_COLOR_PIXEL -DUSE_ICONV -DUSE_GIF -DUSE_PNG -DUSE_ZLIB 
>>>>> -DUSE_FREETYPE   -DDISABLE_CVSID -I/usr/include/freetype2  
>>>>> -I/usr/local/include   -I/usr/include -Irenderers/agg/include    
>>>>> -I/usr/include   -I/usr/local/include -I/usr/include/postgresql 
>>>>> -I/usr/include/mysql  -DBIG_JOINS=1 -fPIC    -I/usr/include   
>>>>> -I/usr/include/libxml2   mapimageio.c -o mapimageio.o
>>>>>
>>>>>
>>>>> regards, dejan
>>>>>
>>>>> BTW, I don't have 1.4 installed, just 1.5.4. And system libpng in /usr/lib
>>>> as you had stated you tried with 1.4 I just wanted to make sure.
>>>>
>>>> ok, last step before opening a ticket:
>>>>
>>>> - revert mapimageio.c to its original state
>>>> - check the output of
>>>>
>>>> gcc -c -g  -fPIC -Wall     -DHAVE_VSNPRINTF -DNEED_STRLCPY
>>>> -DNEED_STRLCAT -DNEED_STRRSTR           -DUSE_WMS_LYR -DUSE_WFS_LYR
>>>> -DUSE_LIBXML2 -DUSE_CURL -DUSE_CURLOPT_PROXYAUTH -DUSE_KML
>>>> -DUSE_WFS_SVR -DUSE_WMS_SVR  -DUSE_MYSQL -DUSE_POSTGIS
>>>> -DPOSTGIS_HAS_SERVER_VERSION -DUSE_GDAL -DUSE_OGR   -DUSE_PROJ
>>>> -DUSE_AGG_SVG_SYMBOLS    -DUSE_GD_GIF -DUSE_GD_PNG -DUSE_GD_JPEG
>>>> -DUSE_GD_WBMP -DUSE_GD_FT -DGD_HAS_FTEX_XSHOW -DGD_HAS_GDIMAGEGIFPTR
>>>> -DGD_HAS_GETBITM

Re: [mapserver-users] Problem compiling MapServer 6.0.1 with libpng

2011-09-12 Thread thomas bonfort
Note that even though this may make it compile, you might end up with
runtime errors as you are mixing png versions (gd is linked against
libpng from /usr/lib64)

you might try not using the system gd version, and compile your own
one using the png version of /usr/local

On Mon, Sep 12, 2011 at 12:21, thomas bonfort  wrote:
> it's using the libpng.so from /usr/lib64 instead of /usr/local
>
> try adding -L/usr/local/lib right after "-o shp2img.o"
>
> 2011/9/12 Dejan Gambin :
>> Is this ok?
>>
>> coin:/home/dgambin/mapserver-6.0.1# g++ -g -t -fPIC -Wall     
>> -DHAVE_VSNPRINTF -DNEED_STRLCPY -DNEED_STRLCAT -DNEED_STRRSTR           
>> -DUSE_WMS_LYR -DUSE_WFS_LYR  -DUSE_LIBXML2 -DUSE_CURL 
>> -DUSE_CURLOPT_PROXYAUTH -DUSE_KML  -DUSE_WFS_SVR -DUSE_WMS_SVR  -DUSE_MYSQL 
>> -DUSE_POSTGIS -DPOSTGIS_HAS_SERVER_VERSION -DUSE_GDAL -DUSE_OGR   -DUSE_PROJ 
>> -DUSE_AGG_SVG_SYMBOLS    -DUSE_GD_GIF -DUSE_GD_PNG -DUSE_GD_JPEG 
>> -DUSE_GD_WBMP -DUSE_GD_FT -DGD_HAS_FTEX_XSHOW -DGD_HAS_GDIMAGEGIFPTR 
>> -DGD_HAS_GETBITMAPFONTS -DGD_HAS_GET_TRUE_COLOR_PIXEL -DUSE_ICONV -DUSE_GIF 
>> -DUSE_PNG -DUSE_ZLIB -DUSE_FREETYPE   -DDISABLE_CVSID 
>> -I/usr/include/freetype2  -I/usr/local/include   -I/usr/include 
>> -Irenderers/agg/include    -I/usr/include   -I/usr/local/include 
>> -I/usr/include/postgresql -I/usr/include/mysql  -DBIG_JOINS=1 -fPIC    
>> -I/usr/include   -I/usr/include/libxml2   shp2img.o  -L. -lmapserver 
>> -lfreetype -lz -lgd -L/usr/lib64 -lgd -ljpeg -lfreetype -lz -L/usr/local/lib 
>> -lpng -lz -lXpm -lX11  -lexpat   -L/usr/lib64 -lproj -ljpeg -L/usr/local/lib 
>> -lpng -lgif  -L/usr/local/lib -lgdal -L/usr/lib -lpq -L/usr/lib/mysql 
>> -lmysqlclient -lmysqlclient -lcurl    -L/usr/lib -lc    -lz -lxml2  -lm 
>> -lstdc++    -o shp2img
>> /usr/bin/ld: mode elf_x86_64
>> /usr/lib/gcc/x86_64-linux-gnu/4.3.2/../../../../lib/crt1.o
>> /usr/lib/gcc/x86_64-linux-gnu/4.3.2/../../../../lib/crti.o
>> /usr/lib/gcc/x86_64-linux-gnu/4.3.2/crtbegin.o
>> shp2img.o
>> (./libmapserver.a)mapstring.o
>> (./libmapserver.a)mapfile.o
>> (./libmapserver.a)maputil.o
>> (./libmapserver.a)mapscale.o
>> (./libmapserver.a)mapquery.o
>> (./libmapserver.a)maplabel.o
>> (./libmapserver.a)maperror.o
>> (./libmapserver.a)mapprimitive.o
>> (./libmapserver.a)mapproject.o
>> (./libmapserver.a)mapogr.o
>> (./libmapserver.a)maplayer.o
>> (./libmapserver.a)maporaclespatial.o
>> (./libmapserver.a)mapdraw.o
>> (./libmapserver.a)mapoutput.o
>> (./libmapserver.a)mapgdal.o
>> (./libmapserver.a)mapimagemap.o
>> (./libmapserver.a)mapows.o
>> (./libmapserver.a)mapwfs.o
>> (./libmapserver.a)mapwfs11.o
>> (./libmapserver.a)mapwfslayer.o
>> (./libmapserver.a)maphttp.o
>> (./libmapserver.a)mapjoin.o
>> (./libmapserver.a)mapgraticule.o
>> (./libmapserver.a)mapcopy.o
>> (./libmapserver.a)mapogcfilter.o
>> (./libmapserver.a)maptime.o
>> (./libmapserver.a)cgiutil.o
>> (./libmapserver.a)maprasterquery.o
>> (./libmapserver.a)mapobject.o
>> (./libmapserver.a)mapio.o
>> (./libmapserver.a)mappool.o
>> (./libmapserver.a)mapregex.o
>> (./libmapserver.a)mappluginlayer.o
>> (./libmapserver.a)mappostgresql.o
>> (./libmapserver.a)mapcrypto.o
>> (./libmapserver.a)mapowscommon.o
>> (./libmapserver.a)maplibxml2.o
>> (./libmapserver.a)mapdebug.o
>>
>>
>> (./libmapserver.a)mapchart.o
>> (./libmapserver.a)mapkml.o
>> (./libmapserver.a)mapkmlrenderer.o
>> (./libmapserver.a)mapogroutput.o
>> (./libmapserver.a)mapogcfiltercommon.o
>> (./libmapserver.a)mapunion.o
>> (./libmapserver.a)mapcluster.o
>> (./libmapserver.a)mapdummyrenderer.o
>> (./libmapserver.a)mapogl.o
>> (./libmapserver.a)mapimageio.o
>> (./libmapserver.a)mapcairo.o
>> (./libmapserver.a)maprendering.o
>> (./libmapserver.a)mapgeomtransform.o
>> (./libmapserver.a)mapquantization.o
>> (./libmapserver.a)maptemplate.o
>> (./libmapserver.a)mapbits.o
>> (./libmapserver.a)maphash.o
>> (./libmapserver.a)mapshape.o
>> (./libmapserver.a)mapxbase.o
>> (./libmapserver.a)mapparser.o
>> (./libmapserver.a)maplexer.o
>> (./libmapserver.a)maptree.o
>> (./libmapserver.a)mapsearch.o
>> (./libmapserver.a)mapsymbol.o
>> (./libmapserver.a)maplegend.o
>> (./libmapserver.a)mapraster.o
>> (./libmapserver.a)mapsde.o
>> (./libmapserver.a)mappostgis.o
>> (./libmapserver.a)mapresample.o
>> (./libmapserver.a)mapwms.o
>> (./libmapserver.a)mapwmslayer.o
>> (./libmapserver.a)mapgml.o
>> (./libmapserver.a)mapprojhack.o
>> (./libmapserver.a)

Re: [mapserver-users] Problem compiling MapServer 6.0.1 with libpng

2011-09-12 Thread thomas bonfort
don't do that. recompile gd using the /usr/local libpng and
reconfigure mapserver with --with-gd=/usr/local

regards,
thomas


2011/9/12 Dejan Gambin :
> Thanks Thomas,
>
> I have suspection something might be related to gd but wasn't sure. Besides 
> this solution, where should I add this piece of code (-L/usr/local/lib) so it 
> get linked properly?
>
> dejan
> On 12. ruj. 2011., at 12:24, thomas bonfort wrote:
>
>> Note that even though this may make it compile, you might end up with
>> runtime errors as you are mixing png versions (gd is linked against
>> libpng from /usr/lib64)
>>
>> you might try not using the system gd version, and compile your own
>> one using the png version of /usr/local
>>
>> On Mon, Sep 12, 2011 at 12:21, thomas bonfort  
>> wrote:
>>> it's using the libpng.so from /usr/lib64 instead of /usr/local
>>>
>>> try adding -L/usr/local/lib right after "-o shp2img.o"
>>>
>>> 2011/9/12 Dejan Gambin :
>>>> Is this ok?
>>>>
>>>> coin:/home/dgambin/mapserver-6.0.1# g++ -g -t -fPIC -Wall     
>>>> -DHAVE_VSNPRINTF -DNEED_STRLCPY -DNEED_STRLCAT -DNEED_STRRSTR           
>>>> -DUSE_WMS_LYR -DUSE_WFS_LYR  -DUSE_LIBXML2 -DUSE_CURL 
>>>> -DUSE_CURLOPT_PROXYAUTH -DUSE_KML  -DUSE_WFS_SVR -DUSE_WMS_SVR  
>>>> -DUSE_MYSQL -DUSE_POSTGIS -DPOSTGIS_HAS_SERVER_VERSION -DUSE_GDAL 
>>>> -DUSE_OGR   -DUSE_PROJ -DUSE_AGG_SVG_SYMBOLS    -DUSE_GD_GIF -DUSE_GD_PNG 
>>>> -DUSE_GD_JPEG -DUSE_GD_WBMP -DUSE_GD_FT -DGD_HAS_FTEX_XSHOW 
>>>> -DGD_HAS_GDIMAGEGIFPTR -DGD_HAS_GETBITMAPFONTS 
>>>> -DGD_HAS_GET_TRUE_COLOR_PIXEL -DUSE_ICONV -DUSE_GIF -DUSE_PNG -DUSE_ZLIB 
>>>> -DUSE_FREETYPE   -DDISABLE_CVSID -I/usr/include/freetype2  
>>>> -I/usr/local/include   -I/usr/include -Irenderers/agg/include    
>>>> -I/usr/include   -I/usr/local/include -I/usr/include/postgresql 
>>>> -I/usr/include/mysql  -DBIG_JOINS=1 -fPIC    -I/usr/include   
>>>> -I/usr/include/libxml2   shp2img.o  -L. -lmapserver -lfreetype -lz -lgd 
>>>> -L/usr/lib64 -lgd -ljpeg -lfreetype -lz -L/usr/local/lib -lpng -lz -lXpm 
>>>> -lX11  -lexpat   -L/usr/lib64 -lproj -ljpeg -L/usr/local/lib -lpng -lgif  
>>>> -L/usr/local/lib -lgdal -L/usr/lib -lpq -L/usr/lib/mysql -lmysqlclient 
>>>> -lmysqlclient -lcurl    -L/usr/lib -lc    -lz -lxml2  -lm -lstdc++    -o 
>>>> shp2img
>>>> /usr/bin/ld: mode elf_x86_64
>>>> /usr/lib/gcc/x86_64-linux-gnu/4.3.2/../../../../lib/crt1.o
>>>> /usr/lib/gcc/x86_64-linux-gnu/4.3.2/../../../../lib/crti.o
>>>> /usr/lib/gcc/x86_64-linux-gnu/4.3.2/crtbegin.o
>>>> shp2img.o
>>>> (./libmapserver.a)mapstring.o
>>>> (./libmapserver.a)mapfile.o
>>>> (./libmapserver.a)maputil.o
>>>> (./libmapserver.a)mapscale.o
>>>> (./libmapserver.a)mapquery.o
>>>> (./libmapserver.a)maplabel.o
>>>> (./libmapserver.a)maperror.o
>>>> (./libmapserver.a)mapprimitive.o
>>>> (./libmapserver.a)mapproject.o
>>>> (./libmapserver.a)mapogr.o
>>>> (./libmapserver.a)maplayer.o
>>>> (./libmapserver.a)maporaclespatial.o
>>>> (./libmapserver.a)mapdraw.o
>>>> (./libmapserver.a)mapoutput.o
>>>> (./libmapserver.a)mapgdal.o
>>>> (./libmapserver.a)mapimagemap.o
>>>> (./libmapserver.a)mapows.o
>>>> (./libmapserver.a)mapwfs.o
>>>> (./libmapserver.a)mapwfs11.o
>>>> (./libmapserver.a)mapwfslayer.o
>>>> (./libmapserver.a)maphttp.o
>>>> (./libmapserver.a)mapjoin.o
>>>> (./libmapserver.a)mapgraticule.o
>>>> (./libmapserver.a)mapcopy.o
>>>> (./libmapserver.a)mapogcfilter.o
>>>> (./libmapserver.a)maptime.o
>>>> (./libmapserver.a)cgiutil.o
>>>> (./libmapserver.a)maprasterquery.o
>>>> (./libmapserver.a)mapobject.o
>>>> (./libmapserver.a)mapio.o
>>>> (./libmapserver.a)mappool.o
>>>> (./libmapserver.a)mapregex.o
>>>> (./libmapserver.a)mappluginlayer.o
>>>> (./libmapserver.a)mappostgresql.o
>>>> (./libmapserver.a)mapcrypto.o
>>>> (./libmapserver.a)mapowscommon.o
>>>> (./libmapserver.a)maplibxml2.o
>>>> (./libmapserver.a)mapdebug.o
>>>>
>>>>
>>>> (./libmapserver.a)mapchart.o
>>>> (./libmapserver.a)mapkml.o
>>>> (./libmapserver.a)mapkmlrenderer.o
>>>> (./libmapserver.a)mapogroutput.o
>>>> (./libmapser

Re: [mapserver-users] GEOMTRANSFORM not working on "notices"

2011-09-12 Thread thomas bonfort
On Mon, Sep 12, 2011 at 16:06, Flavio Hendry  wrote:
> Hi all
>
> A notice can be defined as follows (see http://mapserver.org/faq.html):
>
> LAYER
>  NAME "copyright"
>  STATUS ON
>  TYPE annotation
>  TRANSFORM ll #set the image origin to be lower left
>  FEATURE
>    POINTS
>      60 -10 #set the offset from lower left position in pixels
>    END
>    TEXT "Š xyz company 2006" #this is your displaying text
>  END
>  CLASS
>    LABEL #defines the font, colors etc. of the text
>      FONT "sans"
>      TYPE TRUETYPE
>      SIZE 8
>      BUFFER 1
>      COLOR 0 0 0
>      BACKGROUNDCOLOR 255 255 255
>      FORCE TRUE
>    END
>  END
>  UNITS PIXELS #sets the units for the feature object
> END
>
> BACKGROUNDCOLOR on labels is deprecated in V6 (who knows why ..., love this
> backward compatibility)

I guess the folks who spent some time implementing this know better
than you then... It's not like we are obliging you to upgrade, so this
disparaging attitude is not appreciated.


> ... and replaced by "GEOMTRANSFORM", therefore the
> new syntax is:
>
> LAYER
>  NAME "copyright"
>  STATUS ON
>  TYPE annotation
>  TRANSFORM ll #set the image origin to be lower left
>  FEATURE
>    POINTS
>      60 -10 #set the offset from lower left position in pixels
>    END
>    TEXT "Š xyz company 2006" #this is your displaying text
>  END
>  CLASS
>    LABEL #defines the font, colors etc. of the text
>      FONT "sans"
>      TYPE TRUETYPE
>      SIZE 8
>      BUFFER 1
>      COLOR 0 0 0
>        STYLE
>        GEOMTRANSFORM 'labelpoly'
>        COLOR 255 255 255
>        OUTLINECOLOR 255 0 0
>        WIDTH 10
>        END
>      FORCE TRUE
>    END
>  END
>  UNITS PIXELS #sets the units for the feature object
> END
>
> However, it does not work .

what does "not work" mean? those keywords mean you are drawing a very
thick red outline around the polygon, is that intended?

--
Thomas

>
> Mit freundlichem Gruss / Best regards
> Flavio Hendry
>
> 
> TYDAC Inc.  - http://www.tydac.ch
> Web Mapping - http://www.mapserver.ch
> Swiss Maps  - http://www.mapplus.ch
> 
>       Mit freundlichen Gruessen / Kind Regards
>      Flavio Hendry, CEO - mailto:fla...@tydac.ch
>          TYDAC AG - http://www.tydac.ch
>             Geographic Information Solutions
>            Optingenstrasse 27 -- CH-3013 Bern
>    Tel +41 (0)31 368 0180 - Fax +41 (0)31 368 1860
> 
>   Location: http://www.mapplus.ch/adr/bern/optingenstrasse/27
> 
>
> ___
> mapserver-users mailing list
> mapserver-users@lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] GEOMTRANSFORM not working on "notices"

2011-09-12 Thread thomas bonfort
I have just tried your exact same layer and the output is correct and
attached to this email

--
thomas

On Mon, Sep 12, 2011 at 16:29, thomas bonfort  wrote:
> On Mon, Sep 12, 2011 at 16:06, Flavio Hendry  wrote:
>> Hi all
>>
>> A notice can be defined as follows (see http://mapserver.org/faq.html):
>>
>> LAYER
>>  NAME "copyright"
>>  STATUS ON
>>  TYPE annotation
>>  TRANSFORM ll #set the image origin to be lower left
>>  FEATURE
>>    POINTS
>>      60 -10 #set the offset from lower left position in pixels
>>    END
>>    TEXT "Š xyz company 2006" #this is your displaying text
>>  END
>>  CLASS
>>    LABEL #defines the font, colors etc. of the text
>>      FONT "sans"
>>      TYPE TRUETYPE
>>      SIZE 8
>>      BUFFER 1
>>      COLOR 0 0 0
>>      BACKGROUNDCOLOR 255 255 255
>>      FORCE TRUE
>>    END
>>  END
>>  UNITS PIXELS #sets the units for the feature object
>> END
>>
>> BACKGROUNDCOLOR on labels is deprecated in V6 (who knows why ..., love this
>> backward compatibility)
> 
> I guess the folks who spent some time implementing this know better
> than you then... It's not like we are obliging you to upgrade, so this
> disparaging attitude is not appreciated.
> 
>
>> ... and replaced by "GEOMTRANSFORM", therefore the
>> new syntax is:
>>
>> LAYER
>>  NAME "copyright"
>>  STATUS ON
>>  TYPE annotation
>>  TRANSFORM ll #set the image origin to be lower left
>>  FEATURE
>>    POINTS
>>      60 -10 #set the offset from lower left position in pixels
>>    END
>>    TEXT "Š xyz company 2006" #this is your displaying text
>>  END
>>  CLASS
>>    LABEL #defines the font, colors etc. of the text
>>      FONT "sans"
>>      TYPE TRUETYPE
>>      SIZE 8
>>      BUFFER 1
>>      COLOR 0 0 0
>>        STYLE
>>        GEOMTRANSFORM 'labelpoly'
>>        COLOR 255 255 255
>>        OUTLINECOLOR 255 0 0
>>        WIDTH 10
>>        END
>>      FORCE TRUE
>>    END
>>  END
>>  UNITS PIXELS #sets the units for the feature object
>> END
>>
>> However, it does not work .
>
> what does "not work" mean? those keywords mean you are drawing a very
> thick red outline around the polygon, is that intended?
>
> --
> Thomas
>
>>
>> Mit freundlichem Gruss / Best regards
>> Flavio Hendry
>>
>> 
>> TYDAC Inc.  - http://www.tydac.ch
>> Web Mapping - http://www.mapserver.ch
>> Swiss Maps  - http://www.mapplus.ch
>> 
>>       Mit freundlichen Gruessen / Kind Regards
>>      Flavio Hendry, CEO - mailto:fla...@tydac.ch
>>          TYDAC AG - http://www.tydac.ch
>>             Geographic Information Solutions
>>            Optingenstrasse 27 -- CH-3013 Bern
>>    Tel +41 (0)31 368 0180 - Fax +41 (0)31 368 1860
>> 
>>   Location: http://www.mapplus.ch/adr/bern/optingenstrasse/27
>> 
>>
>> ___
>> mapserver-users mailing list
>> mapserver-users@lists.osgeo.org
>> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>>
>
<>___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] 'dot' only features that are labeled

2011-09-12 Thread thomas bonfort
you're looking for TYPE ANNOTATION layer.

--
thomas

On Mon, Sep 12, 2011 at 20:00, Charlton Galvarino  wrote:
> Hi, MS-ers.  Good luck to those of you who are in Denver this week.  For the 
> rest of us working away back home, I have a quick Q.  Probably even a rookie 
> Q.
>
> I have a nice LABEL in a POINT CLASS that draws beautifully.  FORCE is *not* 
> set to TRUE, so no labels get clobbered.  Tiling is a snap.  But I'd like to 
> show the feature dots for those things that are labeled and not the bazillion 
> other points w/i that tile that aren't.  So simply putting a SYMBOL and a 
> COLOR alongside the LABEL doesn't work because it gladly draws all the dots.  
> I'm looking for a way to tie the drawing of a LABEL w/ the drawing of its 
> dot.  Any way to do that?
>
> TIA.
>
>
>
>
>
> Charlton Galvarino
> 1 (803) 233-6205 : voice
> 1 (803) 223-9579 :   fax
> charl...@2creek.com
>
> P.O. Box 50960
> Columbia, SC 29250
>
> ___
> mapserver-users mailing list
> mapserver-users@lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] recommended tile caching mechanism with `mode=tile`

2011-09-18 Thread thomas bonfort
On Sun, Sep 18, 2011 at 08:08, Mr. Puneet Kishor  wrote:
>
> On Sep 17, 2011, at 11:43 PM, Daniel Morissette wrote:
>
>> On 11-09-18 12:08 AM, Mr. Puneet Kishor wrote:
>>> I am using MapServer cgi with `mode=tile` with a Google Maps front-end, and 
>>> am wondering what is a recommended tile cache server.
>>>
>>> Any suggestions from personal experience?
>>>
>>
>> MapServer MapCache of course! It is a fully featured, robust and fast tiling 
>> server. Only available in MapServer SVN trunk at the moment.
>>
>> http://mapserver.org/trunk/mapcache/
>>
>> It was formerly known as Mod-Geocache until a few weeks ago... the website 
>> is in the process of being migrated to the above URL, but in the meantime 
>> you can still reach the old site:
>>
>> http://code.google.com/p/mod-geocache/
>>
>
>
> Very nice. I look forward to installing this; hopefully, it will be 
> straightforward.
>
> A couple of questions --
>
> 1. I was looking at mod_cache (mod_disk_cache and mod_mem_cache) yesterday 
> and wondering if they could be used to cache the images. Is mod_geocache 
> inspired/based on those modules?
As already stated by Mike, there's quite a bit of geo related
intermediary glue code that translates the incoming request into the
actual name of the tile as stored on the system, which makes the
module much more specific than the mod_*_cache existing modules.
There is a memcached storage backend for mapcache, but speed of access
to the tile data is not a use-case that it shines at: it is slower
than disk based caches, but allows the automatic expiring of tiles
based on their creation date.

>
> 2. Why wed this to Apache? By making it web-server agnostic, you open up the 
> audience.
c.f. the fastcgi implementation. cgi is not a recommended setup.

--
thomas

>
>
> Puneet.
>
> ___
> mapserver-users mailing list
> mapserver-users@lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] recommended tile caching mechanism with `mode=tile`

2011-09-18 Thread thomas bonfort
There are no known limitations in running on windows, as it is based
largely on the cross-platform apr library. That said, I have
absolutely no idea on how to build stuff on windows, and so the build
files will have to be contributed before things can start moving on
that platform.

regards,
--
thomas

On Sun, Sep 18, 2011 at 10:52, John Callahan  wrote:
> I'm sure lots of people are very interested in this topic.  Very nice.   I'm
> assuming at some point MapServer MapCache will be supported on the Windows
> platform.  (IIRC, I do not believe mod-geocache is supported there.)   Is
> that true and can the current trunk be built on Windows?
> - John
>
>
>
>
> On Sun, Sep 18, 2011 at 11:02 AM, thomas bonfort 
> wrote:
>>
>> On Sun, Sep 18, 2011 at 08:08, Mr. Puneet Kishor 
>> wrote:
>> >
>> > On Sep 17, 2011, at 11:43 PM, Daniel Morissette wrote:
>> >
>> >> On 11-09-18 12:08 AM, Mr. Puneet Kishor wrote:
>> >>> I am using MapServer cgi with `mode=tile` with a Google Maps
>> >>> front-end, and am wondering what is a recommended tile cache server.
>> >>>
>> >>> Any suggestions from personal experience?
>> >>>
>> >>
>> >> MapServer MapCache of course! It is a fully featured, robust and fast
>> >> tiling server. Only available in MapServer SVN trunk at the moment.
>> >>
>> >> http://mapserver.org/trunk/mapcache/
>> >>
>> >> It was formerly known as Mod-Geocache until a few weeks ago... the
>> >> website is in the process of being migrated to the above URL, but in the
>> >> meantime you can still reach the old site:
>> >>
>> >> http://code.google.com/p/mod-geocache/
>> >>
>> >
>> >
>> > Very nice. I look forward to installing this; hopefully, it will be
>> > straightforward.
>> >
>> > A couple of questions --
>> >
>> > 1. I was looking at mod_cache (mod_disk_cache and mod_mem_cache)
>> > yesterday and wondering if they could be used to cache the images. Is
>> > mod_geocache inspired/based on those modules?
>> As already stated by Mike, there's quite a bit of geo related
>> intermediary glue code that translates the incoming request into the
>> actual name of the tile as stored on the system, which makes the
>> module much more specific than the mod_*_cache existing modules.
>> There is a memcached storage backend for mapcache, but speed of access
>> to the tile data is not a use-case that it shines at: it is slower
>> than disk based caches, but allows the automatic expiring of tiles
>> based on their creation date.
>>
>> >
>> > 2. Why wed this to Apache? By making it web-server agnostic, you open up
>> > the audience.
>> c.f. the fastcgi implementation. cgi is not a recommended setup.
>>
>> --
>> thomas
>>
>> >
>> >
>> > Puneet.
>> >
>> > ___
>> > mapserver-users mailing list
>> > mapserver-users@lists.osgeo.org
>> > http://lists.osgeo.org/mailman/listinfo/mapserver-users
>> >
>> ___
>> mapserver-users mailing list
>> mapserver-users@lists.osgeo.org
>> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>
>
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] installing and configuring mapcache

2011-09-18 Thread thomas bonfort
On Sun, Sep 18, 2011 at 11:23, Mr. Puneet Kishor  wrote:
> installation mostly went well except for pixman. The install docs say, I 
> should have the following incantation
>
>        --with-pixman=[yes|no|/path/to/pkgconfig/pixman.pc]
>
> I installed pixman and have the following
>
> $ll /opt/local/include/pix*
> total 88
> -rw-r--r--  1 root  admin   1739 Sep 18 11:35 pixman-version.h
> -rw-r--r--  1 root  admin  39608 Sep 18 11:35 pixman.h
>
> $ll /opt/local/lib/libpix*
> -rwxr-xr-x  1 root  admin  474024 Sep 18 11:35 
> /opt/local/lib/libpixman-1.0.22.2.dylib*
> lrwxr-xr-x  1 root  admin      24 Sep 18 11:35 
> /opt/local/lib/libpixman-1.0.dylib@ -> libpixman-1.0.22.2.dylib
> -rw-r--r--  1 root  admin  550432 Sep 18 11:35 /opt/local/lib/libpixman-1.a
> lrwxr-xr-x  1 root  admin      24 Sep 18 11:35 
> /opt/local/lib/libpixman-1.dylib@ -> libpixman-1.0.22.2.dylib
> -rwxr-xr-x  1 root  admin     866 Sep 18 11:35 /opt/local/lib/libpixman-1.la*
>
>
> I am not sure where I would find this pitman.pc. I tried configure-ing with 
> `--with-pixman=/opt/local` but no luck. Suggestions on how I could include 
> pixman?

/opt/local/lib/pkgconfig/pixman-1.pc

>
> Anyway, in the meantime, I dropped pixman support and configured 
> successfully. `make` and `sudo make install-module` added the module to my 
> httpd.conf. But, now I am lost again. Per the docs
>
> ---
> Next, a geocache configuration is mapped to the server url with the following 
> snippet
>
> 
>    
>       Order Allow,Deny
>       Allow from all
>    
>    GeoCacheAlias /geocache "/path/to/directory/geocache.xml"
> 
> ---
>
> I can't really parse the above. What is the `path/to/directory` in  ...>? I have the `geocache.xml` in my mapcache src tree; Should I place it 
> somewhere special? Is this `path/to/directory` where the tiles are stored?

it points to the place where the mapcache.xml file is stored. It can
be anywhere accessible by the user that is launching the apache
server. It does not correspond to where the tiles are stored, as
that's configured in mapcache.xml. (the directory where tiles a re
stored should be readable/writable by the user *running* apache (c.f.
httpd.conf)

>
> And, finally, what should I do if I have the following mapserver URL where 
> tile.x, tile.y and zoom are inserted dynamically?
>
> http:///cgi-bin/mapcgi?layers=layer&mode=tile&tilemode=mapcgi&tile=' 
> + tile.x + '+' + tile.y + '+' + zoom

you have to give the url to the *wms* service, not the tile one, i.e.
http:///cgi-bin/mapcgi?map=foo.map

--
thomas

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


Re: [mapserver-users] recommended tile caching mechanism with `mode=tile`

2011-09-18 Thread thomas bonfort
To be a bit more precise, everything *except* blank tile linking
should work on windows, but that code is already ifdef'd out for win32
and so should not pose any build problem.

--
thomas

On Sun, Sep 18, 2011 at 12:41, thomas bonfort  wrote:
> There are no known limitations in running on windows, as it is based
> largely on the cross-platform apr library. That said, I have
> absolutely no idea on how to build stuff on windows, and so the build
> files will have to be contributed before things can start moving on
> that platform.
>
> regards,
> --
> thomas
>
> On Sun, Sep 18, 2011 at 10:52, John Callahan  wrote:
>> I'm sure lots of people are very interested in this topic.  Very nice.   I'm
>> assuming at some point MapServer MapCache will be supported on the Windows
>> platform.  (IIRC, I do not believe mod-geocache is supported there.)   Is
>> that true and can the current trunk be built on Windows?
>> - John
>>
>>
>>
>>
>> On Sun, Sep 18, 2011 at 11:02 AM, thomas bonfort 
>> wrote:
>>>
>>> On Sun, Sep 18, 2011 at 08:08, Mr. Puneet Kishor 
>>> wrote:
>>> >
>>> > On Sep 17, 2011, at 11:43 PM, Daniel Morissette wrote:
>>> >
>>> >> On 11-09-18 12:08 AM, Mr. Puneet Kishor wrote:
>>> >>> I am using MapServer cgi with `mode=tile` with a Google Maps
>>> >>> front-end, and am wondering what is a recommended tile cache server.
>>> >>>
>>> >>> Any suggestions from personal experience?
>>> >>>
>>> >>
>>> >> MapServer MapCache of course! It is a fully featured, robust and fast
>>> >> tiling server. Only available in MapServer SVN trunk at the moment.
>>> >>
>>> >> http://mapserver.org/trunk/mapcache/
>>> >>
>>> >> It was formerly known as Mod-Geocache until a few weeks ago... the
>>> >> website is in the process of being migrated to the above URL, but in the
>>> >> meantime you can still reach the old site:
>>> >>
>>> >> http://code.google.com/p/mod-geocache/
>>> >>
>>> >
>>> >
>>> > Very nice. I look forward to installing this; hopefully, it will be
>>> > straightforward.
>>> >
>>> > A couple of questions --
>>> >
>>> > 1. I was looking at mod_cache (mod_disk_cache and mod_mem_cache)
>>> > yesterday and wondering if they could be used to cache the images. Is
>>> > mod_geocache inspired/based on those modules?
>>> As already stated by Mike, there's quite a bit of geo related
>>> intermediary glue code that translates the incoming request into the
>>> actual name of the tile as stored on the system, which makes the
>>> module much more specific than the mod_*_cache existing modules.
>>> There is a memcached storage backend for mapcache, but speed of access
>>> to the tile data is not a use-case that it shines at: it is slower
>>> than disk based caches, but allows the automatic expiring of tiles
>>> based on their creation date.
>>>
>>> >
>>> > 2. Why wed this to Apache? By making it web-server agnostic, you open up
>>> > the audience.
>>> c.f. the fastcgi implementation. cgi is not a recommended setup.
>>>
>>> --
>>> thomas
>>>
>>> >
>>> >
>>> > Puneet.
>>> >
>>> > ___
>>> > mapserver-users mailing list
>>> > mapserver-users@lists.osgeo.org
>>> > http://lists.osgeo.org/mailman/listinfo/mapserver-users
>>> >
>>> ___
>>> mapserver-users mailing list
>>> mapserver-users@lists.osgeo.org
>>> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>>
>>
>
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] Text outline not working on line features

2011-09-20 Thread thomas bonfort
what mapserver version, what outputformat?
regardless, it should work with any version, are you sure that this is
the actual mapfile snippet that is being used ?

--
thomas

On Tue, Sep 20, 2011 at 18:45, Bistrais, Bob  wrote:
> I’m trying to draw and label road features from a shapefile.  I’d like to
> include an outline of the road name text as a halo.  This works fine on
> polygon and point features, but is not working for me with the line
> features.
>
>
>
> Here is the code block:
>
>
>
>         LABEL
>
>       ANGLE auto
>
>       PARTIALS false
>
>       FORCE false
>
>       MINDISTANCE 250
>
>       POSITION uc
>
>       COLOR 200 0 0
>
>       OUTLINECOLOR 255 255 255
>
>       OUTLINEWIDTH 5
>
>       FONT "verdana"
>
>       SIZE 12
>
>       TYPE truetype
>
>         END
>
>         TEXT ([RDNAME])
>
> ___
> mapserver-users mailing list
> mapserver-users@lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>
>
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] Limits on CLASS EXPRESSIONS for regular expressions

2011-09-21 Thread thomas bonfort
If I'm not mistaken, mapserver uses regex, which has a smaller
featureset than perl's regular expressions. Using pcre instead of
regex inside mapserver might solve your problem.

--
thomas

On Wed, Sep 21, 2011 at 06:29, Stephen Woodbridge
 wrote:
> Does anyone know if/what restrictions we have on regular expressions within
> mapserver. I have a perl regular expression that matches 44 of 120 counties
> in Kentucky:
>
> EXPRESSION
> /(?-xism:(?i:(?=[abcfghjlmnorstw])(?:b(?:o(?:y(?:d|le)|urbon)|u(?:llitt|tler)|(?:arr|rack)en)|c(?:a(?:rter|sey)|(?:hristia|rittende)n|lark)|f(?:ayette|leming|ulton)|h(?:a(?:ncock|rt)|enderson)|l(?:e(?:tcher|wis)|(?:incol|oga|yo)n)|m(?:a(?:di)?son|e(?:rcer|tcalfe)|o(?:ntgomery|rgan)|ccracken|uhlenberg)|s(?:helby|impson|pencer)|t(?:aylor|odd)|w(?:ayne|oodford)|adair|grant|johnson|nicholas|oldham|russell)))/
>
> This has been optimized and uses some embedded modifiers. This works fine in
> Perl but does not match anything in mapserver.
>
> Any thoughts on how to modify this to work with mapserver. While this looks
> very convoluted, it is generated from a list of words and is high efficient
> when matching.
>
> Thoughts?
>
> -Steve W
>
> PS: Using 5.6.x at the moment.
> ___
> mapserver-users mailing list
> mapserver-users@lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] Text outline not working on line features

2011-09-21 Thread thomas bonfort
The GD driver does not support the OUTLINEWIDTH keyword on labels, but
you should see a hard 1-pixel outline be applied to the text.

--
thomas

On Tue, Sep 20, 2011 at 22:56, Bistrais, Bob  wrote:
> This is an older version of MapServer, MS4W 2.3.1, MapServer 5.2.1.
>
> Using a global file with the outputformat params:
>
>        OUTPUTFORMAT
>                NAME 'agg/png'
>                DRIVER AGG/PNG
>                IMAGEMODE RGBA
>                FORMATOPTION "TRANSPARENT=TRUE"
>        END
>
>        OUTPUTFORMAT
>                NAME 'print'
>                DRIVER "GD/GIF"
>                MIMETYPE "image/gif"
>                IMAGEMODE PC256
>                EXTENSION "gif"
>                TRANSPARENT ON
>        END
>
> -So we're going to gif on the printout.
>
> Not sure what you meant by label output.  But here's what I see- on the
> web application, the labels are as they should be- they have the
> background halo.  On the printed map, the label text itself appears, but
> no background halo.
>
> Yes, I'm absolutely sure that's the code being used in the .map file.
>
>
> -Original Message-
> From: Stephen Woodbridge [mailto:wood...@swoodbridge.com]
> Sent: Tuesday, September 20, 2011 1:49 PM
> To: mapserver-users@lists.osgeo.org
> Subject: Re: [mapserver-users] Text outline not working on line features
>
> Bob,
>
> Also, what are you getting for label output in you case? More info would
>
> help diagnose this.
>
> Thanks,
> -Steve W
>
> On 9/20/2011 1:47 PM, thomas bonfort wrote:
>> what mapserver version, what outputformat?
>> regardless, it should work with any version, are you sure that this is
>> the actual mapfile snippet that is being used ?
>>
>> --
>> thomas
>>
>> On Tue, Sep 20, 2011 at 18:45, Bistrais, Bob
> wrote:
>>> I'm trying to draw and label road features from a shapefile.  I'd
> like to
>>> include an outline of the road name text as a halo.  This works fine
> on
>>> polygon and point features, but is not working for me with the line
>>> features.
>>>
>>>
>>>
>>> Here is the code block:
>>>
>>>
>>>
>>>                  LABEL
>>>
>>>                    ANGLE auto
>>>
>>>                    PARTIALS false
>>>
>>>                    FORCE false
>>>
>>>                    MINDISTANCE 250
>>>
>>>                    POSITION uc
>>>
>>>                    COLOR 200 0 0
>>>
>>>                    OUTLINECOLOR 255 255 255
>>>
>>>                    OUTLINEWIDTH 5
>>>
>>>                    FONT "verdana"
>>>
>>>                    SIZE 12
>>>
>>>                    TYPE truetype
>>>
>>>                  END
>>>
>>>                  TEXT ([RDNAME])
>>>
>>> ___
>>> mapserver-users mailing list
>>> mapserver-users@lists.osgeo.org
>>> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>>>
>>>
>>>
>>>
>>> ___
>>> mapserver-users mailing list
>>> mapserver-users@lists.osgeo.org
>>> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>
>
> ___
> mapserver-users mailing list
> mapserver-users@lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: Σχετ: [mapserver-users] Re: Mapserver 6 WMS / PostGIS Problem

2011-09-22 Thread thomas bonfort
When the request hangs, is it the mapserver process or the postgres
one that is eating all the cpu cycles ?

--
thomas

2011/9/22 Rahkonen Jukka :
> Hi,
>
> I can repeat this problem with Mapserver 6.0.1 on Windows Vista 32-bit.  I
> defined one PostGIS test layer without metadata and GetCapabilities fails
> after a long waiting. With DEBUG 5 the last line in MS_ERRORFILE that
> appears is this
> msPostGISLayerIsOpen called.
>
> Adding "wms_extent" corrects the situation.  Same mapfile does work on Linux
> and it used to work for me on Windows too with Mapserver 5.x.
>
> -Jukka Rahkonen-
>
> 
> Lähettäjä: Andreas Douvalis [mailto:anddre...@yahoo.gr]
> Lähetetty: 22. syyskuuta 2011 10:14
> Vastaanottaja: Rahkonen Jukka
> Aihe: Σχετ: [mapserver-users] Re: Mapserver 6 WMS / PostGIS Problem
>
> No problem with pgsql
> 
> 
> It takes 78 ms the sql of the layer that it doesn't work with wms get map
> request.
> Unfortunately  there is no debug error to check the query that mapserver
> runs.
> 
> Απο: Rahkonen Jukka 
> Προς: 'anddreas2' ; "'mapserver-users@lists.osgeo.org'"
> 
> Στάλθηκε: 9:32 π.μ. Πέμπτη, 22 Σεπτεμβρίου 2011
> Θεμα: Re: [mapserver-users] Re: Mapserver 6 WMS / PostGIS Problem
>
> Hi,
>
> Basically it means that the SQL query for getting the extents of your layer
> is slow.
> Set timing on with \timing on in your psql window and run query
> select st_extent(geom) from titles;
> http://postgis.refractions.net/docs/ST_Extent.html
> How long does it take? Do vacuum analyze for the table and try again to see
> if there has been some trouble with indexes.
> Anyway, it is always faster to get extents from the metadata line than from
> PostGIS, but normally it should not take very long. For me it takes 1500 ms
> with a table of 30 polygons.
>
> -Jukka Rahkonen-
>
>
>
>> -Alkuperäinen viesti-
>> Lähettäjä: mapserver-users-boun...@lists.osgeo.org
>> [mailto:mapserver-users-boun...@lists.osgeo.org] Puolesta anddreas2
>> Lähetetty: 22. syyskuuta 2011 8:52
>> Vastaanottaja: mapserver-users@lists.osgeo.org
>> Aihe: [mapserver-users] Re: Mapserver 6 WMS / PostGIS Problem
>>
>> I found the solution:
>>
>> Just set THE wms_extent METADATA in the layer section and it
>> works.  Without
>> Layers wms_extent it crashes.
>>
>> (Jesus, I spent three days of my life for this stupid thing.
>> I tested with
>> all versions of postgis (1.5, 1.4) postgresql (8.4,9.0,9.1).
>> I am think it
>> is ms4w problem).
>>
>> --
>> View this message in context:
>> http://osgeo-org.1803224.n2.nabble.com/Mapserver-6-WMS-PostGIS
>> -Problem-tp6387007p6819004.html
>> Sent from the Mapserver - User mailing list archive at Nabble.com.
>> ___
>> mapserver-users mailing list
>> mapserver-users@lists.osgeo.org
>> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>>
>
>
> ___
> mapserver-users mailing list
> mapserver-users@lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>
>
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] Text outline not working on line features

2011-09-22 Thread thomas bonfort
color yes, width not with GD.

--
thomas

On Thu, Sep 22, 2011 at 17:10, Bistrais, Bob  wrote:
> Yes, I think I see a white outline about 1 pixel.  Do I have any control over 
> that at all? (width and/or color)
>
> -Original Message-----
> From: thomas bonfort [mailto:thomas.bonf...@gmail.com]
> Sent: Wednesday, September 21, 2011 9:18 PM
> To: Bistrais, Bob
> Cc: Stephen Woodbridge; mapserver-users@lists.osgeo.org
> Subject: Re: [mapserver-users] Text outline not working on line features
>
> The GD driver does not support the OUTLINEWIDTH keyword on labels, but
> you should see a hard 1-pixel outline be applied to the text.
>
> --
> thomas
>
> On Tue, Sep 20, 2011 at 22:56, Bistrais, Bob  wrote:
>> This is an older version of MapServer, MS4W 2.3.1, MapServer 5.2.1.
>>
>> Using a global file with the outputformat params:
>>
>>        OUTPUTFORMAT
>>                NAME 'agg/png'
>>                DRIVER AGG/PNG
>>                IMAGEMODE RGBA
>>                FORMATOPTION "TRANSPARENT=TRUE"
>>        END
>>
>>        OUTPUTFORMAT
>>                NAME 'print'
>>                DRIVER "GD/GIF"
>>                MIMETYPE "image/gif"
>>                IMAGEMODE PC256
>>                EXTENSION "gif"
>>                TRANSPARENT ON
>>        END
>>
>> -So we're going to gif on the printout.
>>
>> Not sure what you meant by label output.  But here's what I see- on the
>> web application, the labels are as they should be- they have the
>> background halo.  On the printed map, the label text itself appears, but
>> no background halo.
>>
>> Yes, I'm absolutely sure that's the code being used in the .map file.
>>
>>
>> -Original Message-
>> From: Stephen Woodbridge [mailto:wood...@swoodbridge.com]
>> Sent: Tuesday, September 20, 2011 1:49 PM
>> To: mapserver-users@lists.osgeo.org
>> Subject: Re: [mapserver-users] Text outline not working on line features
>>
>> Bob,
>>
>> Also, what are you getting for label output in you case? More info would
>>
>> help diagnose this.
>>
>> Thanks,
>> -Steve W
>>
>> On 9/20/2011 1:47 PM, thomas bonfort wrote:
>>> what mapserver version, what outputformat?
>>> regardless, it should work with any version, are you sure that this is
>>> the actual mapfile snippet that is being used ?
>>>
>>> --
>>> thomas
>>>
>>> On Tue, Sep 20, 2011 at 18:45, Bistrais, Bob
>> wrote:
>>>> I'm trying to draw and label road features from a shapefile.  I'd
>> like to
>>>> include an outline of the road name text as a halo.  This works fine
>> on
>>>> polygon and point features, but is not working for me with the line
>>>> features.
>>>>
>>>>
>>>>
>>>> Here is the code block:
>>>>
>>>>
>>>>
>>>>                  LABEL
>>>>
>>>>                    ANGLE auto
>>>>
>>>>                    PARTIALS false
>>>>
>>>>                    FORCE false
>>>>
>>>>                    MINDISTANCE 250
>>>>
>>>>                    POSITION uc
>>>>
>>>>                    COLOR 200 0 0
>>>>
>>>>                    OUTLINECOLOR 255 255 255
>>>>
>>>>                    OUTLINEWIDTH 5
>>>>
>>>>                    FONT "verdana"
>>>>
>>>>                    SIZE 12
>>>>
>>>>                    TYPE truetype
>>>>
>>>>                  END
>>>>
>>>>                  TEXT ([RDNAME])
>>>>
>>>> ___
>>>> mapserver-users mailing list
>>>> mapserver-users@lists.osgeo.org
>>>> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>>>>
>>>>
>>>>
>>>>
>>>> ___
>>>> mapserver-users mailing list
>>>> mapserver-users@lists.osgeo.org
>>>> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>>
>>
>> ___
>> mapserver-users mailing list
>> mapserver-users@lists.osgeo.org
>> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>>
>
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] Abandoned railroad symbol

2011-09-22 Thread thomas bonfort
SYMBOL
  NAME "tie"
  TYPE TRUETYPE
  FONT "path/to/arial.ttf"
  CHARACTER "|"
END


CLASS
EXPRESSION ('[STATUS]' = '3')
# The crossties:
STYLE
  COLOR 200 200 200
  SIZE 4
  SYMBOL "tie"
  GAP -10
END
# The centerline:
STYLE
  COLOR 200 200 200
  WIDTH 1
  PATTERN
5 10
  END
END

  END

On Thu, Sep 22, 2011 at 17:15, Bistrais, Bob  wrote:
> I’ve been playing around with the symbology but I’m not getting my spacing
> right.  I’m trying to create a symbol for abandoned railroad track, looks
> like the standard RR symbol, a line with the crossties, but dashed.  Here is
> my code.  Problem is, although I get a dashed line and the crossties, the
> interval isn’t correct, and I was wondering if anyone had advice on making
> it more consistent so the crossties are always on the dashed line:
>
>
>
>   CLASS
>
>     EXPRESSION ('[STATUS]' = '3')
>
> # The crossties:
>
>     STYLE
>
>   COLOR 200 200 200
>
>   WIDTH 4
>
>   LINECAP BUTT
>
>   ANGLE 90
>
>   PATTERN
>
>     1 10
>
>   END
>
>     END
>
> # The centerline:
>
>     STYLE
>
>   COLOR 200 200 200
>
>   WIDTH 1
>
>   PATTERN
>
>     5 10
>
>   END
>
>     END
>
>
>
>   END
>
> ___
> mapserver-users mailing list
> mapserver-users@lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>
>
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] Abandoned railroad symbol

2011-09-26 Thread thomas bonfort
Havard,

#3867 seems reasonable, we would just need to document that in the
migration guide for people who are using a symbol who's size is larger
than the gap they specified, as this will result in messed up
rendering.

#3879 is more involved, as it requires the addition of two mapfile
keywords. You might want to bring this up on the -dev list to see what
the reactions are w.r.t these keyword additions.

regards,
thomas

On Mon, Sep 26, 2011 at 12:09, Havard Tveite  wrote:
> Dear Bob,
>
> Mapserver does not allow sensible styling of dashed lines with for
> instance point symbols.
> To be able to do this, a new mechanism will have to be introduced
> (for instance INITIALGAP, as used in the SLD specification).  This
> is what Mapserver ticket #3879 suggests.
> http://trac.osgeo.org/mapserver/ticket/3879
>
> Advanced styling of lines with point symbols is also hampered by the
> strange calculation of GAP in Mapserver, as reported in ticket #3867.
> GAP should, in my opinion, specify the centre to centre distance
> between the point symbols.
> http://trac.osgeo.org/mapserver/ticket/3867
>
> Håvard Tveite
>
> On 9/22/2011 6:14 PM, Bistrais, Bob wrote:
>>
>> Hmm, still not getting the spacing correct.  The crossties seem to be at a
>> consistent interval, but the dashed centerline isn't spacing well- sometimes
>> I get ties centered on the line (which is whaat I want), and sometimes the
>> ties are at the end of a dash.
>>
>> -Original Message-
>> From: thomas bonfort [mailto:thomas.bonf...@gmail.com]
>> Sent: Thursday, September 22, 2011 11:21 AM
>> To: Bistrais, Bob
>> Cc: mapserver-users@lists.osgeo.org
>> Subject: Re: [mapserver-users] Abandoned railroad symbol
>>
>> SYMBOL
>>   NAME "tie"
>>   TYPE TRUETYPE
>>   FONT "path/to/arial.ttf"
>>   CHARACTER "|"
>> END
>>
>>
>> CLASS
>>     EXPRESSION ('[STATUS]' = '3')
>> # The crossties:
>>     STYLE
>>       COLOR 200 200 200
>>       SIZE 4
>>       SYMBOL "tie"
>>       GAP -10
>>     END
>> # The centerline:
>>     STYLE
>>       COLOR 200 200 200
>>       WIDTH 1
>>       PATTERN
>>         5 10
>>       END
>>     END
>>
>>   END
>>
>> On Thu, Sep 22, 2011 at 17:15, Bistrais, Bob
>>  wrote:
>>>
>>> I've been playing around with the symbology but I'm not getting my
>>> spacing
>>> right.  I'm trying to create a symbol for abandoned railroad track, looks
>>> like the standard RR symbol, a line with the crossties, but dashed.  Here
>>> is
>>> my code.  Problem is, although I get a dashed line and the crossties, the
>>> interval isn't correct, and I was wondering if anyone had advice on
>>> making
>>> it more consistent so the crossties are always on the dashed line:
>>>
>>>
>>>
>>>   CLASS
>>>
>>>     EXPRESSION ('[STATUS]' = '3')
>>>
>>> # The crossties:
>>>
>>>     STYLE
>>>
>>>       COLOR 200 200 200
>>>
>>>       WIDTH 4
>>>
>>>       LINECAP BUTT
>>>
>>>       ANGLE 90
>>>
>>>       PATTERN
>>>
>>>         1 10
>>>
>>>       END
>>>
>>>     END
>>>
>>> # The centerline:
>>>
>>>     STYLE
>>>
>>>       COLOR 200 200 200
>>>
>>>       WIDTH 1
>>>
>>>       PATTERN
>>>
>>>         5 10
>>>
>>>       END
>>>
>>>     END
>>>
>>>
>>>
>>>   END
>>>
> ___
> mapserver-users mailing list
> mapserver-users@lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] Displaying repeated values in label

2011-09-26 Thread thomas bonfort
remove the MINDISTANCE keywords from your labels, they prevent
duplicate labels from appearing closer than the specified distance
(i.e. 600 in your case) which depending an your image size can mean
that your 0.0 is only displayed once.

--
thomas

On Mon, Sep 26, 2011 at 17:52, Toni Martínez  wrote:
> Hi all,
> I am using MapServer version 5.6.1 reading data from Postgis.
> One of the layers I am working with makes use of labels displaying data from
> a Postgis column over a marker on the map. Everything seems to be working
> fine but some data to be displayed on labels is 0.0 In such case, mapserver
> only displays one marker with its label.
> Because I need all markers and labels to be represented on that layer even
> if values are the same, I have been trying some options that I read in
> mapserver official docs like MINDISTANCE or FORCE or PROCESSING
> "LABEL_NO_CLIP=ON" with no results.
> Please take a look at my layer's code.
>
> LAYER
>     NAME pern_lectura
>     GROUP overlays
>     TYPE POINT
>     STATUS OFF
>     PROCESSING "CLOSE_CONNECTION=DEFER"
>     CONNECTIONTYPE POSTGIS
>     CONNECTION 'user=postgres password=xx dbname=UAS host=xxx
> port=5432'
>     DATA "the_geom from gis_schema.perno_estat_geom using SRID=23031 using
> unique id_perno"
>     FILTER "nombre_anillo='A903'"
>     OPACITY 100
>     CLASS
>   NAME 'Normalitat'
>   EXPRESSION ([estat] = 0)
>     STYLE
>     SYMBOL "quadrat"
>     SIZE 15
>     COLOR 45 181 45
>     OUTLINECOLOR 0 0 0
>     END
>     STYLE
>     SYMBOL "circle"
>     SIZE 11.25
>     COLOR 204 204 255
>     OUTLINECOLOR 0 0 0
>     END
>     STYLE
>     SYMBOL "creu"
>     SIZE 6
>     COLOR 0 0 0
>     END
>     LABEL
>     MINFEATURESIZE  80
>     TYPE  TRUETYPE
>     FONT  "arial"
>     SIZE  8
>     ANGLE FOLLOW
>     COLOR 25 25 175
>     OUTLINECOLOR  255 255 255
>     MINDISTANCE   600
>     PARTIALS  FALSE
>   END
>     END
>     CLASS
>   NAME 'Notificació'
>   EXPRESSION ([estat] = 1)
>   STYLE
>     SYMBOL "quadrat"
>     SIZE 15
>     COLOR 226 226 0
>     OUTLINECOLOR 0 0 0
>     END
>     STYLE
>     SYMBOL "circle"
>     SIZE 11.25
>     COLOR 204 204 255
>     OUTLINECOLOR 0 0 0
>     END
>     STYLE
>     SYMBOL "creu"
>     SIZE 6
>     COLOR 0 0 0
>     END
>      LABEL
>     MINFEATURESIZE  80
>     TYPE  TRUETYPE
>     FONT  "arial"
>     SIZE  8
>     ANGLE FOLLOW
>     COLOR 25 25 175
>     OUTLINECOLOR  255 255 255
>     MINDISTANCE   600
>     PARTIALS  FALSE
>   END
>     END
>     CLASS
>   NAME 'Preavís'
>   EXPRESSION ([estat] = 2)
>   STYLE
>     SYMBOL "quadrat"
>     SIZE 15
>     COLOR 255 130 0
>     OUTLINECOLOR 0 0 0
>     END
>     STYLE
>     SYMBOL "circle"
>     SIZE 11.25
>     COLOR 204 204 255
>     OUTLINECOLOR 0 0 0
>     END
>     STYLE
>     SYMBOL "creu"
>     SIZE 6
>     COLOR 0 0 0
>     END
>       LABEL
>     MINFEATURESIZE  80
>     TYPE  TRUETYPE
>     FONT  "arial"
>     SIZE  8
>     ANGLE FOLLOW
>     COLOR 25 25 175
>     OUTLINECOLOR  255 255 255
>     MINDISTANCE   600
>     PARTIALS  FALSE
>   END
>     END
>     CLASS
>   NAME 'Atenció'
>   EXPRESSION ([estat] = 3)
>   STYLE
>     SYMBOL "quadrat"
>     SIZE 15
>     COLOR 212 0 0
>     OUTLINECOLOR 0 0 0
>     END
>     STYLE
>     SYMBOL "circle"
>     SIZE 11.25
>     COLOR 204 204 255
>     OUTLINECOLOR 0 0 0
>     END
>     STYLE
>     SYMBOL "creu"
>     SIZE 6
>     COLOR 0 0 0
>     END
>       LABEL
>     MINFEATURESIZE  80
>     TYPE  TRUETYPE
>     FONT  "arial"
>     SIZE  8
>     ANGLE FOLLOW
>     COLOR 25 25 175
>     OUTLINECOLOR  255 255 255
>     MINDISTANCE   600
>     PARTIALS  FALSE
>   END
>     END
>     PROJECTION
>       "init=epsg:23031"
>     END
>     METADATA
>         

Re: [mapserver-users] arrow head doesn't draw at the end

2011-09-28 Thread thomas bonfort
On Wed, Sep 28, 2011 at 15:09, Mr. Puneet Kishor  wrote:
> Hi luis,
>
> Thanks for helping out. I will try OVERLAYSYMBOL, but from the docs it seems 
> it is no different that using two stacked symbols. I did try GAP, but that 
> doesn't help at all.
>
> As I mentioned below, I am drawing these points, not unlike the recent thread 
> started by Brent on drawing wind barbs. Except, in my case, these are GPS 
> sensor readings. The reading values are always 0 or more (actually, they are 
> close to 0, but let's say, the really tiny ones are identifiable). The 
> readings have two values... rate and azimuth.
>
> The length of the arrows has to be drawn proportional to the rate, and arrows 
> have to be pointed toward the azimuth.
>
> First, I don't want arrows on the 0 (or, close to 0) readings but I still 
> want to show them. So, I've decided I will just select them out and draw them 
> as a separate layer with just dots. Easy.
>
> Now, the ones that are to be drawn with an arrow: the problem I am facing is 
> that I want the arrow head at the end of the arrow stem that is of a 
> non-predictable length. Even though the docs imply that I can achieve this 
> with GEOMTRANSFORM, I have failed to do so. And, of course, just now I 
> learned that perhaps that could be because GEOMSTRANSFORM applies *only* to 
> LINE layers.

The docs have *never* implied that, even if you might have wanted them to.
"end: produces the last point of the geometry": the last point of a
point geometry is the point itself, which is what is happening.


>
> Seems to me the *only* reasonable way to achieve this would be to have a 
> GEOMTRANSFORM kind of capability for POINT layers as well, so that the last 
> (or first or whatever... the specified) point of the symbol geometry could be 
> decorated with another symbol.

again, geomtransform applies to the underlying feature, not the symbol
you are rendering on top of the feature. geomtransform will not help
in your case.

as paul suggested, you need to classify your data with a different
symbol depending on your [rate], and use the azimuth for the
orientation.

>
> I am open to all kinds of suggestions at this point.
>
>
> On Sep 28, 2011, at 3:04 AM, luis peinado wrote:
>
>> Hi, just trying to help.
>> I used some trick with arrows than maybe can help you with some variation.
>> I use mapserver-5.X and the way it worked for me was a LINE type layer using
>> a normal class (continous line) with an OVERLAYSYMBOL, using  a ">"
>> character.
>> Maybe changin some parameters like GAP may be useful to you.
>>
>> This is my class on a TYPE LINE layer
>> CLASS
>> NAME "capa_tub"
>> SYMBOL "continous"
>> SIZE 2
>> COLOR 6 79 167
>> OVERLAYSYMBOL "arrow"
>> OVERLAYSIZE 30
>> OVERLAYCOLOR 6 79 167
>> END
>>
>> And my continous and arrow are
>>
>> SYMBOL
>>  NAME "arrow"
>>  TYPE TRUETYPE
>>  FONT arial
>>  CHARACTER '>'
>>  FILLED true
>>  ANTIALIAS true
>>  GAP -100
>> END
>>
>> SYMBOL
>> NAME "continous"
>> TYPE ELLIPSE
>> POINTS 1 1 END
>> END
>>
>> Hope it helps.
>> Lluís
>>
>> 2011/9/27 Puneet Kishor 
>>
>>>
>>> On Sep 27, 2011, at 2:18 AM, Havard Tveite wrote:
>>>
 Have you seen:


>>> http://mapserver.org/mapfile/symbology/construction.html#changing-the-center-of-a-point-symbol
>>>
>>>
>>> Yup, seen and read it from end to end until my eyes glazed. Perhaps it is
>>> clear as crystal to the rest of the world, but I can't fathom anything there
>>> applicable to me. I am facing four problems --
>>>
>>> 1. As I mentioned below, per the docs, I am supposed to be able to declare
>>> "ANGLE AUTO" in my STYLE definition. That simply does not work for me. I
>>> *have* to declare the angle the same as the angle of the stem of the arrow
>>> "ANGLE [az]" in order to get arrow heads headed in the same direction as the
>>> arrow stems.
>>>
>>> 2. From the docs on GEOMTRANSFORM, "end: produces the last point of the
>>> geometry. When used with ANGLE AUTO, it can for instance be used to render
>>> an arrowhead." Well, no... it is *not* producing the *last point of the
>>> geometry* as I understand it. Instead, it is producing the middle point of
>>> the geometry. And it sure as as I can see is not working with ANGLE AUTO
>>> (see #1 above).
>>>
>>> 3. I have tried several variations on my arrow head to try shift its
>>> center, but I am failing to translate the information in the above document
>>> to be able to do it correctly.
>>>
>>> 4. Perhaps most important: the length of the arrow is varying based on
>>> [rate]. In other words, I want only the stem to be shorter or longer, but
>>> the arrow head to be the same size, and to be at the "end" of the stem
>>> always. In fact, there are instances in which [rate] could be equal to zero.
>>> In those instances I don't want any arrow to be drawn at all.
>>>
>>> *** In other words, I want an arrow stem to be as long as the varying
>>> [rate], and if the stem has a length greater than zero then and only then do
>>> I want an arrow head at the end

Re: [mapserver-users] minscaledenom puzzle, Mapserver 6.0.1

2011-09-29 Thread thomas bonfort
> Thomas is right that I needed a real symbol and not "symbol 0"
> within the pixel-sized class.  I was confused by the docs under
> class:symbol, which says "Default is 0, which results in a single
> pixel, ..."  Is that part now out of date?

Yes, it's out of date. The default symbol at index 0 should probably
be updated so it becomes a circle symbol.

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


Re: [mapserver-users] How to remove the label of a class with mapscript

2011-09-29 Thread thomas bonfort
remove the layer->labelitem and label->text

--
thomas

On Thu, Sep 29, 2011 at 16:33, Frank Broniewski  wrote:
> Hi,
>
> how can I remove the label of a class with mapscript, or disable labeling?
> Doing this by hand, I would simply delete the label definition part in the
> mapfile but apparently this is not possible with mapscript since the label
> property is immutable ..
> Thanks for any hints
>
> Frank
> --
> Frank BRONIEWSKI
>
> METRICO s.à r.l.
> géomètres
> technologies d'information géographique
> rue des Romains 36
> L-5433 NIEDERDONVEN
>
> tél.: +352 26 74 94 - 28
> fax.: +352 26 74 94 99
> http://www.metrico.lu
> ___
> mapserver-users mailing list
> mapserver-users@lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] Need help with Expression

2011-09-30 Thread thomas bonfort
You can use a regular expression

CLASSITEM RDNAME

CLASS
  EXPRESSION /^Main/
  ...
END

--
thomas

On Fri, Sep 30, 2011 at 15:51, Bistrais, Bob  wrote:
> I’m trying to create an Expression to select features in a Class, MapServer
> 6.0.1.  I want to do something such as a wildcard or a Like statement, to
> select records with certain item values.  Something similar to this:
>
>
>
> EXPRESSION (‘[RDNAME]’ = ‘Main%’ )
>
>
>
> Or perhaps
>
>
>
> EXPRESSION (‘[RDNAME]’ like ‘Main%’)
>
>
>
> -neither of these formats worked for me.  I checked the MS documentation
> under Expression, but could not find the solution.  Can anyone shed some
> light on this?
>
> ___
> mapserver-users mailing list
> mapserver-users@lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>
>
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] MapCache - failed to remove lockfile error

2011-10-06 Thread thomas bonfort
The log message should be more explicit, and contain the reason of the
unsuccessful removal. In any case, looking at the code, this error
will have interrupted the seeding process.

regards,
thomas

On Thu, Oct 6, 2011 at 15:03, Travis Kirstine  wrote:
> Hi All,
> I hope this is the right spot to post MapCache questions.  I had
> seeded a large area and receive the error "failed to remove lockfile".
>  It appears that this error(s) happens at the end of the seeding but
> it is hard tell as the process has been running for a few days.  Does
> this error kill the seeder process or is it simply a warning?
>
> Regards
> ___
> mapserver-users mailing list
> mapserver-users@lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] MapCache - failed to remove lockfile error

2011-10-06 Thread thomas bonfort
what seed command were you using, and what kind of cache ?

On Thu, Oct 6, 2011 at 15:52, Travis Kirstine  wrote:
> Thanks Thomas,
>
> The complete error message is below.  Do you have any idea what would
> cause this error - why would mapcache fail to create or delete the
> lockfile.
>
>
>
> seeding tile 583296 1337304 21failed to remove lockfile
> /var/mod-geocache/cachesseeding tile 583304 1337296 21failed to remove
> lockfile /var/mod-geocache/caches/_gc_lock-21-167156-72919-ms_tileset_8:
> No such file or directoryfailed to remove lockfile
> /var/mod-geocache/caches/_gc_lock-21-167157-72919-ms_tileset_8: No
> such file or directoryfailed to remove lockfile
> /var/mod-geocache/caches/_gc_lock-20-83579-36459-ms_tileset_8: No such
> file or directoryfailed to remove lockfile
> /var/mod-geocache/caches/_gc_lock-21-167156-72918-ms_tileset_8: No
> such file or directoryfailed to remove lockfile
> /var/mod-geocache/caches/_gc_lock-21-167159-72918-ms_tileset_8: No
> such file or directoryfailed to remove lockfile
> /var/mod-geocache/caches/_gc_lock-21-167158-72918-ms_tileset_8: No
> such file or directoryfailed to remove lockfile
> /var/mod-geocache/caches/_gc_lock-21-167159-72919-ms_tileset_8: No
> such file or directoryfailed to remove lockfile
> /var/mod-geocache/caches/_gc_lock-18-20895-9114-ms_tileset_8: No such
> file or directoryfailed to remove lockfile
> /var/mod-geocache/caches/_gc_lock-21-167158-72919-ms_tileset_8: No
> such file or directory
>
>
> Regards
>
>
> On 6 October 2011 09:11, thomas bonfort  wrote:
>> The log message should be more explicit, and contain the reason of the
>> unsuccessful removal. In any case, looking at the code, this error
>> will have interrupted the seeding process.
>>
>> regards,
>> thomas
>>
>> On Thu, Oct 6, 2011 at 15:03, Travis Kirstine  
>> wrote:
>>> Hi All,
>>> I hope this is the right spot to post MapCache questions.  I had
>>> seeded a large area and receive the error "failed to remove lockfile".
>>>  It appears that this error(s) happens at the end of the seeding but
>>> it is hard tell as the process has been running for a few days.  Does
>>> this error kill the seeder process or is it simply a warning?
>>>
>>> Regards
>>> ___
>>> mapserver-users mailing list
>>> mapserver-users@lists.osgeo.org
>>> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>>>
>>
>
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] MapCache - failed to remove lockfile error

2011-10-06 Thread thomas bonfort
I don't have a specific advice to give unfortunately. There have been
some fixes lately (macpcache only, not mod-geocache) to the way
multiple threads accessed the curl library that might help, so you
might want to try with a fresh checkout from the mapserver svn.

--
thomas

On Thu, Oct 6, 2011 at 18:08, Travis Kirstine  wrote:
> Thomas,
>
> My command is below, I'm using a disk cache, my config file is below.
> I'm using a local copy of MapServer for the source image generation
>
>
> ./geocache_seed -c ../geocache.xml -t ms_tileset_8 -z 0,21 -e
> -8895580.772,5411569.158,-8797157.196,5538966.276 -n 6
>
>
> 
> 
>
>   
>      geocache service esx11
>      mod-geocache service
>      
>   
>
>         
>            
>               GoogleMapsCompatible
>               
> urn:ogc:def:wkss:OGC:1.0:GoogleMapsCompatible
>            
>            -20037508.3427892480 -20037508.3427892480
> 20037508.3427892480 20037508.3427892480
>            EPSG:3857
>            EPSG:900913
>            m
>            256 256
>            156543.0339280410 78271.51696402048
> 39135.75848201023 19567.87924100512 9783.939620502561
> 4891.969810251280 2445.984905125640 1222.992452562820
> 611.4962262814100 305.7481131407048 152.8740565703525
> 76.43702828517624 38.21851414258813 19.10925707129406
> 9.554628535647032 4.777314267823516 2.388657133911758
> 1.194328566955879 0.5971642834779395 0.29858214173896975
> 0.149291070869484875 0.0746455354347424375
>         
>
>   
>      /var/mod-geocache/caches
>      
>   
>
>   
>      fast 
>      256
>   
>   
>      75
>   
>   
>      best
>   
>   
>      PNG_BEST
>      JPEG
>   
>
>   
>      
>         
>            image/png
>            YORK2009
>            true
>         
>      
>      
>         http://localhost.jdbarnes.com/cgi-bin/ms_wms
>      
>   
>
>   
>      ms_wms
>      disk
>      
>      googlemaps_grid
>      mixed
>      8 8
>      0
>   
>
>   JPEG
>
>   
>   
>   
>   
>   
>   
>
>   report
>
>   /var/mod-geocache/caches
>
> 
>
> On 6 October 2011 10:31, thomas bonfort  wrote:
>> what seed command were you using, and what kind of cache ?
>>
>> On Thu, Oct 6, 2011 at 15:52, Travis Kirstine  
>> wrote:
>>> Thanks Thomas,
>>>
>>> The complete error message is below.  Do you have any idea what would
>>> cause this error - why would mapcache fail to create or delete the
>>> lockfile.
>>>
>>>
>>>
>>> seeding tile 583296 1337304 21failed to remove lockfile
>>> /var/mod-geocache/cachesseeding tile 583304 1337296 21failed to remove
>>> lockfile /var/mod-geocache/caches/_gc_lock-21-167156-72919-ms_tileset_8:
>>> No such file or directoryfailed to remove lockfile
>>> /var/mod-geocache/caches/_gc_lock-21-167157-72919-ms_tileset_8: No
>>> such file or directoryfailed to remove lockfile
>>> /var/mod-geocache/caches/_gc_lock-20-83579-36459-ms_tileset_8: No such
>>> file or directoryfailed to remove lockfile
>>> /var/mod-geocache/caches/_gc_lock-21-167156-72918-ms_tileset_8: No
>>> such file or directoryfailed to remove lockfile
>>> /var/mod-geocache/caches/_gc_lock-21-167159-72918-ms_tileset_8: No
>>> such file or directoryfailed to remove lockfile
>>> /var/mod-geocache/caches/_gc_lock-21-167158-72918-ms_tileset_8: No
>>> such file or directoryfailed to remove lockfile
>>> /var/mod-geocache/caches/_gc_lock-21-167159-72919-ms_tileset_8: No
>>> such file or directoryfailed to remove lockfile
>>> /var/mod-geocache/caches/_gc_lock-18-20895-9114-ms_tileset_8: No such
>>> file or directoryfailed to remove lockfile
>>> /var/mod-geocache/caches/_gc_lock-21-167158-72919-ms_tileset_8: No
>>> such file or directory
>>>
>>>
>>> Regards
>>>
>>>
>>> On 6 October 2011 09:11, thomas bonfort  wrote:
>>>> The log message should be more explicit, and contain the reason of the
>>>> unsuccessful removal. In any case, looking at the code, this error
>>>> will have interrupted the seeding process.
>>>>
>>>> regards,
>>>> thomas
>>>>
>>>> On Thu, Oct 6, 2011 at 15:03, Travis Kirstine  
>>>> wrote:
>>>>> Hi All,
>>>>> I hope this is the right spot to post MapCache questions.  I had
>>>>> seeded a large area and receive the error "failed to remove lockfile".
>>>>>  It appears that this error(s) happens at the end of the seeding but
>>>>> it is hard tell as the process has been running for a few days.  Does
>>>>> this error kill the seeder process or is it simply a warning?
>>>>>
>>>>> Regards
>>>>> ___
>>>>> mapserver-users mailing list
>>>>> mapserver-users@lists.osgeo.org
>>>>> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>>>>>
>>>>
>>>
>>
>
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] MapCache - failed to remove lockfile error

2011-10-07 Thread thomas bonfort
What version of mod-geocache are you using (revision number or release
version) ?

On Thu, Oct 6, 2011 at 22:17, Travis Kirstine  wrote:
> This doesn't seem to be a issue, I have lots of inodes left.  It
> appears that the error occurred when generating (linking)  areas with
> a large volume of transparent tiles, could this be related?
>
> Regards
>
> On 6 October 2011 14:19, Stephen Woodbridge  wrote:
>> Have you verified that you have not filled up the disk or run out of inodes?
>>
>> # check the diskspace with
>> df -h
>>
>> # check for inode issues
>> touch /path/to/cache/test.junk
>>
>> # if the touch failed then you have run out of inodes
>> # otherwise clean up
>> rm /path/to/cache/test.junk
>>
>> Thanks,
>>  -Steve W
>>
>> On 10/6/2011 12:14 PM, thomas bonfort wrote:
>>>
>>> I don't have a specific advice to give unfortunately. There have been
>>> some fixes lately (macpcache only, not mod-geocache) to the way
>>> multiple threads accessed the curl library that might help, so you
>>> might want to try with a fresh checkout from the mapserver svn.
>>>
>>> --
>>> thomas
>>>
>>> On Thu, Oct 6, 2011 at 18:08, Travis Kirstine
>>>  wrote:
>>>>
>>>> Thomas,
>>>>
>>>> My command is below, I'm using a disk cache, my config file is below.
>>>> I'm using a local copy of MapServer for the source image generation
>>>>
>>>>
>>>> ./geocache_seed -c ../geocache.xml -t ms_tileset_8 -z 0,21 -e
>>>> -8895580.772,5411569.158,-8797157.196,5538966.276 -n 6
>>>>
>>>>
>>>> 
>>>> 
>>>>
>>>>   
>>>>      geocache service esx11
>>>>      mod-geocache service
>>>>      
>>>>   
>>>>
>>>>         
>>>>            
>>>>               GoogleMapsCompatible
>>>>
>>>> urn:ogc:def:wkss:OGC:1.0:GoogleMapsCompatible
>>>>            
>>>>            -20037508.3427892480 -20037508.3427892480
>>>> 20037508.3427892480 20037508.3427892480
>>>>            EPSG:3857
>>>>            EPSG:900913
>>>>            m
>>>>            256 256
>>>>            156543.0339280410 78271.51696402048
>>>> 39135.75848201023 19567.87924100512 9783.939620502561
>>>> 4891.969810251280 2445.984905125640 1222.992452562820
>>>> 611.4962262814100 305.7481131407048 152.8740565703525
>>>> 76.43702828517624 38.21851414258813 19.10925707129406
>>>> 9.554628535647032 4.777314267823516 2.388657133911758
>>>> 1.194328566955879 0.5971642834779395 0.29858214173896975
>>>> 0.149291070869484875 0.0746455354347424375
>>>>         
>>>>
>>>>   
>>>>      /var/mod-geocache/caches
>>>>      
>>>>   
>>>>
>>>>   
>>>>      fast  
>>>>      256
>>>>   
>>>>   
>>>>      75
>>>>   
>>>>   
>>>>      best
>>>>   
>>>>   
>>>>      PNG_BEST
>>>>      JPEG
>>>>   
>>>>
>>>>   
>>>>      
>>>>         
>>>>            image/png
>>>>            YORK2009
>>>>            true
>>>>         
>>>>      
>>>>      
>>>>         http://localhost.jdbarnes.com/cgi-bin/ms_wms
>>>>      
>>>>   
>>>>
>>>>   
>>>>      ms_wms
>>>>      disk
>>>>      
>>>>      googlemaps_grid
>>>>      mixed
>>>>      8 8
>>>>      0
>>>>   
>>>>
>>>>   JPEG
>>>>
>>>>   
>>>>   
>>>>   
>>>>   
>>>>   
>>>>   
>>>>
>>>>   report
>>>>
>>>>   /var/mod-geocache/caches
>>>>
>>>> 
>>>>
>>>> On 6 October 2011 10:31, thomas bonfort  wrote:
>>>>>
>>>>> what seed command were you using, and what kind of cache ?
>>>>>
>>>>> On Thu, Oct 6, 2011 at 15:52, Travis Kirstine
>>>>>  wrote:
>>>>>>
>>>>>> Thanks Thomas,
>>>>>>
>>>>>> The complete error message i

Re: [mapserver-users] symbolunits meters doesn't work

2011-10-17 Thread thomas bonfort
make sure your map UNIT is correctly set (meters or dd depending on
the projection).

On Mon, Oct 17, 2011 at 08:56, knasia  wrote:
> Hi,
> I am trying to put symbols on the map giving their size in meters, but I
> didn't manage. Here is my code.
>
> LAYER
>        NAME queue
>                PROJECTION "init=epsg:4326"
>                END
>
>                CONNECTIONTYPE postgis
>                CONNECTION 'user=  password=  dbname=  host=  port='
>                TRANSPARENCY 95
>                STATUS ON
>                DATA 'coor FROM nodes using unique id using srid=4326'
>                TYPE POINT
>                SIZEUNITS meters
>
>                #I have also tried:
>                #UNITS meters
>                #SYMBOLSCALE 35000
>
>                CLASS
>                        STYLE
>                        COLOR 102 102 102
>                        SYMBOL "cross"
>                        SIZE 10
>                        #WIDTH 2
>                        END
>                END
>        END
>
> Could somebody please help?
>
> KN
>
> --
> View this message in context: 
> http://osgeo-org.1803224.n2.nabble.com/symbolunits-meters-doesn-t-work-tp6899443p6899443.html
> Sent from the Mapserver - User mailing list archive at Nabble.com.
> ___
> mapserver-users mailing list
> mapserver-users@lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] Problem compiling MapServer - "error: cannot find gif lib"

2011-10-17 Thread thomas bonfort
--with-gif=$HOME if you have installed it there. As a rule of thumb,
it is not a good idea to only compile the packages and not install
them (i.e. no make install) as there is no reason that the packages
respect the include/ lib/ hierarchy inside their source structure.
(i.e. you should be using  --with-gdal=/home/david/bin/gdal-config,
--with-proj=/home/david, etc... )

--
thomas


On Mon, Oct 17, 2011 at 06:48, David Quinn  wrote:
> Hello List,
>
> I'm trying to install Mapserver on CentOS5 (specifically on a Webfaction
> shared hosting server). I'm using the following options:
>
> ./configure --prefix=$HOME \
> --enable-debug  \
> --with-gd \
> --with-freetype --without-tiff \
> --with-gdal=/home/david/src/gdal-1.8.1/apps/gdal-config \
> --with-ogr=/home/david/src/gdal-1.8.1/apps/gdal-config \
> --with-proj=/home/david/src/proj-4.7.0/ \
> --without-pdf \
> --with-png=/usr/ --with-threads \
> --with-postgis=/home/david/src/postgresql-8.4.6/src/bin/pg_config \
> --with-wfs --with-wcs --with-wmsclient --with-wfsclient \
> --with-php=/usr/include/php5/ --enable-debug \
> --with-geos=/home/david/bin/geos-config \
> --with-python \
> --with-gif=/home/david/src/giflib-4.1.6/lib/gif_lib.h
>
> However I get the following error:
>
> checking setjmp.h usability... yes
> checking setjmp.h presence... yes
> checking for setjmp.h... yes
> configure: checking where GIF is installed...
> configure: error: cannot find gif lib in
> /home/urbmet/src/giflib-4.1.6/lib/gif_lib.h
>
> After I got this error the first time, I installed giflib-4.1.6. The results
> of running $ find | grep gif_lib.h
> ./include/gif_lib.h
> ./src/giflib-4.1.6/lib/gif_lib.h
> ./src/giflib-4.1.6/doc/gif_lib.html
> ./src/gdal-1.8.1/frmts/gif/giflib/gif_lib.h
>
> I have tried --with-gif with all of the following arguments, either to the
> folder or to gif_lib.h without success. Am I missing any settings or
> dependencies?
>
> Thanks,
> David
>
>
>
> ___
> mapserver-users mailing list
> mapserver-users@lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>
>
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] Problem compiling MapServer - "error: cannot find gif lib"

2011-10-17 Thread thomas bonfort
lib -lxml2 -lz -lm  -lm -lstdc++    -o shp2img
> ./libmapserver.a(mapogroutput.o): In function `msOGRWriteShape':
> /home/david/src/mapserver-6.0.1/mapogroutput.c:380: undefined reference to
> `OGR_G_ForceToPolygon'
> /home/david/src/mapserver-6.0.1/mapogroutput.c:385: undefined reference to
> `OGR_G_ForceToMultiPolygon'
> /home/david/src/mapserver-6.0.1/mapogroutput.c:390: undefined reference to
> `OGR_G_ForceToMultiPoint'
> /home/david/src/mapserver-6.0.1/mapogroutput.c:395: undefined reference to
> `OGR_G_ForceToMultiLineString'
> ./libmapserver.a(mapogroutput.o): In function `msOGRWriteFromQuery':
> /home/david/src/mapserver-6.0.1/mapogroutput.c:979: undefined reference to
> `CPLCreateZip'
> /home/david/src/mapserver-6.0.1/mapogroutput.c:984: undefined reference to
> `CPLCreateFileInZip'
> /home/david/src/mapserver-6.0.1/mapogroutput.c:989: undefined reference to
> `CPLCloseZip'
> /home/david/src/mapserver-6.0.1/mapogroutput.c:1000: undefined reference to
> `CPLWriteFileInZip'
> /home/david/src/mapserver-6.0.1/mapogroutput.c:1004: undefined reference to
> `CPLCloseFileInZip'
> /home/david/src/mapserver-6.0.1/mapogroutput.c:1006: undefined reference to
> `CPLCloseZip'
> collect2: ld returned 1 exit status
> make: *** [shp2img] Error 1
>
> Does anyone have a suggestion about how I can solve the following errors? I
> read some very old bug reports with the following error suggesting that it
> was due to the compiler version but I don't know if this is relevant.
>
> Thanks,
> David
>
> On Mon, Oct 17, 2011 at 3:17 AM, thomas bonfort 
> wrote:
>>
>> --with-gif=$HOME if you have installed it there. As a rule of thumb,
>> it is not a good idea to only compile the packages and not install
>> them (i.e. no make install) as there is no reason that the packages
>> respect the include/ lib/ hierarchy inside their source structure.
>> (i.e. you should be using  --with-gdal=/home/david/bin/gdal-config,
>> --with-proj=/home/david, etc... )
>>
>> --
>> thomas
>>
>>
>> On Mon, Oct 17, 2011 at 06:48, David Quinn  wrote:
>> > Hello List,
>> >
>> > I'm trying to install Mapserver on CentOS5 (specifically on a Webfaction
>> > shared hosting server). I'm using the following options:
>> >
>> > ./configure --prefix=$HOME \
>> > --enable-debug  \
>> > --with-gd \
>> > --with-freetype --without-tiff \
>> > --with-gdal=/home/david/src/gdal-1.8.1/apps/gdal-config \
>> > --with-ogr=/home/david/src/gdal-1.8.1/apps/gdal-config \
>> > --with-proj=/home/david/src/proj-4.7.0/ \
>> > --without-pdf \
>> > --with-png=/usr/ --with-threads \
>> > --with-postgis=/home/david/src/postgresql-8.4.6/src/bin/pg_config \
>> > --with-wfs --with-wcs --with-wmsclient --with-wfsclient \
>> > --with-php=/usr/include/php5/ --enable-debug \
>> > --with-geos=/home/david/bin/geos-config \
>> > --with-python \
>> > --with-gif=/home/david/src/giflib-4.1.6/lib/gif_lib.h
>> >
>> > However I get the following error:
>> >
>> > checking setjmp.h usability... yes
>> > checking setjmp.h presence... yes
>> > checking for setjmp.h... yes
>> > configure: checking where GIF is installed...
>> > configure: error: cannot find gif lib in
>> > /home/urbmet/src/giflib-4.1.6/lib/gif_lib.h
>> >
>> > After I got this error the first time, I installed giflib-4.1.6. The
>> > results
>> > of running $ find | grep gif_lib.h
>> > ./include/gif_lib.h
>> > ./src/giflib-4.1.6/lib/gif_lib.h
>> > ./src/giflib-4.1.6/doc/gif_lib.html
>> > ./src/gdal-1.8.1/frmts/gif/giflib/gif_lib.h
>> >
>> > I have tried --with-gif with all of the following arguments, either to
>> > the
>> > folder or to gif_lib.h without success. Am I missing any settings or
>> > dependencies?
>> >
>> > Thanks,
>> > David
>> >
>> >
>> >
>> > ___
>> > mapserver-users mailing list
>> > mapserver-users@lists.osgeo.org
>> > http://lists.osgeo.org/mailman/listinfo/mapserver-users
>> >
>> >
>
>
> ___
> mapserver-users mailing list
> mapserver-users@lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>
>
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] Re: symbolunits meters doesn't work

2011-10-17 Thread thomas bonfort
epsg:4326 is units dd

On Mon, Oct 17, 2011 at 15:19, knasia  wrote:
> This is my declaration:
>
>  PROJECTION
>  "init=epsg:4326"
>  END
> UNITS METERS
>
> No matter what I use my symbol is of a size which has nothing to do with
> real legth in meters. When I change zoom level size of a symbol is the same.
> I want to have symbols 7 meters long, but they are all the time the same.
> Maybe I shouldn't use symbol made of POINTS but something else.
>
> For example now I use arrows such as:
> SYMBOL
>    NAME "backArrow"
>    TYPE vector
>    POINTS
>        0 1
>        1 0
>        -99 -99
>        0 1
>        1 2
>        -99 -99
>        0 1
>        4 1
>    END
>        STYLE
>        1 40 1 40
>        END
> END
>
> --
> View this message in context: 
> http://osgeo-org.1803224.n2.nabble.com/symbolunits-meters-doesn-t-work-tp6899443p6900513.html
> Sent from the Mapserver - User mailing list archive at Nabble.com.
> ___
> mapserver-users mailing list
> mapserver-users@lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] Cairo and text elements

2011-10-18 Thread thomas bonfort
I agree this would be a nice feature to have, but this concerns the
cairo library. Once cairo supports this kind of text placement, we can
have a look at how to support it inside mapserver.

you might want to have a look at
http://lists.freedesktop.org/archives/cairo/2011-February/021777.html
for a cairo patch. I don't know if this can be picked up by mapserver
without patching its cairo calls.

regards,

Thomas

On Mon, Oct 17, 2011 at 21:26, Jefferson Williams
 wrote:
> For some years now, I have been using PHP MapScript with my own code to make
> SVG maps for use on Wikipedia.  Since these are static maps, I typically
> tweak them with an editor (moving or editing labels, re-positioning or
> re-sizing highway shields, et cetera) to make the maps look as good as
> possible.
> Upon upgrading to MapServer 6.0.1, I found that with Cairo handling the SVG
> output, I can no longer modify the labels.  It also makes the SVG files
> about three times larger in this application.  I understand the rationale
> that I've read on this, in terms of ensuring that an SVG looks consistent
> across many different viewers; but it's not ideal for all applications.
> I'm wondering if there are any plans for MapServer/Cairo to allow the option
> of producing text through  elements.  For now I will probably move
> back to MapScript 5.6, but some of the new features in 6.0 would be very
> useful.
>
> --
>
> Jeff Williams
>
> ___
> mapserver-users mailing list
> mapserver-users@lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>
>
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] How to deal with floating point exception?

2011-10-20 Thread thomas bonfort
your bounding box is invalid as minx=maxx and miny=maxy. please open a
ticket for this as mapserver should return an error message, and not
fail with an exception.

--
thomas

On Thu, Oct 20, 2011 at 04:39, jjwang  wrote:
> I got an floating point exception when I tried to run the mapserv.
>
> *./mapserv -nh
> "QUERY_STRING=map=/images/mapserv_map_files/BR_WFS.map&request=GetFeature&service=WFS&version=1.1.0&typename=nsw&BBOX=153.50183890072711,-28.163052299741643,153.50183890072711,-28.163052299741643&outputformat=stateonly"
> Content-type: text/html
>
> Floating point exception*
>
> I found this was caused by the longitude value I provided
> '153.50183890072711'. If I make a little change of the value, for example
> change it to '153.50183890072701', it will works fine. But obviously, it's
> not a solution to my problem.
>
> Any ideas on this issue?
>
> JJ
>
> --
> View this message in context: 
> http://osgeo-org.1803224.n2.nabble.com/How-to-deal-with-floating-point-exception-tp6911285p6911285.html
> Sent from the Mapserver - User mailing list archive at Nabble.com.
> ___
> mapserver-users mailing list
> mapserver-users@lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] mapcache in a cluster

2011-10-20 Thread thomas bonfort
Travis,
I haven't had any feedback from people using mapcache in a cluster.
This is my understanding of the possibilities and pitfalls:

- if you have a fully seeded cache, there are no locking issues,
therefore running a mapcache cluster will be transparent.
- if you have a non-seeded cache, there are some potential pitfalls:
  - mapcache does not lock the tiles directly as tilecache does, it
instead locks a "resource" corresponding to the metatile that is being
created.
  - This resource is a file placed in the  directory. If you
configure the lock directory to be a shared network mounted directory,
then the multiple mapcache instances /should/ manage to synchronize
between one another.
  - There is a mutex protecting the aquisition of the lock file, which
of course is of no use if you have a cluster of mapcache instances.
Depending on the capabilities of your network mounted filesystem, it
is not impossible that multiple instances manage to aquire a lock on
the same resource, which would potentially cause each instance to
request the metatile from the source wms. In the worst case scenario,
you would have N duplicate requests on the source, where N is the
number of mapcache instances. For reference, with tilecache, the usual
behavior (i.e. not worst case) is M of these duplicate requests, where
M is the number of tiles displayed in the browser window arriving on
an unseeded area.
 - I would consider it a bug if there are these N duplicate requests
in the case where the filesystem supports the atomic locking of a
file.

In conclusion, mapcache /should/ support the architecture you are
proposing, although as it is yet untested it is difficult to guarantee
that it will be bug free from day 1. Please post your experience back
to the list, and/or file bugs should they happen.

regards,
thomas

On Wed, Oct 19, 2011 at 16:02, Travis Kirstine  wrote:
> Has anyone attempted to set mapcache up in a cluster, one large file
> server holding caches with several mapcache servers? A few years ago
> we tried to have TileCache in a cluster but had issues with tile
> locking.
>
> Regards
> ___
> mapserver-users mailing list
> mapserver-users@lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] mapcache in a cluster

2011-10-20 Thread thomas bonfort
So, this discussion inspired me to completely rework the locking
mechanism in mapcache, to stop relying on file locks which have their
quirks on network filesystems.
I have tried using multiple apache instances configured to used a
SMB-mounted lock directory and hammered both instances on unseeded
identical area to force locking, and ended up with absolutely no
duplicate wms requests or failed requests for the clients.
The code is committed in trunk. Thanks for bringing this up, this
allowed me to really simplify the locking code and remove a lot of
unneeded stuff :)

--
thomas

On Thu, Oct 20, 2011 at 17:08, Travis Kirstine  wrote:
> Andreas and Thomas
>
> Thanks for you responses,  I have discussed this with some of our IT
> staff and they had similar solution as Andreas using gfs.  Their
> comments are below:
>
> "I suspect this scheme is not reliable over NFS. The problem is the
> directory updates are not synchronized across multiple nodes. I had a
> similar issue with the IMAP E-mail protocol. Our workaround currently
> is to force each user to leverage a single server.
>
> Ref:
> http://wiki.dovecot.org/NFS
>
> Seems like there's some tweaks to disable directory attribute caching
> but this can trigger slower performance.
> Only workaround is to use GFS which I found to have it's own issues. "
>
> Regards
>
>
>
> On 20 October 2011 05:32, Eichner, Andreas - SID-NLKM
>  wrote:
>>
>> We use TileCache.py on two servers with the cache on an OCFS2 on a
>> shared LUN in the SAN. No known issues with that for now. Note: Spurious
>> stale lock files occurred already on a single machine. There seemed to
>> be issues with lots of requests and a very slow upstream server. I used
>> a cron job to delete lock files older than 5 minutes or so.
>> As Thomas noted, if the lock files are created on a shared filesystem
>> and you make sure the filesystem you use is able to lock files properly
>> (read the docs carefully!) there's no reason why it should not work.
>>
> ___
> mapserver-users mailing list
> mapserver-users@lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] How ro get transparent image on 6.0.1

2011-11-03 Thread thomas bonfort
Either your asp page is selecting the wrong (i.e. a non-transparent)
imagetype, or you have a layer that is drawn ontop of the transparent
background, thus making the final image non transparent. The
outputformat you have shown is correct and produces trasnparent
images.

--
thomas

On Thu, Nov 3, 2011 at 14:46, Janeks Kamerovskis
 wrote:
> Hi,
>
> I recently moved to 6.0.1, but stumped to getting transparent image.
>
> I used following syntaxis in my map file:
>
>    IMAGECOLOR 255 255 255
>
>    OUTPUTFORMAT
>        NAME "png"
>        DRIVER AGG/PNG
>        MIMETYPE "image/png"
>        IMAGEMODE RGBA
>        EXTENSION "png"
>        FORMATOPTION "GAMMA=0.75"
>        TRANSPARENT ON
>    END
>
>    IMAGETYPE png
>
> But my request is still getting nontransparent image:
> http://10.162.129.14/MapApp/wms_rs.asp?LAYERS=rs&TRANSPARENT=true&FORMAT=image%2Fpng&SERVICE=WMS&VERSION=1.1.1&REQUEST=GetMap&STYLES=&SRS=EPSG%3A25884&BBOX=166509.5,6040766.7857144,908910.5,6571053.2142856&WIDTH=1050&HEIGHT=750
>
> What could be wrong?
>
> brgds & thanks in advance
> Janeks
> ___
> mapserver-users mailing list
> mapserver-users@lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] hatch symbol edge effects when rendering tiles with TilecCache

2011-11-10 Thread thomas bonfort
there's ticket http://trac.osgeo.org/mapserver/ticket/3847 for this
issue. It should be implemented in the coming days/weeks.

regards,
thomas

On Thu, Nov 10, 2011 at 09:24, SQ9MEV  wrote:
> Hi all!
>
> Working on my first webgis app, I use mapserver with python mapscript to
> generate WMS tiles. I use metatiling (5x5), but
>
> I'm struggling with edge effects when using hatch filled polygons - hatch
> pattern is moved by some offset on neighbouring tiles (I use metatiling, but
> it cannot resolve my problem, as polygons share several metatiles
> sometimes).
>
> The problem is somehow mentioned in MS RFC 45:
> http://mapserver.org/development/rfc/ms-rfc-45.html?highlight=hatch#polygon-fill-symbols
>
> but not a word about how to get rid of the edge effect.
>
> Any hints how to achieve repeating hatching accros many tiles?
>
> I think the pattern should have stable geographical origin as it's mentioned
> or at least "stable tile origin".
>
> I do not need continous hatch pattern, so as for now i use workaround:
>
> SYMBOL 'hatch-test'
> PATTERN 2 3 1 4 2 4 2 3 2 END
>
> The gaps are more or lesl random, so edge effect is not so visible as with
> continous hatch, but it is.
>
> Anyway, my map looks reasonable, so thanks guys for your work on MapServer.
>
> --
> Bart
> ___
> mapserver-users mailing list
> mapserver-users@lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] quality of 8bit image in 6.0

2011-11-14 Thread thomas bonfort
should be fixed in r12767 and r12768, please confirm.

regards,
thomas

On Sun, Nov 13, 2011 at 19:57, Richard Greenwood
 wrote:
> Steve,
>
> I put a small test set together at:
>  http://www.greenwoodmap.com/mapserver-image-quality/test.zip
> It has a shape file and two map files, one for mapserver 5 and another
> for mapserver 6. There are a couple zoomed in mapext's in the comments
> of the map5.map file so you can quickly get to a good location at a
> couple representative scales.
>
> PNG8 produces a nice quality image which is about 1/2 the size of the
> default 24bit but still 4x the size of the ugly GIF. The pretty GIF
> produced by mapserver 5.6 is the same size as the ugly GIF created by
> mapserver 6.0.
>
> Thanks!
> Rich
>
> On Sun, Nov 13, 2011 at 10:08 AM, Lime, Steve D (DNR)
>  wrote:
>> Rich: Any chance you could put together a test case? Also, have you tried 
>> IMAGETYPE PNG8?
>>
>> Steve
>> 
>> From: mapserver-users-boun...@lists.osgeo.org 
>> [mapserver-users-boun...@lists.osgeo.org] on behalf of Richard Greenwood 
>> [richard.greenw...@gmail.com]
>> Sent: Saturday, November 12, 2011 5:43 PM
>> To: mapserver
>> Subject: [mapserver-users] quality of 8bit image in 6.0
>>
>> I can not achieve the same quality of 8bit images in MapServer 6.0
>> that I was able to in 5.6. I have links to 4 example images
>>
>> 1. MapServer 5.6 8bit gif, I like this and this is generally what I want:
>> http://www.greenwoodmap.com/mapserver-image-quality/mapserv-5.6.gif
>>
>> 2. MapServer 6. 8bit gif. Kind of ragged, center line not in the
>> middle of grey outlines.
>> http://www.greenwoodmap.com/mapserver-image-quality/mapserv-6.0.1.gif
>>
>> 3. I submitted a related ticket 3962 which has been fixed (Thank you!)
>> and the image is slightly better (compare  NW'ly edge of HWY 789 to
>> above image)
>> http://www.greenwoodmap.com/mapserver-image-quality/mapserv-6.0-ticket3962.gif
>>
>> 4. A 24bit png from MapServer 6.0. Beautiful, but 9x larger than the
>> three above.
>> http://www.greenwoodmap.com/mapserver-image-quality/mapserv-6.0.1.png
>>
>> I do not have an OUTPUTFORMAT block defined so I'm using default
>> setting in 5.6 and 6.0. (I've fiddled with OUTPUTFORMAT but I
>> generally seem to make things worse).
>>
>> Any suggestions would be greatly appreciated.
>>
>> Thanks,
>> Rich
>>
>> --
>> Richard Greenwood
>> richard.greenw...@gmail.com
>> www.greenwoodmap.com
>> ___
>> mapserver-users mailing list
>> mapserver-users@lists.osgeo.org
>> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>>
>>
>>
>
>
>
> --
> Richard Greenwood
> richard.greenw...@gmail.com
> www.greenwoodmap.com
> ___
> mapserver-users mailing list
> mapserver-users@lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] style level opacity issue

2011-11-17 Thread thomas bonfort
I've just run a quick check and opacity on the style object works
correctly. please come up with a self contained test case that
reproduces your issue.

regards,
thomas

On Thu, Nov 17, 2011 at 18:15, Huotari, John B   (RCIS)
 wrote:
> I’d likewise like to see an answer to this as I’ve thus far been unable to
> make opacity work at the style level.  I’ve worked around that by using the
> opacity at the layer level instead, which might be a suitable solution in
> your situation.
>
>
>
> From: mapserver-users-boun...@lists.osgeo.org
> [mailto:mapserver-users-boun...@lists.osgeo.org] On Behalf Of
> li...@killface.org
> Sent: Thursday, November 17, 2011 10:02 AM
> To: mapserver-users@lists.osgeo.org
> Subject: [mapserver-users] style level opacity issue
>
>
>
> I'm trying to render a single vector layer that has overlapping polygons,
> but I cant seem to get the settings correct for what I want. There are
> overlapping polygons on the layer, and I would like them to each be drawn
> transparently so that I can see the overlapping regions. However, no matter
> what I try I can't seem to get this effect and the rendering will make the
> shapes draw over each other.
>
>
>
> I'm using Mapserver 6.0.1
>
>
>
> OUTPUTFORMAT
>
> NAME "png"
>
> DRIVER AGG/PNG
>
> MIMETYPE "image/pngt"
>
> IMAGEMODE RGBA
>
> EXTENSION "png"
>
> FORMATOPTION "GAMMA=1.0"
>
> TRANSPARENT TRUE
>
> END
>
>
>
> I have a very simple class for my layer
>
>   CLASS
>
>   STYLE
>
> OPACITY 25
>
> COLOR [color]
>
> OUTLINECOLOR -1 -1 -1
>
> ANTIALIAS TRUE
>
> END
>
>   LABEL
>
> COLOR  0 0 255
>
> OUTLINECOLOR 250 250 250
>
> OUTLINEWIDTH 3
>
> FONT stMYFont
>
> TYPE truetype
>
> SIZE 9
>
> POSITION AUTO
>
> PARTIALS FALSE
>
> MINFEATURESIZE AUTO
>
> END
>
>  END
>
>
>
> ___
> mapserver-users mailing list
> mapserver-users@lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>
>
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] mapcache in a cluster

2011-11-21 Thread thomas bonfort
What kind of performance issues? The current locking code only uses
the presence/absence of a file for it's locking functions, and does
not rely on flock/fcntl.

--
thomas

On Mon, Nov 21, 2011 at 15:16, Travis Kirstine  wrote:
> Thomas,
>
> We have been running into some performance issues mapcache and nfs.
> We feel the issue may be related to how nfs locks files/directories
> compared to smb.  We are trying a few thing on our end (disable
> locking / nfs4 etc).  Do you have any ideas?
>
> Regards
>
> On 20 October 2011 12:19, thomas bonfort  wrote:
>> So, this discussion inspired me to completely rework the locking
>> mechanism in mapcache, to stop relying on file locks which have their
>> quirks on network filesystems.
>> I have tried using multiple apache instances configured to used a
>> SMB-mounted lock directory and hammered both instances on unseeded
>> identical area to force locking, and ended up with absolutely no
>> duplicate wms requests or failed requests for the clients.
>> The code is committed in trunk. Thanks for bringing this up, this
>> allowed me to really simplify the locking code and remove a lot of
>> unneeded stuff :)
>>
>> --
>> thomas
>>
>> On Thu, Oct 20, 2011 at 17:08, Travis Kirstine  
>> wrote:
>>> Andreas and Thomas
>>>
>>> Thanks for you responses,  I have discussed this with some of our IT
>>> staff and they had similar solution as Andreas using gfs.  Their
>>> comments are below:
>>>
>>> "I suspect this scheme is not reliable over NFS. The problem is the
>>> directory updates are not synchronized across multiple nodes. I had a
>>> similar issue with the IMAP E-mail protocol. Our workaround currently
>>> is to force each user to leverage a single server.
>>>
>>> Ref:
>>> http://wiki.dovecot.org/NFS
>>>
>>> Seems like there's some tweaks to disable directory attribute caching
>>> but this can trigger slower performance.
>>> Only workaround is to use GFS which I found to have it's own issues. "
>>>
>>> Regards
>>>
>>>
>>>
>>> On 20 October 2011 05:32, Eichner, Andreas - SID-NLKM
>>>  wrote:
>>>>
>>>> We use TileCache.py on two servers with the cache on an OCFS2 on a
>>>> shared LUN in the SAN. No known issues with that for now. Note: Spurious
>>>> stale lock files occurred already on a single machine. There seemed to
>>>> be issues with lots of requests and a very slow upstream server. I used
>>>> a cron job to delete lock files older than 5 minutes or so.
>>>> As Thomas noted, if the lock files are created on a shared filesystem
>>>> and you make sure the filesystem you use is able to lock files properly
>>>> (read the docs carefully!) there's no reason why it should not work.
>>>>
>>> ___
>>> mapserver-users mailing list
>>> mapserver-users@lists.osgeo.org
>>> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>>>
>>
>
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] Re: mapeditor for mapserver

2011-11-28 Thread thomas bonfort
Janeks,
The vim documentation page dates from 2008 (given by the svn rev
8369), but the actual vim syntax file it links to is regularly updated
(c.f. http://trac.osgeo.org/mapserver/browser/trunk/docs/_static/map.vim
)

If you would like to update those doc pages and add other syntax
files, please request commit access to the docs.

--
thomas

On Mon, Nov 28, 2011 at 09:55, Janeks Kamerovskis
 wrote:
> It looks like the documentation chapter:
> http://mapserver.org/development/editing/index.html
> needs to be updated...
> The last and only record is for VIM from 2006 year or 2008.
>
> I can send the SciTe syntax file.
>
> brgds
> Janeks
>
> On 2011.11.28. 10:41, Ulisse wrote:
>>
>> ok, thanks at all.
>>
>> I'm trying the different solutions...
>>
>> Thanks!
>>
>> Ulisse
>>
>>
>> On 25 November 2011 18:25, mailto:s...@planyukon.ca>>
>> wrote:
>>
>>    I edit my mapserver-related files using Crimson Editor. I've
>>    posted the syntax files that I developed/adapted here:
>>    http://www.planyukon.ca/index.php/documents/atlas.html
>>    I find these helpful, but there is room for improvement.
>>
>>    I don't use UltraEdit, but I found a syntax file for it at:
>>    http://www.ultraedit.com/files/wf/mapserver.uew
>>    The Crimson Editor syntax files are based on the UltraEdit one.
>>
>>    Hope that helps.
>>    Sam
>>
>>    ___
>>    mapserver-users mailing list
>>    mapserver-users@lists.osgeo.org
>>    
>>    http://lists.osgeo.org/mailman/listinfo/mapserver-users
>>
>>
>>
>>
>> ___
>> mapserver-users mailing list
>> mapserver-users@lists.osgeo.org
>> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>
> ___
> mapserver-users mailing list
> mapserver-users@lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] mod-geocache to mod-mapcache transition...

2011-11-28 Thread thomas bonfort
aside from the opening block called  instead of 
they should be indentical.
recent mapcache will work with the same caches as  modgeocache, except
for the WGS84 preconfigured grid where the zoom level numbering has
changed (mod-geocache's zoom level 0 has been deleted, it's level 1 is
now mapcache's level 0)

--
thomas

On Mon, Nov 28, 2011 at 18:50, Lime, Steve D (DNR)
 wrote:
> Hi all: I’m currently running somewhat recent mod-geocache from trunk
> successfully and would like to move to mod-mapcache. Does mod-mapcache use
> the same config format (looks like it) and can it work off tiles generated
> by mod-geocache?
>
>
>
> Steve
>
>
>
> ___
> mapserver-users mailing list
> mapserver-users@lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>
>
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] mod-geocache to mod-mapcache transition...

2011-11-28 Thread thomas bonfort
Stve, can you provide a backtrace for this:
- apachectl stop
- gdb /usr/sbin/httpd (or whatever the path is to the httpd binary)
- # run -X

--
thomas

On Mon, Nov 28, 2011 at 19:46, Lime, Steve D (DNR)
 wrote:
> I'm getting a segfault trying to access any images. Config file is the same 
> except for the opening block. Can the modules be run together? The demos run 
> for both although the mapcache image calls all
> Segfault. The layer list is there so it's parsing the config- there are 
> actually more layers at
> /mapcache/demo/wms than the geocache setup (WMS and singleTile).
>
> Steve
>
> -----Original Message-
> From: thomas bonfort [mailto:thomas.bonf...@gmail.com]
> Sent: Monday, November 28, 2011 11:56 AM
> To: Lime, Steve D (DNR)
> Cc: mapserver-users@lists.osgeo.org
> Subject: Re: [mapserver-users] mod-geocache to mod-mapcache transition...
>
> aside from the opening block called  instead of 
> they should be indentical.
> recent mapcache will work with the same caches as  modgeocache, except
> for the WGS84 preconfigured grid where the zoom level numbering has
> changed (mod-geocache's zoom level 0 has been deleted, it's level 1 is
> now mapcache's level 0)
>
> --
> thomas
>
> On Mon, Nov 28, 2011 at 18:50, Lime, Steve D (DNR)
>  wrote:
>> Hi all: I’m currently running somewhat recent mod-geocache from trunk
>> successfully and would like to move to mod-mapcache. Does mod-mapcache use
>> the same config format (looks like it) and can it work off tiles generated
>> by mod-geocache?
>>
>>
>>
>> Steve
>>
>>
>>
>> ___
>> mapserver-users mailing list
>> mapserver-users@lists.osgeo.org
>> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>>
>>
>
>
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] high memory usage on map draw

2011-11-29 Thread thomas bonfort
On Tue, Nov 29, 2011 at 09:20, Daniele Debernardi  wrote:
> Hi,
> with mapserver trunk version (but i think with others too) I have to
> generate very big map to be imported in a pdf file.
> I use php mapscript to generate maps with 300 dpi for an A1/A0 pdf page or
> bigger.
> This mean that the map has dimensions like 15000x25000 pxl and when I call
> the MapObj->draw method i get this error:
>
> PHP Warning:  mapObj::draw(): [MapServer Error]: agg2CreateImage():
> mapagg.cpp: 708: Out of memory allocating 1550851152 bytes.
>
> Map server is configured with the AGG/PNG driver with imagemode RGBA.
>
> Is it normal that need so much memory to generate the image?
>
> I already tryied the php ini_set memory_limit but with a limit of 2048M i
> still have some problem with memory.
>
> I checked other possible outputs but generating maps in pdf through Cairo
> driver but doc says that polygons filled with symbols are not supported, and
> for that reason I cant use it.
> SVG output has some limitations too like line drawn without symbols or
> pixmap symbols not supported.

All those features are supported by the pdf renderer, cf
http://trac.osgeo.org/mapserver/browser/trunk/msautotest/renderers/expected
(all files ending in .pdf.png are actually pdfs not pngs)
Pixmap symbols are not scaled when using higher resolution (i,e
resolution/defresolution) output, but that is inherent to the pixmap
symbols themselves, not mapserver (i.e. if you want high res output,
you should ban the usage of pixmap symbols, and prefer symbols that
can be scaled correctly)

>
> Is there a better way to generate so big map images and imported in a pdf
> file?
>
> Hope you guys can help me.
>
> Daniele
> ___
> mapserver-users mailing list
> mapserver-users@lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] MapCache: Disabling WMS requests for fully-seeded caches?

2011-11-29 Thread thomas bonfort
You can do this by commenting out the  block from the tileset
once the wanted tiles have been created. You'll probably also want set
error reporting to return blank images from that stage onwards.

--
thomas

On Tue, Nov 29, 2011 at 00:09, John Taranu
 wrote:
> We have a fully seeded cache that was fully seeded to a polygon outline.
> The intent is to serve the tileset through a variety of services (WMS, TMS)
> using mod-mapcache.
>
>
>
> Tiles that are outside the polygon outline but still within the polygon
> bounding box should be blank tiles.  However, a request for one of these
> tiles results in a call to that tileset’s WMS source.  This creates
> considerable overhead by starting up MapServer and writing the resulting
> tile to the cache.  Is there any way to disable the WMS calls for these
> blank tiles, and instead short-circuit the request to return a blank?  That
> is, once a tileset has been fully seeded, is it possible to disable any
> further calls to the WMS, so that requests for tiles that are not in the
> cache return a blank?
>
>
> ___
> mapserver-users mailing list
> mapserver-users@lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] MapCache: Disabling WMS requests for fully-seeded caches?

2011-11-29 Thread thomas bonfort
I've just tried report_img locally without issues, any chance you can
provide a backtrace ?

On Tue, Nov 29, 2011 at 17:32, John Taranu
 wrote:
> Hi Thomas,
>
> Thanks for the suggestion.  Commenting out the source block disables the WMS 
> requests.
>
> However, the error reporting seems to be broken.  Setting 
> empty_img crashes Apache with a segmentation fault 
> (mod_mapcache SVN revision 12828).  Setting report throws 
> HTTP 404 responses, which is a more reasonable result.
>
> John
>
>
>
> -Original Message-
> From: thomas bonfort [mailto:thomas.bonf...@gmail.com]
> Sent: Tuesday, November 29, 2011 10:33 AM
> To: John Taranu
> Cc: mapserver-users@lists.osgeo.org
> Subject: Re: [mapserver-users] MapCache: Disabling WMS requests for 
> fully-seeded caches?
>
> You can do this by commenting out the  block from the tileset once 
> the wanted tiles have been created. You'll probably also want set error 
> reporting to return blank images from that stage onwards.
>
> --
> thomas
>
> On Tue, Nov 29, 2011 at 00:09, John Taranu  
> wrote:
>> We have a fully seeded cache that was fully seeded to a polygon outline.
>> The intent is to serve the tileset through a variety of services (WMS,
>> TMS) using mod-mapcache.
>>
>>
>>
>> Tiles that are outside the polygon outline but still within the
>> polygon bounding box should be blank tiles.  However, a request for
>> one of these tiles results in a call to that tileset’s WMS source.
>> This creates considerable overhead by starting up MapServer and
>> writing the resulting tile to the cache.  Is there any way to disable
>> the WMS calls for these blank tiles, and instead short-circuit the
>> request to return a blank?  That is, once a tileset has been fully
>> seeded, is it possible to disable any further calls to the WMS, so
>> that requests for tiles that are not in the cache return a blank?
>>
>>
>> ___
>> mapserver-users mailing list
>> mapserver-users@lists.osgeo.org
>> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>>
>
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] MapCache: Disabling WMS requests for fully-seeded caches?

2011-11-29 Thread thomas bonfort
I'll have a look, but my config that doesn't segfault is using JPEG.
Note that the 404 error code is the way it's supposed to work, if you
inspect the headers and body you should see a image/jpeg mimetype, a
jpeg body, and an X-MapCache-Error header explaining what happened.

--
thomas

On Tue, Nov 29, 2011 at 21:22, John Taranu
 wrote:
> Note that setting the default format to PNG doesn't cause a segmentation
> fault:
>
>
>   PNG
>   empty_img
>
> However, in this case mapcache still returns a HTTP 404 instead of a blank
> image.
>
>
>
> -Original Message-
> From: Travis Kirstine [mailto:traviskirst...@gmail.com]
> Sent: Tuesday, November 29, 2011 3:21 PM
> To: thomas bonfort
> Cc: John Taranu; mapserver-users@lists.osgeo.org
> Subject: Re: [mapserver-users] MapCache: Disabling WMS requests for
> fully-seeded caches?
>
> Thomas,
>
> Here is the backtrace:
>
> (gdb) run -X
> Starting program: /usr/sbin/httpd -X
> warning: no loadable sections found in added symbol-file system-supplied DSO
> at 0x2ad1b000 [Thread debugging using libthread_db enabled]
>
> Program received signal SIGSEGV, Segmentation fault.
> 0x2ca4e32b in strstr () from /lib64/libc.so.6
> (gdb) bt
> #0  0x2ca4e32b in strstr () from /lib64/libc.so.6
> #1  0x2aaab539737d in mapcache_image_create_empty () from
> /usr/lib64/httpd/modules/mod_mapcache.so
> #2  0x2aaab53971fe in mapcache_configuration_parse_xml () from
> /usr/lib64/httpd/modules/mod_mapcache.so
> #3  0x2aaab53a047a in mapcache_configuration_parse () from
> /usr/lib64/httpd/modules/mod_mapcache.so
> #4  0x2aaab53879e6 in mapcache_add_alias (cmd=0x7fffe760, cfg= optimized out>, alias=0x2ae0f850 "/mapcache",
>    configfile=0x2ae0f860 "/var/www/html/mapcache/mapcache.xml")
> at mod_mapcache.c:502
> #5  0x2aad5c4b in ?? ()
> #6  0x2aad60d0 in ap_walk_config ()
> #7  0x2aad6232 in ap_process_config_tree ()
> #8  0x2aac1c51 in main ()
> (gdb)
>
> #
>
> MapCache snippet:
>
>  mixed
>
>  empty_img
>
> Regards
>
>
>
>
> On 29 November 2011 11:56, thomas bonfort  wrote:
>> I've just tried report_img locally without issues, any chance you can
>> provide a backtrace ?
>>
>> On Tue, Nov 29, 2011 at 17:32, John Taranu
>>  wrote:
>>> Hi Thomas,
>>>
>>> Thanks for the suggestion.  Commenting out the source block disables the
> WMS requests.
>>>
>>> However, the error reporting seems to be broken.  Setting
> empty_img crashes Apache with a segmentation fault
> (mod_mapcache SVN revision 12828).  Setting report throws
> HTTP 404 responses, which is a more reasonable result.
>>>
>>> John
>>>
>>>
>>>
>>> -Original Message-
>>> From: thomas bonfort [mailto:thomas.bonf...@gmail.com]
>>> Sent: Tuesday, November 29, 2011 10:33 AM
>>> To: John Taranu
>>> Cc: mapserver-users@lists.osgeo.org
>>> Subject: Re: [mapserver-users] MapCache: Disabling WMS requests for
> fully-seeded caches?
>>>
>>> You can do this by commenting out the  block from the tileset
> once the wanted tiles have been created. You'll probably also want set error
> reporting to return blank images from that stage onwards.
>>>
>>> --
>>> thomas
>>>
>>> On Tue, Nov 29, 2011 at 00:09, John Taranu
>  wrote:
>>>> We have a fully seeded cache that was fully seeded to a polygon outline.
>>>> The intent is to serve the tileset through a variety of services
>>>> (WMS,
>>>> TMS) using mod-mapcache.
>>>>
>>>>
>>>>
>>>> Tiles that are outside the polygon outline but still within the
>>>> polygon bounding box should be blank tiles.  However, a request for
>>>> one of these tiles results in a call to that tileset’s WMS source.
>>>> This creates considerable overhead by starting up MapServer and
>>>> writing the resulting tile to the cache.  Is there any way to
>>>> disable the WMS calls for these blank tiles, and instead
>>>> short-circuit the request to return a blank?  That is, once a
>>>> tileset has been fully seeded, is it possible to disable any further
>>>> calls to the WMS, so that requests for tiles that are not in the cache
> return a blank?
>>>>
>>>>
>>>> ___
>>>> mapserver-users mailing list
>>>> mapserver-users@lists.osgeo.org
>>>> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>>>>
>>>
>> ___
>> mapserver-users mailing list
>> mapserver-users@lists.osgeo.org
>> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>
>
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] MapCache: Disabling WMS requests for fully-seeded caches?

2011-11-29 Thread thomas bonfort
hmm, ok, you're using the mixed image format for the empty image, and
that was not a supported use-case. I've just commit a fix that fixes
the issue for me here.

regards,
thomas

On Tue, Nov 29, 2011 at 22:13, thomas bonfort  wrote:
> I'll have a look, but my config that doesn't segfault is using JPEG.
> Note that the 404 error code is the way it's supposed to work, if you
> inspect the headers and body you should see a image/jpeg mimetype, a
> jpeg body, and an X-MapCache-Error header explaining what happened.
>
> --
> thomas
>
> On Tue, Nov 29, 2011 at 21:22, John Taranu
>  wrote:
>> Note that setting the default format to PNG doesn't cause a segmentation
>> fault:
>>
>>
>>   PNG
>>   empty_img
>>
>> However, in this case mapcache still returns a HTTP 404 instead of a blank
>> image.
>>
>>
>>
>> -Original Message-
>> From: Travis Kirstine [mailto:traviskirst...@gmail.com]
>> Sent: Tuesday, November 29, 2011 3:21 PM
>> To: thomas bonfort
>> Cc: John Taranu; mapserver-users@lists.osgeo.org
>> Subject: Re: [mapserver-users] MapCache: Disabling WMS requests for
>> fully-seeded caches?
>>
>> Thomas,
>>
>> Here is the backtrace:
>>
>> (gdb) run -X
>> Starting program: /usr/sbin/httpd -X
>> warning: no loadable sections found in added symbol-file system-supplied DSO
>> at 0x2ad1b000 [Thread debugging using libthread_db enabled]
>>
>> Program received signal SIGSEGV, Segmentation fault.
>> 0x2ca4e32b in strstr () from /lib64/libc.so.6
>> (gdb) bt
>> #0  0x2ca4e32b in strstr () from /lib64/libc.so.6
>> #1  0x2aaab539737d in mapcache_image_create_empty () from
>> /usr/lib64/httpd/modules/mod_mapcache.so
>> #2  0x2aaab53971fe in mapcache_configuration_parse_xml () from
>> /usr/lib64/httpd/modules/mod_mapcache.so
>> #3  0x2aaab53a047a in mapcache_configuration_parse () from
>> /usr/lib64/httpd/modules/mod_mapcache.so
>> #4  0x2aaab53879e6 in mapcache_add_alias (cmd=0x7fffe760, cfg=> optimized out>, alias=0x2ae0f850 "/mapcache",
>>    configfile=0x2ae0f860 "/var/www/html/mapcache/mapcache.xml")
>> at mod_mapcache.c:502
>> #5  0x2aad5c4b in ?? ()
>> #6  0x2aad60d0 in ap_walk_config ()
>> #7  0x2aad6232 in ap_process_config_tree ()
>> #8  0x2aac1c51 in main ()
>> (gdb)
>>
>> #
>>
>> MapCache snippet:
>>
>>  mixed
>>
>>  empty_img
>>
>> Regards
>>
>>
>>
>>
>> On 29 November 2011 11:56, thomas bonfort  wrote:
>>> I've just tried report_img locally without issues, any chance you can
>>> provide a backtrace ?
>>>
>>> On Tue, Nov 29, 2011 at 17:32, John Taranu
>>>  wrote:
>>>> Hi Thomas,
>>>>
>>>> Thanks for the suggestion.  Commenting out the source block disables the
>> WMS requests.
>>>>
>>>> However, the error reporting seems to be broken.  Setting
>> empty_img crashes Apache with a segmentation fault
>> (mod_mapcache SVN revision 12828).  Setting report throws
>> HTTP 404 responses, which is a more reasonable result.
>>>>
>>>> John
>>>>
>>>>
>>>>
>>>> -Original Message-
>>>> From: thomas bonfort [mailto:thomas.bonf...@gmail.com]
>>>> Sent: Tuesday, November 29, 2011 10:33 AM
>>>> To: John Taranu
>>>> Cc: mapserver-users@lists.osgeo.org
>>>> Subject: Re: [mapserver-users] MapCache: Disabling WMS requests for
>> fully-seeded caches?
>>>>
>>>> You can do this by commenting out the  block from the tileset
>> once the wanted tiles have been created. You'll probably also want set error
>> reporting to return blank images from that stage onwards.
>>>>
>>>> --
>>>> thomas
>>>>
>>>> On Tue, Nov 29, 2011 at 00:09, John Taranu
>>  wrote:
>>>>> We have a fully seeded cache that was fully seeded to a polygon outline.
>>>>> The intent is to serve the tileset through a variety of services
>>>>> (WMS,
>>>>> TMS) using mod-mapcache.
>>>>>
>>>>>
>>>>>
>>>>> Tiles that are outside the polygon outline but still within the
>>>>> polygon bounding box should be blank tiles.  However, a request for
>>>>> one of 

Re: [mapserver-users] MapCache: Disabling WMS requests for fully-seeded caches?

2011-11-29 Thread thomas bonfort
I spoke a bit too soon, the segfault is fixed, but the empty image is
returned with a text/plain mimetype which is incorrect.
I don't have the time to look into this further now, could you please
open a ticket for this so the issue isn't forgotten?

tks,
thomas

On Tue, Nov 29, 2011 at 22:27, thomas bonfort  wrote:
> hmm, ok, you're using the mixed image format for the empty image, and
> that was not a supported use-case. I've just commit a fix that fixes
> the issue for me here.
>
> regards,
> thomas
>
> On Tue, Nov 29, 2011 at 22:13, thomas bonfort  
> wrote:
>> I'll have a look, but my config that doesn't segfault is using JPEG.
>> Note that the 404 error code is the way it's supposed to work, if you
>> inspect the headers and body you should see a image/jpeg mimetype, a
>> jpeg body, and an X-MapCache-Error header explaining what happened.
>>
>> --
>> thomas
>>
>> On Tue, Nov 29, 2011 at 21:22, John Taranu
>>  wrote:
>>> Note that setting the default format to PNG doesn't cause a segmentation
>>> fault:
>>>
>>>
>>>   PNG
>>>   empty_img
>>>
>>> However, in this case mapcache still returns a HTTP 404 instead of a blank
>>> image.
>>>
>>>
>>>
>>> -Original Message-
>>> From: Travis Kirstine [mailto:traviskirst...@gmail.com]
>>> Sent: Tuesday, November 29, 2011 3:21 PM
>>> To: thomas bonfort
>>> Cc: John Taranu; mapserver-users@lists.osgeo.org
>>> Subject: Re: [mapserver-users] MapCache: Disabling WMS requests for
>>> fully-seeded caches?
>>>
>>> Thomas,
>>>
>>> Here is the backtrace:
>>>
>>> (gdb) run -X
>>> Starting program: /usr/sbin/httpd -X
>>> warning: no loadable sections found in added symbol-file system-supplied DSO
>>> at 0x2ad1b000 [Thread debugging using libthread_db enabled]
>>>
>>> Program received signal SIGSEGV, Segmentation fault.
>>> 0x2ca4e32b in strstr () from /lib64/libc.so.6
>>> (gdb) bt
>>> #0  0x2ca4e32b in strstr () from /lib64/libc.so.6
>>> #1  0x2aaab539737d in mapcache_image_create_empty () from
>>> /usr/lib64/httpd/modules/mod_mapcache.so
>>> #2  0x2aaab53971fe in mapcache_configuration_parse_xml () from
>>> /usr/lib64/httpd/modules/mod_mapcache.so
>>> #3  0x2aaab53a047a in mapcache_configuration_parse () from
>>> /usr/lib64/httpd/modules/mod_mapcache.so
>>> #4  0x2aaab53879e6 in mapcache_add_alias (cmd=0x7fffe760, cfg=>> optimized out>, alias=0x2ae0f850 "/mapcache",
>>>    configfile=0x2ae0f860 "/var/www/html/mapcache/mapcache.xml")
>>> at mod_mapcache.c:502
>>> #5  0x2aad5c4b in ?? ()
>>> #6  0x2aad60d0 in ap_walk_config ()
>>> #7  0x2aad6232 in ap_process_config_tree ()
>>> #8  0x2aac1c51 in main ()
>>> (gdb)
>>>
>>> #
>>>
>>> MapCache snippet:
>>>
>>>  mixed
>>>
>>>  empty_img
>>>
>>> Regards
>>>
>>>
>>>
>>>
>>> On 29 November 2011 11:56, thomas bonfort  wrote:
>>>> I've just tried report_img locally without issues, any chance you can
>>>> provide a backtrace ?
>>>>
>>>> On Tue, Nov 29, 2011 at 17:32, John Taranu
>>>>  wrote:
>>>>> Hi Thomas,
>>>>>
>>>>> Thanks for the suggestion.  Commenting out the source block disables the
>>> WMS requests.
>>>>>
>>>>> However, the error reporting seems to be broken.  Setting
>>> empty_img crashes Apache with a segmentation fault
>>> (mod_mapcache SVN revision 12828).  Setting report throws
>>> HTTP 404 responses, which is a more reasonable result.
>>>>>
>>>>> John
>>>>>
>>>>>
>>>>>
>>>>> -Original Message-
>>>>> From: thomas bonfort [mailto:thomas.bonf...@gmail.com]
>>>>> Sent: Tuesday, November 29, 2011 10:33 AM
>>>>> To: John Taranu
>>>>> Cc: mapserver-users@lists.osgeo.org
>>>>> Subject: Re: [mapserver-users] MapCache: Disabling WMS requests for
>>> fully-seeded caches?
>>>>>
>>>>> You can do this by commenting out the  block from the tileset
>>> once the wante

Re: [mapserver-users] Re: Mapserver 6.0.1 -- Label Class not recognizing token BACKGROUNDCOLOR

2011-11-30 Thread thomas bonfort
Havard,

"labelpnt generates a point with its center at the middle of the
bounding rectangle of the text."

Unless there's a problem with the code, this is not the behavior of
the labelpnt geomtransform. The point created by labelpnt is dependant
on the label's POSITION, i.e. it is the center of the text's bounding
rectangle only if the label is in position CC.

regards,
thomas

On Thu, Dec 1, 2011 at 08:47, Havard Tveite  wrote:
> The documentation has been updated.   An example of GEOMTRANSFORM
> usage has been added in the label document under STYLE.
>
> http://gis.umb.no/~havatv/mapserver/docs/mapfile/label.html#label-style
>
> Håvard
>
> On 11/30/2011 5:09 AM, Stephen Woodbridge wrote:
>>
>> On 11/29/2011 10:19 PM, Matt Pettis wrote:
>>>
>>> I see upon reading closer that it is deprecated... but I thought that
>>> meant
>>> it was discouraged, but not yet removed.  That must not be true... I am
>>> now
>>> working to find a GEOMTRANSFORM example to help me do the equivalent.
>>
>> Hi Matt,
>>
>> These should help you:
>>
>> http://mapserver.org/mapfile/style.html
>> http://mapserver.org/development/rfc/ms-rfc-72.html
>> http://mapserver.org/trunk/MIGRATION_GUIDE.html
>>
>> Also please write a Bug and assign it to the Documentation and the fact
>> that it has been removed. It might be nice to add a comment in the docs
>> that points to the MIGRATION_GUIDE.
>>
>> Thanks,
>>    -Steve W
>> ___
>> 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, UMB
> Drøbakveien 31, POBox 5003, N-1432 Ås, NORWAY
> Phone: +47 64965483 Fax: +47 64965401 http://www.umb.no/imt/
> ___
> mapserver-users mailing list
> mapserver-users@lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] Mapcache question.

2011-12-04 Thread thomas bonfort
Jerl,
mapcache itself does not do any pruning of the caches it has created,
but you can get the same effect by using a cache backend that supports
expiration (i.e. memcache).
Mapcache can fit your need, provided:
- you configure your tileset with a "targetdate" - you use
a memcache backend to store the created tiles, and set an 
value in mapcache to 5 hours
If the memory requirement for storing 5 hours worth of tiles is too
important for a memcache server instance, you can have a look at
membase which will also store less frequently used data to disk. The
membase protocol is compatible with memcache, so you can use either
memcache or membase with the same mapcache configuration.

Of course, by running a script every hour to delete expired tiles as
you are doing now, you can then use the classic disk based cache
backend.
regards,
thomas
On Sun, Dec 4, 2011 at 20:13, forums  wrote:
> Hi:
>
> I hope this is the proper place to ask questions about Mapcache since it's
> been moved into the trunk of Mapserver.
>
> I'm wondering if Mapcache can help with a particular setup, and if so maybe
> some advice or direction on where to start?
>
> Here's the setup.  Every 5 minutes a new set of GeoTiffs are created in a
> new directory.  I create a tileindex for the GeoTiffs and use those in the
> map layer.  Every hour, anything more than 5hours old gets deleted.
> I have a single mapfile setup.
>
> The general layer is setup like:
>
>     LAYER
>         NAME 'IMG1'
>         METADATA
>             'wms_title'           'IMG 1'
>             'wms_srs'             'EPSG:4326'
>             'wms_extent'          'MINX MINY MAXX MAXY'
>             'default_targetdate' ''
>             'targetdate_validation_pattern' '^[0-9]{12}$'
>         END
>         STATUS ON
>         TILEINDEX '/PATH/TO/IMG/DIR/%targetdate%/TILEINDEX.shp'
>         TILEITEM 'Location'
>         TYPE RASTER
>     END
>
>
> I'm currently loading these images as overlays for Googlemaps. using the
> mode=tile&tilemode=gmaps...&targetdate=2011...etc.
> Problem is it's too slow. I end up loading hundreds of images, as I
> basically create an animation using sequential times.
>
> I'd like to be able to have a single mapcache config file, that will pass
> the date through to pull the proper shapefile, and have the result cached so
> next time it's loading off the disk.  MOST of the images end up being
> blank/transparent tiles.
>
> Is Mapcache a good choice for this?
> The front end for this is just a simple GoogleMaps viewport, but ends up
> loading multiple timeslots for display.  It generates the request URL (not
> currently in WMS fashion but could be).
>
> Thanks for any help I can get.
>
> Jerl
>
>
>
> ___
> mapserver-users mailing list
> mapserver-users@lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] Mapcache question.

2011-12-04 Thread thomas bonfort
only the wms and wmts services support dimensions (there is no spec
defining this support for the others).

you can either adapt your gmaps/js code to build a wmts url, or hack
into the mapcache code to add dimension support to the tms / gmaps
service.

--
thomas

On Sun, Dec 4, 2011 at 22:23, forums  wrote:
> I almost have it, I just can't seem to get the targetdate dimension to
> populate.
>
> /mapcache/gmaps/country@WGS84/1/1/0.png works fine if I don't have the
> layers that require the targetdate parameter.  I get a "parameter pattern
> failed validation" error returned from Mapserver when I have the necessary
> layers defined in the mapcache config file.
>
> The obvious thing for me to try was:
> /mapcache/gmaps/country@WGS84/1/1/0.png?targetdate=201112042105
>
> But that failed.  Is there a way to get the targetdate to fill in? I've
> moved it around a bit, but still can't get it to fill in.
>
> Thanks again!!
>
> Jerl
>
>
> On Sun, Dec 4, 2011 at 2:59 PM, forums  wrote:
>>
>> Thanks Stephen and Thomas.
>>
>> I think I'll be good with the dimension and the disk cache.
>>  Unfortunately, the apache we have doesn't have memcache built into it (too
>> much hassle to upgrade it right now) and the version of SQLite is too
>> old...also a hassle to upgrade.
>>
>> I was able to get it to load the proper map when just using the entire
>> bounding box, the whole world.  Now to make it work with the the tilemode
>> for google...which looks like that should be straight forward??
>>
>>
>> Thanks guys!!
>>
>> Jerl
>>
>>
>> On Sun, Dec 4, 2011 at 2:00 PM, thomas bonfort 
>> wrote:
>>>
>>> Jerl,
>>> mapcache itself does not do any pruning of the caches it has created,
>>> but you can get the same effect by using a cache backend that supports
>>> expiration (i.e. memcache).
>>> Mapcache can fit your need, provided:
>>> - you configure your tileset with a "targetdate" - you use
>>> a memcache backend to store the created tiles, and set an 
>>> value in mapcache to 5 hours
>>> If the memory requirement for storing 5 hours worth of tiles is too
>>> important for a memcache server instance, you can have a look at
>>> membase which will also store less frequently used data to disk. The
>>> membase protocol is compatible with memcache, so you can use either
>>> memcache or membase with the same mapcache configuration.
>>>
>>> Of course, by running a script every hour to delete expired tiles as
>>> you are doing now, you can then use the classic disk based cache
>>> backend.
>>> regards,
>>> thomas
>>> On Sun, Dec 4, 2011 at 20:13, forums  wrote:
>>> > Hi:
>>> >
>>> > I hope this is the proper place to ask questions about Mapcache since
>>> > it's
>>> > been moved into the trunk of Mapserver.
>>> >
>>> > I'm wondering if Mapcache can help with a particular setup, and if so
>>> > maybe
>>> > some advice or direction on where to start?
>>> >
>>> > Here's the setup.  Every 5 minutes a new set of GeoTiffs are created in
>>> > a
>>> > new directory.  I create a tileindex for the GeoTiffs and use those in
>>> > the
>>> > map layer.  Every hour, anything more than 5hours old gets deleted.
>>> > I have a single mapfile setup.
>>> >
>>> > The general layer is setup like:
>>> >
>>> >     LAYER
>>> >         NAME 'IMG1'
>>> >         METADATA
>>> >             'wms_title'           'IMG 1'
>>> >             'wms_srs'             'EPSG:4326'
>>> >             'wms_extent'          'MINX MINY MAXX MAXY'
>>> >             'default_targetdate' ''
>>> >             'targetdate_validation_pattern' '^[0-9]{12}$'
>>> >         END
>>> >         STATUS ON
>>> >         TILEINDEX '/PATH/TO/IMG/DIR/%targetdate%/TILEINDEX.shp'
>>> >         TILEITEM 'Location'
>>> >         TYPE RASTER
>>> >     END
>>> >
>>> >
>>> > I'm currently loading these images as overlays for Googlemaps. using
>>> > the
>>> > mode=tile&tilemode=gmaps...&targetdate=2011...etc.
>>> > Problem is it's too slow. I end up loading hundreds of im

Re: [mapserver-users] Specify resolution (or pixel size) in WMS requests

2011-12-05 Thread thomas bonfort
cgi controls should do the trick?

http://../?SERVICE=WMS&&MAP.RESOLUTION=144&MAP.DEFRESOLUTION=96

--
thomas

On Mon, Dec 5, 2011 at 17:43, Peter Hopfgartner
 wrote:
> Basically, I am looking for a way to something analogous to DEFRESOLUTION in
> a WMS request. The standard says, that a pixel is 0.28 mm x 0.28 mm
> (25.4/0.28 ~= 90.71 DPI). I could not found a way to change this in the WMS
> 1.3.0 standard.
> Is there a MapServer vendor parameter, similar to the one in GeoServer,
> http://docs.geoserver.org/latest/en/user/services/wms/vendor.html#format-options
> ?
>
> Peter
>
> --
> Peter Hopfgartner R3 GIS http://www.r3-gis.com
> ___
> mapserver-users mailing list
> mapserver-users@lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/mapserver-users
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


[mapserver-users] Re: Reloading MapCache configuration file on changes?

2011-12-06 Thread thomas bonfort
AFAIK, this isn't possible. Inside an apache module, the configuration
is considered read-only as it is shared between multiple worker
threads/processed spawned by httpd.

apachectl configtest && apachectl graceful will restart the server
gracefully, i.e. without aborting ongoing requests, and will load the
new configuration for subsequent requests.

--
thomas

On Mon, Dec 5, 2011 at 23:37, John Taranu
 wrote:
> Thomas,
>
>
>
> Is there a better way force MapCache to reload its configuration script than
> restarting apache?  I’m working on an application that will use two
> load-balanced web servers running MapCache, all pointing to a single central
> tile repository and a single central .xml configuration file.  The
> configuration file will occasionally be edited, either with deletions or
> additional tilesets.  Both web servers need to reload the updated
> configuration .xml.
>
>
>
> Is it possible to set up MapCache to check if the config file was recently
> updated and, if so, reload the config .xml?  It looks like this is currently
> enabled under FastCGI, but not under Apache.
>
>
>
> John
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


<    1   2   3   4   5   6   7   8   9   >