フィルターのクリア

how o save a part of figure with gui to image

3 ビュー (過去 30 日間)
Itzik Ben Shabat
Itzik Ben Shabat 2013 年 11 月 26 日
コメント済み: Image Analyst 2013 年 11 月 26 日
hello all, i have read every post and answer on the subject but nothing solved my problem. I have a figure with a gui. it also has an axes which plots objects in 3d. i wish to save only the axes area without the rest. i tried print, saveas,getframe and the matlab file exchange export_fig but nothing does it.
the only thing that worked was getting the image from export_fig and taking only a part of it.
so does anyone know of a better way to crop using export_fig? or a general better way to do this task ? thanks

採用された回答

Itzik Ben Shabat
Itzik Ben Shabat 2013 年 11 月 26 日
So I found the answer myself. it seems that the export_fig from the file exchange can do this if you give it an axes handle and have it crop.
so the solution looks like this
export_fig(axes handle,'-transparent',filename);
just thought someone might find this usefull in the future.
  1 件のコメント
Image Analyst
Image Analyst 2013 年 11 月 26 日
I was out so I didn't see this in time. But yes, export_fig is the always the #1 most downloaded file, and for good reason. It's also in the FAQ: http://matlab.wikia.com/wiki/FAQ#How_do_I_save_my_figure.2C_axes.2C_or_image.3F_I.27m_having_trouble_with_the_built_in_MATLAB_functions.

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

その他の回答 (0 件)

カテゴリ

Help Center および File ExchangeIntroduction to Installation and Licensing についてさらに検索

製品

Community Treasure Hunt

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

Start Hunting!

Translated by