Beefy Boxes and Bandwidth Generously Provided by pair Networks
more useful options
 
PerlMonks  

Re: PDF::API2 behaving differently on two computers?

by Corion (Pope)
on Apr 08, 2020 at 17:52 UTC ( #11115230=note: print w/replies, xml ) Need Help??


in reply to PDF::API2 behaving differently on two computers?

Can you reduce the program to a very short program that still exhibits the problem? I'm thinking of something like:

#!perl use strict; use warnings; use PDF::API2; print "Using PDF::API2 version $PDF::API2::VERSION\n"; my $pdf = PDF::API2->new; my $bg_file = 'watermark.pdf'; my $bg = $pdf->importPageIntoForm( $bg_file, 1 ); # ... $page->gfx->formimage( $bg, 0, 0, 1.0 ) # write to another file

That would help me understand your steps better and maybe point out where the problem(s) might lie.

Replies are listed 'Best First'.
Re^2: PDF::API2 behaving differently on two computers?
by trillich (Acolyte) on Apr 08, 2020 at 20:42 UTC

    Aha, this was a helpful kick in the pants. When I do a simple script as you suggest, everything works swimmingly. So there's something in the home-grown modules in between, that we are using, that's corrupting things. So at least I have a starting point for sleuthing now.

    One thing I've noticed in the past, is that I must disable $pdf->{forcecompress} = 0. Sometimes it's okay even with forcecompress left enabled, other times it really scrambles the presentation when displaying via a PDF reader (text enormous or skewed or mispositioned on the page). Turning it off makes it so there's dependable display of the results.

    Is that common -- where forcecompress causes issues?

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://11115230]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others studying the Monastery: (4)
As of 2021-01-23 23:46 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    Notices?