Register Guidelines E-Books Today's Posts Search

Go Back   MobileRead Forums > E-Book Software > Calibre

Notices

Reply
 
Thread Tools Search this Thread
Old 10-24-2010, 04:02 AM   #1
dkritso109
Enthusiast
dkritso109 began at the beginning.
 
Posts: 43
Karma: 10
Join Date: Jun 2010
Device: Kindle 3
Adding Pictures As Covers

I have tons of comics which I am adding to calibre with no problem. The problem comes with adding jpgs to the database for use as covers. I have jpgs of all the covers, and it is getting real tedious dragging and dropping each jpg to the database. All of my jpgs have the exact name as the pdf or cbr I was adding. I was wondering if there was a way to add a bulk of jpgs to the database and then they would be automatically added as covers to the ebooks with matching filenames.
dkritso109 is offline   Reply With Quote
Old 10-24-2010, 05:48 AM   #2
Manichean
Wizard
Manichean is the 'tall, dark, handsome stranger' all the fortune-tellers are referring to.Manichean is the 'tall, dark, handsome stranger' all the fortune-tellers are referring to.Manichean is the 'tall, dark, handsome stranger' all the fortune-tellers are referring to.Manichean is the 'tall, dark, handsome stranger' all the fortune-tellers are referring to.Manichean is the 'tall, dark, handsome stranger' all the fortune-tellers are referring to.Manichean is the 'tall, dark, handsome stranger' all the fortune-tellers are referring to.Manichean is the 'tall, dark, handsome stranger' all the fortune-tellers are referring to.Manichean is the 'tall, dark, handsome stranger' all the fortune-tellers are referring to.Manichean is the 'tall, dark, handsome stranger' all the fortune-tellers are referring to.Manichean is the 'tall, dark, handsome stranger' all the fortune-tellers are referring to.Manichean is the 'tall, dark, handsome stranger' all the fortune-tellers are referring to.
 
Manichean's Avatar
 
Posts: 3,130
Karma: 91256
Join Date: Feb 2008
Location: Germany
Device: Cybook Gen3
That sounds like it could be automated using the command line. I'm guessing that a combination of ebook-meta and some scripting should get you there.
Edit: You should read the documentation for ebook-meta. It might be that you have to do this before adding the books to the library.
Manichean is offline   Reply With Quote
Advert
Old 10-24-2010, 07:25 AM   #3
dkritso109
Enthusiast
dkritso109 began at the beginning.
 
Posts: 43
Karma: 10
Join Date: Jun 2010
Device: Kindle 3
Thank you for your response, but I have no clue about ebook-meta or scripting. Could you point me into the right direction?
dkritso109 is offline   Reply With Quote
Old 10-24-2010, 09:46 AM   #4
Manichean
Wizard
Manichean is the 'tall, dark, handsome stranger' all the fortune-tellers are referring to.Manichean is the 'tall, dark, handsome stranger' all the fortune-tellers are referring to.Manichean is the 'tall, dark, handsome stranger' all the fortune-tellers are referring to.Manichean is the 'tall, dark, handsome stranger' all the fortune-tellers are referring to.Manichean is the 'tall, dark, handsome stranger' all the fortune-tellers are referring to.Manichean is the 'tall, dark, handsome stranger' all the fortune-tellers are referring to.Manichean is the 'tall, dark, handsome stranger' all the fortune-tellers are referring to.Manichean is the 'tall, dark, handsome stranger' all the fortune-tellers are referring to.Manichean is the 'tall, dark, handsome stranger' all the fortune-tellers are referring to.Manichean is the 'tall, dark, handsome stranger' all the fortune-tellers are referring to.Manichean is the 'tall, dark, handsome stranger' all the fortune-tellers are referring to.
 
Manichean's Avatar
 
Posts: 3,130
Karma: 91256
Join Date: Feb 2008
Location: Germany
Device: Cybook Gen3
Quote:
Originally Posted by dkritso109 View Post
Thank you for your response, but I have no clue about ebook-meta or scripting. Could you point me into the right direction?
Read the Calibre manual entry for ebook-meta (Hint: The option you want is, unsurprisingly, called --cover). Then, read documentation as to how to do command line scripts/ bash files in whatever OS you have. The program logic you'll want to implement is something like getting a list of all cover files you have, then adding that cover to the ebook file of the same name. (Hint: This assumes that, apart from the file extension, the file names really are 100% identical. If not, figure out a way to compensate.)
Manichean is offline   Reply With Quote
Old 10-24-2010, 10:41 AM   #5
Starson17
Wizard
Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.
 
Posts: 4,004
Karma: 177841
Join Date: Dec 2009
Device: WinMo: IPAQ; Android: HTC HD2, Archos 7o; Java:Gravity T
Quote:
Originally Posted by Manichean View Post
Read the Calibre manual entry for ebook-meta (Hint: The option you want is, unsurprisingly, called --cover). ...It might be that you have to do this before adding the books to the library.... Then, read documentation as to how to do command line scripts/ bash files in whatever OS you have.
This will update the cover in the ebook. You'll then have to re-add the book with metadata reading from the ebook turned on.
Other methods include:
  • Use calibredb to set the metadata in the library, but to do that you'll need to create an opf file.
  • Copy the cover to the Calibre library and change its name to cover.jpg.
  • Fetch the cover online. You need correct titles and authors for this to work well.

Last edited by Starson17; 10-24-2010 at 11:58 AM.
Starson17 is offline   Reply With Quote
Advert
Old 10-24-2010, 10:44 AM   #6
Manichean
Wizard
Manichean is the 'tall, dark, handsome stranger' all the fortune-tellers are referring to.Manichean is the 'tall, dark, handsome stranger' all the fortune-tellers are referring to.Manichean is the 'tall, dark, handsome stranger' all the fortune-tellers are referring to.Manichean is the 'tall, dark, handsome stranger' all the fortune-tellers are referring to.Manichean is the 'tall, dark, handsome stranger' all the fortune-tellers are referring to.Manichean is the 'tall, dark, handsome stranger' all the fortune-tellers are referring to.Manichean is the 'tall, dark, handsome stranger' all the fortune-tellers are referring to.Manichean is the 'tall, dark, handsome stranger' all the fortune-tellers are referring to.Manichean is the 'tall, dark, handsome stranger' all the fortune-tellers are referring to.Manichean is the 'tall, dark, handsome stranger' all the fortune-tellers are referring to.Manichean is the 'tall, dark, handsome stranger' all the fortune-tellers are referring to.
 
Manichean's Avatar
 
Posts: 3,130
Karma: 91256
Join Date: Feb 2008
Location: Germany
Device: Cybook Gen3
Quote:
Originally Posted by Starson17 View Post
  • Copy the cover to the Calibre library and change its name to cover.jpg.
That works? Without updating metadata or anything?
Manichean is offline   Reply With Quote
Old 10-24-2010, 11:57 AM   #7
Starson17
Wizard
Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.
 
Posts: 4,004
Karma: 177841
Join Date: Dec 2009
Device: WinMo: IPAQ; Android: HTC HD2, Archos 7o; Java:Gravity T
Quote:
Originally Posted by Manichean View Post
That works? Without updating metadata or anything?
Yes. If the cover.jpg file exists, Calibre uses it as the cover. If not, it uses the default. The existence or lack is not stored in the metadata.db. It probably is stored in metadata.opf, but AFAIK, that file's just used for backup. I know it's not used for Merge, Copy to Library or for displaying the cover when Edit metadata is used.
Starson17 is offline   Reply With Quote
Old 10-24-2010, 12:01 PM   #8
Manichean
Wizard
Manichean is the 'tall, dark, handsome stranger' all the fortune-tellers are referring to.Manichean is the 'tall, dark, handsome stranger' all the fortune-tellers are referring to.Manichean is the 'tall, dark, handsome stranger' all the fortune-tellers are referring to.Manichean is the 'tall, dark, handsome stranger' all the fortune-tellers are referring to.Manichean is the 'tall, dark, handsome stranger' all the fortune-tellers are referring to.Manichean is the 'tall, dark, handsome stranger' all the fortune-tellers are referring to.Manichean is the 'tall, dark, handsome stranger' all the fortune-tellers are referring to.Manichean is the 'tall, dark, handsome stranger' all the fortune-tellers are referring to.Manichean is the 'tall, dark, handsome stranger' all the fortune-tellers are referring to.Manichean is the 'tall, dark, handsome stranger' all the fortune-tellers are referring to.Manichean is the 'tall, dark, handsome stranger' all the fortune-tellers are referring to.
 
Manichean's Avatar
 
Posts: 3,130
Karma: 91256
Join Date: Feb 2008
Location: Germany
Device: Cybook Gen3
Okay, that would permit another scripting approach: Get list of all cover filenames, extract author and title from the filenames, figure out the corresponding folder in the library, copy image to cover.jpg.
Manichean is offline   Reply With Quote
Old 10-24-2010, 12:13 PM   #9
Starson17
Wizard
Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.
 
Posts: 4,004
Karma: 177841
Join Date: Dec 2009
Device: WinMo: IPAQ; Android: HTC HD2, Archos 7o; Java:Gravity T
Quote:
Originally Posted by Manichean View Post
Okay, that would permit another scripting approach: Get list of all cover filenames, extract author and title from the filenames, figure out the corresponding folder in the library, copy image to cover.jpg.
That's why I mentioned it, but Calibre library folders aren't named with obvious names (length control and book id issues), so it needs some more work. What is really needed is more comprehensive metadata import control during Add Books.

A table (like a plugboard) that says get the author and title from the filename, the series from the directory name, the book cover from the jpg image that matches the file title, and all other metadata (publisher, etc) from internal metadata would be nice. It's on Kovid's ToDo, which gets longer each day. (One of the few things with a length that grows faster than the speed of light - it's a good thing Kovid has a Physics background).
Starson17 is offline   Reply With Quote
Reply


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Covers, covers and damn statistics (wait, I got that wrong). Moejoe Writers' Corner 86 11-29-2010 08:34 PM
Covers vs. Pictures? hnoto Calibre 2 12-31-2009 05:49 PM
Adding pictures to epub from a txt file p3aul Calibre 3 04-16-2009 06:05 PM
Book Designer Vista and Allowing Book Covers and Pictures andyafro Sony Reader 0 01-22-2008 09:49 PM
Adding book covers with sony connect reader jhempel24 Sony Reader 2 01-22-2008 08:42 AM


All times are GMT -4. The time now is 05:00 PM.


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