AW: [mapserver-users] Oracle Spatial + MS 5.2.0: No drawing of certain objects
Schönhammer, Herbert
Schoenhammer.Herbert at Regensburg.de
Mon Sep 22 00:41:40 PDT 2008
Hallo Paul,
using this patch, mapserver is not ignoring those polygons anymore (polygons, which exists ONLY of a connected sequence of circular arcs that closes on itself).
But instead of rendering those polygons, I get know an error message:
msDrawMap(): Image handling error. Failed to draw layer named 'stgk_gebaeude_orcl'.
msDrawShape(): General error message. Only polygon shapes can be drawn using a POLYGON layer definition.
The first step for rendering those polgons is done: Mapserver recognizes the polygons !
Can I do anything else ?
Greetings
Herbert
"polygons, which exists ONLY of
>a connected sequence of circular arcs that closes on itself
>-----Ursprüngliche Nachricht-----
>Von: Paul Ramsey [mailto:pramsey at cleverelephant.ca]
>Gesendet: Freitag, 19. September 2008 16:40
>An: Schönhammer, Herbert
>Cc: Mapserver-users (mapserver-users at lists.osgeo.org)
>Betreff: Re: [mapserver-users] Oracle Spatial + MS 5.2.0: No
>drawing of certain objects
>
>
>Try the following completely untested patch:
>
>Index: maporaclespatial.c
>===================================================================
>--- maporaclespatial.c (revision 7827)
>+++ maporaclespatial.c (working copy)
>@@ -1476,6 +1476,9 @@
> case 31: /* simple polygon with n points, last
>point equals the first one */
> osClosedPolygon(hand, shape, obj, ord_start,
>ord_end, points, elem_type, data3d);
> break;
>+ case 32: /* simple polygon with only arcs
>for bounds */
>+ osArcPolygon(hand, shape, obj, ord_start,
>ord_end, points, data3d);
>+ break;
> case 33: /* rectangle defined by 2 points */
> osRectangle(hand, shape, obj, ord_start,
>ord_end, points, point5, data3d);
> break;
>
>
>
>
>On Fri, Sep 19, 2008 at 3:20 AM, Schönhammer, Herbert
><Schoenhammer.Herbert at regensburg.de> wrote:
>> Hallo Paul,
>>
>> 1.) Yes, there is no difference in behavior between the old
>and new mapserver versions.
>>
>> 2.) Yes and No. In detail:
>>
>> 2a) If there is at most ONE straight line in the polygon,
>mapserver renders this polygon correct, even if there is a
>curved segement (arc) in the polygon. For example this is a
>church, which contains three arcs in the polygon (triple
>11,2,2 and 31,2,2 and 51,2,2). This polygon is rendered correct.
>>
>> INSERT INTO AX_GEBAEUDE (FID,GEOM) VALUES
>(14080503,mdsys.sdo_geometry(2003,82032,null,mdsys.sdo_elem_inf
>o_array(1,1005,7,1,2,1,11,2,2,15,2,1,31,2,2,35,2,1,51,2,2,55,2,
>1),mdsys.sdo_ordinate_array(4506867.81,5430890.76,4506872.05,54
>30889.72,4506881.01,5430887.51,4506881.58,5430889.82,4506883.14
>,5430896.16,4506937.22,5430883.9,4506941.09222415,5430884.75129
>585,4506943.86,5430887.59,4506948.31,5430886.72,4506947.53,5430
>882.98,4506950.45,5430882.37,4506950.02,5430880.3,4506955.17,54
>30879.23,4506955.58,5430881.2,4506958.35,5430880.62,4506959.21,
>5430884.73,4506961.57385865,5430886.53782314,4506960.13,5430889
>.14,4506960.94,5430893,4506957.92,5430893.63,4506958.4,5430896.
>12,4506953.2,5430897.12,4506952.74,5430894.72,4506950.1,5430895
>.27,4506949.23,5430891.12,4506944.73,5430892,4506942.9045371,54
>30896.27675424,4506939.38,5430899.31,4506893.36,5430909.55,4506
>886.79,5430911.01,4506888.96,5430919.81,4506882.98,5430921.28,4
>506874.83,5430923.28,4506874.09,5430920.3,4506872.55,5430914.03
>,4506866.92,5430915.42,4506864.74,5430915.95,4506861.35,5430902
>.17,4506870.09,5430900.02,4506867.81,5430890.76)));
>>
>> 2b) Mapserver does not render polygons, which exists ONLY of
>a connected sequence of circular arcs that closes on itself.
>(Examples below).
>>
>> Greetings
>> Herbert
>>
>>>-----Ursprüngliche Nachricht-----
>>>Von: Paul Ramsey [mailto:pramsey at cleverelephant.ca]
>>>Gesendet: Donnerstag, 18. September 2008 16:35
>>>An: Schönhammer, Herbert
>>>Betreff: Re: [mapserver-users] Oracle Spatial + MS 5.2.0: No
>>>drawing of certain objects
>>>
>>>
>>>So, to confirm, there is now no difference in behavior between your
>>>old and new mapserver installations?
>>>
>>>However, the old and new installations share an inability to render
>>>polygons that include curved boundaries?
>>>
>>>P.
>>>
>>>On Thu, Sep 18, 2008 at 3:14 AM, Schönhammer, Herbert
>>><Schoenhammer.Herbert at regensburg.de> wrote:
>>>> Hallo Paul,
>>>>
>>>> (I needed some time because new hardware, ...)
>>>>
>>>> Okay: First of all:
>>>>
>>>> The reported NEW DIFFICULTIES are not reproducable any more.
>>>I really don't know what happened. But LINESTRINGS made up of
>>>a connected sequence of circular arcs ARE DRAWN by mapserver.
>>>>
>>>> The old problem still exists.
>>>> =============================
>>>> POLYGONS made up of a connected sequence of circular arcs
>>>ARE NOT DRAWN by mapserver. No error message.
>>>>
>>>> I have made a config error in my mapfile. So I could get an
>>>error message from mapserver. In this error message the
>>>SQL-statement sent to the oracle database is:
>>>>
>>>> SELECT fid, geom FROM AX_GEBAEUDE WHERE SDO_FILTER( geom,
>>>MDSYS.SDO_GEOMETRY(2003, 82032,
>>>NULL,MDSYS.SDO_ELEM_INFO_ARRAY(1,1003,3),MDSYS.SDO_ORDINATE_ARR
>>>AY(4505602.25,5430841.31,4505622.97,5430856.39)
>>>),'querytype=window') = 'TRUE'
>>>>
>>>> When i submit this SQL direct to the databse I get 4
>geometries back.
>>>> Two POLYGONS made up of straight line segements.
>>>> Two POLYGONS made up of a connected sequence of circular arcs.
>>>>
>>>> The polygons with straight line segments are drawn, the
>>>polygons made up of a connected sequence of circular arcs are
>>>not drawn.
>>>>
>>>> I have exported these objects from my database:
>>>>
>>>> The drawn polygons are:
>>>> INSERT INTO AX_GEBAEUDE (FID,GEOM) VALUES
>>>(14079074,mdsys.sdo_geometry(2003,82032,null,mdsys.sdo_elem_inf
>>>o_array(1,1003,1),mdsys.sdo_ordinate_array(4505658.59,5430772.1
>>>7,4505643.27,5430803.04,4505634.39,5430798.05,4505625.41,543081
>>>4,4505619.34,5430810.5898,4505607.9,5430830.95,4505607.4,543083
>>>0.7,4505600.29,5430845.02,4505511.2,5430801.08,4505534.42,54307
>>>54.01,4505552.34,5430762.86,4505569.51,5430728.08,4505658.59,54
>>>30772.17)));
>>>> INSERT INTO AX_GEBAEUDE (FID,GEOM) VALUES
>>>(14079078,mdsys.sdo_geometry(2003,82032,null,mdsys.sdo_elem_inf
>>>o_array(1,1003,1),mdsys.sdo_ordinate_array(4505643.27,5430803.0
>>>4,4505643.85,5430803.37,4505644.39,5430803.67,4505644.34,543080
>>>3.76,4505635.46,5430819.49,4505633.64,5430822.73,4505619.68,543
>>>0847.46,4505609.69,5430841.9199,4505613.95,5430834.36,4505625.4
>>>1,5430814,4505634.39,5430798.05,4505643.27,5430803.04)));
>>>>
>>>> The polygons which are not drawn are:
>>>> INSERT INTO AX_GEBAEUDE (FID,GEOM) VALUES
>>>(14079126,mdsys.sdo_geometry(2003,82032,null,mdsys.sdo_elem_inf
>>>o_array(1,1003,2),mdsys.sdo_ordinate_array(4505611.03,5430848.5
>>>5,4505611.03,5430845.19,4505614.39,5430845.19,4505614.39,543084
>>>8.55,4505611.03,5430848.55)));
>>>> INSERT INTO AX_GEBAEUDE (FID,GEOM) VALUES
>>>(14079128,mdsys.sdo_geometry(2003,82032,null,mdsys.sdo_elem_inf
>>>o_array(1,1003,2),mdsys.sdo_ordinate_array(4505615.64,5430849.9
>>>,4505615.64,5430847.3,4505618.24,5430847.3,4505618.24,5430849.9
>>>,4505615.64,5430849.9)));
>>>>
>>>>
>>>> All polygons are GTYPE=2003 in SRID=82032. All POLYGONS are
>>>SDO_ETYPE=1003.
>>>> The POLYGONS with SDO_INTERPRETATION = 1 are drawn.
>>>> The POLYGONS with SDO_INTERPRETATION = 2 are not drawn.
>>>>
>>>>
>>>> greetings
>>>> Herbert
>>>>
>>>>>-----Ursprüngliche Nachricht-----
>>>>>Von: Paul Ramsey [mailto:pramsey at cleverelephant.ca]
>>>>>Gesendet: Donnerstag, 11. September 2008 19:07
>>>>>An: Schönhammer, Herbert
>>>>>Cc: Mapserver-users (mapserver-users at lists.osgeo.org)
>>>>>Betreff: Re: [mapserver-users] Oracle Spatial + MS 5.2.0: No
>>>>>drawing of certain objects
>>>>>
>>>>>
>>>>>Could you do a bit more legwork and see if the problem
>appears at the
>>>>>transition to 5.0 or the transition to 5.2? From there we
>>>can probably
>>>>>find the code change that caused it.
>>>>>
>>>>>P.
>>>>>
>>>>>On Wed, Sep 10, 2008 at 7:03 AM, Schönhammer, Herbert
>>>>><Schoenhammer.Herbert at regensburg.de> wrote:
>>>>>> Hi list,
>>>>>>
>>>>>> ( I had a similar discussion using Mapserver 4.10.x and
>>>>>Oracle Spatial 9i in
>>>>>> May 2007. But the problems changed using Mapserver 5.2.0 .).
>>>>>>
>>>>>>
>>>>>> The new environmet:
>>>>>> ===============
>>>>>> Server SLES10
>>>>>> Mapserver 5.2.0
>>>>>> Oracle OCI - Interface used with Oracle 11-Client-Software
>>>>>>
>>>>>> DB-Server Windows 2xxx
>>>>>> Oracle Spatial 10g
>>>>>>
>>>>>>
>>>>>> The new problem :
>>>>>> ==============
>>>>>> Line strings made up of a connected sequence of circular
>>>>>arcs ARE NOT DRAWN.
>>>>>> No error message is generated by mapserver, but the objects
>>>>>are not shown in
>>>>>> the map.
>>>>>>
>>>>>> Example:
>>>>>> INSERT INTO AX_BES_GEBLINIE (FID,GEOM) VALUES
>>>>>>
>>>>>(14196363,mdsys.sdo_geometry(2002,82032,null,mdsys.sdo_elem_inf
>>>>>o_array(1,2,2),mdsys.sdo_ordinate_array(4512474.1948,5426555.09
>>>>>79,4512473.3318,5426554.2349,4512474.1948,5426553.3719,4512475.
>>>>>0578,5426554.2349,4512474.1948,5426555.0979)));
>>>>>>
>>>>>> (Background:
>>>>>> In my mailing from May 2007 I reported that these
>Objects are drawn
>>>>>> correctly by mapserver. This statement is indeed
>>>>>reproducable correct using
>>>>>> mapserver 4.10.x. This is independent from the used oracle
>>>>>version ( 9i or
>>>>>> 10g ).
>>>>>> Now, using mapserver 5.2.0 these objects are not drawn
>>>>>anymore. No error
>>>>>> message is produced. This is also independent from the used
>>>>>oracle version (
>>>>>> 9i or 10g ). )
>>>>>>
>>>>>> The old problem:
>>>>>> ============
>>>>>> Polygons made up of a connected sequence of circular arcs
>>>>>ARE NOT DRAWN. No
>>>>>> error message is generated by mapserver, but the objects are
>>>>>not shown in
>>>>>> the map.
>>>>>>
>>>>>> (This problem was already reported in May 2007. The
>>>>>behaviour did not change
>>>>>> from mapserver 4.10.x to 5.2.0)
>>>>>>
>>>>>> Example:
>>>>>> INSERT INTO AX_GEBAEUDE (FID,GEOM) VALUES
>>>>>>
>>>>>(14079065,mdsys.sdo_geometry(2003,82032,null,mdsys.sdo_elem_inf
>>>>>o_array(1,1003,2),mdsys.sdo_ordinate_array(4505553.2585,5430757
>>>>>.2937,4505551.1659,5430755.2011,4505553.2585,5430753.1085,45055
>>>>>55.3511,5430755.2011,4505553.2585,5430757.2937)));
>>>>>>
>>>>>>
>>>>>> Oracle Documentation:
>>>>>> =================
>>>>>> Reading the Oracle Docs, I think all the objects are correct
>>>>>defined. The
>>>>>> geometries are validating by oracle 9i and oracle 10g (Using
>>>>>the st_valid -
>>>>>> method, e.g. SELECT a.GEOM.ST_IsValid()
>>>>>> FROM ax_bes_geblinie a WHERE a.fid = 14196363;).
>>>>>>
>>>>>>
>>>>>>
>>>>>> Does anybody know a solution how to draw these objects with
>>>>>mapserver ?
>>>>>>
>>>>>> greetings
>>>>>> Herbert
>>>>>>
>>>>>> _______________________________________________
>>>>>> mapserver-users mailing list
>>>>>> mapserver-users at lists.osgeo.org
>>>>>> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>>>>>>
>>>>>>
>>>>>
>>>>
>>>
>> _______________________________________________
>> mapserver-users mailing list
>> mapserver-users at lists.osgeo.org
>> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>>
>
More information about the MapServer-users
mailing list