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 bfra...@geoanalytic.com 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 Brent Fraser

Using

  STYLE
GEOMTRANSFORM difference([shape],buffer([shape], -5))
COLOR255 211 127
  END

results in the entire original polygon being filled.

Using
GEOMTRANSFORM (difference([shape],buffer([shape], -5)))
results in no fill.

Best Regards,
Brent Fraser


On 5/9/2011 4:20 PM, Lime, Steve D (DNR) wrote:

That's were a difference operator might come in handy since you're looking for 
more of a fill-type effect:

   GEOMTRANSFORM (difference([shape], buffer([shape], -2)))

or something like that.

Steve

-Original Message-
From: Brent Fraser [mailto:bfra...@geoanalytic.com]
Sent: Monday, May 09, 2011 5:18 PM
To: Lime, Steve D (DNR)
Cc: mapserver-users@lists.osgeo.org
Subject: Re: [mapserver-users] Rendering Challenges

Steve L.,

Good point;  I couldn't do any of this in pre-6.0 either!

I tried the buffer and it worked great (but we might have to work on
the end-cap types in PDF output)! See http://i52.tinypic.com/2qjc9yv.jpg

Best Regards,
Brent Fraser


On 5/9/2011 2:36 PM, Lime, Steve D (DNR) wrote:

These aren't specific to 6.0 though- more of a wish list...

Item 1 might be doable in 6.0 as it sits. In 6.0 a style GEOMTRANSFORM is 
really an expression and I exposed
the GEOS buffer operator as a proof-of-concept. For example:

STYLE
GEOMTRANSFORM (buffer([shape], -2))
OUTLINECOLOR 255 0 0
END

Should generate a single pixel red line on the inside of a polygon shape. You 
can render it however you'd like.
Note that a GEOMTRANSFORM is performed AFTER a shape is converted from map to 
image coordinates so it's effective
for rendering effects only.

If we exposed a few others you'd be able to do some other interesting things 
(like fills just inside a line...).

The rest of the ideas are interesting and worthy of discussion.

Steve

-Original Message-
From: mapserver-users-boun...@lists.osgeo.org 
[mailto:mapserver-users-boun...@lists.osgeo.org] On Behalf Of Brent Fraser
Sent: Monday, May 09, 2011 2:52 PM
To: mapserver-users@lists.osgeo.org
Subject: [mapserver-users] Rendering Challenges

 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)
2. Place polygon annotation on/inside boundary line
(http://trac.osgeo.org/mapserver/ticket/1592 point 8.)
3. Rotate anno if required to fit inside a polygon
4. Place polygon annotation outside polygon if anno doesn't fit inside
5. Place line anno above (or below) when using ANGLE FOLLOW
6. Rotate vector symbols to follow lines (a font might work but is a
pain to create)
7. User specified character spacing
8. Erase lines (but not other objects) under annotation

 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.







___
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 Brent Fraser

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 Fraserbfra...@geoanalytic.com  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 Lime, Steve D (DNR)
I don't have a difference operator implemented. Wouldn't take much though...

-Original Message-
From: Brent Fraser [mailto:bfra...@geoanalytic.com] 
Sent: Tuesday, May 10, 2011 9:07 AM
To: Lime, Steve D (DNR)
Cc: mapserver-users@lists.osgeo.org
Subject: Re: [mapserver-users] Rendering Challenges

Using

   STYLE
 GEOMTRANSFORM difference([shape],buffer([shape], -5))
 COLOR255 211 127
   END

results in the entire original polygon being filled.

Using
 GEOMTRANSFORM (difference([shape],buffer([shape], -5)))
results in no fill.

Best Regards,
Brent Fraser


On 5/9/2011 4:20 PM, Lime, Steve D (DNR) wrote:
 That's were a difference operator might come in handy since you're looking 
 for more of a fill-type effect:

GEOMTRANSFORM (difference([shape], buffer([shape], -2)))

 or something like that.

 Steve

 -Original Message-
 From: Brent Fraser [mailto:bfra...@geoanalytic.com]
 Sent: Monday, May 09, 2011 5:18 PM
 To: Lime, Steve D (DNR)
 Cc: mapserver-users@lists.osgeo.org
 Subject: Re: [mapserver-users] Rendering Challenges

 Steve L.,

 Good point;  I couldn't do any of this in pre-6.0 either!

 I tried the buffer and it worked great (but we might have to work on
 the end-cap types in PDF output)! See http://i52.tinypic.com/2qjc9yv.jpg

 Best Regards,
 Brent Fraser


 On 5/9/2011 2:36 PM, Lime, Steve D (DNR) wrote:
 These aren't specific to 6.0 though- more of a wish list...

 Item 1 might be doable in 6.0 as it sits. In 6.0 a style GEOMTRANSFORM is 
 really an expression and I exposed
 the GEOS buffer operator as a proof-of-concept. For example:

 STYLE
 GEOMTRANSFORM (buffer([shape], -2))
 OUTLINECOLOR 255 0 0
 END

 Should generate a single pixel red line on the inside of a polygon shape. 
 You can render it however you'd like.
 Note that a GEOMTRANSFORM is performed AFTER a shape is converted from map 
 to image coordinates so it's effective
 for rendering effects only.

 If we exposed a few others you'd be able to do some other interesting things 
 (like fills just inside a line...).

 The rest of the ideas are interesting and worthy of discussion.

 Steve

 -Original Message-
 From: mapserver-users-boun...@lists.osgeo.org 
 [mailto:mapserver-users-boun...@lists.osgeo.org] On Behalf Of Brent Fraser
 Sent: Monday, May 09, 2011 2:52 PM
 To: mapserver-users@lists.osgeo.org
 Subject: [mapserver-users] Rendering Challenges

  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)
 2. Place polygon annotation on/inside boundary line
 (http://trac.osgeo.org/mapserver/ticket/1592 point 8.)
 3. Rotate anno if required to fit inside a polygon
 4. Place polygon annotation outside polygon if anno doesn't fit inside
 5. Place line anno above (or below) when using ANGLE FOLLOW
 6. Rotate vector symbols to follow lines (a font might work but is a
 pain to create)
 7. User specified character spacing
 8. Erase lines (but not other objects) under annotation

  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.







___
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 bfra...@geoanalytic.com 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 Fraserbfra...@geoanalytic.com
  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 Brent Fraser

I think it would be very valuable

Best Regards,
Brent Fraser


On 5/10/2011 8:25 AM, Lime, Steve D (DNR) wrote:

I don't have a difference operator implemented. Wouldn't take much though...

-Original Message-
From: Brent Fraser [mailto:bfra...@geoanalytic.com]
Sent: Tuesday, May 10, 2011 9:07 AM
To: Lime, Steve D (DNR)
Cc: mapserver-users@lists.osgeo.org
Subject: Re: [mapserver-users] Rendering Challenges

Using

STYLE
  GEOMTRANSFORM difference([shape],buffer([shape], -5))
  COLOR255 211 127
END

results in the entire original polygon being filled.

Using
  GEOMTRANSFORM (difference([shape],buffer([shape], -5)))
results in no fill.

Best Regards,
Brent Fraser


On 5/9/2011 4:20 PM, Lime, Steve D (DNR) wrote:

That's were a difference operator might come in handy since you're looking for 
more of a fill-type effect:

GEOMTRANSFORM (difference([shape], buffer([shape], -2)))

or something like that.

Steve

-Original Message-
From: Brent Fraser [mailto:bfra...@geoanalytic.com]
Sent: Monday, May 09, 2011 5:18 PM
To: Lime, Steve D (DNR)
Cc: mapserver-users@lists.osgeo.org
Subject: Re: [mapserver-users] Rendering Challenges

Steve L.,

 Good point;  I couldn't do any of this in pre-6.0 either!

 I tried the buffer and it worked great (but we might have to work on
the end-cap types in PDF output)! See http://i52.tinypic.com/2qjc9yv.jpg

Best Regards,
Brent Fraser


On 5/9/2011 2:36 PM, Lime, Steve D (DNR) wrote:

These aren't specific to 6.0 though- more of a wish list...

Item 1 might be doable in 6.0 as it sits. In 6.0 a style GEOMTRANSFORM is 
really an expression and I exposed
the GEOS buffer operator as a proof-of-concept. For example:

STYLE
 GEOMTRANSFORM (buffer([shape], -2))
 OUTLINECOLOR 255 0 0
END

Should generate a single pixel red line on the inside of a polygon shape. You 
can render it however you'd like.
Note that a GEOMTRANSFORM is performed AFTER a shape is converted from map to 
image coordinates so it's effective
for rendering effects only.

If we exposed a few others you'd be able to do some other interesting things 
(like fills just inside a line...).

The rest of the ideas are interesting and worthy of discussion.

Steve

-Original Message-
From: mapserver-users-boun...@lists.osgeo.org 
[mailto:mapserver-users-boun...@lists.osgeo.org] On Behalf Of Brent Fraser
Sent: Monday, May 09, 2011 2:52 PM
To: mapserver-users@lists.osgeo.org
Subject: [mapserver-users] Rendering Challenges

  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)
2. Place polygon annotation on/inside boundary line
(http://trac.osgeo.org/mapserver/ticket/1592 point 8.)
3. Rotate anno if required to fit inside a polygon
4. Place polygon annotation outside polygon if anno doesn't fit inside
5. Place line anno above (or below) when using ANGLE FOLLOW
6. Rotate vector symbols to follow lines (a font might work but is a
pain to create)
7. User specified character spacing
8. Erase lines (but not other objects) under annotation

  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.










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


[mapserver-users] Rendering Challenges - Polygon labeling

2011-05-10 Thread Brent Fraser
  I've been thinking about the polygon label challenge.  The difficulty 
is the view (the extent of the rendered map image) may be completely 
inside the polygon-to-be-labeled (and so no polygon edges are visible), 
partially overlap the polygon, or completely enclose the polygon.


Here's my thought on how to handle the various cases:

1. if View completely within Poly, then
place Label at top left of View
(but be careful, there could be multiple layers of polygons putting 
labels there

 so maybe the user should specify X,Y, location in pixels?)

2. else if Poly partially overlaps View
place Label at inside edge (POSITION FollowEdgeInside?) of Poly

3. else (polygon is completely within view)
3.1 if Label fits within Poly
place Label within (allow: CC, FollowEdgeInside, 
FollowEdgeOutside)

3.2 else if rotated text fits within Poly
rotate Label and place within
3.3 else
place Label beside Poly (allow the eight positions similar 
to point labeling?)


Might be a big effort to implement, and I have no clue how to make it 
configurable via the map file


--
Best Regards,
Brent Fraser


___
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 Lime, Steve D (DNR)
I've attached a patch against trunk that adds the difference function. It's 
untested, give it a whirl and
let me know how it goes... You'll have to re-build the lexer and parser.

Steve

-Original Message-
From: Brent Fraser [mailto:bfra...@geoanalytic.com] 
Sent: Tuesday, May 10, 2011 9:42 AM
To: Lime, Steve D (DNR)
Cc: mapserver-users@lists.osgeo.org
Subject: Re: [mapserver-users] Rendering Challenges

I think it would be very valuable

Best Regards,
Brent Fraser


On 5/10/2011 8:25 AM, Lime, Steve D (DNR) wrote:
 I don't have a difference operator implemented. Wouldn't take much though...

 -Original Message-
 From: Brent Fraser [mailto:bfra...@geoanalytic.com]
 Sent: Tuesday, May 10, 2011 9:07 AM
 To: Lime, Steve D (DNR)
 Cc: mapserver-users@lists.osgeo.org
 Subject: Re: [mapserver-users] Rendering Challenges

 Using

 STYLE
   GEOMTRANSFORM difference([shape],buffer([shape], -5))
   COLOR255 211 127
 END

 results in the entire original polygon being filled.

 Using
   GEOMTRANSFORM (difference([shape],buffer([shape], -5)))
 results in no fill.

 Best Regards,
 Brent Fraser


 On 5/9/2011 4:20 PM, Lime, Steve D (DNR) wrote:
 That's were a difference operator might come in handy since you're looking 
 for more of a fill-type effect:

 GEOMTRANSFORM (difference([shape], buffer([shape], -2)))

 or something like that.

 Steve

 -Original Message-
 From: Brent Fraser [mailto:bfra...@geoanalytic.com]
 Sent: Monday, May 09, 2011 5:18 PM
 To: Lime, Steve D (DNR)
 Cc: mapserver-users@lists.osgeo.org
 Subject: Re: [mapserver-users] Rendering Challenges

 Steve L.,

  Good point;  I couldn't do any of this in pre-6.0 either!

  I tried the buffer and it worked great (but we might have to work on
 the end-cap types in PDF output)! See http://i52.tinypic.com/2qjc9yv.jpg

 Best Regards,
 Brent Fraser


 On 5/9/2011 2:36 PM, Lime, Steve D (DNR) wrote:
 These aren't specific to 6.0 though- more of a wish list...

 Item 1 might be doable in 6.0 as it sits. In 6.0 a style GEOMTRANSFORM is 
 really an expression and I exposed
 the GEOS buffer operator as a proof-of-concept. For example:

 STYLE
  GEOMTRANSFORM (buffer([shape], -2))
  OUTLINECOLOR 255 0 0
 END

 Should generate a single pixel red line on the inside of a polygon shape. 
 You can render it however you'd like.
 Note that a GEOMTRANSFORM is performed AFTER a shape is converted from map 
 to image coordinates so it's effective
 for rendering effects only.

 If we exposed a few others you'd be able to do some other interesting 
 things (like fills just inside a line...).

 The rest of the ideas are interesting and worthy of discussion.

 Steve

 -Original Message-
 From: mapserver-users-boun...@lists.osgeo.org 
 [mailto:mapserver-users-boun...@lists.osgeo.org] On Behalf Of Brent Fraser
 Sent: Monday, May 09, 2011 2:52 PM
 To: mapserver-users@lists.osgeo.org
 Subject: [mapserver-users] Rendering Challenges

   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)
 2. Place polygon annotation on/inside boundary line
 (http://trac.osgeo.org/mapserver/ticket/1592 point 8.)
 3. Rotate anno if required to fit inside a polygon
 4. Place polygon annotation outside polygon if anno doesn't fit inside
 5. Place line anno above (or below) when using ANGLE FOLLOW
 6. Rotate vector symbols to follow lines (a font might work but is a
 pain to create)
 7. User specified character spacing
 8. Erase lines (but not other objects) under annotation

   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.










difference.patch
Description: difference.patch
___
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 Brent Fraser

Steve,

So I've done

C:\svn -r 11667 co https://svn.osgeo.org/mapserver/trunk/mapserver 
mapserver-6.0.0-r11667


C:\ mapserver-6.0.0-r11667 patch  difference.patch
  patching file mapparser.y
  patching file mapserver.h
  patching file maplexer.l

C:\ mapserver-6.0.0-r11667 flex  -Pmsyy -i -omaplexer.c maplexer.l

but my make results in:

   Creating library mapserver_i.lib and object mapserver_i.exp
mapfile.obj : error LNK2019: unresolved external symbol _msyylex_destroy 
referenced in function _msUpdateLabelFromString

maputil.obj : error LNK2001: unresolved external symbol _msyylex_destroy

Did I miss a step?

Best Regards,
Brent Fraser


On 5/10/2011 9:32 AM, Lime, Steve D (DNR) wrote:

I've attached a patch against trunk that adds the difference function. It's 
untested, give it a whirl and
let me know how it goes... You'll have to re-build the lexer and parser.

Steve

-Original Message-
From: Brent Fraser [mailto:bfra...@geoanalytic.com]
Sent: Tuesday, May 10, 2011 9:42 AM
To: Lime, Steve D (DNR)
Cc: mapserver-users@lists.osgeo.org
Subject: Re: [mapserver-users] Rendering Challenges

I think it would be very valuable

Best Regards,
Brent Fraser


On 5/10/2011 8:25 AM, Lime, Steve D (DNR) wrote:

I don't have a difference operator implemented. Wouldn't take much though...

-Original Message-
From: Brent Fraser [mailto:bfra...@geoanalytic.com]
Sent: Tuesday, May 10, 2011 9:07 AM
To: Lime, Steve D (DNR)
Cc: mapserver-users@lists.osgeo.org
Subject: Re: [mapserver-users] Rendering Challenges

Using

 STYLE
   GEOMTRANSFORM difference([shape],buffer([shape], -5))
   COLOR255 211 127
 END

results in the entire original polygon being filled.

Using
   GEOMTRANSFORM (difference([shape],buffer([shape], -5)))
results in no fill.

Best Regards,
Brent Fraser


On 5/9/2011 4:20 PM, Lime, Steve D (DNR) wrote:

That's were a difference operator might come in handy since you're looking for 
more of a fill-type effect:

 GEOMTRANSFORM (difference([shape], buffer([shape], -2)))

or something like that.

Steve

-Original Message-
From: Brent Fraser [mailto:bfra...@geoanalytic.com]
Sent: Monday, May 09, 2011 5:18 PM
To: Lime, Steve D (DNR)
Cc: mapserver-users@lists.osgeo.org
Subject: Re: [mapserver-users] Rendering Challenges

Steve L.,

  Good point;  I couldn't do any of this in pre-6.0 either!

  I tried the buffer and it worked great (but we might have to work on
the end-cap types in PDF output)! See http://i52.tinypic.com/2qjc9yv.jpg

Best Regards,
Brent Fraser


On 5/9/2011 2:36 PM, Lime, Steve D (DNR) wrote:

These aren't specific to 6.0 though- more of a wish list...

Item 1 might be doable in 6.0 as it sits. In 6.0 a style GEOMTRANSFORM is 
really an expression and I exposed
the GEOS buffer operator as a proof-of-concept. For example:

STYLE
  GEOMTRANSFORM (buffer([shape], -2))
  OUTLINECOLOR 255 0 0
END

Should generate a single pixel red line on the inside of a polygon shape. You 
can render it however you'd like.
Note that a GEOMTRANSFORM is performed AFTER a shape is converted from map to 
image coordinates so it's effective
for rendering effects only.

If we exposed a few others you'd be able to do some other interesting things 
(like fills just inside a line...).

The rest of the ideas are interesting and worthy of discussion.

Steve

-Original Message-
From: mapserver-users-boun...@lists.osgeo.org 
[mailto:mapserver-users-boun...@lists.osgeo.org] On Behalf Of Brent Fraser
Sent: Monday, May 09, 2011 2:52 PM
To: mapserver-users@lists.osgeo.org
Subject: [mapserver-users] Rendering Challenges

   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)
2. Place polygon annotation on/inside boundary line
(http://trac.osgeo.org/mapserver/ticket/1592 point 8.)
3. Rotate anno if required to fit inside a polygon
4. Place polygon annotation outside polygon if anno doesn't fit inside
5. Place line anno above (or below) when using ANGLE FOLLOW
6. Rotate vector symbols to follow lines (a font might work but is a
pain to create)
7. User specified character spacing
8. Erase lines (but not other objects) under annotation

   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.










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


[mapserver-users] WMS GetFeatureInfo - is it possible to support multiple INFO_FORMATs?

2011-05-10 Thread myOpenLayersUName
Hello all,

I've been trying to figure out how to do this for a while this afternoon and
thought perhaps I'd better step back and find out if it's even possible
before I keep struggling with it.

Is it possible to support multiple INFO_FORMAT properties to a WMS
GetFeatureInfo request? That is, is there a way to configure a MAP file that
is acting as a WMS Server to return HTML or XML based on what is asked for
in the request itself?

Cheers,
jtm

--
View this message in context: 
http://osgeo-org.1803224.n2.nabble.com/WMS-GetFeatureInfo-is-it-possible-to-support-multiple-INFO-FORMATs-tp6349109p6349109.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


Re: [mapserver-users] WMS GetFeatureInfo - is it possible to support multiple INFO_FORMATs?

2011-05-10 Thread Jeff McKenna

On 11-05-10 4:11 PM, myOpenLayersUName wrote:

Hello all,

I've been trying to figure out how to do this for a while this afternoon and
thought perhaps I'd better step back and find out if it's even possible
before I keep struggling with it.

Is it possible to support multiple INFO_FORMAT properties to a WMS
GetFeatureInfo request? That is, is there a way to configure a MAP file that
is acting as a WMS Server to return HTML or XML based on what is asked for
in the request itself?


Further comments:

- maybe look into a mapscript wrapper for your WMS service: 
http://www.mapserver.org/ogc/mapscript.html


Have fun.

-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] Re: WMS GetFeatureInfo - is it possible to support multiple INFO_FORMATs?

2011-05-10 Thread myOpenLayersUName
Thanks for your response, Jeff; and, to be honest, I didn't think it could. 

However, it's quite interesting that you would reference that particular
documentation because it was exactly that section that started me looking
into how it might be possible. There are three links to what I was guessing
was ultimately the same MAP file at http://demo.mapserver.org/cgi-bin/wms:

Here are working examples of GetFeatureInfo requests: text/plain,
text/html, gml ... 

However, given your confirmation and my own previous understanding, I
imagine it's likely a script that is looking at different MAP files based on
the value passed for the INFO_FORMAT parameter.

Again, thanks. It's always nice to know when I can stop beating my head
against a wall.


--
View this message in context: 
http://osgeo-org.1803224.n2.nabble.com/WMS-GetFeatureInfo-is-it-possible-to-support-multiple-INFO-FORMATs-tp6349109p6349243.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] Re: WMS GetFeatureInfo - is it possible to support multiple INFO_FORMATs?

2011-05-10 Thread myOpenLayersUName
Ah, you're two steps ahead of me again!

Thanks,

--
View this message in context: 
http://osgeo-org.1803224.n2.nabble.com/WMS-GetFeatureInfo-is-it-possible-to-support-multiple-INFO-FORMATs-tp6349109p6349248.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


Re: [mapserver-users] WMS GetFeatureInfo - is it possible to supportmultiple INFO_FORMATs?

2011-05-10 Thread Rahkonen Jukka
Hi,

If you mean an effect like this

http://demo.mapserver.org/cgi-bin/wms?SERVICE=WMSVERSION=1.1.1REQUEST=GetFeatureInfoBBOX=-11.332970,24.121208,47.584718,57.965035SRS=EPSG:4326WIDTH=1001HEIGHT=575LAYERS=citiesSTYLES=FORMAT=image/pngTRANSPARENT=trueQUERY_LAYERS=citiesINFO_FORMAT=text/plainX=229Y=280

vs.

http://demo.mapserver.org/cgi-bin/wms?SERVICE=WMSVERSION=1.1.1REQUEST=GetFeatureInfoBBOX=-11.332970,24.121208,47.584718,57.965035SRS=EPSG:4326WIDTH=1001HEIGHT=575LAYERS=citiesSTYLES=FORMAT=image/pngTRANSPARENT=trueQUERY_LAYERS=citiesINFO_FORMAT=text/htmlX=229Y=280

then yes, it is possible

-Jukka Rahkonen-


-Alkuperäinen viesti-
Lähettäjä: mapserver-users-boun...@lists.osgeo.org puolesta: Jeff McKenna
Lähetetty: ti 10.5.2011 22:34
Vastaanottaja: mapserver-users@lists.osgeo.org
Aihe: Re: [mapserver-users] WMS GetFeatureInfo - is it possible to 
supportmultiple INFO_FORMATs?
 
On 11-05-10 4:11 PM, myOpenLayersUName wrote:
 Hello all,

 I've been trying to figure out how to do this for a while this afternoon and
 thought perhaps I'd better step back and find out if it's even possible
 before I keep struggling with it.

 Is it possible to support multiple INFO_FORMAT properties to a WMS
 GetFeatureInfo request? That is, is there a way to configure a MAP file that
 is acting as a WMS Server to return HTML or XML based on what is asked for
 in the request itself?

Not that I know of.  In fact you should probably check the WMS spec on 
the OGC site to see if that is allowed by the standard (my guess is no). 
  I do know that the MapServer support for GetFeatureInfo requests is 
documented in the Configuring for GetFeatureInfo Requests section of 
http://www.mapserver.org/ogc/wms_server.html

Of course, I've been wrong many times before, so someone can correct me 
if I am wrong here :)

-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


Re: [mapserver-users] Re: WMS GetFeatureInfo - is it possible to support multiple INFO_FORMATs?

2011-05-10 Thread Jeff McKenna
Wait! MapServer out of the box supports the formats described in that 
document...I think I am misunderstanding your question.  I thought you 
were trying to return multiple formats in one request, so I answered no. 
 But if you read that section it tells you how to configure the mapfile 
for the requests individually (and yes I included those working examples 
to show you..no script involved).


-jeff


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



On 11-05-10 4:44 PM, myOpenLayersUName wrote:

Thanks for your response, Jeff; and, to be honest, I didn't think it could.

However, it's quite interesting that you would reference that particular
documentation because it was exactly that section that started me looking
into how it might be possible. There are three links to what I was guessing
was ultimately the same MAP file at http://demo.mapserver.org/cgi-bin/wms:

Here are working examples of GetFeatureInfo requests: text/plain,
text/html, gml ... 

However, given your confirmation and my own previous understanding, I
imagine it's likely a script that is looking at different MAP files based on
the value passed for the INFO_FORMAT parameter.

Again, thanks. It's always nice to know when I can stop beating my head
against a wall.



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


[mapserver-users] Re: WMS GetFeatureInfo - is it possible to support multiple INFO_FORMATs?

2011-05-10 Thread myOpenLayersUName
To clarify, I want to be able to make two completely separate GetFeatureInfo
requests to a WMS Server; one that will return HTML and the other will
return XML. 

As far as I'm understand from the MapServer documentation, I need to set
wms_feature_info_mime_type parameter to one of three values:

- text/xml
- text/html
- application/vnd.ogc.gml

How can I set it to two of those values?

Or, am I supposed to be able to do something like the following in a LAYER's
WEB object?

wms_feature_info_mime_type text/html
wms_feature_info_mime_type text/xml

And, if I can do that, how can I point to two different TEMPLATES? An HTML
one and an XSL for the XML? Or, again, am I supposed to be able to have two
TEMPLATE keywords in a single LAYER?

Or, am I completely missing some very important item in all these
discussions?


BTW, Rahkonen Jukka, I particularly appreciated your description of these
items at: 
http://osgeo-org.1803224.n2.nabble.com/GetFeatureInfo-request-doubts-td5083816.html
http://osgeo-org.1803224.n2.nabble.com/GetFeatureInfo-request-doubts-td5083816.html
.


--
View this message in context: 
http://osgeo-org.1803224.n2.nabble.com/WMS-GetFeatureInfo-is-it-possible-to-support-multiple-INFO-FORMATs-tp6349109p6349329.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] Re: WMS GetFeatureInfo - is it possible to support multiple INFO_FORMATs?

2011-05-10 Thread myOpenLayersUName
I'm starting to think that what I might do is support HTML and GML and simply
not return any geometry for the GML. Does that sound like a way to do what I
need?

--
View this message in context: 
http://osgeo-org.1803224.n2.nabble.com/WMS-GetFeatureInfo-is-it-possible-to-support-multiple-INFO-FORMATs-tp6349109p6349334.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] Re: WMS GetFeatureInfo - is it possible to support multiple INFO_FORMATs?

2011-05-10 Thread myOpenLayersUName
There is no such thing as text/xml. Where the heck did I come up with that?

Okay, I know how to support HTML and GML at the same time. 

Sorry about all that...

--
View this message in context: 
http://osgeo-org.1803224.n2.nabble.com/WMS-GetFeatureInfo-is-it-possible-to-support-multiple-INFO-FORMATs-tp6349109p6349382.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


RE: [mapserver-users] Mapserver as a WMS Client - problems working with a 'remote' Tilecache service

2011-05-10 Thread Andrew Cowie
Hi Jukka,

Many thanks for the suggestion however we've decided to take another route - 
which basically entails publishing a OGC standards compliant Mapserver WMS 
alongside a WMTS enabled Tilecache service.

Cheers

Andrew

-Original Message-
From: Rahkonen Jukka [mailto:jukka.rahko...@mmmtike.fi]
Sent: Friday, 6 May 2011 4:10 p.m.
To: Andrew Cowie; mapserver-users@lists.osgeo.org
Subject: Re: [mapserver-users] Mapserver as a WMS Client - problems working 
with a 'remote' Tilecache service

Hi,

I have never tried myself but I would guess that you need to prepare a xml file 
for defining a gdal-wms datasource and refer to that xml file in your mapfile. 
Read http://gdal.org/frmt_wms.html

-Jukka Rahkonen-

Andrew Cowie wrote:


 Hello List,

 We are currently setting up a cascading WMS using Mapserver as a client to 
 request maps from another Mapserver and from a Tilecache. We have read that 
 Mapserver can be configured to do this but we are running into problems when 
 using Mapserver as a client to Tlecache. Specifically, how do we publish 
 metadata in the MapSever Client capabilities document about the correct 
 resolutions / bounding box of a Tilecache service.

 More details...

 Here's a snippet of our 'top level' Mapserver mapfile, which will sit on our 
 public server:


   LAYER
  NAME 'lcr_basemap_cache_wgs84'
  TYPE RASTER
  CONNECTIONTYPE WMS
  CONNECTION http://ourserver/tilecache/wms-c/tilecache.py?;
  PROCESSING CLOSE_CONNECTION=DEFER

  METADATA
 wms_name  lcr_basemap_cache_wgs84
 wms_title Baselayer - Cached
 wms_server_version1.1.1
 wms_formatimage/png
 wms_srs   EPSG:4326
 wms_extent165 -48 179.5 -33
 wms_abstract  Cached via Tilcache
  END
   END

This pulls a layer from our Tilecache (a snippet from our tilecache config 
file):

[lcr_basemap_cache_wgs84]
type=WMSLayer
layers=coastpoly,veg,urban_grp,contours,water,coast_feats,height_pnts,tracks,rail,all_roads,railway_station,text
srs=EPSG:4326
bbox=165,-48,179.5,-33
resolutions=0.025398253504337,0.012699126752168,0.006349563376084,0.003174781688042,0.001587390844021,0.000793695422011,0.000317478168804,0.000158739084402,0.79369542201,0.31747816880,0.15873908440,0.06349563376,0.03174781688
url=http://ourserver/cgi-bin/mapserv?map=/path/to/ourmapfile.maptransparent=true;
extent_type=loose
metaBuffer=10
metasize=6,6
metaTile=true

(As you can see, Tilecache is pointing to another Mapserver which generates the 
maps.)

We have had some success in connecting to the Tilecache via the Mapserver 
Client using an Openlayers client to view the 'top level' WMS layers ** BUT ** 
this only works because we configured Openlayers to use the correct resolutions 
/ bounding box etc. What we are really trying to achieve with this is a public 
WMS for which other people/clients can use, e.g. Openlayers / QGIS, by just 
reading the Capabilities document provided by the MapServer client.

So far, we have yet to find a way to advertise (via the capabilities document) 
these underlying Tilecache resolutions as metadata in the cascading level 
Mapserver. Is this possible?

If it is not possible, does anybody have recommendations as to how to go about 
this in a standards compliant way?

Many thanks,

Andy



Please consider the environment before printing this email
Warning: This electronic message together with any attachments is confidential. 
If you receive it in error: (i) you must not read, use, disclose, copy or 
retain it; (ii) please contact the sender immediately by reply email and then 
delete the emails.
The views expressed in this email may not be those of Landcare Research New 
Zealand Limited. http://www.landcareresearch.co.nz


Please consider the environment before printing this email
Warning:  This electronic message together with any attachments is 
confidential. If you receive it in error: (i) you must not read, use, disclose, 
copy or retain it; (ii) please contact the sender immediately by reply email 
and then delete the emails.
The views expressed in this email may not be those of Landcare Research New 
Zealand Limited. http://www.landcareresearch.co.nz
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] WMS GetFeatureInfo - is it possible to support multiple INFO_FORMATs?

2011-05-10 Thread Trond Michelsen
On Tue, May 10, 2011 at 04:34:31PM -0300, Jeff McKenna wrote:
 Is it possible to support multiple INFO_FORMAT properties to a WMS
 GetFeatureInfo request? That is, is there a way to configure a MAP
 file that is acting as a WMS Server to return HTML or XML based on
 what is asked for in the request itself?
 Not that I know of.  In fact you should probably check the WMS spec
 on the OGC site to see if that is allowed by the standard (my guess
 is no).

The standard allows multiple mime types for the GetFeatureInfo request:

7.4.3.5  INFO_FORMAT
The mandatory INFO_FORMAT parameter indicates what format to use when
returning the feature information.  Supported values for a
GetFeatureInfo request on a WMS server are listed as MIME types in one
or more RequestFeatureInfoFormat elements of its service
metadata. The entire MIME type string in Format is used as the value
of the INFO_FORMAT parameter. In an HTTP environment, the MIME type
shall be set on the returned object using the Content-type entity
header. If the request specifies a format not supported by the server,
the server shall issue a service exception (code = InvalidFormat).


However, as the example capabilities document shows, the available
mime types for the GetFeatureInfo request is defined on a per-server
basis, and as far as I can tell, all queryable layers must support
all formats.

http://schemas.opengis.net/wms/1.3.0/capabilities_1_3_0.xml

Capability
  ...
  Request
...
GetFeatureInfo
  Formattext/xml/Format
  Formattext/plain/Format
  Formattext/html/Format
  DCPType
HTTP
  Get
OnlineResource xmlns:xlink=http://www.w3.org/1999/xlink;
 xlink:type=simple
 xlink:href=http://hostname/path?; /
  /Get
/HTTP
  /DCPType
/GetFeatureInfo
  /Request
/Capability


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


[mapserver-users] Re: Arrowhead in Mapserver 6.0

2011-05-10 Thread Makoto Niwa
me again,

It was resoleved.
I used negative value in vector symbol point such as -20,-10.
It was wrong. I thougt only -99 was non-continuous line value.
Use all postive value(except non-continuous value -99) in it,
I can get the same results by all 3 renderers.

thanks,

makoto.

At 06 May 2011 13:59:45 +0900 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


---
丹羽 誠  (株)オークニー
〒220-6212
横浜市西区みなとみらい2-3-5 クイーンズタワーC棟12階
Tel.045-228-3320  Fax.045-228-3321
E-mail:n...@orkney.co.jp URL:www.orkney.co.jp
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users