Order it now! Amazon prioritizes orders on a first come, first served basis.


View Full Version : A brute force method to read PDF files on Cybook


Hanselda
07-21-2008, 06:29 PM
The idea is simple. We all know the pdf support on Cybook sucks. But at least it can display the jpg quite OK. Then just convert the pdf to jpg, that's it. So here comes the dirty script.

Usage: prepare_pdf file.pdf, then follow the questions.

The script will convert every page into several jpg files to fit the Cybook screen. Usually you can have 2-3 images per page if the page is set to 'landscape' mode in the script. All the images should be viewed on cybook in landscape and fit page mode, since the script will do all the slicing and rotation on the computer. On Cybook you simply press left to turn pages. You can also crop the page if you don't like any margin. At last you can compress all the images into one pdf file. This pdf can be opened on Cybook.

What you need:
python
imagemagick
pdftoppm (from ghostscript)
pdfimage (from pdflib)

changed in V3:
Add the two columns mode. The page can be sliced into two regions and viewed separately.
Now the program can continue with the viewer window kept open.
Use multiple threads for imagemagick. The converting process should be faster.

Hanselda
07-22-2008, 06:14 AM
I made a small modification. The pages are saved in png file, not jpg. The png file has much smaller size in this case. Also the final size of the converted pdf is smaller.

[some minor changes again. Now it should work more reliable.]

PS: I forgot to mention that the script will call a viewer to display the page. Please change the varable VIEWER = 'kview' to whatever program which you can call from console.

Boeboe
07-24-2008, 05:06 PM
Wouldn't it be MUCH, MUCH easier to simply convert the pdf file to mobipocket format instead of ending up with hundreds of image files without bookmark possibilities?

Hanselda
07-25-2008, 05:08 AM
If you convert it simply to mobipocket, there is a great chance that it messes up the formating. If the pdf contains special characters, lots of figures and especially mathematical formula and vector plot the result is really unreadable. And it is especially this kind of PDF that the Cybook cannot open.

For fiction or pure English words it's no problem to convert to mobi, but not for non-fictions like mathematics, physics and technical documents. And especially if such documents are scanned PDF.

Gianfranco
08-07-2008, 06:35 PM
So, how DO you do to read a PDF without an electron microscope?

I've been trying to read my lecture notes, but gave up right after Landscape -> Fit page width

/Gf

Gianfranco
08-07-2008, 07:26 PM
Ps. I am trying out your Script Hanselda

Hanselda
08-08-2008, 03:20 AM
Please provide more infomation. Else I cannot help.

If you like please post you pdf file here.

lordmax
08-08-2008, 04:00 AM
HI

Please provide more infomation. Else I cannot help.
If you like please post you pdf file here.

Good work.
I have signaled it to the italian ebook forum. ^___^

Gianfranco
08-08-2008, 07:57 AM
Hanselda; I fixed it with Adobe Acrobat Pro.
But thanks anyway, I'll try using imagemagick in ubuntu (sitting on Windows right now).

Removing white margins made it really readable with Landscape -> Fit to width.