Hopefully my question below is appropriate to this Forum. If it is not, my apologies.
What I am trying to do is to convert a jpeg file to Postscript using the PrintGIFtoStream.java file available at http://java.sun.com/j2se/1.4.1/docs/guide/jps/spec/JPSTOC.fm.html which is an online version of the Java Print Service API User Guide. I changed the DocFlavor.INPUT_STREAM.GIF specification to DocFlavor.INPUT_STREAM.JPEG and changed "java2dlogo.gif" to "myjpegfile.jpg". Compiling and running this code I got a "newfile.ps" as the output. This was just great since I wasn't aware that getting a postscript dump was so easy in Java 1.4. However, when I compared the resulting postscript file size from Java to that produced by the public domain utility jpeg2ps, I was a little intrigued to note that the Java output was much larger. Any particular reason why this should be so ? As a testcase I used the nesrin.jpg file available as part of the jpeg2ps distribution and compared the resulting postscript file sizes. The stats are as below: jpeg2ps 49 kb Java 1.4 Mb (uncompressed) & 931 Kb (gzipped) Is this expected or am I missing any fine tuning parameters ? Any help will be appreciated. Regards Vaidya =========================================================================== To unsubscribe, send email to [EMAIL PROTECTED] and include in the body of the message "signoff JAVA2D-INTEREST". For general help, send email to [EMAIL PROTECTED] and include in the body of the message "help".
