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

Home » Public Forums » archive » Re: Zoom-like procedure
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Switch to threaded view of this topic Create a new topic Submit Reply
Re: Zoom-like procedure [message #25931] Sat, 28 July 2001 15:55
Bob Fugate is currently offline  Bob Fugate
Messages: 18
Registered: March 2001
Junior Member
Craig,
You are right. However, it appears one must also add the keyword SAMPLE or
all but the last row of the enlarged pixels will contain a number of
gradient levels proportional to the dimensions of the array being expanded.
The first time I tried this I had the scale factors wrong -- not integer
multiples of the dimensions of the array and I didn't use the sample
keyword.
Thanks, again for your help. This solves my problem.

Bob


>
> Bob,
>
> Isn't this exactly what REBIN does? It replicates pixels. The value
> of this BLOWUP:
>
> blowup = rebin(img(0:15,0:15), 16*nscale, 16*nscale)
>
> is a new array with NSCALE times as many pixels in each direction as
> the original 16x16 subimage. Then of course you have to TV it onto
> the screen. :-)
>
> Craig
>
> --
> ------------------------------------------------------------ --------------
> Craig B. Markwardt, Ph.D. EMAIL: craigmnet@cow.physics.wisc.edu
> Astrophysics, IDL, Finance, Derivatives | Remove "net" for better response
> ------------------------------------------------------------ --------------
Re: Zoom-like procedure [message #25932 is a reply to message #25931] Sat, 28 July 2001 13:06 Go to previous message
Craig Markwardt is currently offline  Craig Markwardt
Messages: 1869
Registered: November 1996
Senior Member
Bob Fugate <rqfugate@mindspring.com> writes:

> I am displaying small parts (e.g. 16x16 pixels) of images and need to zoom
> regions up to a size large enough to see the relative brightness of the
> pixels. The ZOOM procedure does exactly what I want, but in an interactive
> mode. Does anyone know of a function or procedure or other means that would
> allow me to include this feature in my program to automatically zoom a
> preselected subregion of the image? REBIN, and CONGRID resample and that is
> not what I want, I just want the intensity in each original pixel to be
> reproduced everywhere in a synthesized, larger pixel, ideally whose size I
> can choose.

Bob,

Isn't this exactly what REBIN does? It replicates pixels. The value
of this BLOWUP:

blowup = rebin(img(0:15,0:15), 16*nscale, 16*nscale)

is a new array with NSCALE times as many pixels in each direction as
the original 16x16 subimage. Then of course you have to TV it onto
the screen. :-)

Craig

--
------------------------------------------------------------ --------------
Craig B. Markwardt, Ph.D. EMAIL: craigmnet@cow.physics.wisc.edu
Astrophysics, IDL, Finance, Derivatives | Remove "net" for better response
------------------------------------------------------------ --------------
  Switch to threaded view of this topic Create a new topic Submit Reply
Previous Topic: Re: plotting two sets of contours
Next Topic: Re: Color Problems in IDL for Linux (Gnome)

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

Current Time: Wed Oct 08 13:45:43 PDT 2025

Total time taken to generate the page: 0.00662 seconds