Package: latex2html
Version: 2002-2-1-10
Followup-For: Bug #132451

with respect to the pstoimg Perl script breaking when the -depth 24 or 
-color 24 options were used:

  (don't know where the other stuff in this bug report came from)

$reduce_color is only getting set if the depth was "1" or "8".
So the $cmd line was adding an empty pipe step in the case of 24bit.


Solutions:

a) in code that sets up "ppmquant 8" or "ppmquant 256" add a test for 24-bitness
and set to "ppmquant 16777216"

or

b) if 24-bit just skip the ppmquant step. Patch for this solution follows.

--- /usr/bin/pstoimg    2005-03-21 01:27:23.000000000 +1200
+++ pstoimg     2005-07-12 21:22:41.000000000 +1200
@@ -1271,10 +1271,12 @@
   }
   # run ppmquant only on color/gray images
   if(!$type || $type =~ /(ppm|pgm)/i) {
-    if($cmd) {
-      $cmd .= "| $reduce_color "
-    } else {
-      $cmd = "$reduce_color < $in ";
+    if($opt{depth} != 24) {
+      if($cmd) {
+        $cmd .= "| $reduce_color "
+      } else {
+        $cmd = "$reduce_color < $in ";
+      }
     }
   }


And this bug has been around since the Potato days!

cheers,
Hamish


-- System Information:
Debian Release: 3.1
  APT prefers testing
  APT policy: (990, 'testing')
Architecture: i386 (i686)
Kernel: Linux 2.4.27-2-686
Locale: LANG=C, LC_CTYPE=C (charmap=ANSI_X3.4-1968)

Versions of packages latex2html depends on:
ii  gs                            8.01-5     Transitional package
ii  gs-gpl [gs]                   8.01-5     The GPL Ghostscript PostScript int
ii  netpbm                        2:10.0-8   Graphics conversion tools
ii  perl                          5.8.4-8    Larry Wall's Practical Extraction 
ii  tetex-bin                     2.0.2-30   The teTeX binary files
ii  tetex-extra                   2.0.2c-8   Additional library files of teTeX

-- no debconf information


-- 
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]

Reply via email to