フィルターのクリア

print('-RGBImage', '-r0') for invisible figure

2 ビュー (過去 30 日間)
Haider Ali
Haider Ali 2018 年 10 月 27 日
編集済み: Haider Ali 2018 年 10 月 27 日
Hi,
I need to get the cdata of a .fig file using print('-RGBImage', '-r0') which is opened using openfig(_,'invisible') command. The problem is that the figure is not opened maximized and thus the print('-RGBImage', '-r0') command does not output image at screen resolution but at a lower one. But when I use openfig(_) with 'visible' option and then maximize the 'WindowState' of that figure, then print('-RGBImage', '-r0') outputs the data at my desired screens resolution.
The code for these two cases is given below:
First case: 'invisible'
f = openfig('test', 'visible');
f.WindowState = 'maximized';
im1 = print('-RGBImage', '-r0');
The im1 dimensions are 420x560x3 (not desired)
Second case: 'visible'
f = openfig('test', 'visible'); f.WindowState = 'maximized'; im2 = print('-RGBImage', '-r0');
The im2 dimensions are 783x1600x3 (desired)
My question is: how can I get the full screen resolution image while opening the figure using 'invisible' option?
Regards

回答 (0 件)

カテゴリ

Help Center および File ExchangeStartup and Shutdown についてさらに検索

製品


リリース

R2018a

Community Treasure Hunt

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

Start Hunting!

Translated by