You are not logged in.
I have a PostScript printer (Xerox Phaser 6130) that I can't get to print pdfs generated with LuaTeX in acceptable time and quality. This also happened with some published papers.
I use the opentype version of either Latin Modern or Linux Libertine for the documents. Printing from Zathura or evince always results in the printer taking about one minute to process (per page) and all symbols are printed in an wavey fashion.
For some reason I tested importing one page in inkscape and expoerting it in PostsScript, which results in all text being turned into paths and the exact same problem when printing.
The same pdf printed using Windows 10 (with the PostScript driver it pulls automaticly) and Adobe Reader looks perfect. Printing from LibreOffice is fine too.
Any ideas?
Offline
Can you first enable logging on the cups server and print a file to see what conversions are done (they should appears in the cups log file as 'started filter ...' or something like that. The filters that cups use can be tuned in the '*.convs' files. Possibly, you could try these filters by hand. For example:
/usr/lib/cups/filter/pdftops x x x x x pdffile.pdf > psfile.psAlso try to convert the pdf file to ps yourself (use pdf2ps from ghostscript or pdftops from poppler) and print the ps directly bypassing any filter (lpr -o raw file.ps).
Last edited by olive (2017-08-24 11:26:42)
Offline
I enabled logging
[...] Started filter /usr/lib/cups/filter/pdftopdf (PID 7146)
[...] Started filter /usr/lib/cups/filter/pdftops (PID 7147)
[...] Started backend /usr/lib/cups/backend/usb (PID 7148)That looks normal. Not normal is the output generated by running the ps filter
/usr/lib/cups/filter/pdftops x x x x x pdffile.pdf > psfile.psA single page 11kB pdf becomes a 790kB PostScript file. Printing it bypassing any filter results in bad printing, but pdftops with no options generates a 90kB ps file that prints fine when bypassing any filter.
I am currently failing at finding out how to configure the filter and a corresponding *convs file does not seem to be present.
Offline
The cups filter /usr/lib/cups/filter/pdftops is a wrapper around a usual command that convert pdf to ps. The last command can be configured at compile time. You can ask the cups filter to use poppler pdftops by recompiling the cups-filters package with the --enable-poppler option.
Note that complex pdf will always lead to complex ps with which the printer can struggle (printers have a less powerful processor than a computer). It is often more desirable to send a low level format to the printer instead and let the computer do the heavy task. Most PS printer accept a lower level format, often pcl. If you can configure your printer to use that instead, it could be more desirable.
Last edited by olive (2017-08-24 16:59:55)
Offline
I might try recompiling the filter later.
The printer does only support PS to my knowledge - which is what I bought it for, other printers tended to render text slightly wrong. The pocessing time of the printer for the ps generated with poppler seems typically to be less than 2sec per page - at least for pdfs generated with LaTeX.
I also found a workaurond for printing with pdftops for double sided printing using psselect so select even/odd pages.
pdftops inputfile.pdf - | psselect [options] | lpr -l Works, but I have to end printing manually.
Edit: I just realized that the cups filter creates a raster image that is stored in the ps file, the ps generated by pdftops is not. Printer does not like the first one.
Last edited by Flo169 (2017-08-25 13:44:57)
Offline
I might try recompiling the filter later.
That's actually quite easy. Just get the source package and edit the PKGBUILD (very easy to do) and issue a makepkg command. You can use ABS or simply yaourt (with the -G option) from the AUR.
The printer does only support PS to my knowledge - which is what I bought it for, other printers tended to render text slightly wrong.
According to: http://www.support.xerox.com/support/ph … stem=winxp the printer support PCL6 and it is the manufacturer recommended driver for Windows (XP but it is probably not relevant). Probably it is what is used under Windows and explain why you don't have any issue there. Don't know if it still works in the latest Windows , but you can try to print to a file from within Windows and examine the file you get. It's probably not PS.
The processing time of the printer for the ps generated with poppler seems typically to be less than 2sec per page - at least for pdfs generated with LaTeX.
LaTeX generates good compact files. These files indeed does not pose problem for a correctly configured printer. But try to print a complicated files and problems will reappear.
I also found a workaurond for printing with pdftops for double sided printing using psselect so select even/odd pages.
pdftops inputfile.pdf - | psselect [options] | lpr -lWorks, but I have to end printing manually.
Edit: I just realized that the cups filter creates a raster image that is stored in the ps file, the ps generated by pdftops is not. Printer does not like the first one.
You know, recompiling the cups-filters packages may be quicker than your workaround. One of the great thing with ArchLinux is that you can recompile a package with only basic bash knowledge. You don't need to learn huge manual to do it; you barely need to read any manual at all.
Last edited by olive (2017-08-25 14:02:01)
Offline
According to: http://www.support.xerox.com/support/ph … stem=winxp the printer support PCL6 and it is the manufacturer recommended driver for Windows (XP but it is probably not relevant). Probably it is what is used under Windows and explain why you don't have any issue there. Don't know if it still works in the latest Windows , but you can try to print to a file from within Windows and examine the file you get. It's probably not PS.
Windows seems to have loaded the PS driver. xerox de mentions PCL5 and 6 only as emulated, which is why avoided both.
Adobe PostScript® 3™, PCL® 5c-Emulation, PCL® 6-Emulation
But try to print a complicated files and problems will reappear.
Luckily this printer is only used for scientific papers, my own reports and the occasional spreadsheet or train ticket so i don't care. Everything complicated or long gets printed in university - there is a free color printer (that also struggels with powerpoint presentations) :-)
I have now recomiled the cups-filter packages and poppler. The README mentions
The Poppler-based filters need a C++ compiler which supports C++11 and Poppler being built with the "./configure" options "--enable-splash --disable-fixedpoint --disable-single-precision" (if in the actually used Poppler version such options are available). This is the case for most modern Linux distributions.
and setting the ps to pdf renderer to poppler via
lpadmin -p printer -o pdftops-renderer-default=pdftopsText ouptut with recompiled poppler and filters is now fast and worse.
Okay, lets try running the filter pdf to pdf without options and pdftops with the only one option: use popplers pdftops.
'/usr/lib/cups/filter/pdftopdf' x x x 1 x '/home/uni/master.pdf' > ~/neu3.pdf
'/usr/lib/cups/filter/pdftops' x x x 1 pdftops-renderer=pdftops '/home/uni/neu3.pdf' > ~/neu3.ps
lpr -l '/home/uni/neu3.ps'Lightnings fast and perfect printing of the ps generated this way.
This is from the log and is the filter beeing called with all the options
D [25/Aug/2017:18:16:30 +0200] [Job 389] Running command line for pstops: pstops 389 uni /home/uni/master.pdf 1 \'noXRTonerSaver XRRGBInputProfile=SRGB XRSubPaperSelection=Policy0 XRGrayBalance XREngineScreen=Auto PageSize=A4 InputSlot=1stTray XRBrightness=Normal XROutputMode=HighQuality XRHalftoneMode XRRGBImageType=Standard MediaType=Stationary XRCustomPageSizeCorrection XRColorTemperature=TemperatureD50 XRColorMode=Color XRRGBCorrection=None XRRGBBCorrection=Off noXRSaveBlankSheet Smoothing job-uuid=urn:uuid:96c59888-a22d-34f2-73f1-928d26963b81 pdftops-renderer=pdftops job-originating-host-name=localhost date-time-at-creation= date-time-at-processing= time-at-creation=1503677790 time-at-processing=1503677790\'Edit: Followed by running pstopdf
Running command line for pdftops: pdftops -level3 -origpagesizes -nocenter -r 600 /var/spool/cups/tmp/0078259a57906 - This looks ok to me.
and than runs a final pstops.
What is causing the output to be bad?
Last edited by Flo169 (2017-08-26 17:47:55)
Offline