But lacking that, worry about the algorithm first, and only then worry about
how to do it in MapBasic or any other programming environment.
The first step is to be clear about your terminology. Use of the term
"waypoint" in the context of a 2-dimensional object like a region puzzles
me, because that term is used more appropriately in the context of a
1-dimensional linear path.
________________________________
Spencer
Hi All!
Thanks!!
Cyrus
--
You received this message because you are subscribed to the
Google Groups "MapInfo-L" group.To post a message to this group, send
email to mapi...@googlegroups.com
To unsubscribe from this group, go to:
http://groups.google.com/group/mapinfo-l/subscribe?hl=en
For more options, information and links to MapInfo resources (searching
archives, feature requests, to visit our Wiki, visit the Welcome page at
http://groups.google.com/group/mapinfo-l?hl=en
---
To fill a polygon with psuedo random points:
assign var 'bbox" to the minimum bounding rectangle of your polygon.
assign var pg to a polygon
set var max_count to the maximum number of points you want in your polygon
set var count to 0
TOP:
set var x to pick random value between bbox.minx and bbox.maxx
set var y to pick random value between bbox.miny and bbox.maxy
set var p = make a point from x, y
if p is inside polygon
add point to map
increment count
if count <= max then
jump to TOP
---