Crating Jpeg files in MATLAB

Status
Not open for further replies.

hunter694

Member level 2
Joined
Aug 11, 2004
Messages
48
Helped
5
Reputation
10
Reaction score
2
Trophy points
1,288
Location
Sweden
Activity points
299
Hi,

Could some one please elaborate if it is possible to 'not' have the figure window show up before a jpeg file creation (using print -djpeg command)?

If used in a loop, the plot command takes a long time in creating the window on every iteration on the screen, when all I really want is to create a jpeg file afterwards.

Thanks,
/Hunter

P.S. Here is what the code looks like:

plot(f, fft_data_ov, '.'); hold; plot(f, fft_y, 'r.'); grid on; ylim.......
print('-djpeg100', '-r175', filename);
close all; %the window is just closed without viewing after jpeg is created
 

Tried that before I posted here. imwrite with 'jpeg' option doesn't support anything 'cept uint data.

I need something that just stops the figure window from appearing on screen (even if it is creating it in the background) so it doesn't waste time painting graphics that I am not going to use.

Thanks,
/Hunter
 

Status
Not open for further replies.
Cookies are required to use this site. You must accept them to continue using the site. Learn more…