David,

The issue of curved lines has not been clarified by the sender of the query,
but Bill Thoen framed the problem in MI terms quite explicitly.

Your contribution about selecting curved polylines by using objectgeography
adds confusion to the subject because, in MI, curved forms exist only as ARC
objects and the attributes you use for that function apply only to ARC
objects; you could have selected those forms more precisely with objectinfo
for type=arc. That means that all the considerations about S shapes are
factitious and that your approach is irrelevant when dealing with polylines.

My view of the world translates into a curved geography; for me, pure
straight lines do not exist in reality, straight line segments are only
approximation of real shapes, the quality of the approximation depending on
the scale and the coordsys used. The presence of a node is enough for me to
indicate a change in direction (a curve?); but a change of direction is not
enough to define a "curved" portion; the intensity of the change must be
defined and only the user can specify it.

Jacques

Jacques PARIS

[EMAIL PROTECTED]

For MapInfo support, see the Paris PC Consult enr. site  at
http://www.paris-pc-gis.com

-----Original Message-----
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED]]On Behalf Of David Booth
Sent: April 11, 2001 4:36 AM
To: '[EMAIL PROTECTED]'; [EMAIL PROTECTED]
Subject: RE: MI-L Line attributes

Hi Peter,

As Bill Thoen says, a "curved" polyline is made up of straight segments, so
to determine if it is curved, you need to work out if segments run in the
same direction as each other.

You should be able to knock something together using mapbasic. Objectnodex()
and Objectnodey() will return coordinates for the nodes on a polyline, then
some variation on

tan(angle) = (y2-y1) / (x2-x1)

Where

angle = the angle of the segment
x1,y1 = coords of first node
x2,y2 = coords of second node

for each segment - if the angles differ then the polyline is curved.

If this sounds horrible, you could probably do a quick and dirty check
using:

select where objectgeography(obj,OBJ_GEO_ARCBEGANGLE)  <>
objectgeography(obj,OBJ_GEO_ARCENDANGLE)

which would select curved polylines, except those where the last segment
goes in the same direction as the first (eg S or Z shapes).

Anyway, it's far too early in the morning for me to dredge up trigonometry
from my schooldays, so I'm off for a coffee.

Hope this helps, and my trig. is right!
---------------------------------------------
David Booth
Senior GIS Officer
Merseyside Information Service

> -----Original Message-----
> From: [EMAIL PROTECTED] [SMTP:[EMAIL PROTECTED]]
> Sent: 10 April 2001 18:28
> To:   [EMAIL PROTECTED]
> Subject:      MI-L Line attributes
>
> Greetings,
>
> I think this should be a simple request. I am wondering if anyone knows of
> a technique to select a portion of a polyline that may have a curvature. I
> have a number of polylines that I would like to select only the portion
> which curves.
>
> Your thoughts and suggestions are welcome.
>
> TIA
>
> Cheers,
>
> Peter
>
> ___________________________
> Peter McPherson
> GIS Technician
> Cameco Corporation
> 2121 11th Street West
> Saskatoon, Saskatchewan
> S7M 1J3
> Canada
>
> Telephone (306) 956 6433
> Fax (306) 956 6390
>
>
>
>
> _______________________________________________________________________
> List hosting provided by Directions Magazine | www.directionsmag.com |
> To unsubscribe, send e-mail to [EMAIL PROTECTED] and
> put "unsubscribe MapInfo-L" in the message body.



_______________________________________________________________________
List hosting provided by Directions Magazine | www.directionsmag.com |
To unsubscribe, send e-mail to [EMAIL PROTECTED] and
put "unsubscribe MapInfo-L" in the message body.



_______________________________________________________________________
List hosting provided by Directions Magazine | www.directionsmag.com |
To unsubscribe, send e-mail to [EMAIL PROTECTED] and
put "unsubscribe MapInfo-L" in the message body.

Reply via email to