so I created this image in matlab and saved it as an eps-image. And then in latex I compile and build with DVI-PS-PDF-chain, I also use package epstopdf (strange also that the pdf-images (converted from the eps-images) in the latex folder are plank :O, even though the images in the final PDF are okay, other than this).

And image appears like this: It seems to show the mesh also, which I dont want. In matlab when I display the figure, everything is okay.

Do you have any clue why this happens? :)

enter image description here

  • It seems a problem in your Matlab eps creation. Does the eps or pdf file you create by Matlab is fine ? Y-axis is the problem ? Commented Sep 6, 2016 at 16:39
  • I havent checked that yet, i'll take a look. no I just took screenshot and cropped it :D both axis show fine. But the image should contain only the color, not the mesh lines which are in white color now :O
    – JeaBoy
    Commented Sep 6, 2016 at 17:48
  • Dude, how are we supposed to see the white color lines ? ;-) I hope you got your answer. Commented Sep 6, 2016 at 18:55
  • haha cant you see the mesh with light white color :D well anyway I got the problem solved. The problem was in the matlab code :)
    – JeaBoy
    Commented Sep 6, 2016 at 19:32

2 Answers 2


It is a problem about your Matlab EPS saving. I would recommend you to take a look at Translating Matlab figures into TikZ in order to convert your figures in a tikz format, suitable for LaTex. Also you can check the Plotting without axes and background if you insist to stick to Matlab ploting tools.


This usually happens because the eps includes instructions to draw polygons to make up the image, but not their outlines. One way to fix this is as follows:

  • Open the eps file in your favourite text editor.
  • Look for a line that says something like /F { fill bind def } or perhaps /F fill load def (usually this will be near the top).

  • Change fill to gsave fill grestore stroke.

  • Save the file and open it in your eps viewer. The mesh should be gone.

Alternatively, use polygone to remove the mesh and reduce the file size, without reducing the image quality.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .