Talk About Network

Google


Register and Login
Nick
Password
Register create new account Sign up is FREE and you can post replies, new topics, bookmark posts and more!
Recover lost password


Programming > Idl-pvware > Re: pollyfillv,...
Latest [ Topics | Posts ] Archive Post A New Topic Post a Reply
<< Topic < Post Post 3 of 7 Topic 5594 of 6457
Post > Topic >>

Re: pollyfillv, area of a blob, etc...

by David Fanning <news@[EMAIL PROTECTED] > Apr 3, 2008 at 08:16 AM

JP writes:

> by the way, I would be happy if at least I could calculate the
> centroid of each polygon and then get the array index for each
> centroid.

I suppose the centroid of the polygon is the average
value of it vertices, or maybe the mean if you didn't
want to overbias outliers. In your case, you could
probably just pick a vertex and be pretty darn close
to it. :-)
 
> But I don't know how to calculate the centroid (Coyote's procedure
> CENTROID works with an array, not with a polygon).
> 
> And if I had the centroid, how do I easily get the array index?

ROUND would probably work. :-)

Or, if you polygons were in some other coordinate system,
you will have to convert from that system to device coordinates.
CONVERT_COORD will be helpful.

Cheers,

David
-- 
David Fanning, Ph.D.
Fanning Software Consulting, Inc.
Coyote's Guide to IDL Programming: http://www.dfanning.com/
Se****e ma de ni thui. ("Perhaps thou speakest truth.")
 




 7 Posts in Topic:
pollyfillv, area of a blob, etc...
JP <guerschman@[EMAIL   2008-04-02 23:16:04 
Re: pollyfillv, area of a blob, etc...
JP <guerschman@[EMAIL   2008-04-02 23:38:44 
Re: pollyfillv, area of a blob, etc...
David Fanning <news@[E  2008-04-03 08:16:33 
Re: pollyfillv, area of a blob, etc...
JP <guerschman@[EMAIL   2008-04-03 16:08:07 
Re: pollyfillv, area of a blob, etc...
James Kuyper <jameskuy  2008-04-04 11:03:20 
Re: pollyfillv, area of a blob, etc...
David Fanning <news@[E  2008-04-04 06:31:24 
Re: pollyfillv, area of a blob, etc...
pgrigis@[EMAIL PROTECTED]  2008-04-04 07:18:51 

Post A Reply:
  Go here to Signup

AddThis Feed Button


About - Advertising - Contact - Frequently Asked Questions - Privacy Policy - Terms of Use - Signup

Contact
tan12V112 Wed Dec 3 21:29:40 CST 2008.