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

Home » Public Forums » archive » Re: circles
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: circles [message #9512 is a reply to message #9500] Thu, 10 July 1997 00:00 Go to previous messageGo to previous message
pit is currently offline  pit
Messages: 92
Registered: January 1996
Member
In article <33C3DE74.356F@mad.scientist.com>,
lady of the elves <galadriel@mad.scientist.com> writes:
> [incidentally, I'm new to this language :)]
>
> I'm trying to create a two-dimensional array, such that tvscl of the
> array will show a filled circle. So far, my best idea has not

Hm, maybe the easiest way to create an array of dimension
(X,Y) with a circle of radius R at location x0,y0) would be:

img = (shift(dist(X,Y),x0,y0)) LT R

DIST: creates an array (X,Y) (in FFT-segmented form, but thats not
important for the moment) where each element contains the distance
from (0,0)
SHIFT -> Shift (0,0) to desired center of circle

array LT value will result in an byte array that is 1 where the value
(=distance) is lower than the radius, and 0 everywhere else.

TVSCLing img will show the circle

Peter

--
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ~~~~~~~~~~~~~~
Peter "Pit" Suetterlin http://www.uni-sw.gwdg.de/~pit
Universitaets-Sternwarte Goettingen
Tel.: +49 551 39-5048 pit@uni-sw.gwdg.de
-- * -- * ...-- * -- * ...-- * -- * ...-- * -- * ...-- * -- * ...-- * --
Come and see the stars! http://www.kis.uni-freiburg.de/~ps/SFB
Sternfreunde Breisgau e.V. Tel.: +49 7641 3492
____________________________________________________________ ______________
[Message index]
 
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: .Free Cash Grants
Next Topic: Are IDL functions callable from C++ programs under Win-NT

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

Current Time: Sat Oct 11 19:09:12 PDT 2025

Total time taken to generate the page: 1.67876 seconds