Progress report:
Running these tests is a very slow process but I have made some steps forward.
So far I have reached the following conclusions (but there is much more testing to come):
1) The most reliable tool for getting data off the dvd disc is vobcopy which produced 2x 2048MB and 1x1024MB vobs.
In my case (with what appears to be a damaged dvd) the other tools such as pburn, mplayer and pdvdrsab left large sections of the vob data unread, ignored or truncated.
2) Now that I can view the entirety of the film data within the 3 vobs created by vobcopy I can see that the data stream contains 4 different "episodes". (I won't call these "chapters" as I think that would be misleading and has a specific meaning in regard to dvd structure).
I initially tried to shrink these vobs with vamps but have decided that vamps is an unreliable tool and I am not going to use it. That "unreliability" is probably due to a combination of damaged dvd, complexity of the data structure within the vob files, and/or possibly my incorrect usage of vamps commandline parameters/arguments.
(Vamps worked fine on another dvd which contained a much shorter film and no dvd scratches)
So now that I see the dvd contains 4 episodes spread across 3 vobs I wanted to find a way to cut and concatenate the vobs as required (ie: make 4 vobs from 3) instead of trying to shrink them unreliably.
I tried to use ffmpeg to do this trimming (ffmpeg has no trouble clipping and joining mkv, avi etc) but it was not capable of trimming at the correct time boundaries I selected in the vobs. There were error messages about timestamps being irregular and some functions being deprecated:
Code: Select all
Input #0, mpeg, from '/root/TESTin.vob':
Duration: 00:13:12.28, start: 0.287267, bitrate: 21683 kb/s
Stream #0:0[0x1bf]: Data: dvd_nav_packet
Stream #0:1[0x1e0]: Video: mpeg2video (Main), yuv420p(tv), 720x576 [SAR 64:45 DAR 16:9], 25 fps, 25 tbr, 90k tbn, 50 tbc
Stream #0:2[0x20]: Subtitle: dvd_subtitle
Stream #0:3[0x80]: Audio: ac3, 48000 Hz, stereo, fltp, 192 kb/s
Stream #0:4[0x81]: Audio: ac3, 48000 Hz, stereo, fltp, 192 kb/s
Stream #0:5[0x82]: Audio: ac3, 48000 Hz, stereo, fltp, 192 kb/s
Stream #0:6[0x83]: Audio: ac3, 48000 Hz, stereo, fltp, 192 kb/s
Stream #0:7[0x84]: Audio: ac3, 48000 Hz, stereo, fltp, 192 kb/s
Stream #0:8[0x85]: Audio: ac3, 48000 Hz, stereo, fltp, 192 kb/s
[svcd @ 0xa9c5460] Using AVStream.codec to pass codec parameters to muxers is deprecated, use AVStream.codecpar instead.
Last message repeated 1 times
[svcd @ 0xa9c5460] VBV buffer size not set, using default size of 130KB
If you want the mpeg file to be compliant to some specification
Like DVD, VCD or others, make sure you set the correct buffer size
Output #0, svcd, to 'TESTout.vob':
Metadata:
encoder : Lavf57.41.100
Stream #0:0: Video: mpeg2video, yuv420p(tv), 720x576 [SAR 64:45 DAR 16:9], q=2-31, 25 fps, 25 tbr, 90k tbn, 50 tbc
Stream #0:1: Audio: ac3, 48000 Hz, stereo, 192 kb/s
Stream mapping:
Stream #0:1 -> #0:0 (copy)
Stream #0:3 -> #0:1 (copy)
Press [q] to stop, [?] for help
[svcd @ 0xa9c5460] Timestamps are unset in a packet for stream 0. This is deprecated and will stop working in the future. Fix your code to set the timestamps properly
frame= 390 fps=0.0 q=-1.0 Lsize= 13466kB time=00:00:15.00 bitrate=7354.2kbits/s speed= 184x
video:12930kB audio:369kB subtitle:0kB other streams:0kB global headers:0kB muxing overhead: 1.256009%
It appears that it is common for timestamps to jump all over the place when handling files from dvds (I suspect this is part of a deliberate strategy to make DVDs hard or impossible to duplicate).
I found the following link which describes such an issue:
https://superuser.com/questions/1389922 ... o-in-and-o
The suggested solution was to use avidemux to manipulate the vobs.
This was very successful. I was able to see all of the data clearly, identify the points at which each episode began and ended - and to save the resulting files as mp4s. Timestamps are now good.
(I had also found links advising how to use ffmpeg to re-format the vobs and rebuild the timestamps without it re-encoding them but I had no success with that approach)
So now I have 4 mp4 files that contain the whole of the 4 episodes that were on the DVD. At least this is first base - even though it is not the route I expected to travel.
My inability to properly manipulate the vobs the way I originally intended is likely due to the dvd scratching. Note to wife: 2 year old grandchildren holding DVDs do not belong near sandpits.
One of my next steps will be how to get from this first base of separate mp4 files back to one full DVD containing 4 episodes. But that will be a different thread as this one was mostly about using Vamps to shrink the ripped dvd but my conclusion is that using vamps may not be a reliable approach.
Although I have now got to first base I still have a number of unresolved questions regarding the best way to get a dvd ripped and shrunk so I have further tests to perform:
1) rcrsn51 » Fri Jun 18, 2021 9:16 pm
According to the vobcopy man page, it will generate a single file with the --large-file option.
2) rcrsn51 » Sat Jun 19, 2021 6:17 am
If the objective is still to make a new DVD, you could skip vamps and try converting the VOB file to an MP4 with ffmpeg. If that gets you a playable file, you could convert it back to a hopefully smaller VOB and author/burn it.
ffmpeg -y -i input.vob -vf format=yuv420p -vcodec libx264 -acodec aac output.mp4
ffmpeg -y -i output.mp4 -target pal-dvd -aspect 4:3 final.vob
3) wizard » Sat Jun 19, 2021 8:11 am
using dpup stretch 7,5 rc5 ran a test as follows:
-DVDrip_mplayer.sh used to rip original movie to single file, test.vob = 7.4gb
-use pdvdrsab shrink size set to 3900
-test-shrank.vob= 4.4gb and is full movie
(I thought my copy of Dpup Stretch was the latest but it does not appear to include DVDrip_mplayer.sh) Need to look more closely at this.
4) Test Devede
5) Test Handbrake
6) Work out why many sites say vob max size is 1GB, yet vobcopy creates 2GB vobs quite happily. (Is this normal?)
Thank you all for the help so far - I will report back once I finish the other tests.
Any further suggestions or questions gratefully received.