View Full Version : PDIxtract: Extract files from .pdi file sets


schlaufer
17th February 2003, 16:22
Since the new version of DVD Decrypter is not ready by now and image mounting is not a option for everybody, I made a new tool that helps the poor FAT32 guys as well:

PDIxtract extracts all files from a given .pdi file set into the current directory. With the switch -l it just lists the directory of the .pdi file without extracting the contents.

As usual a simple command-line utlity. Source code included, compiles under linux with gcc and under windows with OpenWatcom compiler.

http://www.freewebs.com/schlaufer/pdixtract.zip

Update (1.4 now)
Added new command-line switches:

-l list only
-r remove source files after extraction
-d <dir> extract files into <dir> instead of current directory
-m <dir> create directory <dir> and extract files into <dir>
-v create VIDEO_TS subdirectory and extract files there
-x "Do it all", same as -r -m <pdi-file-name> -v
-i <iso-name> converts the .pdi file set to an iso image.


The option -r is ment for those of us that run out of disk space. In this processing mode, every .pdi-segment is deleted immediately after all files from it had been processed. This way, we do not need twice the disk-space of the .iso image but only the size + 1GB.

PDIxtract can extract only selected files if you specify them after the .pdi file; a * as trailing joker is supported.

Usage examples:

pdixtract -l blade2
-> shows the contents of blade2.pdi
pdixtract d:\lotr_see_d1
-> extract the contents of the lotr_see_d1.pdi* files on drive d:
pdixtract -r -m spidey spidey
-> create directory spidey and extract spidey.pdi* into it, remove all .pdi files as soon as possible
pdixtract -x hpcos
-> create directories hpcos/VIDEO_TS and extract hpcos.pdi* into it, remove all .pdi files as soon as possible
pdixtract h:\lotr1_see_d4 vts_08*
-> extract only video title set 8 from h:\lotr1_see_d4.pdi*


Bugfix If you have a lot of files in your .pdi-set and pdixtract give strange error messages upgrade to version 1.3 or later.

New tool There is a new tool released. It is pdixtract together with a real nice GUI. Discuss PDITool here (http://forum.doom9.org/showthread.php?s=&threadid=47259).

mikegun
17th February 2003, 16:39
cool, oh I love this community ...

regards, mike

p.s. it seems like you have to make a "get vts sectors" with
ifoedit before you start burning these files

p.p.s I suggest to specify an output folder so ifoedit didn't get confused by the pdixtract.exe

DVD Maniac
17th February 2003, 21:07
Hey schlaufer, thanks for coming up with this - exactly what I was looking for. Unfortunately your download link seems to be looping back to the original thread page - is there a problem with your host page?

mpucoder
17th February 2003, 21:14
This is how anti-leeching works at freewebs. To get around it copy and paste the URL into the browser location box, then hit enter.

To all who have short programs and anti-leeching such as this: It would be far easier to upload your programs to this forum. While the attachments have to approved by a moderator, that should not be a long wait currently.

DVD Maniac
17th February 2003, 21:22
Thanks for the quick response MPUC (a new shortname!?)

mpucoder
17th February 2003, 21:28
I'm snowed in (expected 18 inches) with not much else to do.

DVD Maniac
17th February 2003, 21:58
Being british it would be easy to make a crude joke regarding you staying in and expecting 18 inches later - but I won't. They always say everyting in the US is bigger though. mmm

schlaufer
18th February 2003, 00:16
Originally posted by mikegun

p.s. it seems like you have to make a "get vts sectors" with
ifoedit before you start burning these files

The files are exactly the files that would get burned by IC7. I just took a look at the VTS sector issue: it seems, that there is a bug either in ifoedit (0.95) or in ifoupdate (0.67) and IC 7. If you remove certain titles with IC 7 (using the registry hack), ifoupdate agrees with the generated sector addresses and ifoedit disagrees. (tested with the movie blade after removing titles 2, 3, and 7)

Originally posted by mikegun

p.p.s I suggest to specify an output folder so ifoedit didn't get confused by the pdixtract.exe
I usualy do not have pdixtract in the same directory. Either I have its location in my PATH environment or I call it with absolut path (during development). Nevertheless I will include an appropriate option switch in the next release.

valnar
18th February 2003, 01:31
After I get the PDI extracted files from IC, I always run every VTS set through Ifoedit before burning anyway. I need to do a "clean VOB Extras" run which takes a lot of time, but removes the phantom layer breaks. I then run Get VTS Sectors afterwards.

Now the DVD is perfect, and plays on all players. But it still takes awhile for this whole procedure. :angry:

-Robert

Subzero
18th February 2003, 07:26
I just downloaded the demo for instant copy and I'm backing up a dvd (The Four Feathers) now.....and I've been reading about how it produces the image in .pdi format.......so what I did was when I set my destination I put the file tpye to All Files and I named my image as "tff.iso" and press start and it currently transcoding and the extension is showing up as iso on my harddrive.

mpucoder
18th February 2003, 07:45
Well, let us know if the file is indeed iso once it's done. Some programs, like Paint Shop Pro, determine the format you want by the extension you use. Others ignore it, and make whatever they make (like Notepad, you can call the file anything you want, but it's plain text regardless). Usually if it is not one of the pulldown list choices, then the program cannot produce it.

schlaufer
18th February 2003, 11:18
Originally posted by Subzero
...I put the file tpye to All Files and I named my image as "tff.iso" and press start and it currently transcoding and the extension is showing up as iso on my harddrive.

But the generated file is still in the propriary .pdi format. No win :(

drpaulng
18th February 2003, 12:33
Originally posted by valnar
After I get the PDI extracted files from IC, I always run every VTS set through Ifoedit before burning anyway. I need to do a "clean VOB Extras" run which takes a lot of time, but removes the phantom layer breaks. I then run Get VTS Sectors afterwards.

Now the DVD is perfect, and plays on all players. But it still takes awhile for this whole procedure. :angry:

-Robert

Will you be kind enough to show us how to do the phantom layer break removal?
Thanks.

valnar
18th February 2003, 12:58
I just found this out myself. Run each VTS IFO that has a layer break through a VOB Extras run in IfoEdit. Make sure you select all VOB's. We're not removing anything here. Put them in a temp directory. When that is done, move all the files back into your source VIDEO_TS folder. Do this again for each IFO with a layer break. Run Get VTS Sectors when you're done, although it may not be necessary.

Yep, it takes a lot longer now, but it cleans and validates the IFO.

Then burn!

Robert

schlaufer
18th February 2003, 18:55
Originally posted by mikegun

p.p.s I suggest to specify an output folder so ifoedit didn't get confused by the pdixtract.exe

New version (1.2) uploaded, see first posting of this thread. ;)

BrandonClaps
18th February 2003, 19:08
hey man, can u make this GUI based instead of command line?

Pratticus
18th February 2003, 21:57
Is it absolutely necessary to run IFOEdit on the resultant .ifo files?

valnar
18th February 2003, 22:07
Originally posted by Pratticus
Is it absolutely necessary to run IFOEdit on the resultant .ifo files?

I am not sure yet. I am awaiting (in another thread) some answers from the Ifoedit gurus for an answer to that question.

Robert

DVD Maniac
18th February 2003, 23:07
Which VOB Extras run do you mean? Keep vob's or streams? In any case I do not think it will make any difference to the resulting VTS's, but the Get VTS sectors step is probably vital. I guess we need a steer from the Ifoedit guru's (not Derrow by any chance?)

WPELLE
19th February 2003, 16:46
I've made a very simple GUI for pdixtract. I'm attaching it to my post.

With it you can browse for the .pdi file or just type the path in manually. Then just browse or type in the destination folder and hit
Extract.

Alternately you can press Make ISO to make an ISO of the pdi-files.

Make sure that you copy pdixtract.exe and pdi2iso.exe to the same directory as pdiGUI.exe.

It's written in VB6 so you might need the VB runtimes to use it.

EDIT: New version. It's now possible to choose output directory.

EDIT: Yet another version. It's now possible to write an ISO instead of extracting the files if pdi2iso.exe is placed in the same directory as pdiGUI.

DVD Maniac
20th February 2003, 12:09
Thanks for writing this - Just tried the GUI and it does not appear to work as instructed. Guess I need the VB runtimes. I hate downloading stuff from Microsoft as it almost always screws up my system - do you have a source?

JJF007
20th February 2003, 13:06
Thanks for that nice tool! I tried to extract two pdi sets without problems, but now i got twice time the same error on one move (encoded twice, because of final size)

I get out:

writing VIDEO_TS (24576 bytes).
writing (24576 bytes) .Bad file number

Thats what i get after doing -l

[ 548] VIDEO_TS.BUP 24576 20. 2.2003 10:58:14
[ 536] VIDEO_TS.IFO 24576 20. 2.2003 10:58:14
[ 78874] VTS_01_0.BUP 69632 20. 2.2003 11:03:28
[ 560] VTS_01_0.IFO 69632 20. 2.2003 10:58:14
[ 594] VTS_01_0.VOB 159848448 20. 2.2003 11:03:24
[ 78645] VTS_01_1.VOB 468992 20. 2.2003 11:03:28
[1698518] VTS_02_0.BUP 81920 20. 2.2003 12:49:22
[ 78908] VTS_02_0.IFO 81920 20. 2.2003 11:03:28
[ 78948] VTS_02_0.VOB 157696 20. 2.2003 11:03:28
[ 79025] VTS_02_1.VOB 1073739776 20. 2.2003 11:39:20
[ 603312] VTS_02_2.VOB 1073739776 20. 2.2003 12:12:04
[1127599] VTS_02_3.VOB 1073739776 20. 2.2003 12:45:08
[1651886] VTS_02_4.VOB 95502336 20. 2.2003 12:46:22
[1830701] VTS_03_0.BUP 28672 20. 2.2003 13:05:12
[1698558] VTS_03_0.IFO 28672 20. 2.2003 12:49:22
[1698572] VTS_03_0.VOB 157696 20. 2.2003 12:49:22
[1698649] VTS_03_1.VOB 270442496 20. 2.2003 13:05:02
[1925321] VTS_04_0.BUP 26624 20. 2.2003 13:17:10
[1830715] VTS_04_0.IFO 26624 20. 2.2003 13:05:12
[1830728] VTS_04_0.VOB 157696 20. 2.2003 13:05:12
[1830805] VTS_04_1.VOB 193568768 20. 2.2003 13:17:06
[2001716] VTS_05_0.BUP 24576 20. 2.2003 13:26:28
[1925334] VTS_05_0.IFO 24576 20. 2.2003 13:17:10
[1925346] VTS_05_0.VOB 157696 20. 2.2003 13:17:10
[1925423] VTS_05_1.VOB 156248064 20. 2.2003 13:26:26
[2058665] VTS_06_0.BUP 20480 20. 2.2003 13:32:22
[2001728] VTS_06_0.IFO 20480 20. 2.2003 13:26:28
[2001738] VTS_06_0.VOB 157696 20. 2.2003 13:26:30
[2001815] VTS_06_1.VOB 116428800 20. 2.2003 13:32:20
[2094215] VTS_07_0.BUP 18432 20. 2.2003 13:36:22
[2058675] VTS_07_0.IFO 18432 20. 2.2003 13:32:22
[2058684] VTS_07_0.VOB 157696 20. 2.2003 13:32:22
[2058761] VTS_07_1.VOB 72609792 20. 2.2003 13:36:22
[2130058] VTS_08_0.BUP 18432 20. 2.2003 13:40:22
[2094224] VTS_08_0.IFO 18432 20. 2.2003 13:36:22
[2094233] VTS_08_0.VOB 157696 20. 2.2003 13:36:24
[2094310] VTS_08_1.VOB 73211904 20. 2.2003 13:40:22
[2178184] VTS_09_0.BUP 20480 20. 2.2003 13:46:00
[2130067] VTS_09_0.IFO 20480 20. 2.2003 13:40:22
[2130077] VTS_09_0.VOB 157696 20. 2.2003 13:40:24
[2130154] VTS_09_1.VOB 98365440 20. 2.2003 13:45:26
[2205943] VTS_10_0.BUP 18432 20. 2.2003 13:48:14
[2178194] VTS_10_0.IFO 18432 20. 2.2003 13:46:00
[2178203] VTS_10_0.VOB 157696 20. 2.2003 13:46:00
[2178280] VTS_10_1.VOB 56653824 20. 2.2003 13:48:14
[2206267] VTS_11_0.BUP 18432 20. 2.2003 13:48:16
[2205952] VTS_11_0.IFO 18432 20. 2.2003 13:48:14
[2205961] VTS_11_0.VOB 157696 20. 2.2003 13:48:14
[2206038] VTS_11_1.VOB 468992 20. 2.2003 13:48:16
[ 548] 24576 20. 2.2003 10:58:14
[ 536] 24576 20. 2.2003 10:58:14
[ 78874] 69632 20. 2.2003 11:03:28
[ 560] 69632 20. 2.2003 10:58:14
[ 594] 159848448 20. 2.2003 11:03:24
[ 78645] 468992 20. 2.2003 11:03:28
[1698518] 81920 20. 2.2003 12:49:22
[ 78908] 81920 20. 2.2003 11:03:28
[ 78948] 157696 20. 2.2003 11:03:28
[ 79025] 1073739776 20. 2.2003 11:39:20
[ 603312] 1073739776 20. 2.2003 12:12:04
[1127599] 1073739776 20. 2.2003 12:45:08
[1651886] 95502336 20. 2.2003 12:46:22
[1830701] 28672 20. 2.2003 13:05:12
[1698558] 28672 20. 2.2003 12:49:22
[1698572] 157696 20. 2.2003 12:49:22
[1698649] 270442496 20. 2.2003 13:05:02
[1925321] 26624 20. 2.2003 13:17:10
[1830715] 26624 20. 2.2003 13:05:12
[1830728] 157696 20. 2.2003 13:05:12
[1830805] 193568768 20. 2.2003 13:17:06
[2001716] 24576 20. 2.2003 13:26:28
[1925334] 24576 20. 2.2003 13:17:10
[1925346] 157696 20. 2.2003 13:17:10
[1925423] 156248064 20. 2.2003 13:26:26
[2058665] 20480 20. 2.2003 13:32:22
[2001728] 20480 20. 2.2003 13:26:28
[2001738] 157696 20. 2.2003 13:26:30
[2001815] 116428800 20. 2.2003 13:32:20
[2094215] 18432 20. 2.2003 13:36:22
[2058675] 18432 20. 2.2003 13:32:22
[2058684] 157696 20. 2.2003 13:32:22
[2058761] 72609792 20. 2.2003 13:36:22
[2130058] 18432 20. 2.2003 13:40:22
[2094224] 18432 20. 2.2003 13:36:22
[2094233] 157696 20. 2.2003 13:36:24
[2094310] 73211904 20. 2.2003 13:40:22
[2178184] 20480 20. 2.2003 13:46:00
[2130067] 20480 20. 2.2003 13:40:22
[2130077] 157696 20. 2.2003 13:40:24
[2130154] 98365440 20. 2.2003 13:45:26
[2205943] 18432 20. 2.2003 13:48:14
[2178194] 18432 20. 2.2003 13:46:00
[2178203] 157696 20. 2.2003 13:46:00
[2178280] 56653824 20. 2.2003 13:48:14
[2206267] 18432 20. 2.2003 13:48:16
[2205952] 18432 20. 2.2003 13:48:14
[2205961] 157696 20. 2.2003 13:48:14
[2206038] 468992 20. 2.2003 13:48:16


Thats weird, because after displaying all files it restarts but without the filenames! The Movie is "Sum of all Fears" German!

WPELLE
20th February 2003, 14:03
Originally posted by DVD Maniac
Thanks for writing this - Just tried the GUI and it does not appear to work as instructed. Guess I need the VB runtimes. I hate downloading stuff from Microsoft as it almost always screws up my system - do you have a source?

If you want the sourcecode just mail me and i'll send it to you.

Here's the runtime for VB6 (1MB)
http://www.karenware.com/progs/vbrun60-setup.exe

schlaufer
20th February 2003, 14:09
@JJF007:

This is really weird, it seems that you ran into a shadow of the directory without filenames. I'v added a check against it and put a new
version (1.3) (http://www.freewebs.com/schlaufer/pdixtract.zip) on my homepage.

Please check if this solve your problem and give me an update (that I may update the version at the top of this thread too).

Good luck,
schlaufer

JJF007
20th February 2003, 14:50
@schlaufer:

whooooo! Fast work - and it works perfect .. thanks for the !=null :)


Greets

CrazyIvan007

schlaufer
20th February 2003, 18:05
New version (1.3) uploaded, see first posting of this thread.

armyb77
21st February 2003, 01:03
Hi I was just wondering if you can ad the capability to extract the pdi file into another drive? If it is already possible I haven't figured out the proper command prompt trigger. I have to hard drives, one drive I use for authoring, and one I use for burning, so I want to extract the files from the PDI from drive D to Drive E, this would speed up the extraction time alot for me.

Thanks
Armyb77

schlaufer
21st February 2003, 10:06
Hi armyb77,

that's very easy. You can either change the drive of the command shell to E: and specify D: in the file to extract or use the -d/-m switch and specify E: as destination. The easiest way is to specify the full paths in the command arguments. Assume your movie is in D:\MOVIE.pdi* and you want to extract into E:\MOVIE\VIDEO_TS you can type

pdixtract -m E:\MOVIE -v D:\MOVIE

-m would create the directory E:\MOVIE -v would create E:\MOVIE\VIDEO_TS and D:\MOVIE.pdi* is the movie to extract.

Cheers,
schlaufer

P.S.: the -v switch requires version 1.3, the -m switch at least version 1.2 of pdixtract

WPELLE
21st February 2003, 11:23
I updated the GUI for this great program. It's now possible to choose output directory e.g another drive and so on.

I attached it to my post on the first page of this thread.

DVD Maniac
21st February 2003, 12:26
For some reason your attachment link is not there on your first post. Can you do another post? Also - might I suggest you ask Mpucoder to put your great littel up in the sticky on the front of this forum.

Thanks

WPELLE
21st February 2003, 15:19
It took a while for it to be attached, but it's there now.

Since mpucoder has already linked to this thread in the InstantCopy helpprogs thread maybe it should be enough.

KaoS
21st February 2003, 15:40
Would it be possible for one of you to add in the ability to add a AUDIO_TS directory to the ISO as it converts it?

That would help those of us that have DVD players that require that directory to exist (since InstantCopy does not include that directory)

My main DVD player is fine, but my player in the bedroom requires that directory and it would be so nice if one of these programs could just stick it in there during the conversion to ISO

Thanks

I posted this in the other thread also for the other author that does a utility like this, but I was not sure if you were reading that thread so I am posting it here also

WPELLE
21st February 2003, 15:43
schlaufer's utility does not make an ISO, it extracts the files from the pdi's.

KaoS
21st February 2003, 15:48
He actually did make a utility that does a conversion (see Helper Programs sticky)

I posted my request to him here because the other thread dealing with that utility is umm... dead :) and I know he reads this thread

REECYCUP
21st February 2003, 15:49
kaos

what dvd player do you have in the bedroom?
im looking into which dvd players require a audio_tsfolder

mpucoder
21st February 2003, 15:50
@Kaos - one request is enough. Two requests is frowned upon, but three times?

After extraction you will be working with folders, so you can add your own empty AUDIO_TS with your favorite burner program.

I'm no WinRar expert, but is it not possible to add a folder to an iso with it?

KaoS
21st February 2003, 15:51
To be honest with you, I am not sure of the brand (it is pretty old). I will check into it when I get home and let you know

REECYCUP
21st February 2003, 15:52
thanks i have one of the first rca's
still chugging along

KaoS
21st February 2003, 15:53
Originally posted by mpucoder
@Kaos - one request is enough. Two requests is frowned upon, but three times?

Three times?

Once in a thread about why it would not play in someones DVD player, I mentioned that it would be nice if there was something that did that.

Then I requested it to each author

If that is excessive to you.. maybe I will just become like some of the other users of this forum and start flaming everyone and every program. That seems to be excepted

WPELLE
21st February 2003, 17:02
I've made further changes to the pdixtracter GUI. Now it can use schlaufers other program pdi2iso (http://forum.doom9.org/attachment.php?s=&postid=262272) to convert the pdi files to an ISO.

The new version has been attached to my previous post on the first page of this thread.

schlaufer
21st February 2003, 17:08
@WPELLE
check your pm please.

greets,
schlaufer

KaoS
21st February 2003, 17:09
Originally posted by WPELLE
I've made further changes to the pdixtracter GUI. Now it can use schlaufers other program pdi2iso (http://forum.doom9.org/attachment.php?s=&postid=262272) to convert the pdi files to an ISO.

The new version has been attached to my previous post on the first page of this thread.

Knowing is half the battle :)

Thanks for the GUI btw, pretty nice

marcovan
21st February 2003, 17:30
Hi there. The PDIGUI is no longer attached to the first post. Where can I get it?

WPELLE
21st February 2003, 17:43
It's temporary availble here until a moderator approves the attachment.

http://members.chello.se/jonas.thornqvist/pdiGUI03.zip

fooljoe
27th February 2003, 20:37
I've tried making backups with InstantCopy, and each time it crashes on the burning stage. However, I'm not left with any .pdi files, but 5 or so .tmp files (something like cdw.tmp, cdw1.tmp01, etc.) Has anyone seen this before, and is there anyway to extract video_ts compatible files from these? I suspect they're basically just .vobs, since most of them are about 1 gb each, but simply changing the suffix doesn't work.

thanks

WPELLE
27th February 2003, 20:47
Did you rename them like:
cdw.pdi
cdw.pdi01
cdw.pdi02
cdw.pdi03

fooljoe
27th February 2003, 20:53
no, I didn't try that, but I did try running pdixtract on them with no success. I haven't seen the .pdi images created by IC, but from reading these posts I get the idea that it's just one big file for one dvd, not several files like I have. Is that correct?

WPELLE
27th February 2003, 21:03
They are suppose to be several files, they split at 1GB.

Just rename your files as I explained and then run either pdixtract or me and schlaufers new tool PDITool to extract the files.

I think it should work.

fooljoe
27th February 2003, 22:24
wpelle, that did the trick. the pditool didn't work, asking for some dll (mentioned in another post), and installing the vb runtimes didn't help. but i did get it to extract with pdixtract.

cheers

goober22
28th February 2003, 04:58
I haven't had any luck with pdiXtract or pdi2iso. Both lock up on me. pdiXtract usually locks up on the last vob in the pdi set. I have to reset my pc & when I check the files, the last vob is "0" in size.

pdi2iso seems to go about 1/4 to 1/2 way & then locks up.

I have been using the other pdi2iso (same name, diff app) to convert it to an iso & then extract. Extra steps.

I tried the new pditool that was posted but it locked up as well (about 1/4 the way in)

WinXP Pro SP1, 1gigmem, 100gigHD - 60 free.

schlaufer
28th February 2003, 08:47
That's strange.

There is nothing special in the code for any particular file position (except the transition from on .pdi file to another). So if it works on the first parts, it should work on the following parts too.

Even if it sounds weird to you, did you consider a file system check? And please check the compatibility options in the file properties dialog for pdixtract.exe. There should be nothing checked.

Sorry for the short reply, but I currently see no obvious point to check for either program, PC or OS faults.

goober22
28th February 2003, 16:45
@schlaufer

Hmmmm. I don't know what's up?! No compatibilty options are set on either program. I went ahead & ran a system file check, but it still does it with both your programs. I guess they do not like my 'puter!

I can use the one by MrWGT (pdi2iso) but your's lock up my PC totally.

PdiXtract always locks up on the very last vob in the set. After a reset, it is always "0" in size. Pdi2iso goes to different %'s but locks up at some point. Even the new pdiTool locks up. i tried it once and it did it on vob set 4 out of a 8 vob file (vob 7 was the movie)

:confused: Goob

RB
23rd April 2003, 09:57
Having a problem with pdixtract here as well. Here is the log:
E:\DVD2DVD-R\Mittermeier\Disk 1>pdixtract -d "D:\DVD\Back To Life" "Disk 1.pdi"
$Id: pdixtract.c,v 1.5 2003/02/27 15:08:50 smurf Exp $

[extent ] File Name Size Date Time
[ 345] VIDEO_TS.BUP 12288 23. 4.2003 10:58:08
[ 319] VIDEO_TS.IFO 12288 23. 4.2003 10:58:06
[ 325] VIDEO_TS.VOB 40960 23. 4.2003 10:58:08
[3506244] VTS_01_0.BUP 61440 23. 4.2003 11:20:16
[ 351] VTS_01_0.IFO 61440 23. 4.2003 10:58:08
[ 381] VTS_01_0.VOB 707590144 23. 4.2003 11:11:00
[ 345884] VTS_01_1.VOB 1073739776 23. 4.2003 11:12:20
[ 870171] VTS_01_2.VOB 1073739776 23. 4.2003 11:14:02
[1394458] VTS_01_3.VOB 1073739776 23. 4.2003 11:15:12
[1918745] VTS_01_4.VOB 1073739776 23. 4.2003 11:16:26
[2443032] VTS_01_5.VOB 1073739776 23. 4.2003 11:17:14
[2967319] VTS_01_6.VOB 1073739776 23. 4.2003 11:19:02
[3491606] VTS_01_7.VOB 29978624 23. 4.2003 11:19:04
[3728932] VTS_02_0.BUP 22528 23. 4.2003 11:31:12
[3506274] VTS_02_0.IFO 22528 23. 4.2003 11:20:16
[3506285] VTS_02_0.VOB 455970816 23. 4.2003 11:31:00
[3728927] VTS_02_1.VOB 10240 23. 4.2003 11:31:10
writing D:\DVD\Back To Life\VIDEO_TS.IFO (6 extents)
writing D:\DVD\Back To Life\VIDEO_TS.VOB (20 extents)
writing D:\DVD\Back To Life\VIDEO_TS.BUP (6 extents)
writing D:\DVD\Back To Life\VTS_01_0.IFO (30 extents)
writing D:\DVD\Back To Life\VTS_01_0.VOB (345503 extents) .................................
writing D:\DVD\Back To Life\VTS_01_1.VOB (524287 extents) .................(Disk 1.pdi01).................................
writing D:\DVD\Back To Life\VTS_01_2.VOB (524287 extents) .................(Disk 1.pdi02).................................
writing D:\DVD\Back To Life\VTS_01_3.VOB (524287 extents) .................(Disk 1.pdi03).................................
writing D:\DVD\Back To Life\VTS_01_4.VOB (524287 extents) .................(Disk 1.pdi04).................................
writing D:\DVD\Back To Life\VTS_01_5.VOB (524287 extents) .................(Disk 1.pdi05).................................
writing D:\DVD\Back To Life\VTS_01_6.VOB (524287 extents) .................(Disk 1.pdi06).................................
writing D:\DVD\Back To Life\VTS_01_7.VOB (14638 extents) .
writing D:\DVD\Back To Life\VTS_01_0.BUP (30 extents)
writing D:\DVD\Back To Life\VTS_02_0.IFO (11 extents)
writing D:\DVD\Back To Life\VTS_02_0.VOB (222642 extents) ...............(Disk 1.pdi07)during read of extents: No error

VTS_02_0_VOB is only partially saved when this happens. I also tried PDI2ISO by MrWGT but it has a similar problem in that it creates the ISO without errors, but when I mount it in Daemon Tools, I get read errors when trying to copy off the VTS_02_* files. Any idea what's going wrong?

Yes, I know the PDIs are too large to fit on a DVD-R but I really only transcoded the menu and left the movie at 100% because I wanted to encode the main title with CCE and then merge it in via IFOUpdate and IFOEdit.

schlaufer
23rd April 2003, 10:36
Originally posted by RB
Having a problem with pdixtract here as well. Here is the log:
E:\DVD2DVD-R\Mittermeier\Disk 1>pdixtract -d "D:\DVD\Back To Life" "Disk 1.pdi"
$Id: pdixtract.c,v 1.5 2003/02/27 15:08:50 smurf Exp $

writing D:\DVD\Back To Life\VTS_02_0.VOB (222642 extents) ...............(Disk 1.pdi07)during read of extents: No error

Sorry, I guess this error message is a little misleading. Actually this "No error" should be interpreted as "short read", i.e. Disk1.pdi07 simply ends before the file VTS_02_0.VOB was completed. Naturally pdi2iso/daemontools neither can extract non-existant data. It seems to mee that IC7 crashed during encoding leaving only partial data.

IC7 sometimes has problems with very low settings for the menu - try to increases the percentage for the menus.

But, if you only want to compress menus and extras, I suggest you should try DVD95Copy (trial version suffices). It does a real good job compressing menu stuff. The resulting menus are far smaller than the menus generated by IC7 and are still watchable, sometimes better quality than the IC7 menus of larger size. The only drawback is, that dvd95copy sometimes removes the audio from the menus.

Cheers,

RB
23rd April 2003, 12:17
Thanks for the quick response. No, IC didn't crash, it completed without errors (I set the menus to 60% because they are really huge, 1.6 GB).

Actually, I fixed the problem by recompiling your source with the BUFFSIZE constant reduced to 64k, seeing that you are allocating 20 megs on the stack didn't make me feel save anyway :). I'm not completely sure how that fixed the problem, but the following piece of code (in copy_extents(), near line 248) looks suspicious:

if(BUFFSIZE>read(fin,buffer,BUFFSIZE))
errexit("during read of extents");

Can't this easily be true when you are near the end of the current .pdi or the current .pdi is just smaller than BUFFSIZE? Shouldn't you check for a real error returned from read() instead (i.e. return value is < 0)?

FYI, Disk 1.pdi07 is 120.784.689 bytes, pdixtract seems to fail as soon as it tries to read from the file for the first time...

schlaufer
23rd April 2003, 13:19
Originally posted by RB
Actually, I fixed the problem by recompiling your source with the BUFFSIZE constant reduced to 64k, seeing that you are allocating 20 megs on the stack didn't make me feel save anyway :). I'm not completely sure how that fixed the problem, but the following piece of code (in copy_extents(), near line 248) looks suspicious:

if(BUFFSIZE>read(fin,buffer,BUFFSIZE))
errexit("during read of extents");

Can't this easily be true when you are near the end of the current .pdi or the current .pdi is just smaller than BUFFSIZE? Shouldn't you check for a real error returned from read() instead (i.e. return value is < 0)?

This code is correct because this is the loop entered if (and only if) there are at least BUFFSIZE bytes to copy. You have to look at the whole chunk:

while(no_extents>BUFFSIZE){
if(BUFFSIZE>read(fin,buffer,BUFFSIZE))
errexit("during read of extents");
if(BUFFSIZE>write(fout,buffer,BUFFSIZE))
errexit("during write of extents");
no_extents-=BUFFSIZE;
putc('.',stderr);
}

;)
And I do not allocate the buffer on the stack. Declaring the buffer static on top frame should allocate it in the block storage segment - at least this is the way it is done since the old days on all reasonable computers (Unix, Atari ST, Amiga, VMS,...). It is possible, that M$ screwed up reasonable conventions again. ;/&(/)=

There is already a version with reduced buffer size linked from the PDITool thread to my page http://www.freewebs.com/schlaufer/pdixtract-smallbuf.zip to solve goober22's lockup problems.

I am a Unix/Linux programmer and in fact, pdi2iso and pdixtract are ports from Linuy made with the OpenWatcom compiler on Windows. I stille hesitate to reduce the buffer size in general because this could result in disk trashing if source and destination are on the same hard drive. There will be version forthcoming which allocates the buffer on the heap, looking if this solves the problem. If at all possible, pleasep keep the .pdi files until this evening (MET) until I have access to my build machine.

Greetings,
schlaufer

RB
23rd April 2003, 13:54
OK, thanks. I must admit I didn't look into the code in great detail :). I'll keep .pdi set as long as you need it. You are probably right about where the buffer memory is allocated, I never checked this for VC++.

About the buffer size in general: I don't think a smaller buffer will lead to disk trashing. Remember there is always the Windows disk cache inbetween and it's fairly good at caching disk reads/writes.

I can't download this version with the small buffer from your site, it simply redirects me to this thread...

RB
23rd April 2003, 14:33
Here is an interesting update:

Turns out that pdixtract works fine for this pdi set even with the original buffer size if I recompile it in VC++ 6.0 SP5 but only when I build it in debug mode. When I build in release mode and even when using a dynamically allocated buffer, using wildcards doesn't seem to work. For instance, with the release executable, an

pdixtract -d d:\temp "Disk 1.pdi" VTS_02*

results in
writing d:\temp\VTS_02_0.IFO (11 extents) (Disk 1.pdi01)(Disk
1.pdi02)(Disk 1.pdi03)(Disk 1.pdi04)(Disk 1.pdi05)(Disk 1.pdi06)
during skip of .pdi-data: Bad file descriptor

Really strange, this does not happen with the debug executable. What's the default structure alignment in Watcom C++? VC++ uses 8 bytes, maybe the iso_directory_record struct is incorrectly aligned for me?

schlaufer
23rd April 2003, 20:32
Structure alignment in WatCom ist 32 bit I think, but I am not sure. Propably MS-C++ has a so-called "extension" to make a structure packed, you may add this to the definition of the struct iso_directory_record, the only struct in the program where alignment matters.

I've just put a new version of pdixtract on my web-site: http://www.freewebs.com/schlaufer/pdixtract.zip. It now dynamically allocates the buffer from the heap and has a new option -b <buffsize_k> to adjust i/o buffer size at runtime.

Please check this out and test it.

If you have difficulties downloading the file from within the forum, just copy the link address and paste it into the "open loaction" dialog of your browser. This is a known protection on doom9.org.

Cheers,
schlaufer

RB
23rd April 2003, 21:02
Thanks for the update! I tried it and I just can't make the error go away, no matter what I set the buffer size to! It still fails with
..........................................(Disk 1.pdi07)during read of extents: No error
However, as I said, my "custom debug build" of the source works fine :confused: Let me know if you need more information. Here is the complete PDI set:23.04.2003 09:31 1.073.741.520 Disk 1.pdi
23.04.2003 09:31 1.073.741.824 Disk 1.pdi01
23.04.2003 09:31 1.073.741.824 Disk 1.pdi02
23.04.2003 09:31 1.073.741.824 Disk 1.pdi03
23.04.2003 09:31 1.073.741.824 Disk 1.pdi04
23.04.2003 09:31 1.073.741.824 Disk 1.pdi05
23.04.2003 09:31 1.073.741.824 Disk 1.pdi06
23.04.2003 09:31 120.748.689 Disk 1.pdi07

Here are the contents according to "pdixtract -l":
[extent ] File Name Size Date Time
[ 345] VIDEO_TS.BUP 12288 23. 4.2003 10:58:08
[ 319] VIDEO_TS.IFO 12288 23. 4.2003 10:58:06
[ 325] VIDEO_TS.VOB 40960 23. 4.2003 10:58:08
[3506244] VTS_01_0.BUP 61440 23. 4.2003 11:20:16
[ 351] VTS_01_0.IFO 61440 23. 4.2003 10:58:08
[ 381] VTS_01_0.VOB 707590144 23. 4.2003 11:11:00
[ 345884] VTS_01_1.VOB 1073739776 23. 4.2003 11:12:20
[ 870171] VTS_01_2.VOB 1073739776 23. 4.2003 11:14:02
[1394458] VTS_01_3.VOB 1073739776 23. 4.2003 11:15:12
[1918745] VTS_01_4.VOB 1073739776 23. 4.2003 11:16:26
[2443032] VTS_01_5.VOB 1073739776 23. 4.2003 11:17:14
[2967319] VTS_01_6.VOB 1073739776 23. 4.2003 11:19:02
[3491606] VTS_01_7.VOB 29978624 23. 4.2003 11:19:04
[3728932] VTS_02_0.BUP 22528 23. 4.2003 11:31:12
[3506274] VTS_02_0.IFO 22528 23. 4.2003 11:20:16
[3506285] VTS_02_0.VOB 455970816 23. 4.2003 11:31:00
[3728927] VTS_02_1.VOB 10240 23. 4.2003 11:31:10
And these are the files extracted via "pdixtract -b 64 -d d:\temp "Disk 1.pdi" VTS_02*" after the error occurs:
23.04.2003 21:55 22.528 VTS_02_0.IFO
23.04.2003 21:55 335.321.088 VTS_02_0.VOB

Steel
25th May 2003, 18:46
I am having this same problem with not being able to extract files. I get the same "no error" message. IC encoded just fine, no crash.

Steel
25th May 2003, 19:21
RB, could you post your custom debug build for me, I am having the same trouble as you were.

RB
26th May 2003, 12:01
I've uploaded it here (http://home.t-online.de/home/340044300675/pdixtract_debug.zip).