Resize N-D arrays and images

Y = RESIZE(X,newsize) resizes input array X using a discrete cosine transform.
3,1K descargas
Actualizado 12 oct 2014

Ver licencia

Y = RESIZE(X,NEWSIZE) resizes input array X using a DCT (discrete cosine transform) method. X can be any array of any size. Output Y is of size NEWSIZE.
Input and output formats: Y has the same class as X.
As an example, if you want to multiply the size of an RGB image by a factor N, use the following syntax:
newsize = size(I).*[N N 1];
J = resize(I,newsize);

------
% Upsample and stretch an RGB image
I = imread('onion.png');
sizeJ = size(I).*[2 2 1];
J = resize(I,sizeJ);
sizeK = size(I).*[1/2 2 1];
K = resize(I,sizeK);
figure,imshow(I),figure,imshow(J),figure,imshow(K)

------
Enter "help resize" to obtain other examples.

Citar como

Damien Garcia (2024). Resize N-D arrays and images (https://www.mathworks.com/matlabcentral/fileexchange/26385-resize-n-d-arrays-and-images), MATLAB Central File Exchange. Recuperado .

Compatibilidad con la versión de MATLAB
Se creó con R2010b
Compatible con cualquier versión
Compatibilidad con las plataformas
Windows macOS Linux

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!
Versión Publicado Notas de la versión
1.3.0.0

.

1.2.0.0

The functions IDCTN and DCTN are now in RESIZE

1.1.0.0

DCTN and IDCTN are now included, as requested

1.0.0.0