View Single Post
Old 01-27-2009, 03:10 PM   #59
soilwork
useR!
soilwork will become famous soon enoughsoilwork will become famous soon enoughsoilwork will become famous soon enoughsoilwork will become famous soon enoughsoilwork will become famous soon enoughsoilwork will become famous soon enough
 
soilwork's Avatar
 
Posts: 299
Karma: 651
Join Date: Nov 2007
Location: NY
Device: Onyx Boox Max 2, Kobo Libra H2O, iRiver Story HD
Quote:
Originally Posted by mazzeltjes View Post
the only thing is that the top quarter of
the letters on the following page are at the
bottom of the previous one.
this progresses through the document
so that after a few pages the letters are cut in half
is there a way to fix this
It would be great if this problem can be fixed but, for now, I am using Papercrop and PDFLRF to avoid this problem. I do the following.

1. Convert each page into one long image
1a. First, need to edit 'config.lua' to increase 'device_height' option. You need to do this only once. For example, I use the following.
Code:
device_width=700
device_height=30000
scroll_overlap_pixels=0
1b. Load a PDF file
1c. Press "Process current page" in each page

2. Archive all images into one ZIP file

3. Process by PDFLRF using Portrait or Comic-Portrait with Smart-cut option on. I use a simple batch file such as
Code:
pdflrf --erode=2 --nocrop -rs -c 8 --rotation="0" --pad=10 --overlap=0 -i %1 -o "%~n1.lrf" -t %2 -a %3
Note that I am using a DOS version of PDFLRF instead of windows version to avoid changing the option each time, but you can also use PDFLRFwin with proper option.

If this batch file is named as 'plb.bat', then you can use the following command to convert the zip file from step 2.
Code:
plb 'filename.zip' 'Title of the book' 'Author of the book'
As you can see, this may work with rather short PDF (e.g. journal articles) but probably too labor-intensive for longer books (step 1c).
It is too bad that PDFLRF is not open-sourced. If it were, smart crop algorithm could have been incorporated in programs like PaperCrop rather easily.

Last edited by soilwork; 01-29-2009 at 02:45 PM. Reason: Modified the batch file with less arguments
soilwork is offline   Reply With Quote