新浪博客

[转]MATLAB保存生成高质量的清晰图片

2015-07-18 12:03阅读:
[转载]MATLAB保存生成高质量的清晰图片
http://blog.sciencenet.cn/blog-228329-574762.html
MATLAB保存生成高质量的清晰图片
saveas保存jpg格式的图像线条变粗、变模糊,整幅图片就像有一层很薄的水印盖在上面。
解决方案:
(1)其实matlab的出图都是矢量图,你就直接在‘edit’里面选择copy,然后就paste到word里面,伸缩自如,保证清晰
(2)可以试试print
如要把图保存成jpeg的格式的话,可以这样
print -djpeg -r85 jpegtest
其中,
-djpeg是格式 d表示device,jpeg是格式,
-r85 表示像素 85dpi r 表示resolution ,也就是分辨率的第一个字母
jpegtest 是文件名
也可以
print('-djpeg','-r300',Path)

print(gcf,'-djpeg','-r300',Path)
print( ... )
Same as above but this calls PRINT as a MATLAB function instead of
a MATLAB command. The difference is only in the parenthesized argument
list. It allows the passing of
variables for any of the input
arguments and is especially useful for passing the handles
of figures and/or models to print and filenames.
注:dpi的含义
Dots Per Inch的缩写。每英寸所打印的点数或线数,用来表示打印机打印分辨率。一般来说,该值越大,表明打印机的打印精度越高。
   dpi是指单位面积内像素的多少,也就是扫描精度。dpi越小,扫描的清晰度越低,由于受网络传输速度的影响,web上使用的图片都是72dpi,但是 冲洗照片不能使用这个参数,必须是300dpi或者更高350dpi。例如要冲洗4*6英寸的照片,扫描精度必须是300,那么文件尺寸应该是(4*300)*(6*300)=1200像素*1800像素。
http://blog.sciencenet.cn/blog-228329-574762.html

我的更多文章

下载客户端阅读体验更佳

APP专享