I want to choose an image formate for including images in both html and latex.
I found that jpeg and png formates are not always working well in latex. Is eps format the best for latex. It seems eps is not supported in html?
What other format is good too?
Thanks and regards!
Standard LaTeX "loves" EPS, indeed, but there is a reason — it is a vector format. Properly creating your graphics in EPS will ensure that the quality of your printed output is limited only by the quality of your printer, not by the resolution of your image file (as will be the case with rasterized formats like JPEG and PNG).
So, if you include e.g. line drawings, bar charts, etc, you pretty much have to do it in EPS (or PDF), and then convert to PNG for the web. If you graphics is inherently rasterized (e.g. you want to include a photo), you can settle for a high-quality JPEG and then use jpeg2ps to create EPS file for LaTeX (or inlude them directly in pdfLaTeX).
To recap: it's your image, not your program, that determines the proper image format.
P.S. Tools like TeX4ht will usually handle image conversion if needed.