Question

I have two images with same dimensions but with different sizes. I want the bigger image's size to be changed to match the smaller image's size. For example, I have an image A with size 300x400x3 and image B with size 600x800x3. I want to change the size of image B to 300x400x3. Thanks for any help.

Was it helpful?

Solution

Just one-liner as suggested by Andrey -

B = imresize( B,[size(A,1) size(A,2)]);

For accessing more options with resizing, use this resource.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top