View Single Post
Old 09-16-2011, 09:11 AM   #206
fandrieu
Member
fandrieu began at the beginning.
 
Posts: 11
Karma: 10
Join Date: Sep 2011
Device: kindle 3
As siebert suggested, I modified the code to use the IDXT data in INDX1 to "find" the entries.

Before we relied exclusively on the TAGX data and assumed that after having parsed an entry we would be correctly positioned at the start of the next one.

Now the offsets found in the IDXT are used to (i hope) accurately find each entry: there should be no more "positioning" bugs.

(note that to do that I chose to pass the whole INDX section to parseINDX1 (before it was only the "navdata" part) so that the offsets in IDXT are used verbatim...)

....

I also fixed "buildNCX" to correctly (i guess) set "playOrder" and "dtb:depth".

....

Also I didn't mention it before, but in my previous version I introduced some code to include the "filepos" found in INDX in the "anchor" algorithm.
Without that, if a link is found only in the NCX and not in the html itself, the corresponding anchor would be missing.

...

@KevinH: I'll try to look into it over the week end if possible....
Attached Files
File Type: zip mobiunpack_ncx_idxt.zip (16.9 KB, 1211 views)
fandrieu is offline   Reply With Quote