[l2h] image generation problem

Ross Moore ross at ics.mq.edu.au
Sun Apr 24 02:10:12 CEST 2005


Hello Bob,

On 24/04/2005, at 8:53 AM, Bob van der Poel wrote:

>
>
> Thanks. I have tried this now.
>
>> Try running latex2html with a -debug flag.  That should keep all the
>> temporary files around, as well as produce some useful messages in the
>
> YEs, lots of extra files :)
>
>> log.  Another place to look is the images.log file (which may explain 
>> why
>
> Nothing I can find there to give me a clue.

First look at the screen output from LaTeX2HTML just before
the image generation starts.
It should say how many images it expects to make.

Compare this to the number of pages produced by LaTeX
on the  images.tex  file.
See this at the end of  images.log  which is not available
(since you used -debug ).

If those numbers do not agree -- probably more pages than images --
then you will be getting one (or more) images that have no content.
Ultimately these will be cropped away completely, leaving an
empty image file, hence no  .png .
That's one possible explanation for the message that you get.


Now, why are there extra pages of .dvi output ?

Either there are (La)TeX errors encountered in  images.tex
  --- examine  images.log  carefully to get evidence ---
or maybe some of the images are too small for the $PAPERSIZE
(defaults to 'a6' -- quite small!), so a blank page is produced
before the real page with the image.

In  .latex2html-init  you can change this:
   $PAPERSIZE = 'a3';
That's much bigger than you need, and will eat up memory
  --- but these days you have plenty of that, right ?

Does this solve all your problems ?


If the number of pages agree, but you get *no* images
at all ...

  ... then there is an installation problem.

Carefully examine the (extensive, due to -debug) log-output
for the first sign of something going wrong in the processing
of an image.
  e.g.  the size is too small:  width = 0 or height = 0
or too many lines are cropped away (100s or 1000s of lines)
leaving nothing behind.

(You seem to have done this already, so skip these next
    few comments!)

Be aware that  pstoimg  constructs a long pipe of commands
(when using Unix or Linux), and one piece of the pipe
may have failed.
You should see a line in the log that gives the full
piped command, before getting messages from each piece.


>
>> the images weren't produced).  One caveat: the \begin{latexonly} ..
>> \end{latexonly} (or the equivalent %-forms) aren't used in image
>> production -- you need to replicate the necessary code in a
>> \begin{imagesonly} .. \end{imagesonly} section, or extract it to a 
>> .sty

Any errors due to failure to have done this should show up
as undefined commands, within the  images.log  file.


>> file.
>> HTH,
>> 	Igor
>
> I was hoping too :) But, I'm still having the same problems. I did try 
> to use different settings for -tmp (which is normally not set in my 
> makefile), but it made no difference. I think this error:
> Error while converting image
>
> Error: Cannot read 'img2.png': No such file or directory
> Converting image #14
> pstoimg: Warning: Cannot use /home/bob/tmp/l2h6263 as temporary 
> directory.
> pstoimg: Error: Cannot find file "/home/bob/tmp/l2h6263/_image014.ps": 
> No such file or directory

This looks like a lack of write-permission.
Or maybe there is a delay in creating the directory ?
  --- due to some kind of caching of OS commands ?

>
> has more to do with the img2.png not being found at all, not the 
> directory problem? But, which isn't img2.png (and 30 or 40 others) 
> being created. I'm sure I'm missing a program, but have no idea what.

Did  dvips  run on images.dvi  ?
That's what creates the  .ps  files.

No wait-on!  Check images.log again.
Is it creating  .dvi  output,  or  .pdf  output ?

If it's creating  .pdf  then there needs to be a line
that sets   \pdfoutput = 0 .
Alternatively, there could be a command-line switch
added to the  $LATEX  variable to force this mode.

That's an easy fix to add at installation time.


> -- 
> Bob van der Poel ** Wynndel, British Columbia, CANADA **
> EMAIL: bvdp at uniserve.com
> WWW:   http://mypage.uniserve.com/~bvdp


Hope this helps,

	Ross Moore


>
>
> _______________________________________________
> latex2html mailing list
> latex2html at tug.org
> http://tug.org/mailman/listinfo/latex2html
>
------------------------------------------------------------------------
Ross Moore                                         ross at maths.mq.edu.au
Mathematics Department                             office: E7A-419
Macquarie University                               tel: +61 +2 9850 8955
Sydney, Australia                                  fax: +61 +2 9850 8114
------------------------------------------------------------------------



More information about the latex2html mailing list