i want to alter dpi

 Respuesta aceptada

Sean de Wolski
Sean de Wolski el 25 de Feb. de 2013

0 votos

In print? Specify the rnumber
print(gcf,'-r300')

2 comentarios

nayana
nayana el 25 de Feb. de 2013
not in print i have to save it on my disk. the dpi property of the image should be adjusted to 300 and it should be saved
Sean de Wolski
Sean de Wolski el 25 de Feb. de 2013
Yes. You save a figure as an image with the print command:
figure;
surf(peaks);
print(gcf,'-r300','-dpng','test.png')
And for more info:
doc print

Iniciar sesión para comentar.

Más respuestas (1)

Walter Roberson
Walter Roberson el 25 de Feb. de 2013

0 votos

dpi is not an physical property of images, and cannot be set by imwrite() or print(). In some kinds of images, dpi can be set in auxillary information headers, such as EXIF headers. Unfortunately MATLAB does not have any routines that can write those headers. See http://www.mathworks.com/matlabcentral/newsreader/view_thread/298784

Preguntada:

el 25 de Feb. de 2013

Community Treasure Hunt

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

Start Hunting!

Translated by