Lossless DVB-T Transport Stream from PVR to DVD

classic Classic list List threaded Threaded
15 messages Options
Reply | Threaded
Open this post in threaded view
|

Lossless DVB-T Transport Stream from PVR to DVD

Emzo
Appologies if some of my knowledge is incorrect, but I need some help
figuring out how to use ffmpeg to losslessly (that's the important bit!)
convert an MPEG2 transport stream from a DVB-T PVR (Humax T9200) to a
VOB file suitable for burning onto a DVD.

I'm running Mac OS X, and I've successfully done this using a combination
of GUI tools to demux[1] the transport stream and the (re)mux[2] and burn
to DVD. However, I'd prefer to do this via command line tools ;-)

Am I right in thinking that ffmpeg is the appropriate tool for the job
(I'm tlking about the remuxing here, NOT burning the file to DVD
obviously), or will I require other tools?

How do you remux with ffmpeg - everything I've tried so far results in the
data being re-encoded, which reduces quality and wastes processor time!

Here's some info on the contents of one of the .ts files from the DVR:

  Duration: 00:09:19.6, start: 91593.231322, bitrate: 2388 kb/s
  Stream #0.0[0x1a11]: Video: mpeg2video, yuv420p, 544x576, 15000
kb/s, 25.00 fps(r)
  Stream #0.1[0x1a12](eng): Audio: mp2, 48000 Hz, stereo, 128 kb/s
  Stream #0.2[0x1a13](eng): Audio: mp2, 48000 Hz, mono, 64 kb/s
  Stream #0.3[0x1a16](eng): Subtitle: dvbsub

I only need streams #0.0 (video) and #0.1 (autio) and don't mind loosing
streams #0.2 (alternative audio for hearing impaired - usually blank
anyway) and #0.3 (subtitles).

So, does anyone know what arguments I need to pass to ffmpeg to achieve
lossless conversion? Ideally, I'd like it to generate a VIDEO_TS directory
filled with the .VOB container and the associated .IFO and .BUP files, so
that I can add those to a UDF disc image ready to burn to DVD.

Thanks for your help,

Emyr

[1] Project X - http://sourceforge.net/projects/project-x
[2] ffmpegX - http://www.ffmpegx.com
_______________________________________________
ffmpeg-user mailing list
[hidden email]
http://lists.mplayerhq.hu/mailman/listinfo/ffmpeg-user
Reply | Threaded
Open this post in threaded view
|

Re: Lossless DVB-T Transport Stream from PVR to DVD

Michel Bardiaux-2
Emyr Thomas a écrit :

> Appologies if some of my knowledge is incorrect, but I need some help
> figuring out how to use ffmpeg to losslessly (that's the important bit!)
> convert an MPEG2 transport stream from a DVB-T PVR (Humax T9200) to a
> VOB file suitable for burning onto a DVD.
>
> I'm running Mac OS X, and I've successfully done this using a combination
> of GUI tools to demux[1] the transport stream and the (re)mux[2] and burn
> to DVD. However, I'd prefer to do this via command line tools ;-)
>
> Am I right in thinking that ffmpeg is the appropriate tool for the job
> (I'm tlking about the remuxing here, NOT burning the file to DVD
> obviously), or will I require other tools?
>
> How do you remux with ffmpeg - everything I've tried so far results in the
> data being re-encoded, which reduces quality and wastes processor time!

Rule #1: never post vague problem reports like ït didnt work". Always
post the command line used, and its complete output messages.

>
> Here's some info on the contents of one of the .ts files from the DVR:
>
>   Duration: 00:09:19.6, start: 91593.231322, bitrate: 2388 kb/s
>   Stream #0.0[0x1a11]: Video: mpeg2video, yuv420p, 544x576, 15000
> kb/s, 25.00 fps(r)
>   Stream #0.1[0x1a12](eng): Audio: mp2, 48000 Hz, stereo, 128 kb/s
>   Stream #0.2[0x1a13](eng): Audio: mp2, 48000 Hz, mono, 64 kb/s
>   Stream #0.3[0x1a16](eng): Subtitle: dvbsub

Basically:

ffmpeg -i the.ts -vcodec copy -acodec copy -f dvd desired.vob

Now that will produce a VOB with 15mbits video. Is that acceptable for a
DVD? I dont know. Try (and let us know). If not, then you *have* to
re-encode. And yes, currently ffmpeg is unable to reduce the bitrate
without re-encoding.

ffmpeg.c in opt_target sets some more parameters, you might need to set
them too. Alternately try

ffmpeg -i the.ts -target dvd -vcodec copy -acodec copy desired.vob

>
> I only need streams #0.0 (video) and #0.1 (autio) and don't mind loosing
> streams #0.2 (alternative audio for hearing impaired - usually blank
> anyway) and #0.3 (subtitles).
>
> So, does anyone know what arguments I need to pass to ffmpeg to achieve
> lossless conversion? Ideally, I'd like it to generate a VIDEO_TS directory
> filled with the .VOB container and the associated .IFO and .BUP files, so
> that I can add those to a UDF disc image ready to burn to DVD.
>
ffmpeg cant help you for the IFO and BUP files, you need a DVD authoring
software for that.

--
Michel Bardiaux
R&D Director
T +32 [0] 2 790 29 41
F +32 [0] 2 790 29 02
E mailto:[hidden email]

Mediaxim NV/SA
Vorstlaan 191 Boulevard du Souverain
Brussel 1160 Bruxelles
http://www.mediaxim.com/
_______________________________________________
ffmpeg-user mailing list
[hidden email]
http://lists.mplayerhq.hu/mailman/listinfo/ffmpeg-user
Reply | Threaded
Open this post in threaded view
|

Re: Lossless DVB-T Transport Stream from PVR to DVD

Hervé-4
Michel Bardiaux a écrit :

> Emyr Thomas a écrit :
>> Appologies if some of my knowledge is incorrect, but I need some help
>> figuring out how to use ffmpeg to losslessly (that's the important bit!)
>> convert an MPEG2 transport stream from a DVB-T PVR (Humax T9200) to a
>> VOB file suitable for burning onto a DVD.
>>
>> I'm running Mac OS X, and I've successfully done this using a combination
>> of GUI tools to demux[1] the transport stream and the (re)mux[2] and burn
>> to DVD. However, I'd prefer to do this via command line tools ;-)
>>
>> Am I right in thinking that ffmpeg is the appropriate tool for the job
>> (I'm tlking about the remuxing here, NOT burning the file to DVD
>> obviously), or will I require other tools?
>>
>> How do you remux with ffmpeg - everything I've tried so far results in the
>> data being re-encoded, which reduces quality and wastes processor time!
>
> Rule #1: never post vague problem reports like ït didnt work". Always
> post the command line used, and its complete output messages.
>
>> Here's some info on the contents of one of the .ts files from the DVR:
>>
>>   Duration: 00:09:19.6, start: 91593.231322, bitrate: 2388 kb/s
>>   Stream #0.0[0x1a11]: Video: mpeg2video, yuv420p, 544x576, 15000
>> kb/s, 25.00 fps(r)
>>   Stream #0.1[0x1a12](eng): Audio: mp2, 48000 Hz, stereo, 128 kb/s
>>   Stream #0.2[0x1a13](eng): Audio: mp2, 48000 Hz, mono, 64 kb/s
>>   Stream #0.3[0x1a16](eng): Subtitle: dvbsub
>
> Basically:
>
> ffmpeg -i the.ts -vcodec copy -acodec copy -f dvd desired.vob
>
> Now that will produce a VOB with 15mbits video. Is that acceptable for a
> DVD? I dont know.


the written bitrate is too high for DVD specfs (DVD hardware buffer).
But it means nothing (this is only an information, you cannot be sure
it's the real one).
My DVB "from internet provider" is written as 8000k to 15000k.
In fact its peak-bitrate can reach 3000k (and average 2500k)


Try (and let us know). If not, then you *have* to
> re-encode. And yes, currently ffmpeg is unable to reduce the bitrate
> without re-encoding.
>
> ffmpeg.c in opt_target sets some more parameters, you might need to set
> them too. Alternately try
>
> ffmpeg -i the.ts -target dvd -vcodec copy -acodec copy desired.vob


...
the buffer size is  written in the elementary stream, I don't think a
"-vcodec copy" will change it (-traget will just change container and I
don't know if it's sufficient in this caase)



>> I only need streams #0.0 (video) and #0.1 (autio) and don't mind loosing
>> streams #0.2 (alternative audio for hearing impaired - usually blank
>> anyway) and #0.3 (subtitles).
>>
>> So, does anyone know what arguments I need to pass to ffmpeg to achieve
>> lossless conversion? Ideally, I'd like it to generate a VIDEO_TS directory
>> filled with the .VOB container and the associated .IFO and .BUP files, so
>> that I can add those to a UDF disc image ready to burn to DVD.
>>
> ffmpeg cant help you for the IFO and BUP files, you need a DVD authoring
> software for that.

bye
Hervé
_______________________________________________
ffmpeg-user mailing list
[hidden email]
http://lists.mplayerhq.hu/mailman/listinfo/ffmpeg-user
Reply | Threaded
Open this post in threaded view
|

Re: Lossless DVB-T Transport Stream from PVR to DVD

Michel Bardiaux-2
HervŽe a écrit :

> Michel Bardiaux a écrit :
>> Emyr Thomas a écrit :
>>> Appologies if some of my knowledge is incorrect, but I need some help
>>> figuring out how to use ffmpeg to losslessly (that's the important bit!)
>>> convert an MPEG2 transport stream from a DVB-T PVR (Humax T9200) to a
>>> VOB file suitable for burning onto a DVD.
>>>
>>> I'm running Mac OS X, and I've successfully done this using a combination
>>> of GUI tools to demux[1] the transport stream and the (re)mux[2] and burn
>>> to DVD. However, I'd prefer to do this via command line tools ;-)
>>>
>>> Am I right in thinking that ffmpeg is the appropriate tool for the job
>>> (I'm tlking about the remuxing here, NOT burning the file to DVD
>>> obviously), or will I require other tools?
>>>
>>> How do you remux with ffmpeg - everything I've tried so far results in the
>>> data being re-encoded, which reduces quality and wastes processor time!
>> Rule #1: never post vague problem reports like ït didnt work". Always
>> post the command line used, and its complete output messages.
>>
>>> Here's some info on the contents of one of the .ts files from the DVR:
>>>
>>>   Duration: 00:09:19.6, start: 91593.231322, bitrate: 2388 kb/s
>>>   Stream #0.0[0x1a11]: Video: mpeg2video, yuv420p, 544x576, 15000
>>> kb/s, 25.00 fps(r)
>>>   Stream #0.1[0x1a12](eng): Audio: mp2, 48000 Hz, stereo, 128 kb/s
>>>   Stream #0.2[0x1a13](eng): Audio: mp2, 48000 Hz, mono, 64 kb/s
>>>   Stream #0.3[0x1a16](eng): Subtitle: dvbsub
>> Basically:
>>
>> ffmpeg -i the.ts -vcodec copy -acodec copy -f dvd desired.vob
>>
>> Now that will produce a VOB with 15mbits video. Is that acceptable for a
>> DVD? I dont know.
>
>
> the written bitrate is too high for DVD specfs (DVD hardware buffer).
> But it means nothing (this is only an information, you cannot be sure
> it's the real one).
> My DVB "from internet provider" is written as 8000k to 15000k.
> In fact its peak-bitrate can reach 3000k (and average 2500k)
>
>
> Try (and let us know). If not, then you *have* to
>> re-encode. And yes, currently ffmpeg is unable to reduce the bitrate
>> without re-encoding.
>>
>> ffmpeg.c in opt_target sets some more parameters, you might need to set
>> them too. Alternately try
>>
>> ffmpeg -i the.ts -target dvd -vcodec copy -acodec copy desired.vob
>
>
> ...
> the buffer size is  written in the elementary stream, I don't think a
> "-vcodec copy" will change it (-traget will just change container and I
> don't know if it's sufficient in this caase)

Then you have answered your own question: if changing the container is
not enough, then re-encoding is required, and that will never be lossless.

And currently ffmpeg cant do partial re-encoding, even lossy. It would
be a neat feature to have though!

>
>
>
>>> I only need streams #0.0 (video) and #0.1 (autio) and don't mind loosing
>>> streams #0.2 (alternative audio for hearing impaired - usually blank
>>> anyway) and #0.3 (subtitles).
>>>
>>> So, does anyone know what arguments I need to pass to ffmpeg to achieve
>>> lossless conversion? Ideally, I'd like it to generate a VIDEO_TS directory
>>> filled with the .VOB container and the associated .IFO and .BUP files, so
>>> that I can add those to a UDF disc image ready to burn to DVD.
>>>
>> ffmpeg cant help you for the IFO and BUP files, you need a DVD authoring
>> software for that.

--
Michel Bardiaux
R&D Director
T +32 [0] 2 790 29 41
F +32 [0] 2 790 29 02
E mailto:[hidden email]

Mediaxim NV/SA
Vorstlaan 191 Boulevard du Souverain
Brussel 1160 Bruxelles
http://www.mediaxim.com/
_______________________________________________
ffmpeg-user mailing list
[hidden email]
http://lists.mplayerhq.hu/mailman/listinfo/ffmpeg-user
Reply | Threaded
Open this post in threaded view
|

Re: Lossless DVB-T Transport Stream from PVR to DVD

Mikael Hakman
In reply to this post by Emzo
Hello,

Emyr Thomas wrote:


> Appologies if some of my knowledge is incorrect, but I need some help
> figuring out how to use ffmpeg to losslessly (that's the important bit!)
> convert an MPEG2 transport stream from a DVB-T PVR (Humax T9200) to a
> VOB file suitable for burning onto a DVD.
>
> I'm running Mac OS X, and I've successfully done this using a combination
> of GUI tools to demux[1] the transport stream and the (re)mux[2] and burn
> to DVD. However, I'd prefer to do this via command line tools ;-)
>
> Am I right in thinking that ffmpeg is the appropriate tool for the job
> (I'm tlking about the remuxing here, NOT burning the file to DVD
> obviously), or will I require other tools?
>
> How do you remux with ffmpeg - everything I've tried so far results in the
> data being re-encoded, which reduces quality and wastes processor time!
>
> Here's some info on the contents of one of the .ts files from the DVR:
>
>  Duration: 00:09:19.6, start: 91593.231322, bitrate: 2388 kb/s
>  Stream #0.0[0x1a11]: Video: mpeg2video, yuv420p, 544x576, 15000
> kb/s, 25.00 fps(r)
>  Stream #0.1[0x1a12](eng): Audio: mp2, 48000 Hz, stereo, 128 kb/s
>  Stream #0.2[0x1a13](eng): Audio: mp2, 48000 Hz, mono, 64 kb/s
>  Stream #0.3[0x1a16](eng): Subtitle: dvbsub
>
> I only need streams #0.0 (video) and #0.1 (autio) and don't mind loosing
> streams #0.2 (alternative audio for hearing impaired - usually blank
> anyway) and #0.3 (subtitles).
>
> So, does anyone know what arguments I need to pass to ffmpeg to achieve
> lossless conversion? Ideally, I'd like it to generate a VIDEO_TS directory
> filled with the .VOB container and the associated .IFO and .BUP files, so
> that I can add those to a UDF disc image ready to burn to DVD.

You may want to take a look at dvdauthor and mplex. Perhaps you will need to
build them from sources under OS X.

Another approach could be to create an AppleScript to run your GUI tools
that are already working for you. Then you can execute AppleScript from
command line. If your GUI tools don't support AppleScript (they almost
certainly don't) then you could use System Events in AppleScript to simulate
text entry and mouse clicks within named GUI objects such as text fields and
buttons.

Another possibility would be to add command line interface to the two tools
that you mention, both are open source AFAIK. Does ffmpegX build IFO etc.?

Concerning the bit rate, I wouldn't think about that too much. While your
info for stream #0 says 15 Mbps, it's only a maximum specification. DVB-T
seldom contains more than 8-9 Mbps per single channel and this includes all
audio streams as well. In my experience it is often in the vicinity of 4-6
Mpbs.

Thanks/Mikael

_______________________________________________
ffmpeg-user mailing list
[hidden email]
http://lists.mplayerhq.hu/mailman/listinfo/ffmpeg-user
Reply | Threaded
Open this post in threaded view
|

Re: Lossless DVB-T Transport Stream from PVR to DVD

Nico Sabbi
In reply to this post by Hervé-4
Il Thursday 20 December 2007 15:22:24 HervŽe ha scritto:
> Michel Bardiaux a écrit :
> > Emyr Thomas a écrit :

> >> Here's some info on the contents of one of the .ts files from
> >> the DVR:
> >>
> >>   Duration: 00:09:19.6, start: 91593.231322, bitrate: 2388 kb/s
> >>   Stream #0.0[0x1a11]: Video: mpeg2video, yuv420p, 544x576,
> >> 15000 kb/s, 25.00 fps(r)
> >>   Stream #0.1[0x1a12](eng): Audio: mp2, 48000 Hz, stereo, 128
> >> kb/s Stream #0.2[0x1a13](eng): Audio: mp2, 48000 Hz, mono, 64
> >> kb/s Stream #0.3[0x1a16](eng): Subtitle: dvbsub
> >
> > Basically:
> >
> > ffmpeg -i the.ts -vcodec copy -acodec copy -f dvd desired.vob
> >
> > Now that will produce a VOB with 15mbits video. Is that
> > acceptable for a DVD? I dont know.
>
> the written bitrate is too high for DVD specfs (DVD hardware
> buffer). But it means nothing (this is only an information, you
> cannot be sure it's the real one).
> My DVB "from internet provider" is written as 8000k to 15000k.
> In fact its peak-bitrate can reach 3000k (and average 2500k)
>

that is the nominal max bitrate, but the actual bitrate is never so
high. You can alter it remuxing with mencoder:
$ mencoder -of mpeg -mpegopts format=dvd:tsaf:vbitrate=9800 -oac
copy -ovc copy -o file.dvd file.ts
_______________________________________________
ffmpeg-user mailing list
[hidden email]
http://lists.mplayerhq.hu/mailman/listinfo/ffmpeg-user
Reply | Threaded
Open this post in threaded view
|

Re: Lossless DVB-T Transport Stream from PVR to DVD

Emzo
In reply to this post by Michel Bardiaux-2

Michel Bardiaux-2 wrote
ffmpeg -i the.ts -target dvd -vcodec copy -acodec copy desired.vob
This worked like a charm.
Thanks Michel.
Reply | Threaded
Open this post in threaded view
|

Re: Lossless DVB-T Transport Stream from PVR to DVD

Emzo
In reply to this post by Mikael Hakman
Mikael Hakman wrote
You may want to take a look at dvdauthor and mplex. Perhaps you will need to
build them from sources under OS X.
dvdauthor is what I used to create the VIDEO_TS to burn onto DVD.
It's pretty simple, and works well for my needs.
There's also a port of it in macports, so I didn't even have to build it.

I didn't need mplex thanks to Michel Bardiaux's info - ffmpeg can do all the remuxing itself.

Another approach could be to create an AppleScript to run your GUI tools
that are already working for you. Then you can execute AppleScript from
command line. If your GUI tools don't support AppleScript (they almost
certainly don't) then you could use System Events in AppleScript to simulate
text entry and mouse clicks within named GUI objects such as text fields and
buttons.
Yes, I thought of this, but wanted to keep clear of AppleScript if at all possible.

Another possibility would be to add command line interface to the two tools
that you mention, both are open source AFAIK. Does ffmpegX build IFO etc.?
My skills don't extend that far I'm afraid :-(

Concerning the bit rate, I wouldn't think about that too much. While your
info for stream #0 says 15 Mbps, it's only a maximum specification. DVB-T
seldom contains more than 8-9 Mbps per single channel and this includes all
audio streams as well. In my experience it is often in the vicinity of 4-6
Mpbs.
True, the actual bitrate was 2388 kb/s
 
Thanks for all the help!

--Emyr
Reply | Threaded
Open this post in threaded view
|

Re: Lossless DVB-T Transport Stream from PVR to DVD

Emzo
In reply to this post by Emzo
I also found replex[1], a tool to remux transport stream data taken from a DVB source.
The result is a program stream that can be burned to a DVD (with dvdauthor or something similar).

It does works, but the resulting VOB seems to stutter quite a bit, so I think I'll stick with ffmpeg ;-)

--Emyr

[1] http://www.metzlerbros.org/dvb/
Reply | Threaded
Open this post in threaded view
|

Re: Lossless DVB-T Transport Stream from PVR to DVD

Michel Bardiaux-2
In reply to this post by Emzo
Emzo a écrit :
>
>
> Michel Bardiaux-2 wrote:
>> ffmpeg -i the.ts -target dvd -vcodec copy -acodec copy desired.vob
>>
>
> This worked like a charm.
> Thanks Michel.

For completeness, could you add the brand and model of DVD player on
which you tried the resulting files?

Greetings,
--
Michel Bardiaux
R&D Director
T +32 [0] 2 790 29 41
F +32 [0] 2 790 29 02
E mailto:[hidden email]

Mediaxim NV/SA
Vorstlaan 191 Boulevard du Souverain
Brussel 1160 Bruxelles
http://www.mediaxim.com/
_______________________________________________
ffmpeg-user mailing list
[hidden email]
http://lists.mplayerhq.hu/mailman/listinfo/ffmpeg-user
Reply | Threaded
Open this post in threaded view
|

Re: Lossless DVB-T Transport Stream from PVR to DVD

Emzo
Michel Bardiaux-2 wrote
For completeness, could you add the brand and model of DVD player on
which you tried the resulting files?
Sure, it's a Toshiba SD-140E

Reply | Threaded
Open this post in threaded view
|

Re: Lossless DVB-T Transport Stream from PVR to DVD

vdmsss
In reply to this post by Emzo
On 20 Dec 2007, at 22:46, Emzo wrote:
> Michel Bardiaux-2 wrote:
>>
>> ffmpeg -i the.ts -target dvd -vcodec copy -acodec copy desired.vob
>>
> This worked like a charm.

No, it doesn't. You've just been lucky. This command will not re-
encode, so if the elementary streams do not comply with DVD spec (eg  
bitrate, bufsize, ...), the resulting VOB will not necessarily play on  
your standalone player.

Once you have demux-ed the stream, I found that the easiest way to  
remux is mplex:

        mplex -V -S 0 -f 8 -O 0 -b 1835 -o outputfile.mpg inputfile.m2v  
inputfile.mp2 inputfile.ac3 ...

This will give output stats on screen that will help you see whether  
the resulting VOB is OK; as you demux with ProjectX (which does a  
pretty good job), I suggest you look at its log to check whether the  
relevant information about the video stream (gop, max_bitrate,  
bufsize, etc) respects the DVD spec. (Myself, I just try to burn with  
Toast -- I am on Mac; I use Toast because I want to add menus and I  
don't know how to do that with dvdauthor -- which check dvd-compliance  
for me.) If something is wrong, then your only option is to re-encode:

        ffmpeg -i the.ts -target dvd -vcodec mpeg2video -acodec ac3 <<your  
pref params here>> desired.vob

best

_______________________________________________
ffmpeg-user mailing list
[hidden email]
http://lists.mplayerhq.hu/mailman/listinfo/ffmpeg-user
Reply | Threaded
Open this post in threaded view
|

Re: Lossless DVB-T Transport Stream from PVR to DVD

Mikael Hakman
On Thursday, December 27, 2007 4:08 PM vdmsss wrote:

> On 20 Dec 2007, at 22:46, Emzo wrote:
>> Michel Bardiaux-2 wrote:
>>>
>>> ffmpeg -i the.ts -target dvd -vcodec copy -acodec copy desired.vob
>>>
>> This worked like a charm.
>
> No, it doesn't. You've just been lucky. This command will not re-
> encode, so if the elementary streams do not comply with DVD spec (eg
> bitrate, bufsize, ...), the resulting VOB will not necessarily play on
> your standalone player.
>
> Once you have demux-ed the stream, I found that the easiest way to
> remux is mplex:
>
> mplex -V -S 0 -f 8 -O 0 -b 1835 -o outputfile.mpg inputfile.m2v
> inputfile.mp2 inputfile.ac3 ...
>
> This will give output stats on screen that will help you see whether
> the resulting VOB is OK; as you demux with ProjectX (which does a
> pretty good job), I suggest you look at its log to check whether the
> relevant information about the video stream (gop, max_bitrate,
> bufsize, etc) respects the DVD spec. (Myself, I just try to burn with
> Toast -- I am on Mac; I use Toast because I want to add menus and I
> don't know how to do that with dvdauthor -- which check dvd-compliance
> for me.) If something is wrong, then your only option is to re-encode:
>
> ffmpeg -i the.ts -target dvd -vcodec mpeg2video -acodec ac3 <<your
> pref params here>> desired.vob

There are no guaranties, but IMHO the chances are pretty big that what has
been broadcasted by DVB-T will fit into DVD spec. DVB-T (TS) is more limited
than DVD (PS). Since I got DVB-T in my region, I recorded, demuxed
(ProjectX), and remuxed (IfoEdit) to DVD about 200 movies without problems.

Thanks/Mikael


_______________________________________________
ffmpeg-user mailing list
[hidden email]
http://lists.mplayerhq.hu/mailman/listinfo/ffmpeg-user
Reply | Threaded
Open this post in threaded view
|

Re: Lossless DVB-T Transport Stream from PVR to DVD

Hervé-4

Le 27 déc. 07 à 20:29, Mikael Hakman a écrit :

> On Thursday, December 27, 2007 4:08 PM vdmsss wrote:
>
>> On 20 Dec 2007, at 22:46, Emzo wrote:
>>> Michel Bardiaux-2 wrote:
>>>>
>>>> ffmpeg -i the.ts -target dvd -vcodec copy -acodec copy desired.vob
>>>>
>>> This worked like a charm.
>>
>> No, it doesn't. You've just been lucky. This command will not re-
>> encode, so if the elementary streams do not comply with DVD spec (eg
>> bitrate, bufsize, ...), the resulting VOB will not necessarily play  
>> on
>> your standalone player.
>>
>> Once you have demux-ed the stream, I found that the easiest way to
>> remux is mplex:
>>
>> mplex -V -S 0 -f 8 -O 0 -b 1835 -o outputfile.mpg inputfile.m2v
>> inputfile.mp2 inputfile.ac3 ...
>>
>> This will give output stats on screen that will help you see whether
>> the resulting VOB is OK; as you demux with ProjectX (which does a
>> pretty good job), I suggest you look at its log to check whether the
>> relevant information about the video stream (gop, max_bitrate,
>> bufsize, etc) respects the DVD spec. (Myself, I just try to burn with
>> Toast -- I am on Mac; I use Toast because I want to add menus and I
>> don't know how to do that with dvdauthor -- which check dvd-
>> compliance
>> for me.) If something is wrong, then your only option is to re-
>> encode:
>>
>> ffmpeg -i the.ts -target dvd -vcodec mpeg2video -acodec ac3 <<your
>> pref params here>> desired.vob
>
> There are no guaranties, but IMHO the chances are pretty big that  
> what has
> been broadcasted by DVB-T will fit into DVD spec.

no

> DVB-T (TS) is more limited
> than DVD (PS). Since I got DVB-T in my region, I recorded, demuxed
> (ProjectX), and remuxed (IfoEdit) to DVD about 200 movies without  
> problems.

eg: a GOP can not exceed 0,6second, all my DVB have 1 second GOP.

Most of DVDPlayer are cool, they often accept everything (good point  
to avoid re-encoding), but DVB streams are not DVD compliant (just  
"DVDPlayer" compliant ;-))

bye

Hervé
_______________________________________________
ffmpeg-user mailing list
[hidden email]
http://lists.mplayerhq.hu/mailman/listinfo/ffmpeg-user
Reply | Threaded
Open this post in threaded view
|

Re: Lossless DVB-T Transport Stream from PVR to DVD

Mikael Hakman
On Thursday, December 27, 2007 10:32 PM, [hidden email] wrote:

> Le 27 déc. 07 à 20:29, Mikael Hakman a écrit :
>
>> On Thursday, December 27, 2007 4:08 PM vdmsss wrote:
>>
>>> On 20 Dec 2007, at 22:46, Emzo wrote:
>>>> Michel Bardiaux-2 wrote:
>>>>>
>>>>> ffmpeg -i the.ts -target dvd -vcodec copy -acodec copy desired.vob
>>>>>
>>>> This worked like a charm.
>>>
>>> No, it doesn't. You've just been lucky. This command will not re-
>>> encode, so if the elementary streams do not comply with DVD spec (eg
>>> bitrate, bufsize, ...), the resulting VOB will not necessarily play
>>> on
>>> your standalone player.
>>>
>>> Once you have demux-ed the stream, I found that the easiest way to
>>> remux is mplex:
>>>
>>> mplex -V -S 0 -f 8 -O 0 -b 1835 -o outputfile.mpg inputfile.m2v
>>> inputfile.mp2 inputfile.ac3 ...
>>>
>>> This will give output stats on screen that will help you see whether
>>> the resulting VOB is OK; as you demux with ProjectX (which does a
>>> pretty good job), I suggest you look at its log to check whether the
>>> relevant information about the video stream (gop, max_bitrate,
>>> bufsize, etc) respects the DVD spec. (Myself, I just try to burn with
>>> Toast -- I am on Mac; I use Toast because I want to add menus and I
>>> don't know how to do that with dvdauthor -- which check dvd-
>>> compliance
>>> for me.) If something is wrong, then your only option is to re-
>>> encode:
>>>
>>> ffmpeg -i the.ts -target dvd -vcodec mpeg2video -acodec ac3 <<your
>>> pref params here>> desired.vob
>>
>> There are no guaranties, but IMHO the chances are pretty big that
>> what has
>> been broadcasted by DVB-T will fit into DVD spec.
>
> no
>
>> DVB-T (TS) is more limited
>> than DVD (PS). Since I got DVB-T in my region, I recorded, demuxed
>> (ProjectX), and remuxed (IfoEdit) to DVD about 200 movies without
>> problems.
>
> eg: a GOP can not exceed 0,6second, all my DVB have 1 second GOP.
>
> Most of DVDPlayer are cool, they often accept everything (good point
> to avoid re-encoding), but DVB streams are not DVD compliant (just
> "DVDPlayer" compliant ;-))

That's the difference between theory and practice, or between inflexible
specification and how it is implemented in reality. In reality, it works by
simply remixing TS to PS, at least TS as broadcasted by all channels in my
region. My 200 movies stored on DVDs play on all software players I know of,
and also on even the cheapest standalone DVD players.

We have had the same problem in the very beginning of TCP/IP era. Every
implementer interpreted the specification in a strict way and the result was
that the devices from one vendor couldn't talk to devices from another. This
because even strict interpretation is only an interpretation. After a while
the implementers learned how to do this in a relaxed and robust way and
everything went smoothly.

Therefore my advice to the original author of this thread is: relax, demux,
remux, and it will work.

Thanks/Mikael


_______________________________________________
ffmpeg-user mailing list
[hidden email]
http://lists.mplayerhq.hu/mailman/listinfo/ffmpeg-user