[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: subpixel image movement by bicubic interpolation?,
- Subject: Re: subpixel image movement by bicubic interpolation?,
- From: Wayne Landsman <landsman(at)mpb.gsfc.nasa.gov>
- Date: Thu, 04 Jun 1998 15:37:13 -0400
- Newsgroups: comp.lang.idl-pvwave
- Organization: NASA Goddard Space Flight Center -- Greenbelt, Maryland USA
- References: <35757C9B.5E9AD577@as.arizona.edu>
- Xref: news.doit.wisc.edu comp.lang.idl-pvwave:11170
Dyer Lytle wrote:
> So I thought I'd ask if anyone has a sub-pixel image movement
> routine based on bicubic interpolation that they would be willing
> to share.
>
The INTERPOLATE keyword has a /CUBIC keyword. I would simply replace
the
line in bilinear.pro that reads
return, interpolate(p, ix, jy)
with
return, interpolate(p, ix, jy, CUBIC = -0.5)
I definitely prefer using a value of -0.5 for CUBIC, for reasons
discussed in
this group about a year ago. (Note that the option to set CUBIC = -0.5
has
only been available since V5.0.)
The IDL Astronomy Library has the procedure RINTER which is equivalent
to
INTERPOLATE with CUBIC = -0.5. Although slower, RINTER() has two
possible
advantages: (1) one can optionally obtain the X and Y derivatives at the
reference points, which is useful if you are trying to estimate errors
introduced by the interpolation, (2) if repeated interpolation is to be
applied
the same array, then some values can be pre-computed and stored in
Common.
RINTER is available at http://idlastro.gsfc.nasa.gov/ftp/pro/image
Wayne Landsman landsman@mpb.gsfc.nasa.gov