How to upscale the image and make it higher resolution?

30 visualizaciones (últimos 30 días)
James Lee
James Lee el 30 de Nov. de 2014
Editada: Image Analyst el 30 de Nov. de 2014
I want to make a image to higher resolution in gui?

Respuesta aceptada

David Young
David Young el 30 de Nov. de 2014
You can't truly increase the resolution of an image, because in making the sampled digital image information at higher resolution is lost.
You can simulate a higher-resolution image and increase the number of pixels by interpolation. Assuming you have the Image Processing Toolbox, use imresize, with a scale argument greater than 1.
  2 comentarios
James Lee
James Lee el 30 de Nov. de 2014
Editada: Image Analyst el 30 de Nov. de 2014
Thanks, it helps me a lot. Can I ask you another question?
a1=imread('a.jpg');
a2=imread('a1.jpg');
redChannel1 = a1(:,:,1);
greenChannel1 = a1(:,:,2);
blueChannel1 = a1(:,:,3);
redChannel2 = b1(:,:,1);
greenChannel2 = b1(:,:,2);
blueChannel2 = b1(:,:,3);
diff_red= single(redChannel1) - single (redChannel2);
I want to find the differences of two image of red channel but it came out an error: error using minus operator matrix dimensions must agree. How to fix it?
David Young
David Young el 30 de Nov. de 2014
I'm not sure where b1 comes from. Should it be a2, the result of the second imread? One possibility is that you've mixed up the variable names and that's why the arrays have different sizes.
Another possibility is that the images stored in a.jpg and a1.jpg have different sizes. In this case, how to fix the problem depends on why they have different sizes - it may be that the correct thing to do is to crop or resize one of the images (see imcrop and imresize) to make them the same size, but the correct approach depends on exactly why they are different sizes.

Iniciar sesión para comentar.

Más respuestas (0)

Etiquetas

Community Treasure Hunt

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

Start Hunting!

Translated by