[mapserver-users] RE: Random colours for polygon fill?

2011-07-06 Thread Anzel, Phil - Fort Collins, CO
Robert,
It may be that the SDE plugin does not allow insertion of the Sql fragment from 
the COLOR to be executed by the provider. In such a case the solution provided 
under separate cover by B. Heath Robinson might provide guidance. I do not know 
if the ArcGIS Server lets you use a view as a data source; if so you could add 
a calculated column to yield the RGB string (either as a hexadecimal valye as 
suggested by Heath) or as a string with space-delimited R, G and B values.
FWIW the approach I had suggested worked in MapServer 5.6.2 against Sql Server 
2008; beyond that I've not tried it.
- Phil
From: Robert Sanson [mailto:robert.san...@asurequality.com]
Sent: Wednesday, July 06, 2011 4:48 PM
To: Anzel, Phil - Fort Collins, CO; mapserver-users@lists.osgeo.org
Subject: RE: Random colours for polygon fill?

Looks an interesting approach. I tried it with my layer in ArcGIS Server 
(stored in MS-SQL v 2005) and couldn't get it to work. I am using Mapserver 
5.4.2

Here is my layer:

LAYER
  NAME fbnd
  GROUP CRS
  TYPE POLYGON
  STATUS ON
  CONNECTIONTYPE SDE
  CONNECTIONTYPE PLUGIN
  PLUGIN d:/ms4w/apache/specialplugins/msplugin_sde_93.dll
  CONNECTION db-esri,port:5155,cadastre,user,pass
  DATA CADASTRE.SDEADMIN.VW_FARM_BOUNDARY_SP,SHAPE
  DUMP TRUE
  HEADER   ../templates/apiaries_query_header.html
  TEMPLATE ../templates/apiaries_query_body.html
  LABELMAXSCALE 10
  LABELCACHE on
  LABELITEM 'key_decision_maker'
  MAXSCALE 25
  CLASS
NAME fbnd
DEBUG on
STYLE
  WIDTH 3
  #COLOR 135 206 235
  COLOR [convert(varchar(3), ((128 + convert(int,env_min_x)) % 253)) +   
+ convert(varchar(3), ((200 + convert(int,env_min_x)) % 254)) +   + 
convert(varchar(3), ((64 + convert(int,env_min_x)) % 255))]
  OUTLINECOLOR 0 255 0
END
LABEL
  TYPE truetype
  FONT arial
  SIZE 9
  POSITION auto
  OUTLINECOLOR 255 255 255 #--Halo
  COLOR 76 179 145
  MINDISTANCE 50
  BUFFER 2
END #LABEL
  END #CLASS
Many thanks,

Robert

 Anzel, Phil - Fort Collins, CO phil.an...@ftc.usda.gov 7/07/2011 2:11 
 a.m. 
Hi, Robert,

A simple approach would be to generate a pseudo-random color based upon a value 
unique to each record in your source data. For example, in the following 
example the source data, pulled from a Microsoft Sql Server database, has an 
integer column named ShapeID:

  layer
name mupolygon
status on
connectiontype plugin
plugin C:/ms4w/Apache/specialplugins/msplugin_mssql2008.dll
processing CLOSE_CONNECTION=DEFER
connection server=...;
projection 'init=epsg:4269' END   # NAD83
units DD
DATA shapeGeometry from soilmu_a_wy721_nad83 using unique shapeID using 
SRID=4269
type polygon
opacity 40
class
  name mupoly
  style
COLOR [convert(varchar(3), (128 + shapeID) % 253) + ' ' + 
convert(varchar(3), (200 + shapeID) % 254) + ' ' + convert(varchar(3), (64 + 
shapeID) % 255)]
outlinecolor 0 0 0
outlinewidth 1
  end
end  # of class mupoly
  end # of layer mupolygon

In the context used above, the content of COLOR's specification (everything 
between the square brackets) is passed on as part of the SQL statement 
generated and transmitted to the database engine. Many variations are possible. 
Note that this approach does not provide any protection against the unlikely 
case where adjacent polygons display the same color.

I cannot speak to using data from other data sources. Best of luck with this.

- Phil Anzel
  Web Soil Survey developer
  Vistronix Inc for USDA/NRCS/ITC


-Original Message-

--

Message: 4
Date: Wed, 06 Jul 2011 09:08:28 +1200
From: Robert Sanson robert.san...@asurequality.com
Subject: [mapserver-users] Random colours for polygon fill?
To: mapserver-users@lists.osgeo.org
Message-ID: 4e14260b.379f.003...@asurequality.com
Content-Type: text/plain; charset=us-ascii

Dear Mapserver users

Just wondering if it is possible to colour a polygon Shape file layer with each 
distinct polygon having a different colour?

Many thanks,

Robert Sanson


This email and any attachments are confidential and intended solely for the 
addressee(s). If you are not the intended recipient, please notify us 
immediately and then delete this email from your system.

This message has been scanned for Malware and Viruses by Websense Hosted 
Security. www.websense.comhttp://www.websense.com/
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


RE: [mapserver-users] Build/download site unavailable

2011-03-30 Thread Anzel, Phil - Fort Collins, CO
Thanks for checking, Tamas. I’ll look at our internal network. - Phil

From: Tamas Szekeres [mailto:szeker...@gmail.com]
Sent: Wednesday, March 30, 2011 2:25 PM
To: Anzel, Phil - Fort Collins, CO
Cc: mapserver-users@lists.osgeo.org
Subject: Re: [mapserver-users] Build/download site unavailable

Works for me, currently.

Best regards,

Tamas


2011/3/30 Anzel, Phil - Fort Collins, CO 
phil.an...@ftc.usda.govmailto:phil.an...@ftc.usda.gov
Hi, All,

Is the MapServer binary download site site http://vbkto.dyndns.org/sdk/ 
offline? I'm seeing timeouts when attempting to connect.

Thanks.

- Phil Anzel
Web Soil Survey developer
Vistronix Inc. for USDA/NRCS/ITC
___
mapserver-users mailing list
mapserver-users@lists.osgeo.orgmailto: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 not showing up in MapServer 6.0.0-beta1 release

2011-03-11 Thread Anzel, Phil - Fort Collins, CO
Hi, Thomas,

Thanks for looking into this problem. 

My goal is to create a railroad cross-hatching along a line. I originally 
used:
SYMBOL
  NAME 'default'
  Type simple
END
SYMBOL
  NAME 'tie'
  TYPE vector
  POINTS 0 0  0 7  -99 -99  7 0  7 7  END
END
These were referenced, within a layer of type line, by:
   CLASS
 STYLE
   SYMBOL'default'
   SIZE  1
   COLOR 0 0 0
 END
 STYLE
  SYMBOL 'tie'
  SIZE   8
  COLOR  0 0 0
 END
   END

This had worked under MapServer 5.6.3. I returned to this example after 
upgrading to 5.7DEV on March 9, 2011, and found that the tie cross-hatching 
had disappeared. I tried several other symbols; I used the circle as an 
example because it also worked in the past and is used in the MapServer 
Introduction to MapServer, section 2.4.3, CLASS and STYLE objects.

Closer to the 2.4.3 example, if I define:
  symbol
name 'circle'
filled true
type ellipse
points 0 0 1 1 end
  end
and reference this definition, as per the example, with:
 style
   symbol circle
   color 178 114 1
   size 15
 end
 style
   symbol circle
   color 254 161 0
   size 7
 end
then there is no image created.

Given these experimental results, I wonder if there has been a change in 
behavior in drawing symbols. Alternatively I've made a very simple error.

Is there an error in my map file? How do you recommend that the railroad 
hatched line be drawn?

Thanks again.

- Phil


-Original Message-
From: thomas bonfort [mailto:thomas.bonf...@gmail.com] 
Sent: Friday, March 11, 2011 4:17 AM
To: Anzel, Phil - Fort Collins, CO
Cc: mapserver-users@lists.osgeo.org
Subject: Re: [mapserver-users] Symbol not showing up in MapServer 6.0.0-beta1 
release

huh, I may have misinterpreted...

you can't expect to obtain a point/marker symbology when using a line geometry.

if you effectively want to use marker symbols, you can have a look RFC
48 and its
 GEOMTRANSFORM start|end|vertices transformations.

--
thomas

On Fri, Mar 11, 2011 at 12:10, thomas bonfort thomas.bonf...@gmail.com wrote:
 Phil,

 what kind of symbology are you trying to obtain. I suspect you're
 aiming for a thick line, which now does not require the use of a
 symbol, but rather:

 style
  width 20
  color 0 0 255
 end

 regards,
 thomas

 On Fri, Mar 11, 2011 at 02:24, Anzel, Phil - Fort Collins, CO
 phil.an...@ftc.usda.gov wrote:
 All,

 I upgraded to MapServer 5.7 (6.0.0-beta1) code for x32/VS2010 (downloaded 
 from http://vbkto.dyndns.org/sdk/) on March 9, 2011.

 It appears that embedded symbols are not drawn. Below is a simple map file 
 that has a single diagonal line as a feature and two styles; the first 
 should draw a 25-pixel circle, the second a single-pixel line; similar map 
 files worked under 5.6.3. I do not know if this worked under 5.7 circa 
 December 15, 2010.

 Only the single-pixel line is drawn. I've tried various other symbol 
 definitions; none appear in the output.

 I'm using the drawmap.exe utility to draw the PNG output file under 
 Microsoft Windows XP Professional 2002 SP 3. No errors are reported.

 Can you help?

 Thanks,

 - Phil Anzel
  Web Soil Survey development team
  Vistronix Inc. for USDA/NRCS/ITC

 . start of map file .

 MAP
  OUTPUTFORMAT
    NAME 'pnga'
    MIMETYPE 'image/pnga'
    DRIVER 'AGG/PNG'
    EXTENSION 'png'
    IMAGEMODE 'RGBA'
    TRANSPARENT TRUE
    FORMATOPTION 'INTERLACE=OFF'
  END
  STATUS ON
  SIZE 954 589
  EXTENT -11760744.430293 5057510.78178777 -11752931.9172644 5062334.23060729
  RESOLUTION 70
  UNITS METERS
  IMAGECOLOR 255 255 255
  PROJECTION 'proj=merc' 'a=6378137' 'b=6378137' 'lat_ts=0.0' 'lon_0=0.0' 
 'x_0=0.0' 'y_0=0' 'k=1.0' 'units=m' 'nadgrids=@null' 'north' 'no_defs' END

  symbol
    name 'circle' filled true type ellipse points 0 0 1 1 end
  end

  LAYER
    NAME  'single line'
    STATUS ON
    TYPE LINE
    feature points -11760750 5057520 -11752920 5062330 end end
    CLASS
      style
        symbol 'circle'
        size 20
        color 255 255 0
        outlinecolor 255 0 0
      end
      style
        width 1
        color 0 0 255
      end
    end
  END # end of layer 'single line'
 END  # end of MAP

 . end of map file .
 ___
 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 not showing up in MapServer 6.0.0-beta1 release

2011-03-11 Thread Anzel, Phil - Fort Collins, CO
Thomas,

Thanks yet again. I tried your suggestion and it looks quite nice. 

If I may, a related question: is there a change in behavior in use of symbols? 
I'm fairly certain that the MapServer tutorial example worked under 5.6.3, as 
did my use of the tie symbol. The motivation here is to tease out a potential 
bug in Mapserver 6.0.0-beta1.

- Phil

-Original Message-
From: thomas bonfort [mailto:thomas.bonf...@gmail.com] 
Sent: Friday, March 11, 2011 6:44 AM
To: Anzel, Phil - Fort Collins, CO
Cc: mapserver-users@lists.osgeo.org
Subject: Re: [mapserver-users] Symbol not showing up in MapServer 6.0.0-beta1 
release

for a tie symbol you should specify a (negative) GAP.

something like:
http://www2.terriscope.fr/geocache/wms?LAYERS=osmSERVICE=WMSVERSION=1.1.1REQUEST=GetMapSTYLES=EXCEPTIONS=application%2Fvnd.ogc.se_inimageFORMAT=image%2FjpegSRS=epsg%3A4326BBOX=1.34033203125,43.76953125,1.3623046875,43.79150390625WIDTH=256HEIGHT=256

is obtained with

SYMBOL
NAME rail
TYPE TRUETYPE
FONT sc
CHARACTER '|'
GAP -3
END

...

STYLE
WIDTH 2
OUTLINEWIDTH 1
OUTLINECOLOR #54
COLOR #ff
END
STYLE
SYMBOL rail
SIZE 5
COLOR #54
END

On Fri, Mar 11, 2011 at 14:35, Anzel, Phil - Fort Collins, CO
phil.an...@ftc.usda.gov wrote:
 Hi, Thomas,

 Thanks for looking into this problem.

 My goal is to create a railroad cross-hatching along a line. I originally 
 used:
    SYMBOL
      NAME 'default'
      Type simple
    END
    SYMBOL
      NAME 'tie'
      TYPE vector
      POINTS 0 0  0 7  -99 -99  7 0  7 7  END
    END
 These were referenced, within a layer of type line, by:
   CLASS
     STYLE
       SYMBOL            'default'
       SIZE              1
       COLOR             0 0 0
     END
     STYLE
      SYMBOL             'tie'
      SIZE               8
      COLOR              0 0 0
     END
   END

 This had worked under MapServer 5.6.3. I returned to this example after 
 upgrading to 5.7DEV on March 9, 2011, and found that the tie cross-hatching 
 had disappeared. I tried several other symbols; I used the circle as an 
 example because it also worked in the past and is used in the MapServer 
 Introduction to MapServer, section 2.4.3, CLASS and STYLE objects.

 Closer to the 2.4.3 example, if I define:
  symbol
    name 'circle'
    filled true
    type ellipse
    points 0 0 1 1 end
  end
 and reference this definition, as per the example, with:
     style
       symbol circle
       color 178 114 1
       size 15
     end
     style
       symbol circle
       color 254 161 0
       size 7
     end
 then there is no image created.

 Given these experimental results, I wonder if there has been a change in 
 behavior in drawing symbols. Alternatively I've made a very simple error.

 Is there an error in my map file? How do you recommend that the railroad 
 hatched line be drawn?

 Thanks again.

 - Phil


 -Original Message-
 From: thomas bonfort [mailto:thomas.bonf...@gmail.com]
 Sent: Friday, March 11, 2011 4:17 AM
 To: Anzel, Phil - Fort Collins, CO
 Cc: mapserver-users@lists.osgeo.org
 Subject: Re: [mapserver-users] Symbol not showing up in MapServer 6.0.0-beta1 
 release

 huh, I may have misinterpreted...

 you can't expect to obtain a point/marker symbology when using a line 
 geometry.

 if you effectively want to use marker symbols, you can have a look RFC
 48 and its
  GEOMTRANSFORM start|end|vertices transformations.

 --
 thomas

 On Fri, Mar 11, 2011 at 12:10, thomas bonfort thomas.bonf...@gmail.com 
 wrote:
 Phil,

 what kind of symbology are you trying to obtain. I suspect you're
 aiming for a thick line, which now does not require the use of a
 symbol, but rather:

 style
  width 20
  color 0 0 255
 end

 regards,
 thomas

 On Fri, Mar 11, 2011 at 02:24, Anzel, Phil - Fort Collins, CO
 phil.an...@ftc.usda.gov wrote:
 All,

 I upgraded to MapServer 5.7 (6.0.0-beta1) code for x32/VS2010 (downloaded 
 from http://vbkto.dyndns.org/sdk/) on March 9, 2011.

 It appears that embedded symbols are not drawn. Below is a simple map file 
 that has a single diagonal line as a feature and two styles; the first 
 should draw a 25-pixel circle, the second a single-pixel line; similar map 
 files worked under 5.6.3. I do not know if this worked under 5.7 circa 
 December 15, 2010.

 Only the single-pixel line is drawn. I've tried various other symbol 
 definitions; none appear in the output.

 I'm using the drawmap.exe utility to draw the PNG output file under 
 Microsoft Windows XP Professional 2002 SP 3. No errors are reported.

 Can you help?

 Thanks,

 - Phil Anzel
  Web Soil Survey development team
  Vistronix Inc. for USDA/NRCS/ITC

 . start of map file .

 MAP
  OUTPUTFORMAT
    NAME 'pnga'
    MIMETYPE 'image/pnga'
    DRIVER 'AGG/PNG'
    EXTENSION 'png'
    IMAGEMODE 'RGBA'
    TRANSPARENT TRUE
    FORMATOPTION 'INTERLACE=OFF'
  END

RE: [mapserver-users] Symbol not showing up in MapServer 6.0.0-beta1 release

2011-03-11 Thread Anzel, Phil - Fort Collins, CO
Thomas and All,

A follow up: submitted as a tracker defect: 
http://trac.osgeo.org/mapserver/ticket/3729 

The test map file is:
MAP
  OUTPUTFORMAT
NAME 'pnga'
MIMETYPE 'image/pnga'
DRIVER 'AGG/PNG'
EXTENSION 'png'
IMAGEMODE 'RGBA'
TRANSPARENT TRUE
FORMATOPTION 'INTERLACE=OFF'
  END
  STATUS ON
  SIZE 954 589
  EXTENT 0 0 954 589
  RESOLUTION 72
  IMAGECOLOR 255 255 255

  symbol
name 'circle' filled true type ellipse points 0 0 1 1 end
  end

  LAYER
NAME  'single line'
STATUS ON
TYPE LINE
feature points 10 10 950 580 end end
CLASS
  style
symbol 'circle'
size 20
color 255 255 0
outlinecolor 255 0 0
  end
  style
width 1
color 0 0 255
  end
end
  END # end of layer 'single line'
END  # end of MAP

The above map file works as desired under 5.6 and demonstrates the problem 
under 5.7/6.0.

- Phil

-Original Message-
From: Anzel, Phil - Fort Collins, CO 
Sent: Friday, March 11, 2011 7:08 AM
To: thomas bonfort
Cc: mapserver-users@lists.osgeo.org; Anzel, Phil - Fort Collins, CO
Subject: RE: [mapserver-users] Symbol not showing up in MapServer 6.0.0-beta1 
release

Thomas,

Thanks yet again. I tried your suggestion and it looks quite nice. 

If I may, a related question: is there a change in behavior in use of symbols? 
I'm fairly certain that the MapServer tutorial example worked under 5.6.3, as 
did my use of the tie symbol. The motivation here is to tease out a potential 
bug in Mapserver 6.0.0-beta1.

- Phil

-Original Message-
From: thomas bonfort [mailto:thomas.bonf...@gmail.com] 
Sent: Friday, March 11, 2011 6:44 AM
To: Anzel, Phil - Fort Collins, CO
Cc: mapserver-users@lists.osgeo.org
Subject: Re: [mapserver-users] Symbol not showing up in MapServer 6.0.0-beta1 
release

for a tie symbol you should specify a (negative) GAP.

something like:
http://www2.terriscope.fr/geocache/wms?LAYERS=osmSERVICE=WMSVERSION=1.1.1REQUEST=GetMapSTYLES=EXCEPTIONS=application%2Fvnd.ogc.se_inimageFORMAT=image%2FjpegSRS=epsg%3A4326BBOX=1.34033203125,43.76953125,1.3623046875,43.79150390625WIDTH=256HEIGHT=256

is obtained with

SYMBOL
NAME rail
TYPE TRUETYPE
FONT sc
CHARACTER '|'
GAP -3
END

...

STYLE
WIDTH 2
OUTLINEWIDTH 1
OUTLINECOLOR #54
COLOR #ff
END
STYLE
SYMBOL rail
SIZE 5
COLOR #54
END

On Fri, Mar 11, 2011 at 14:35, Anzel, Phil - Fort Collins, CO
phil.an...@ftc.usda.gov wrote:
 Hi, Thomas,

 Thanks for looking into this problem.

 My goal is to create a railroad cross-hatching along a line. I originally 
 used:
    SYMBOL
      NAME 'default'
      Type simple
    END
    SYMBOL
      NAME 'tie'
      TYPE vector
      POINTS 0 0  0 7  -99 -99  7 0  7 7  END
    END
 These were referenced, within a layer of type line, by:
   CLASS
     STYLE
       SYMBOL            'default'
       SIZE              1
       COLOR             0 0 0
     END
     STYLE
      SYMBOL             'tie'
      SIZE               8
      COLOR              0 0 0
     END
   END

 This had worked under MapServer 5.6.3. I returned to this example after 
 upgrading to 5.7DEV on March 9, 2011, and found that the tie cross-hatching 
 had disappeared. I tried several other symbols; I used the circle as an 
 example because it also worked in the past and is used in the MapServer 
 Introduction to MapServer, section 2.4.3, CLASS and STYLE objects.

 Closer to the 2.4.3 example, if I define:
  symbol
    name 'circle'
    filled true
    type ellipse
    points 0 0 1 1 end
  end
 and reference this definition, as per the example, with:
     style
       symbol circle
       color 178 114 1
       size 15
     end
     style
       symbol circle
       color 254 161 0
       size 7
     end
 then there is no image created.

 Given these experimental results, I wonder if there has been a change in 
 behavior in drawing symbols. Alternatively I've made a very simple error.

 Is there an error in my map file? How do you recommend that the railroad 
 hatched line be drawn?

 Thanks again.

 - Phil


 -Original Message-
 From: thomas bonfort [mailto:thomas.bonf...@gmail.com]
 Sent: Friday, March 11, 2011 4:17 AM
 To: Anzel, Phil - Fort Collins, CO
 Cc: mapserver-users@lists.osgeo.org
 Subject: Re: [mapserver-users] Symbol not showing up in MapServer 6.0.0-beta1 
 release

 huh, I may have misinterpreted...

 you can't expect to obtain a point/marker symbology when using a line 
 geometry.

 if you effectively want to use marker symbols, you can have a look RFC
 48 and its
  GEOMTRANSFORM start|end|vertices transformations.

 --
 thomas

 On Fri, Mar 11, 2011 at 12:10, thomas bonfort thomas.bonf...@gmail.com 
 wrote:
 Phil,

 what kind of symbology are you trying to obtain. I suspect you're
 aiming for a thick line, which now does not require the use of a
 symbol

RE: [mapserver-users] Symbol not showing up in MapServer 6.0.0-beta1 release

2011-03-11 Thread Anzel, Phil - Fort Collins, CO
Thomas,

Thanks again. I'll keep my eyes open for Code Sprint outcomes with respect to 
Symbols of Type Vector. 

- Phil

-Original Message-
From: thomas bonfort [mailto:thomas.bonf...@gmail.com] 
Sent: Friday, March 11, 2011 11:07 AM
To: Anzel, Phil - Fort Collins, CO
Cc: mapserver-users@lists.osgeo.org
Subject: Re: [mapserver-users] Symbol not showing up in MapServer 6.0.0-beta1 
release

Phil,
You're using the old version of drawing thick lines, that was needed
for GD. We'll have to decide at the codesprint if this is something
that we want to stop supporting, as this is something that we are
trailing along since 4.10. As I said in my first email, thick lines
are obtained with the WIDTH keyword.
As for vector symbols, there are known limitations actually, which we
will try to overcome during the codesprint - what's certain is we
won't be able to maintain backwards compatibility *and* expect
consistent rendering across renderers.

best regards,

thomas

On Fri, Mar 11, 2011 at 18:25, Anzel, Phil - Fort Collins, CO
phil.an...@ftc.usda.gov wrote:
 Thomas and All,

 A follow up: submitted as a tracker defect: 
 http://trac.osgeo.org/mapserver/ticket/3729

 The test map file is:
 MAP
  OUTPUTFORMAT
    NAME 'pnga'
    MIMETYPE 'image/pnga'
    DRIVER 'AGG/PNG'
    EXTENSION 'png'
    IMAGEMODE 'RGBA'
    TRANSPARENT TRUE
    FORMATOPTION 'INTERLACE=OFF'
  END
  STATUS ON
  SIZE 954 589
  EXTENT 0 0 954 589
  RESOLUTION 72
  IMAGECOLOR 255 255 255

  symbol
    name 'circle' filled true type ellipse points 0 0 1 1 end
  end

  LAYER
    NAME  'single line'
    STATUS ON
    TYPE LINE
    feature points 10 10 950 580 end end
    CLASS
      style
        symbol 'circle'
        size 20
        color 255 255 0
        outlinecolor 255 0 0
      end
      style
        width 1
        color 0 0 255
      end
    end
  END # end of layer 'single line'
 END  # end of MAP

 The above map file works as desired under 5.6 and demonstrates the problem 
 under 5.7/6.0.

 - Phil

 -Original Message-
 From: Anzel, Phil - Fort Collins, CO
 Sent: Friday, March 11, 2011 7:08 AM
 To: thomas bonfort
 Cc: mapserver-users@lists.osgeo.org; Anzel, Phil - Fort Collins, CO
 Subject: RE: [mapserver-users] Symbol not showing up in MapServer 6.0.0-beta1 
 release

 Thomas,

 Thanks yet again. I tried your suggestion and it looks quite nice.

 If I may, a related question: is there a change in behavior in use of 
 symbols? I'm fairly certain that the MapServer tutorial example worked under 
 5.6.3, as did my use of the tie symbol. The motivation here is to tease out 
 a potential bug in Mapserver 6.0.0-beta1.

 - Phil

 -Original Message-
 From: thomas bonfort [mailto:thomas.bonf...@gmail.com]
 Sent: Friday, March 11, 2011 6:44 AM
 To: Anzel, Phil - Fort Collins, CO
 Cc: mapserver-users@lists.osgeo.org
 Subject: Re: [mapserver-users] Symbol not showing up in MapServer 6.0.0-beta1 
 release

 for a tie symbol you should specify a (negative) GAP.

 something like:
 http://www2.terriscope.fr/geocache/wms?LAYERS=osmSERVICE=WMSVERSION=1.1.1REQUEST=GetMapSTYLES=EXCEPTIONS=application%2Fvnd.ogc.se_inimageFORMAT=image%2FjpegSRS=epsg%3A4326BBOX=1.34033203125,43.76953125,1.3623046875,43.79150390625WIDTH=256HEIGHT=256

 is obtained with

 SYMBOL
    NAME rail
    TYPE TRUETYPE
    FONT sc
    CHARACTER '|'
    GAP -3
 END

 ...

        STYLE
            WIDTH 2
            OUTLINEWIDTH 1
            OUTLINECOLOR #54
            COLOR #ff
        END
        STYLE
            SYMBOL rail
            SIZE 5
            COLOR #54
        END

 On Fri, Mar 11, 2011 at 14:35, Anzel, Phil - Fort Collins, CO
 phil.an...@ftc.usda.gov wrote:
 Hi, Thomas,

 Thanks for looking into this problem.

 My goal is to create a railroad cross-hatching along a line. I originally 
 used:
    SYMBOL
      NAME 'default'
      Type simple
    END
    SYMBOL
      NAME 'tie'
      TYPE vector
      POINTS 0 0  0 7  -99 -99  7 0  7 7  END
    END
 These were referenced, within a layer of type line, by:
   CLASS
     STYLE
       SYMBOL            'default'
       SIZE              1
       COLOR             0 0 0
     END
     STYLE
      SYMBOL             'tie'
      SIZE               8
      COLOR              0 0 0
     END
   END

 This had worked under MapServer 5.6.3. I returned to this example after 
 upgrading to 5.7DEV on March 9, 2011, and found that the tie 
 cross-hatching had disappeared. I tried several other symbols; I used the 
 circle as an example because it also worked in the past and is used in the 
 MapServer Introduction to MapServer, section 2.4.3, CLASS and STYLE 
 objects.

 Closer to the 2.4.3 example, if I define:
  symbol
    name 'circle'
    filled true
    type ellipse
    points 0 0 1 1 end
  end
 and reference this definition, as per the example, with:
     style
       symbol circle
       color 178 114 1
       size 15
     end
     style
       symbol circle
       color 254 161 0
       size 7

[mapserver-users] Symbol not showing up in MapServer 6.0.0-beta1 release

2011-03-10 Thread Anzel, Phil - Fort Collins, CO
All,

I upgraded to MapServer 5.7 (6.0.0-beta1) code for x32/VS2010 (downloaded from 
http://vbkto.dyndns.org/sdk/) on March 9, 2011. 

It appears that embedded symbols are not drawn. Below is a simple map file that 
has a single diagonal line as a feature and two styles; the first should draw a 
25-pixel circle, the second a single-pixel line; similar map files worked under 
5.6.3. I do not know if this worked under 5.7 circa December 15, 2010.

Only the single-pixel line is drawn. I've tried various other symbol 
definitions; none appear in the output. 

I'm using the drawmap.exe utility to draw the PNG output file under Microsoft 
Windows XP Professional 2002 SP 3. No errors are reported.

Can you help?

Thanks,

- Phil Anzel
 Web Soil Survey development team
 Vistronix Inc. for USDA/NRCS/ITC

. start of map file .

MAP
  OUTPUTFORMAT
NAME 'pnga'
MIMETYPE 'image/pnga'
DRIVER 'AGG/PNG'
EXTENSION 'png'
IMAGEMODE 'RGBA'
TRANSPARENT TRUE
FORMATOPTION 'INTERLACE=OFF'
  END
  STATUS ON
  SIZE 954 589
  EXTENT -11760744.430293 5057510.78178777 -11752931.9172644 5062334.23060729
  RESOLUTION 70
  UNITS METERS
  IMAGECOLOR 255 255 255
  PROJECTION 'proj=merc' 'a=6378137' 'b=6378137' 'lat_ts=0.0' 'lon_0=0.0' 
'x_0=0.0' 'y_0=0' 'k=1.0' 'units=m' 'nadgrids=@null' 'north' 'no_defs' END

  symbol
name 'circle' filled true type ellipse points 0 0 1 1 end
  end

  LAYER
NAME  'single line'
STATUS ON
TYPE LINE
feature points -11760750 5057520 -11752920 5062330 end end
CLASS
  style
symbol 'circle'
size 20
color 255 255 0
outlinecolor 255 0 0
  end
  style
width 1
color 0 0 255
  end
end
  END # end of layer 'single line'
END  # end of MAP

. end of map file .
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


[mapserver-users] RE: mapserver-users Digest, Vol 36, Issue 32

2011-01-21 Thread Anzel, Phil - Fort Collins, CO
Excellent! Thanks, Frank.

-Original Message-
From: mapserver-users-boun...@lists.osgeo.org 
[mailto:mapserver-users-boun...@lists.osgeo.org] On Behalf Of 
mapserver-users-requ...@lists.osgeo.org
Sent: Friday, January 21, 2011 10:00 AM
To: mapserver-users@lists.osgeo.org
Subject: mapserver-users Digest, Vol 36, Issue 32

Send mapserver-users mailing list submissions to
mapserver-users@lists.osgeo.org

To subscribe or unsubscribe via the World Wide Web, visit
http://lists.osgeo.org/mailman/listinfo/mapserver-users
or, via email, send a message with subject or body 'help' to
mapserver-users-requ...@lists.osgeo.org

You can reach the person managing the list at
mapserver-users-ow...@lists.osgeo.org

When replying, please edit your Subject line so it is more specific
than Re: Contents of mapserver-users digest...


Today's Topics:

   1. Re: Apache installation for ms4w (Jeff McKenna)
   2. Re: Raster input file delete access prohibited by MapScript
  (Frank Warmerdam)


--

Message: 1
Date: Fri, 21 Jan 2011 09:47:42 -0400
From: Jeff McKenna jmcke...@gatewaygeomatics.com
Subject: Re: [mapserver-users] Apache installation for ms4w
To: mapserver-users mapserver-users@lists.osgeo.org
Message-ID: 4d398e7e.4010...@gatewaygeomatics.com
Content-Type: text/plain; charset=ISO-8859-1; format=flowed

Hello David,

First, all questions related to MS4W should be sent to the MS4W-users 
mailing list, where hundreds of users and devs can assist you with your 
issues (subscribe at http://lists.maptools.org/mailman/listinfo/ms4w-users).

As you mentioned, MS4W is designed for new installations and contains a 
ready to use Web server and everything you need to move forward.  If you 
need to use MS4W in an existing environment, there are some options:

  - follow the existing notes to install in other environments in your 
local README file 
(http://www.maptools.org/ms4w/index.phtml?page=README_INSTALL.html#k-installing-the-ms4w-mapserver-binaries-in-other-environments)
  - search the MS4W mailing list for other users asking this same 
question and the responses (search at: 
http://osgeo-org.1803224.n2.nabble.com/ms4w-users-f4995553.html)
  - contact me directly for assistance

Hope that helps.

-jeff


-- 
Jeff McKenna
MapServer Consulting and Training Services
http://www.gatewaygeomatics.com/




On 11-01-20 7:51 PM, David Hildebrand wrote:
 The installation package for ms4w contains a preconfigured version of
 Apache. This works well for a new installation. In the case of an
 existing Apache installation what are the requirements which need to be
 met for ms4w? Are there potential conflicts to be aware of?




--

Message: 2
Date: Fri, 21 Jan 2011 09:59:28 -0500
From: Frank Warmerdam warmer...@pobox.com
Subject: Re: [mapserver-users] Raster input file delete access
prohibited by   MapScript
To: mapserver-users@lists.osgeo.org
Message-ID: 4d399f50.3050...@pobox.com
Content-Type: text/plain; charset=ISO-8859-1; format=flowed

On 11-01-20 10:13 AM, Anzel, Phil - Fort Collins, CO wrote:
 All,

 I have an application that uses the MapScript API under C# to create map
 images. Without exiting the application, I need to delete the input raster
 (JPEG) files that have been used in the image creation. Deletion of the
 input files is not possible until the application terminates.
...
 Can you help? I'm guessing that the input JPG file is opened for reading by
 MapServer and is never explicitly closed, even when the layer is closed. Is
 there a method defined in the API that will force the closure, if that is
 even the situation?

Phil,

In recent versions MapServer aggressively keeps single raster files used for
raster layers open even after the map is destroyed in order accelerate the
next access to it.  This can be controlled/disabled by adding the following
line in your raster layer:

   PROCESSING CLOSE_CONNECTION=NORMAL

The default setting is DEFER for raster files.

Best regards,
---+--
I set the clouds in motion - turn up   | Frank Warmerdam, warmer...@pobox.com
light and sound - activate the windows | http://pobox.com/~warmerdam
and watch the world go round - Rush| Geospatial Programmer for Rent



--

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


End of mapserver-users Digest, Vol 36, Issue 32
***
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


[mapserver-users] MapServer distro site down at http://vbkto.dyndns.org/sdk ?

2011-01-07 Thread Anzel, Phil - Fort Collins, CO
Hi, All,

The MapServer distro site at http://vbkto.dyndns.org/sdk may need a bit of 
attention; all I get is a page with an amber background (full, yet incomplete, 
HTML shown below). Problem observed 19:00 UTC 7 Jan 2010.

Thanks,

- Phil Anzel
NRCS/USDA/ITC/Vistronix Inc Web Soil Survey Developer

...start of HTML...
html xmlns:v=urn:schemas-microsoft-com:vml
xmlns:o=urn:schemas-microsoft-com:office:office
xmlns:w=urn:schemas-microsoft-com:office:word
xmlns:dt=uuid:C2F41010-65B3-11d1-A29F-00AA00C14882
xmlns=http://www.w3.org/TR/REC-html40;

head
meta name=Microsoft Theme 2.00 content=bars 100
meta http-equiv=Content-Type content=text/html; charset=windows-1252
meta name=ProgId content=Word.Document
meta name=Generator content=Microsoft Word 11
meta name=Originator content=Microsoft Word 11
link rel=File-List href=index_dns_files/filelist.xml
link rel=Edit-Time-Data href=index_dns_files/editdata.mso
!--[if !mso]
style
v\:* {behavior:url(#default#VML);}
o\:* {behavior:url(#default#VML);}
w\:* {behavior:url(#default#VML);}
.shape {behavior:url(#default#VML);}
/style
![endif]--
titleAdvisory Page/title
!--[if gte mso 9]xml
 o:DocumentProperties
  o:Authorbwalker/o:Author
  o:TemplateNormal/o:Template
  o:LastAuthorbkirch/o:LastAuthor
  o:Revision13/o:Revision
  o:TotalTime158/o:TotalTime
  o:Created2008-11-14T15:25:00Z/o:Created
  o:LastSaved2009-09-01T18:43:00Z/o:LastSaved
  o:Pages1/o:Pages
  o:Words88/o:Words
  o:Characters508/o:Characters
  o:CompanyUSDA/o:Company
  o:Lines4/o:Lines
  o:Paragraphs1/o:Paragraphs
  o:CharactersWithSpaces595/o:CharactersWithSpaces
  o:Version11./o:Version
 /o:DocumentProperties
/xml![endif]--!--[if gte mso 9]xml
 w:WordDocument
  w:Zoom85/w:Zoom
  w:SpellingStateClean/w:SpellingState
  w:GrammarStateClean/w:GrammarState
  w:ValidateAgainstSchemas/
  w:SaveIfXMLInvalidfalse/w:SaveIfXMLInvalid
  w:IgnoreMixedContentfalse/w:IgnoreMixedContent
  w:AlwaysShowPlaceholderTextfalse/w:AlwaysShowPlaceholderText
  w:BrowserLevelMicrosoftInternetExplorer4/w:BrowserLevel
 /w:WordDocument
/xml![endif]--!--[if gte mso 9]xml
 w:LatentStyles DefLockedState=false LatentStyleCount=156
 /w:LatentStyles
/xml![endif]--
style
!--
 /* Style Definitions */
 p.MsoNormal, li.MsoNormal, div.MsoNormal
{mso-style-parent:;
margin:0in;
margin-bottom:.0001pt;
mso-pagination:widow-orphan;
font-size:12.0pt;
font-family:Times New Roman;
mso-fareast-font-family:Times New Roman;
color:#00;}
a:link, span.MsoHyperlink
{color:#00;
text-decoration:underline;
text-underline:single;}
a:visited, span.MsoHyperlinkFollowed
{color:#33;
text-decoration:underline;
text-underline:single;}
p
{mso-margin-top-alt:auto;
margin-right:0in;
mso-margin-bottom-alt:auto;
margin-left:0in;
mso-pagination:widow-orphan;
font-size:12.0pt;
font-family:Times New Roman;
mso-fareast-font-family:Times New Roman;
color:#00;}
@page Section1
{size:8.5in 11.0in;
margin:1.0in 1.25in 1.0in 1.25in;
mso-header-margin:.5in;
mso-footer-margin:.5in;
mso-paper-source:0;}
div.Section1
{page:Section1;}
--
/style
!--[if gte mso 10]
style
 /* Style Definitions */
 table.MsoNormalTable
{mso-style-name:Table Normal;
mso-tstyle-rowband-size:0;
mso-tstyle-colband-size:0;
mso-style-noshow:yes;
mso-style-parent:;
mso-padding-alt:0in 5.4pt 0in 5.4pt;
mso-para-margin:0in;
mso-para-margin-bottom:.0001pt;
mso-pagination:widow-orphan;
font-size:10.0pt;
font-family:Times New Roman;
mso-ansi-language:#0400;
mso-fareast-language:#0400;
mso-bidi-language:#0400;}
/style
![endif]--

meta http-equiv=Content-Language content=en-us
meta name=Microsoft Border content=tb, default
!--[if gte mso 9]xml
 o:shapedefaults v:ext=edit spidmax=3074/
/xml![endif]--!--[if gte mso 9]xml
 o:shapelayout v:ext=edit
  o:idmap v:ext=edit data=1/
 /o:shapelayout/xml![endif]--
/head

body bgcolor=#FFCC66 lang=EN-US link=#00

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


RE: [mapserver-users] Feature points not drawn by 5.7DEV drawmap.exe

2010-12-30 Thread Anzel, Phil - Fort Collins, CO
Tamas, thank you; I'll submit a bug ticket. - Phil

From: Tamas Szekeres [mailto:szeker...@gmail.com]
Sent: Wednesday, December 29, 2010 5:29 PM
To: Anzel, Phil - Fort Collins, CO
Cc: mapserver-users@lists.osgeo.org
Subject: Re: [mapserver-users] Feature points not drawn by 5.7DEV drawmap.exe

Phil,

I suspect there is a problem with the default symbol initialization which 
doesn't work with the new rendering code. You could work around the problem by 
specifying a custom symbol as follows:



MAP
 OUTPUTFORMAT
   NAME 'pnga'
   MIMETYPE 'image/pnga'
   DRIVER 'AGG/PNG'
   EXTENSION 'png'
   IMAGEMODE 'RGBA'
   TRANSPARENT TRUE
   FORMATOPTION 'INTERLACE=OFF'
 END
 SYMBOL
  NAME default-marker
  TYPE ELLIPSE
  POINTS
1 1
  END
  FILLED TRUE
 END

 STATUS ON
 SIZE 827 511
 EXTENT -7908630.38 5546155.24 -7903127.77 5548526.51
 UNITS METERS
 IMAGECOLOR 255 255 255
 PROJECTION 'proj=merc' 'a=6378137' 'b=6378137' 'lat_ts=0.0' 'lon_0=0.0' 
'x_0=0.0' 'y_0=0' 'k=1.0' 'units=m' 'nadgri...@null' 'north' 'no_defs' END
LAYER
 layer
   name 'Corner_points'
   PROJECTION 'proj=merc' 'a=6378137' 'b=6378137' 'lat_ts=0.0' 'lon_0=0.0' 
'x_0=0.0' 'y_0=0' 'k=1.0' 'units=m' 'nadgri...@null' 'north' 'no_defs' END   # 
Web Mercator
   status on
   type point
   feature
 points
   -7905423.21336607 5547493.76482495
   -7905423.21336607 5546270.77237239
   -7904200.22091351 5547493.76482495
   -7904200.22091351 5546270.77237239
 end  # end of points
   end  # end of feature
   class
 style
   color 255 0 0
   size 7
   SYMBOL 'default-marker'
 end  # end of style
   end  #end of class
 end  # end of layer
 layer
   name 'grid-WM'
   PROJECTION 'proj=merc' 'a=6378137' 'b=6378137' 'lat_ts=0.0' 'lon_0=0.0' 
'x_0=0.0' 'y_0=0' 'k=1.0' 'units=m' 'nadgri...@null' 'north' 'no_defs' END   # 
Web Mercator
   status on
   type line
   class
 color 0 0 0
   end # of class
   grid
 labelformat '%9.0f'  minarcs 2   maxarcs 6
   end  # of grid
 end # of layer 'grid-WM'
END  # end of MAP


A new ticket would also be sufficient in order to have this symbol 
initialization problem fixed.


Best regards,

Tamas


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


[mapserver-users] Feature points not drawn by 5.7DEV drawmap.exe

2010-12-29 Thread Anzel, Phil - Fort Collins, CO
Happy New Year, All,

Appended below is a short map file containing two layers: points and grid 
lines. The projection used by the map as well as the two layers is Web 
Mercator.

When drawn with drawmap.exe from MapServer 5.6.3, all points and grid lines 
are shown. Using drawmap.exe from 5.7-development, the points are not shown. 

The 5.7-development drawmap.exe, with associated DLLs, was downloaded from 
http://vbkto.dyndns.org/sdk/ on 12/15/2010. I'm using the 
release-1600-gdal-mapserver.zip file created for VS2010/Win32. The same point 
omission occurs if I use the mapObj from mapscript_csharp.dll, load the map 
file, and execute a Draw to generate an output byte array.

Is there an error in this map file? Is the difference an artifact of changes 
planned for 6.0, and if so, where might I find relevant documentation?

Thanks,

- Phil Anzel  (Web Soil Survey developer for USDA/NRCS)

...start of map file...

MAP
  OUTPUTFORMAT
NAME 'pnga'
MIMETYPE 'image/pnga'
DRIVER 'AGG/PNG'
EXTENSION 'png'
IMAGEMODE 'RGBA'
TRANSPARENT TRUE
FORMATOPTION 'INTERLACE=OFF'
  END
  STATUS ON
  SIZE 827 511
  EXTENT -7908630.38 5546155.24 -7903127.77 5548526.51
  UNITS METERS
  IMAGECOLOR 255 255 255
  PROJECTION 'proj=merc' 'a=6378137' 'b=6378137' 'lat_ts=0.0' 'lon_0=0.0' 
'x_0=0.0' 'y_0=0' 'k=1.0' 'units=m' 'nadgri...@null' 'north' 'no_defs' END
LAYER
  layer
name 'Corner_points'
PROJECTION 'proj=merc' 'a=6378137' 'b=6378137' 'lat_ts=0.0' 'lon_0=0.0' 
'x_0=0.0' 'y_0=0' 'k=1.0' 'units=m' 'nadgri...@null' 'north' 'no_defs' END   # 
Web Mercator
status on
type point
feature
  points
-7905423.21336607 5547493.76482495
-7905423.21336607 5546270.77237239
-7904200.22091351 5547493.76482495
-7904200.22091351 5546270.77237239
  end  # end of points
end  # end of feature
class
  style
color 255 0 0
size 7
  end  # end of style
end  #end of class
  end  # end of layer
  layer
name 'grid-WM'
PROJECTION 'proj=merc' 'a=6378137' 'b=6378137' 'lat_ts=0.0' 'lon_0=0.0' 
'x_0=0.0' 'y_0=0' 'k=1.0' 'units=m' 'nadgri...@null' 'north' 'no_defs' END   # 
Web Mercator
status on
type line
class
  color 0 0 0
end # of class
grid
  labelformat '%9.0f'  minarcs 2   maxarcs 6
end  # of grid
  end # of layer 'grid-WM'
END  # end of MAP

...end of map file...
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


[mapserver-users] Polygon outline not drawn in PDF output if polygon is not filled

2010-06-11 Thread Anzel, Phil - Fort Collins, CO
Hi,

It appears that a polygon's outline does not appear in a PDF image unless the 
polygon is also filled.

Consider this MAP file:

  MAP
OUTPUTFORMAT
  NAMEpdf
  DRIVER  pdf
END
#OUTPUTFORMAT
#  NAME png
#  DRIVER GD/PNG
#END
EXTENT 643507 5660466 646127 5661655
SIZE   800 400
IMAGECOLOR 255 255 255
PROJECTION init=epsg:32633  END
LAYER
  NAMEtest_polygon
  STATUS  ON
  TYPEPOLYGON
  FEATURE
 WKT 'POLYGON ((645000 5660900, 645500 5660900, 
645500 5661000, 645000 5661000,
645000 5660900))'
  END
  CLASS
STYLE
  #COLOR0   255 0
  OUTLINECOLOR 255   0 0
END
  END
END
  END

Case 1: Unfilled polygon, PDF output: As written above, the PDF output is 
empty. This is the problem case.

Case 2: Filled polygon, PDF output: If the #COLOR line is uncommented, the 
green-filled polygon, complete with red outline, is drawn. 

Case 3: Unfilled polygon, PNG output: If I switch to PNG output (by 
uncommenting the OUTPUTFORMAT for PNG and commenting-out the PDF one) and 
revert to #COLOR (thereby disabling polygon fill), the unfilled red outline 
is drawn in the PNG output.

Case 4: Filled polygon, PNG output: With PNG output and fill COLOR enabled, the 
filled green polygon with red outline is drawn to the PNG output.

Is this a defect? Could you suggest a work-around for unfilled polygon PDF 
output?

A secondary observation: Using a filled polygon for PDF, use of a WIDTH 
parameter appears to have no effect upon the width of the outline.

I'm using MapServer version 5.6.3 (MS4W distribution) under Windows XP Pro 2002 
SP3. The problem was demonstrated with use of the drawmap.exe command-line 
utility.

Thanks in advance,

- Phil Anzel

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


RE: [mapserver-users] Polygon outline not drawn in PDF output if polygon is not filled

2010-06-11 Thread Anzel, Phil - Fort Collins, CO
Hi, Assefa,

Thanks for getting back to me so quickly.

FWIW it appears that the same problem (no outlines shown when using an unfilled 
polygon) impacts SVG output as well.

There is another problem: layer OPACITY appears to have no effect. Is that a 
defect as well?

I'll work my way up to the Cairo version; thanks for the suggestion.

- Phil

-Original Message-
From: Yewondwossen Assefa [mailto:yass...@dmsolutions.ca] 
Sent: Friday, June 11, 2010 12:12 PM
To: Anzel, Phil - Fort Collins, CO
Cc: mapserver-users@lists.osgeo.org
Subject: Re: [mapserver-users] Polygon outline not drawn in PDF output if 
polygon is not filled

Hi There,

The first issue with the color/fill-color seems to be a defect.
  This second issue with the Width parameter is due to the fact that 
the  parameter is not supported in the PDF driver.

The intention is to depreciate the current PDF support and use the Cairo 
PDF driver for the 6.0 release [1]. At that point we should have support 
for things like width, color/fill-color, ... be consistent between all 
output drivers. You could maybe try using MapServer from svn and try the 
Cairo support and see if that solves your immediate needs.

regards,


[1] http://trac.osgeo.org/mapserver/wiki/60ReleasePlan

 Case 1: Unfilled polygon, PDF output: As written above, the PDF output is 
 empty. This is the problem case.

 Case 2: Filled polygon, PDF output: If the #COLOR line is uncommented, the 
 green-filled polygon, complete with red outline, is drawn.

 Case 3: Unfilled polygon, PNG output: If I switch to PNG output (by 
 uncommenting the OUTPUTFORMAT for PNG and commenting-out the PDF one) and 
 revert to #COLOR (thereby disabling polygon fill), the unfilled red outline 
 is drawn in the PNG output.

 Case 4: Filled polygon, PNG output: With PNG output and fill COLOR enabled, 
 the filled green polygon with red outline is drawn to the PNG output.

 Is this a defect? Could you suggest a work-around for unfilled polygon PDF 
 output?


This seems to be a defect
 A secondary observation: Using a filled polygon for PDF, use of a WIDTH 
 parameter appears to have no effect upon the width of the outline.



 I'm using MapServer version 5.6.3 (MS4W distribution) under Windows XP Pro 
 2002 SP3. The problem was demonstrated with use of the drawmap.exe 
 command-line utility.

 Thanks in advance,

 - Phil Anzel

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




-- 

Assefa Yewondwossen
Software Analyst

Email: yass...@dmsolutions.ca
http://www.dmsolutions.ca/

Phone: (613) 565-5056 (ext 14)
Fax:   (613) 565-0925



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


[mapserver-users] PDF and SVG only shows last georeferenced raster layer

2010-06-11 Thread Anzel, Phil - Fort Collins, CO
Hi,

I think there is a defect when using multiple raster data layers with PDF or 
SVG image formats: only the last geo-referenced raster layer is drawn. This 
problem does not exist if the output is PNG.

To demonstrate this problem, retrieve two adjacent JPEG tile files from 
Microsoft's Virtual Earth, using URLs:
  (west tile) 
http://ecn.t0.tiles.virtualearth.net/tiles/r021323222.jpg?g=409mkt=en-USshading=hilln=z
  (east tile) 
http://ecn.t0.tiles.virtualearth.net/tiles/r021323223.jpg?g=409mkt=en-USshading=hilln=z
The tiles should be saved as files r021323222.jpg and r021323223.jpg, 
respectively.

Create world files to accompany these. For the west tile, create r021323223.wld:
305.748113140705
0.00
0.00
-305.748113140705
-11897270.5785311
5087648.60266133

For the east, create r021323223.wld:
305.748113140705
0.00
0.00
-305.748113140705
-11818999.0615671
5087648.60266133

Here is the map file, with the addition of a red outline around the west tile 
and a green outline around the east one:

  MAP
IMAGETYPE png
SIZE 512 256
CONFIG 'PROJ_LIB' 'C:\ms4w\proj\nad\'
PROJECTION 'init=epsg:3857' END  # Web Mercator
EXTENT -11900270.578531099 5006377.08569731 -11737727.5446031 
5090648.6026613303
UNITS meters

LAYER
  NAME 'left_tile'
  # retrieve from 
http://ecn.t0.tiles.virtualearth.net/tiles/r021323222.jpg?g=409mkt=en-USshading=hilln=z
  data 'r021323222.jpg'
  type raster
  status on
END

LAYER
  NAME 'right_tile'
  # retrieve from 
http://ecn.t0.tiles.virtualearth.net/tiles/r021323223.jpg?g=409mkt=en-USshading=hilln=z
  data 'r021323223.jpg'
  type raster
  status on
END

LAYER
  NAME 'left_outline'
  STATUS on
  TYPE line
  FEATURE #...right edge shifted left 153 meters (about half a tile 
pixel)
WKT 'LINESTRING(
  -11818999.0615671 5009377.08569731,
  -11897423.578531099 5009377.08569731,
  -11897423.578531099 5087648.60266133,
  -11818999.0615671 5087648.60266133,
  -11818999.0615671 5009377.08569731)'
  END
  CLASS
STYLE
  COLOR 255 0 0
END
  END
END

LAYER
  NAME 'right_outline'
  STATUS on
  TYPE line
  FEATURE   #...left edge shifted right 153 meters (about half a tile pixel)
WKT 'LINESTRING(
  -11818846.0615671 5009377.08569731,
  -11740727.5446031 5009377.08569731,
  -11740727.5446031 5087648.60266133,
  -11818846.0615671 5087648.60266133,
  -11818846.0615671 5009377.08569731)'
  END
  CLASS
STYLE
  COLOR 0 255 0
END
  END
END
  END

Note that for PNG output, both tiles are shown. If you change the image type to 
SVG or PDF, only the last raster layer, the east tile, is shown.

Is this a defect? Short of externally aggregating the source bitmaps into a 
single bitmap outside of MapServer, is there a possible workaround? Is this 
associated with failure of OPACITY to work with SVG and PDF?

I'm using MapServer version 5.6.3 (MS4W distribution) under Windows XP Pro 2002 
SP3. The problem was demonstrated with use of the drawmap.exe command-line 
utility.

Thanks in advance.

- Phil Anzel

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


[mapserver-users] Mapserver 5.6.3, IIS, and thread safety

2010-05-04 Thread Anzel, Phil - Fort Collins, CO
All,

As per http://www.mapserver.org/faq.html#is-mapserver-thread-safe , various 
parts of MapScript, and presumably its invocation via the C# wrapper API, are 
not thread safe. We're experimenting with use of MapScript in the form:
  map = mapscript.msLoadMapFromString(mapFileText, null);
  imageObj imageObj = map.draw();
  byte[] img = imageObj.getBytes();
This is to be performed inside of C# code, offered as a Web Service by IIS 
under some enterprise flavor of Windows 2002 or beyond (but not Windows Vista 
or beyond).

Under Apache, I've heard that a pre-fork worker could be used to maintain 
sufficient isolation between Apache MapServer server processes. Can anyone 
advise whether this is correct, and what a suitable IIS configuration 
equivalent would be?

Thanks,
- Phil Anzel
Web Soil Survey team
Vistronix Inc., for USDA/NRCS

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