About Site Map Submit Contact Us Log in | Create an account
Create an account Log In
Average Rating
User Rating:
Visitors Rating:
My rating:

Write review
See full specifications

scripts default icon2D interpolation (Scripts) Publisher's description

ZI = mirt2D_mexinterp(Z,XI,YI) interpolates 2D image Z at the points with coordinates XI,YI.

ZI = mirt2D_mexinterp(Z,XI,YI) interpolates 2D image Z at the points with coordinates XI,YI. Z is assumed to be defined at regular spaced points 1:N, 1:M, where [M,N]=size(Z).
If XI,YI values are outside the image boundaries, put NaNs in ZI.

The function is similar to Matlab's native
ZI = INTERP2(Z,XI,YI,'linear',NaN),
but is much master. If Z is vector valued 2D image (3D array), then iteratively interpolates Z(:,:,1), Z(:,:,2),Z(:,:,3),.. etc. This works faster than to interpolate each image independently, such as
ZI(:,:,1) = INTERP2(Z(:,:,1),XI,YI);
ZI(:,:,2) = INTERP2(Z(:,:,2),XI,YI);
ZI(:,:,3) = INTERP2(Z(:,:,3),XI,YI);

The extra speed gain is from the precomputation of coefficients for interpolation, which are the same for all images. Interpolation of a set of images is useful, e.g. for image registration, when one has to interpolate image and its gradients or for vector valued images such as RGB.

Limitations: only works for images on a regular grid, and only with linear interpolation method.

Don't forget to compile first:
mex mirt2D_mexinterp.cpp

Enjoy! See more at my homepage:

System Requirements:

MATLAB 7.4 (R2007a)
Program Release Status: Major Update
Program Install Support: Install and Uninstall

2D interpolation (Scripts) Tags:

Click on a tag to find related softwares

Is 2D interpolation (Scripts) your software?

Manage your software

Most Popular

scripts default icon ASK, OOK, FSK, BPSK, QPSK, 8PSK modulation 1.1
ASK, OOK, FSK, BPSK, QPSK, 8PSK modulation contain several functions for digital modulation simulation
scripts default icon Simulink Communication Labs 1.1
Simulink Communication Labs allows you to learn communication systems in greater depth.
scripts default icon M-QAM modulation and demodulation 1.1
M-QAM modulation and demodulation is the QAM modulation and demodulation tech.
scripts default icon LZW Compression/Decompression 1.1
LZW Compression/Decompression - Updated LZW compressor and decompressor with reasonable performance
scripts default icon InSPIRE utility to plot a 2D displacement field (Scripts) 1.0
This program plots the deformation field (displace vectors) contained in vector.txt.