View Full Version : Epub to Mobi Conversion - Designating Chapter Starts?


CAJensen01
01-07-2010, 10:53 AM
Sorry if this is a novice question, I just don't fully understand the conversion process and tagging yet. Converting an InDesign layout to epub, is there some tagging that needs done within the layout somehow to designate where a chapter starts? Is there any good readme on the entire process prior to converting to mobi?

Tony_A20
01-16-2010, 12:12 AM
Re-creating an EPUB to mobi from scratch requires quite a bit of work, but is actually simpler if you start from a text document (Word or OO Writer export to html). If you just want to read an epub on a Kindle, the kindle will do a simple conversion, as will Mobipocket reader software. Mobipocket reader creates a .prc version in its library when it does the conversion. Check out

http://www.amazon.com/gp/feature.html/ref=kinww_ddp2?docId=1000426311

to download Kindle for PC software. It comes with sample material and publishing guidelines.

Google to find Mobipocket Creator and Mobipocket Reader software or browse the Amazon website.

Tony

JSWolf
01-16-2010, 09:48 PM
Use InDesign to make the epub and then use Calibre to convert the ePub to Mobipocket. It will work well and give you what you want.

Doing it Tony's way is longer and more tedious. It's really simple with Calibre.

Tony_A20
01-18-2010, 10:16 AM
I'm sorry if I confused the issue, I'm just a newbie, but I think it depends on the end goal.

I'm not familiar with Calibre, and I'm sure there are several tools to convert from epub to mobi.

If all that is desired is to produce a readable mobi document, they will suffice.

However, if the goal is to produce a publishable document meeting Amazon spec's and the Kindle Publishing Guidelines, then the mobi document should be created using Kindlegen, and that is a hand-built process, which is certainly slower and more difficult than using a conversion utility.

I certainly bow to JSWolf's superior knowledge and experience, and will put Calibre on my growing list of things to investigate in the world of e-book publishing.

Tony

JSWolf
01-18-2010, 10:20 AM
I'm sorry if I confused the issue, I'm just a newbie, but I think it depends on the end goal.

I'm not familiar with Calibre, and I'm sure there are several tools to convert from epub to mobi.

If all that is desired is to produce a readable mobi document, they will suffice.

However, if the goal is to produce a publishable document meeting Amazon spec's and the Kindle Publishing Guidelines, then the mobi document should be created using Kindlegen, and that is a hand-built process, which is certainly slower and more difficult than using a conversion utility.

I certainly bow to JSWolf's superior knowledge and experience, and will put Calibre on my growing list of things to investigate in the world of e-book publishing.

Tony
It sounds like Kindlegen is just a slightly modified MobiGen. If the goal is to use it to convert to Mobipocket, then yes, Calibre can do this quite well and do so a lot easier.

Tony_A20
01-22-2010, 09:59 AM
There are several spec's defining the creation of digital content. They apply to e-books. To meet these spec's requires the creation of several files (opf, toc, ncx, content,etc) which control the building of the e-book. Any application that purports to produce an e-book in a specific format (kindle, epub, etc) which does not use these files, is only meant to produce a document which can be displayed on a Reader device for the owner's personal use.

Applications such as Kindlegen accept an OPF file as input and build a document following the instructions in the OPF file, whereas applications such as Mobi Creator do not, although Mobi Creator can produce a PRC file which a Kindle Reader will display.

Other formats, such as EPUB, also use opf, toc, ncx, content files, etc to create e-books and if the application, or method of packaging the e-book meets the digital spec's, the same construction file can be used with only slight modification to accommodate different Reader devices.

In brief, if you want to construct an e-book that meets digital spec's, and can be used to build versions that will run on more than one Reader device, the construction files need to be hand coded. If a translation application is used, the output can be read on a users Reader, but is unlikely to meet spec's, and probably can't be used on another type of Reader

Tony

kovidgoyal
01-22-2010, 10:20 AM
That's a complete myth. Using tools from Amazon to produce Kindle books is completely unnecessary. And hand coding files is also completely unnecessary (though very satisfying).

Pardoz
01-22-2010, 10:25 AM
Applications such as Kindlegen accept an OPF file as input and build a document following the instructions in the OPF file, whereas applications such as Mobi Creator do not, although Mobi Creator can produce a PRC file which a Kindle Reader will display.

Just an addendum - Kindlegen will also accept a (properly-made) .epub file as input and convert it to .mobi, no hand-creation involved or necessary for conversion.

Valloric
01-22-2010, 03:14 PM
In brief, if you want to construct an e-book that meets digital spec's, and can be used to build versions that will run on more than one Reader device, the construction files need to be hand coded. If a translation application is used, the output can be read on a users Reader, but is unlikely to meet spec's, and probably can't be used on another type of Reader.

Completely and utterly false. Pure FUD.

CAJensen01
01-29-2010, 09:02 AM
While I've figured out how to use InDesign + Calibre to do a lot of what I was looking for, I didn't get my question quite answered. When a document is segmented as a 'book' in InDesign, the different documents contained within that book are recognized as different chapter/entries into the TOC upon conversion.

However, what about if the document is one large ID document. Is there a method to tag such that chapter breaks are designated in the conversion process?

Thanks

zdavatz
02-02-2010, 11:07 AM
Kovid: How do you create TOCs from RSS-Feeds from i.e. WSJ or the Economist? Obviously you do not use Kindlegen or Mobigen? Can you point me to a link in the documentation of Calibre please? Thanks for your Feedback.

zdavatz
02-12-2010, 09:04 AM
The answer to the above is that Kovid and the Calibre team reverse engineered the whole section list creator of mobipocket! Kindlegen also can not create any section lists! Calibre can! Also see: http://www.amazon.com/tag/kindle%20publishing/forum/ref=cm_cd_et_md_pl?_encoding=UTF8&cdForum=Fx21HB0U7MPK8XI&cdMsgNo=22&cdPage=1&cdSort=oldest&cdThread=Tx34AOGO6NKB8Y2&cdMsgID=Mx31OEYBU7RUPWO#Mx31OEYBU7RUPWO

kovidgoyal
02-12-2010, 12:31 PM
Amazon intended section lists to be used only by periodicals not normal books, so they haven't made that capability available to the general public.

zdavatz
02-19-2010, 03:32 AM
Dear Kovid! Ahhhhh. Got it! Thanks so much for this input.

charleski
02-19-2010, 07:52 AM
While I've figured out how to use InDesign + Calibre to do a lot of what I was looking for, I didn't get my question quite answered. When a document is segmented as a 'book' in InDesign, the different documents contained within that book are recognized as different chapter/entries into the TOC upon conversion.

However, what about if the document is one large ID document. Is there a method to tag such that chapter breaks are designated in the conversion process?

Thanks

Haha, looks like people got side-tracked by politics :rolleyes:

Unfortunately, the answer to your question is no :(. The only way to get InDesign to split the output files so they stay under the 300K limit for mobile devices is to split the documents by hand. I seriously hope that CS5 will see some major improvements, because right now InDesign is quite clumsy for ePubs, though it does have some nice features.

If you want a program which will allow you to split without having to copy and paste large chunks of text, try Atlantis Word Processor (which works on doc files) or Sigil (which works with html or xhtml). The chaptering process is automatic in AWP and Sigil allows you to manually specify chapter breaks simply by clicking a button. Both are used by major publishing houses, so you don't have to use a big expensive program to get professional results.

To tag chapters in AWP, simply apply a Heading style to the relevant paragraph (i.e. Prologue, Chapter One, etc). To do it in Sigil, use the <h1><h2> etc tags.

If your source document is an InDesign layout, you can export it as XML and import it to Sigil for conversion to ePub. Just make sure that all your elements are correctly tagged before export (Map Styles to Tags in the Tag window menu for automatic tagging).

jimad
02-20-2010, 04:33 PM
Sorry, but this is what I think I've been able to figure out about this subject:

Both Epub and Mobi files can be generated using the set OPF files and by following their specs. Those specs say that NCX (section navigation) and TOC (Table of Contents) are not the same thing.

http://www.openebook.org/2007/opf/OPF_2.0_final_spec.html

EPUB as implemented for ADE (Adobe Digital Editions) uses NCX by default to navigate the document. If you also include a TOC then ADE will display two navigation structures, one simpler cleaner one representing the TOC and a more in-depth messier one for NCX. Since most implementers think it looks like a mistake to display two navigational structures within ADE, most EPUB implementors simply implement NCX and leave out the TOC.

Kindle instead by default uses TOC to navigate the document. Kindle specs for MOBI say "you must have a TOC" meaning NCX is optional. On a Kindle if you push the "TOC" button what you see is TOC not NCX. NCX, if present, is supposed to implement right-click left-click "fast forward" and "fast reverse" to next section, NOT TOC.

Now, I have not been able to get Kindlegen to correctly do the "fast forward" "fast reverse" thing via NCX, so maybe THAT aspect is broken in Kindlegen.

However, I CAN get Kindlegen to expressly implement TOC if I expressly implement TOC in the OPF Files. For example, I can take an EPUB document -- which is simply a zipped version of the OPF file set, add a TOC where a TOC clearly didn't exist previously, compile that OPF set using Kindlegen's option to build from OPF, and the TOC works correctly.

What I suggest Calibre does on EPUB to MOBI conversion is to understand the difference in the conventions used by the EPUB vs MOBI "communities" when implementing the OPF specs and automagically converts the EPUB NCX structure to a OPF TOC. This "works" but gives an "ugly" TOC -- one that has more detail than one would typically expect in a hand-written TOC.

One can manually add a TOC to an existing EPUB (unzipped to OPF file set) or perhaps what is easier one can add a single ref TOC which simply points to the TOC presumably already implemented within the doc files. Then when you push the TOC button on Kindle you get a page displayed with a single link "Table of Contents" you click on that link and it takes you to the TOC embedded within the document.

Unfortunately, most people have a hard time accepting that EPUB and MOBI can implement and expect slightly different versions of the same OPF spec!

jimad
02-20-2010, 04:41 PM
PS: Search this Kindle document repeatedly on "Table of Contents" for a somewhat obtuse and confusing discussion of the difference between NCX and TOC -- "TOC" which this document refers to as "HTML TOC." The OPF specs also confuse this issue by unfortunately choosing the arbitrary name "toc" for their ncx example files!

http://s3.amazonaws.com/kindlegen/AmazonKindlePublishingGuidelinesV1.3.pdf

charleski
02-20-2010, 07:32 PM
What I suggest Calibre does on EPUB to MOBI conversion is to understand the difference in the conventions used by the EPUB vs MOBI "communities" when implementing the OPF specs and automagically converts the EPUB NCX structure to a OPF TOC. This "works" but gives an "ugly" TOC -- one that has more detail than one would typically expect in a hand-written TOC.
This is largely because publishers are incorporating too much in their NCX to start with. There's no reason to have separate navigation entities for the title page, dedication, copyright page and all the other fluff that makes up the front matter. It's just bad practice on the part of the person creating the ePub.

When the Amazon doc tries telling people "It is generally a good idea to place an HTML page with a table of contents at the beginning of the book" I just despair -NO NO NO.

pccsoares
09-29-2010, 01:46 PM
I managed to get the "articles list" option enabled from an ebook compiled with KindleGen.

All I had to do was changing the OPF to include de tag:

<x-metadata><output encoding="utf-8" content-type="application/x-mobipocket-subscription-magazine"></output></x-metadata></metadata>