comp.lang.idl-pvwave archive
Messages from Usenet group comp.lang.idl-pvwave, compiled by Paulo Penteado

Home » Public Forums » archive » Re: Points in a rectangle with an angle
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Return to the default flat view Create a new topic Submit Reply
Re: Points in a rectangle with an angle [message #48228 is a reply to message #48226] Wed, 05 April 2006 09:43 Go to previous messageGo to previous message
K. Bowman is currently offline  K. Bowman
Messages: 330
Registered: May 2000
Senior Member
In article <1144254765.987764.323760@i39g2000cwa.googlegroups.com>,
JJMeyers2@gmail.com wrote:

> Hello,
>
> I have a problem in IDL that I was wondering if anyone has any idea how
> it can be done.
> I have a set of coordinates and I am trying to figure out how many of
> the coordinates are inside a rectangle. I know the coordinates of the 4
> edges of the rectangle but the problem is that the rectangle is at an
> angle in the x,y axis ( I know the slope). I can not just say
> coords=where((x LE xmax) AND (x GT xmin) AND (y LE ymin) AND (y GT
> ymax))
> because that will give me coordinates of a rectangle without an angle
> (parallel to the y axis).
> Is there any function in IDL that might be doing that?
>
> Thank you,
> JJM.

If you know the angle of the rectangle, rotate your coordinate system, then use
the simple comparison that you give above.

Ken Bowman
[Message index]
 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: Re: Shared Memory in Windows
Next Topic: Re: iTools/interactive Analysis >

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ] [ PDF ]

Current Time: Wed Oct 08 16:09:08 PDT 2025

Total time taken to generate the page: 0.00411 seconds