Register Guidelines E-Books Search Today's Posts Mark Forums Read

Go Back   MobileRead Forums > E-Book Formats > PDF

Notices

Reply
 
Thread Tools Search this Thread
Old 03-17-2017, 05:40 PM   #1
mike.foster
Member
mike.foster invented the internet.mike.foster invented the internet.mike.foster invented the internet.mike.foster invented the internet.mike.foster invented the internet.mike.foster invented the internet.mike.foster invented the internet.mike.foster invented the internet.mike.foster invented the internet.mike.foster invented the internet.mike.foster invented the internet.
 
Posts: 22
Karma: 84908
Join Date: May 2014
Device: iPad
k2pdfopt for yellow/brown pages

Hi,

I have a book whose pages are yellow/brown-ish (sample). It's for reading with an iPad. What command can I use with k2pdfopt to increase the contrast (no need to shrink)?
mike.foster is offline   Reply With Quote
Advert
Old 03-17-2017, 09:07 PM   #2
willus
Fuzzball, the purple cat
willus ought to be getting tired of karma fortunes by now.willus ought to be getting tired of karma fortunes by now.willus ought to be getting tired of karma fortunes by now.willus ought to be getting tired of karma fortunes by now.willus ought to be getting tired of karma fortunes by now.willus ought to be getting tired of karma fortunes by now.willus ought to be getting tired of karma fortunes by now.willus ought to be getting tired of karma fortunes by now.willus ought to be getting tired of karma fortunes by now.willus ought to be getting tired of karma fortunes by now.willus ought to be getting tired of karma fortunes by now.
 
willus's Avatar
 
Posts: 977
Karma: 7562459
Join Date: Jun 2011
Location: California
Device: iPad
Quote:
Originally Posted by mike.foster View Post
Hi,

I have a book whose pages are yellow/brown-ish (sample). It's for reading with an iPad. What command can I use with k2pdfopt to increase the contrast (no need to shrink)?
Code:
 k2pdfopt -mode copy -c- -cmax 3 myfile.pdf
You can increase the cmax value if you like. This worked pretty well on your image. Make the value negative to force it (when it is positive, it just acts as a ceiling--k2pdfopt tries to pick an optimum).
Edit #1: See attachment for your sample (page 1) and the conversion (page 2).
Edit #2: Out of curiosity, I added to the attachment the default conversion done by Scan Tailor (v0.9.11.1) on page 3.
Attached Files
File Type: pdf file_plus_conversion.pdf (1.10 MB, 111 views)

Last edited by willus; 03-17-2017 at 09:32 PM. Reason: Added / Modified attachment
willus is offline   Reply With Quote
Old 03-24-2017, 03:11 PM   #3
mike.foster
Member
mike.foster invented the internet.mike.foster invented the internet.mike.foster invented the internet.mike.foster invented the internet.mike.foster invented the internet.mike.foster invented the internet.mike.foster invented the internet.mike.foster invented the internet.mike.foster invented the internet.mike.foster invented the internet.mike.foster invented the internet.
 
Posts: 22
Karma: 84908
Join Date: May 2014
Device: iPad
Thank you!
mike.foster is offline   Reply With Quote
Old 04-20-2017, 12:47 PM   #4
mike.foster
Member
mike.foster invented the internet.mike.foster invented the internet.mike.foster invented the internet.mike.foster invented the internet.mike.foster invented the internet.mike.foster invented the internet.mike.foster invented the internet.mike.foster invented the internet.mike.foster invented the internet.mike.foster invented the internet.mike.foster invented the internet.
 
Posts: 22
Karma: 84908
Join Date: May 2014
Device: iPad
Unfortunately, it didn't work for the entire book (or even bigger samples than the one provided), see attachment. It's huge: 3.15GB
Attached Thumbnails
Click image for larger version

Name:	k2pdfopt-error.png
Views:	87
Size:	23.4 KB
ID:	156278  
mike.foster is offline   Reply With Quote
Old 04-21-2017, 12:34 AM   #5
willus
Fuzzball, the purple cat
willus ought to be getting tired of karma fortunes by now.willus ought to be getting tired of karma fortunes by now.willus ought to be getting tired of karma fortunes by now.willus ought to be getting tired of karma fortunes by now.willus ought to be getting tired of karma fortunes by now.willus ought to be getting tired of karma fortunes by now.willus ought to be getting tired of karma fortunes by now.willus ought to be getting tired of karma fortunes by now.willus ought to be getting tired of karma fortunes by now.willus ought to be getting tired of karma fortunes by now.willus ought to be getting tired of karma fortunes by now.
 
willus's Avatar
 
Posts: 977
Karma: 7562459
Join Date: Jun 2011
Location: California
Device: iPad
Quote:
Originally Posted by mike.foster View Post
Unfortunately, it didn't work for the entire book (or even bigger samples than the one provided), see attachment. It's huge: 3.15GB
It doesn't look like the mupdf library is compatible with PDF files over 2 GB in size. You mght have to try using a separate tool (cpdf?) to break that PDF into two smaller files ( < 2 GB). How many pages is it?
[Edit: If practical, can you PM me a link to the smallest sample size you tested that doesn't work?]

Last edited by willus; 04-21-2017 at 09:38 AM.
willus is offline   Reply With Quote
Old 04-27-2017, 04:06 PM   #6
mike.foster
Member
mike.foster invented the internet.mike.foster invented the internet.mike.foster invented the internet.mike.foster invented the internet.mike.foster invented the internet.mike.foster invented the internet.mike.foster invented the internet.mike.foster invented the internet.mike.foster invented the internet.mike.foster invented the internet.mike.foster invented the internet.
 
Posts: 22
Karma: 84908
Join Date: May 2014
Device: iPad
This worked, thanks.

Code:
cpdf barres-1922-deracines.pdf -split -chunk 100 -o barres%%%.pdf 
k2pdfopt -mode copy -c- -cmax 3 barres0*.pdf
Notice full name, not wild card in cpdf ...
Attached Thumbnails
Click image for larger version

Name:	Screen Shot 2017-04-27 at 4.05.07 PM.png
Views:	75
Size:	10.1 KB
ID:	156399   Click image for larger version

Name:	Screen Shot 2017-04-27 at 4.05.17 PM.png
Views:	75
Size:	10.3 KB
ID:	156400  
mike.foster is offline   Reply With Quote
Old 04-28-2017, 05:17 PM   #7
willus
Fuzzball, the purple cat
willus ought to be getting tired of karma fortunes by now.willus ought to be getting tired of karma fortunes by now.willus ought to be getting tired of karma fortunes by now.willus ought to be getting tired of karma fortunes by now.willus ought to be getting tired of karma fortunes by now.willus ought to be getting tired of karma fortunes by now.willus ought to be getting tired of karma fortunes by now.willus ought to be getting tired of karma fortunes by now.willus ought to be getting tired of karma fortunes by now.willus ought to be getting tired of karma fortunes by now.willus ought to be getting tired of karma fortunes by now.
 
willus's Avatar
 
Posts: 977
Karma: 7562459
Join Date: Jun 2011
Location: California
Device: iPad
Quote:
Originally Posted by mike.foster View Post
This worked, thanks.

Code:
cpdf barres-1922-deracines.pdf -split -chunk 100 -o barres%%%.pdf 
k2pdfopt -mode copy -c- -cmax 3 barres0*.pdf
Notice full name, not wild card in cpdf ...
How did you go from 524 MB for the source file to 7 MB for the converted file? Are the source images completely uncompressed? How many pages are in each of those files (should be the same...)? Can you run k2pdfopt -i on the source file and post the results?
willus is offline   Reply With Quote
Old 01-18-2018, 10:26 PM   #8
mike.foster
Member
mike.foster invented the internet.mike.foster invented the internet.mike.foster invented the internet.mike.foster invented the internet.mike.foster invented the internet.mike.foster invented the internet.mike.foster invented the internet.mike.foster invented the internet.mike.foster invented the internet.mike.foster invented the internet.mike.foster invented the internet.
 
Posts: 22
Karma: 84908
Join Date: May 2014
Device: iPad
Hello,

using:

Quote:
k2pdfopt -mode copy -c- -cmax 3 meadows_ltg-001.pdf
for Meadow's 1972 The limits to Growth,

makes a k2opt file that cannot be opened by either Pdf viewer or Acrobat reader. Any idea Y that might be the case? I tried with other big sized pdf w/o problem.

Thanks.
mike.foster is offline   Reply With Quote
Old 01-18-2018, 10:28 PM   #9
mike.foster
Member
mike.foster invented the internet.mike.foster invented the internet.mike.foster invented the internet.mike.foster invented the internet.mike.foster invented the internet.mike.foster invented the internet.mike.foster invented the internet.mike.foster invented the internet.mike.foster invented the internet.mike.foster invented the internet.mike.foster invented the internet.
 
Posts: 22
Karma: 84908
Join Date: May 2014
Device: iPad
Quote:
Originally Posted by willus View Post
How did you go from 524 MB for the source file to 7 MB for the converted file? Are the source images completely uncompressed? How many pages are in each of those files (should be the same...)? Can you run k2pdfopt -i on the source file and post the results?
I find out about this only now. I don't have the source file anymore.
mike.foster is offline   Reply With Quote
Old 01-19-2018, 05:50 PM   #10
mike.foster
Member
mike.foster invented the internet.mike.foster invented the internet.mike.foster invented the internet.mike.foster invented the internet.mike.foster invented the internet.mike.foster invented the internet.mike.foster invented the internet.mike.foster invented the internet.mike.foster invented the internet.mike.foster invented the internet.mike.foster invented the internet.
 
Posts: 22
Karma: 84908
Join Date: May 2014
Device: iPad
Quote:
Originally Posted by mike.foster View Post
Hello,

using:



for Meadow's 1972 The limits to Growth,

makes a k2opt file that cannot be opened by either Pdf viewer or Acrobat reader. Any idea Y that might be the case? I tried with other big sized pdf w/o problem.

Thanks.
False alert, it worked after all.
mike.foster is offline   Reply With Quote
Reply

Tags
k2pdfopt

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
k2pdfopt segmentation fault mike.foster PDF 3 11-23-2015 10:39 PM
Touch pdf and k2pdfopt on kobo metita Kobo Reader 7 08-23-2015 05:14 AM
Background color of pages yellow please55 Editor 2 12-28-2014 12:30 PM
Problem with reconverting k2PDFOpt to EBUB ittiandro Conversion 7 08-19-2014 06:43 PM


All times are GMT -4. The time now is 02:18 PM.


MobileRead.com is a privately owned, operated and funded community.