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

Home » Public Forums » archive » Pixel positions passing trough a curve
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: Pixel positions passing trough a curve [message #93738 is a reply to message #93736] Tue, 11 October 2016 07:55 Go to previous messageGo to previous message
Helder Marchetto is currently offline  Helder Marchetto
Messages: 520
Registered: November 2011
Senior Member
On Tuesday, October 11, 2016 at 4:30:40 PM UTC+2, miguelfigue...@gmail.com wrote:
> Thank you for your answer but maybe it is not completely what I want (except if I use very simple path)
>
> In your program, I have to give the coordinates of the beginning and end of the segments but if my path is complicated (ellipsis or multi-segment path) it seems to be better to make directly the list on ds9.
>
> In other words, is it possible to draw a curved line and obtain the pixels passing through this curve ?
>
> Miguel

If I understand correctly, your problem can be subdivided in three parts:
(1) draw a path on an image
(2) extract from the drawn path cardinal points defining subsegments
(3) calculate the profile along the segments

I think that the code mentioned solves point (3). However, you need to solve the first two, so:

(1) Try xroi (http://www.harrisgeospatial.com/docs/XROI.html). You may eventually modify or rewrite the code to satisfy your needs.
(2) this is a bit tricky because you want enough points, but not too many. I would completely skip this in a first attempt and then check if the result is what you expect. If not, you might have to take care to reduce the number of curve points so that the arc is always 1 pixel.

There is another thing to mention. If you define masks or areas, you may get the boundary of the area using David's Find_Boundary function (http://www.idlcoyote.com/ip_tips/boundary.html).

I hope this helps.

Cheers,
Helder
[Message index]
 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: IDL intro
Next Topic: ncdf_varput for NetCDF coordinate axes

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

Current Time: Wed Oct 08 20:08:42 PDT 2025

Total time taken to generate the page: 0.38590 seconds