Wrong directory order in UDF part of ISO/UDF filesystem (NeroAPI)

vbimport

#1

As you maybe know, I’m writing the ImgTool Stuff and I use for burning the NeroAPI. In the API version 6 there is a problem of sorting the directories and files outside the VIDEO_TS directory. The order of the files/directories is simply wrong!

This is the second try to get an answer for this problem. Meanwhile I’ve done some more checkings…

As I first tried to discuss this problem I got following comment from AndyE:

UDF Filesystem do not require directories to be sorted alphabetically. You should thus be able to determine the order in which the FIDs are created in the directory by just specifying them in the correct order within the NERO_ISO_ITEM linked list.

Regards,
andyE

This in mind I rewrote the sorting routine in ImgTool Burn but the result wasn’t very satisfactory…

I generate a linked list of NERO_ISO_ITEMS to represent the directory structure. If I start at the start point and walk through the linked list the file/directory order looks like this:

=============================
List ISO Tree…

\AUDIO_TS
\VIDEO_TS
\VIDEO_TS\VIDEO_TS.IFO
\VIDEO_TS\VIDEO_TS.BUP
\VIDEO_TS\VTS_01_0.IFO
\VIDEO_TS\VTS_01_1.VOB
\VIDEO_TS\VTS_01_0.BUP
\Alpha
\Alpha\get_db.php
\Bravo
\Bravo\set-wbb_Retro_Skin.tar
\Charly
\Charly\mp3.html
\Zulu
\Zulu\libs.zip

End ISO Tree…

This order is in my humble opinion the right one. But what makes the NeroAPI from this sorted tree?

Hm… not the right order.

Then I changed the sorting and reversed the order:

=============================
List ISO Tree…

\Zulu
\Zulu\libs.zip
\Charly
\Charly\mp3.html
\Bravo
\Bravo\set-wbb_Retro_Skin.tar
\Alpha
\Alpha\get_db.php
\VIDEO_TS
\VIDEO_TS\VTS_01_0.BUP
\VIDEO_TS\VTS_01_1.VOB
\VIDEO_TS\VTS_01_0.IFO
\VIDEO_TS\VIDEO_TS.BUP
\VIDEO_TS\VIDEO_TS.IFO
\AUDIO_TS

End ISO Tree…

As you can see the list is simply reversed…
…and that makes the NeroAPI from it…

Also not the right order…

I use following function to walk through the ISO tree:


void CImgToolsDlg::ListISOTree (NERO_ISO_ITEM *pStartHere, CString m_strPrefix)
{
   if (pStartHere == pStart)
   {
      AppendString("=============================");
      AppendString("List ISO Tree...");
      AppendString("=============================");
   }

   NERO_ISO_ITEM *pHelp = pStartHere;

   if (pHelp != NULL)
   {
      while (pHelp != NULL)
      {
         AppendString(m_strPrefix + (CString)pHelp->fileName);

         if (pHelp->subDirFirstItem != NULL)
         {
            ListISOTree(pHelp->subDirFirstItem, m_strPrefix + pHelp->fileName + (CString)"\\");
         }

         pHelp = pHelp->nextItem;
      }
   }

   if (pStartHere == pStart)
   {
      AppendString("=============================");
      AppendString("End ISO Tree...");
      AppendString("=============================");
   }
}

…and I call the function after the ISOTree is complete like this…


ListISOTree(pStart, "\\");

It would really be nice to know how I should sort the files that the API burn these files in correct order to DVD?!

Any help would be highly appreciated!

Greets from Germany,
CouJo!


#2

Thanks for your detailed report. This problem is fixed up from version 6.0.0.20.

Now NeroAPI will leave order of NERO_ISO_ITEM objects as it is except if priority differences are found or DVD-Video items are to be written. In this case, DVD-Video items will be sorted to the top of a directory, in the order VIDEO_TS.IFO, VIDEO_TS.VOB, VIDEO_TS.BUP, VTS_0y_0.IFO, VTS_0y_x.VOB, VTS_0y_0.BUP with the rest remaining untouched


#3

This would be really nice!

Thank you!

Greets, CouJo!


#4

Works great now!

Thank you very much!

Greets, CouJo!