Borrar filtros
Borrar filtros

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

2 visualizaciones (últimos 30 días)
Haider Ali
Haider Ali el 27 de Oct. de 2018
Editada: Haider Ali el 27 de Oct. de 2018
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

Respuestas (0)

Categorías

Más información sobre Startup and Shutdown en Help Center y File Exchange.

Productos


Versión

R2018a

Community Treasure Hunt

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

Start Hunting!

Translated by