フィルターのクリア

How to save a figure with inside an image and a plot ?

3 ビュー (過去 30 日間)
Axel L
Axel L 2013 年 9 月 3 日
Hello,
I would like to read an image and to plot anything inside. Then save this figure with a good resolution. I used this code :
figure,
imshow(image);
hold on;
plot(...);
hold off;
F = getframe;
imwrite(F.cdata,directory);
But the image out dont' have the same resolution that image in. Could you help me please ?

採用された回答

Image Analyst
Image Analyst 2013 年 9 月 3 日
Is your image bigger than your screen? Then it won't do what you want.
  1 件のコメント
Axel L
Axel L 2013 年 9 月 3 日
Yes my image is bigger than my screen.

サインインしてコメントする。

その他の回答 (1 件)

Youssef  Khmou
Youssef Khmou 2013 年 9 月 3 日
編集済み: Youssef Khmou 2013 年 9 月 3 日
Axel,
By using the format TIFF, you can control the resolution horizontally and vertically , that is also available for other extensions, like JPEG you have the parameter Quality , or PNG that contains two scalars XResolution & YResolution , here is an example :
I=imshow(imread('circuit.tif'));
hold on,
plot(100*randn(100,1))
hold off
F=getframe;
imwrite(F.cdata,'C:\test.tiff','resolution',[100 100])

カテゴリ

Help Center および File ExchangeGraphics Object Properties についてさらに検索

Community Treasure Hunt

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

Start Hunting!

Translated by