Print option does not save the figure correctly

Dear all, I use a simple code line
print -depsc -tiff -r300 picture
to print the current figure as picture.eps. But the result is not a smooth picure, rather a sparse line picture wiht a lot of white space in between; thus it is useless (the same with jpeg). Where might be the mistake? Thanks for your advice!

 Réponse acceptée

Shashank Prasanna
Shashank Prasanna le 7 Juil 2013

1 vote

What is the version of MATLAB you are using?
Can you post the image? or give some reproduction code?

6 commentaires

Peter
Peter le 7 Juil 2013

Matlab 7.6.

Ho can I post an image?

If you post it online, you can share the link here so we can see.
Also check if this bug report is related to the issue you are facing:
You may need to log into your mathworks account to check the bugreport.
Peter
Peter le 7 Juil 2013
Modifié(e) : Peter le 7 Juil 2013
Here is a link to the picture;
Actually, it is a surf plot
surf(tempT,tempF(tempFstart:tempFstop),(tempxP), 'FaceColor','interp','EdgeColor','none'); % pcolor als test
view(0,90);
axis tight;
set(gca, 'GridLineStyle','none','box','off');
set(gca,'ylim',[5 50], 'yticklabel',[]);
and it is displayed correctly as figure. But when I print it, the blue background is gone and instead of a steady picture I get the lined appearence (the same when I try to save it from the figure menu).
Shashank Prasanna
Shashank Prasanna le 8 Juil 2013
Modifié(e) : Shashank Prasanna le 8 Juil 2013
can you check the renderer you are using?
>> get(gcf,'Renderer')
Change it to painters or zbuffers if it is opengl
>> set(gcf,'Renderer','painters')
Try saving now, does that help?
Peter
Peter le 8 Juil 2013
Thanks a lot - 'painters' works well... (at least for the jpeg or tiff version)
Ali Kandil
Ali Kandil le 13 Nov 2019
Great
It worked for me
Thanks alot

Connectez-vous pour commenter.

Plus de réponses (0)

Catégories

En savoir plus sur Environment and Settings dans Centre d'aide et File Exchange

Community Treasure Hunt

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

Start Hunting!

Translated by