Quantcast

Multiple output files

classic Classic list List threaded Threaded
12 messages Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Multiple output files

Ferenc Deak
Hi all,

I have the following question:

I have one input file, and I want to generate three output files from
it, but the only difference between these files is only the bitrate (in
the command line). So, right now I call ffmpeg three times. I would like
to ask is it possible to make one ffmpeg call to generate three files?

Thanks,
ferenc
_______________________________________________
ffmpeg-user mailing list
[hidden email]
https://lists.mplayerhq.hu/mailman/listinfo/ffmpeg-user
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Multiple output files

Mike Scheutzow
Ferenc Deak wrote:
> I have one input file, and I want to generate three output files from
> it, but the only difference between these files is only the bitrate (in
> the command line). So, right now I call ffmpeg three times. I would like
> to ask is it possible to make one ffmpeg call to generate three files?

The short answer is "No, FFmpeg does not support that."

You don't tell us what it is you are trying to optimize, and you do not
tell us the input format or the output format. Without any information,
no one can make any helpful suggestions for you.


Mike Scheutzow
_______________________________________________
ffmpeg-user mailing list
[hidden email]
https://lists.mplayerhq.hu/mailman/listinfo/ffmpeg-user
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Multiple output files

Ferenc Deak
On 04/30/2010 04:21 PM, Mike Scheutzow wrote:

> Ferenc Deak wrote:
>> I have one input file, and I want to generate three output files from
>> it, but the only difference between these files is only the bitrate
>> (in the command line). So, right now I call ffmpeg three times. I
>> would like to ask is it possible to make one ffmpeg call to generate
>> three files?
>
> The short answer is "No, FFmpeg does not support that."
>
> You don't tell us what it is you are trying to optimize, and you do
> not tell us the input format or the output format. Without any
> information, no one can make any helpful suggestions for you.
>

Sorry for not being more explicit about this, so here are the missing
details:

I have 1 master file: 44_master-00005.ts (1Mbit, 720x486, 96k audio)

and I need to obtain three different bitrates for iphone streaming:

44_100-00005.ts for (100Kbit, 320x240)
44_300-00005.ts for (300Kbit, 320x240)
44_500-00005.ts for (500Kbit, 320x240)

I am running the following commands to obtain the three different files

ffmpeg -i 44_master-00005.ts -b 100000 -f mpegts -acodec libfaac -ar
48000 -ab 64k -vcodec h264 -flags +loop -cmp +chroma -subq 5 -trellis 1
-refs 1 -coder 0 -me_range 16 -keyint_min 25 -sc_threshold 40 -i_qfactor
0.71 -bt 200k -maxrate 96k -bufsize 96k -qcomp 0.6 -qmin 10 -qmax 51
-qdiff 4 -level 30 -aspect 320:240 -g 30 -s 320x240 44_100-00005.ts

ffmpeg -i 44_master-00005.ts -b 300000 -f mpegts -acodec libfaac -ar
48000 -ab 64k -vcodec h264 -flags +loop -cmp +chroma -subq 5 -trellis 1
-refs 1 -coder 0 -me_range 16 -keyint_min 25 -sc_threshold 40 -i_qfactor
0.71 -bt 200k -maxrate 96k -bufsize 96k -qcomp 0.6 -qmin 10 -qmax 51
-qdiff 4 -level 30 -aspect 320:240 -g 30 -s 320x240 44_300-00005.ts

ffmpeg -i 44_master-00005.ts -b 500000 -f mpegts -acodec libfaac -ar
48000 -ab 64k -vcodec h264 -flags +loop -cmp +chroma -subq 5 -trellis 1
-refs 1 -coder 0 -me_range 16 -keyint_min 25 -sc_threshold 40 -i_qfactor
0.71 -bt 200k -maxrate 96k -bufsize 96k -qcomp 0.6 -qmin 10 -qmax 51
-qdiff 4 -level 30 -aspect 320:240 -g 30 -s 320x240 44_500-00005.ts

Rephrasing the question: Is it possible that FFmpeg will generate the
three different files in one run, so that I don't need to run it three
times?

Thanks
Ferenc
_______________________________________________
ffmpeg-user mailing list
[hidden email]
https://lists.mplayerhq.hu/mailman/listinfo/ffmpeg-user
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Multiple output files

Henk D. Schoneveld
Ferenc Deak wrote:

> On 04/30/2010 04:21 PM, Mike Scheutzow wrote:
>> Ferenc Deak wrote:
>>> I have one input file, and I want to generate three output files from
>>> it, but the only difference between these files is only the bitrate
>>> (in the command line). So, right now I call ffmpeg three times. I
>>> would like to ask is it possible to make one ffmpeg call to generate
>>> three files?
>>
>> The short answer is "No, FFmpeg does not support that."
>>
>> You don't tell us what it is you are trying to optimize, and you do
>> not tell us the input format or the output format. Without any
>> information, no one can make any helpful suggestions for you.
>>
>
> Sorry for not being more explicit about this, so here are the missing
> details:
>
> I have 1 master file: 44_master-00005.ts (1Mbit, 720x486, 96k audio)
>
> and I need to obtain three different bitrates for iphone streaming:
>
> 44_100-00005.ts for (100Kbit, 320x240)
> 44_300-00005.ts for (300Kbit, 320x240)
> 44_500-00005.ts for (500Kbit, 320x240)
>
> I am running the following commands to obtain the three different files
>
> ffmpeg -i 44_master-00005.ts -b 100000 -f mpegts -acodec libfaac -ar
> 48000 -ab 64k -vcodec h264 -flags +loop -cmp +chroma -subq 5 -trellis 1
> -refs 1 -coder 0 -me_range 16 -keyint_min 25 -sc_threshold 40 -i_qfactor
> 0.71 -bt 200k -maxrate 96k -bufsize 96k -qcomp 0.6 -qmin 10 -qmax 51
> -qdiff 4 -level 30 -aspect 320:240 -g 30 -s 320x240 44_100-00005.ts
>
> ffmpeg -i 44_master-00005.ts -b 300000 -f mpegts -acodec libfaac -ar
> 48000 -ab 64k -vcodec h264 -flags +loop -cmp +chroma -subq 5 -trellis 1
> -refs 1 -coder 0 -me_range 16 -keyint_min 25 -sc_threshold 40 -i_qfactor
> 0.71 -bt 200k -maxrate 96k -bufsize 96k -qcomp 0.6 -qmin 10 -qmax 51
> -qdiff 4 -level 30 -aspect 320:240 -g 30 -s 320x240 44_300-00005.ts
>
> ffmpeg -i 44_master-00005.ts -b 500000 -f mpegts -acodec libfaac -ar
> 48000 -ab 64k -vcodec h264 -flags +loop -cmp +chroma -subq 5 -trellis 1
> -refs 1 -coder 0 -me_range 16 -keyint_min 25 -sc_threshold 40 -i_qfactor
> 0.71 -bt 200k -maxrate 96k -bufsize 96k -qcomp 0.6 -qmin 10 -qmax 51
> -qdiff 4 -level 30 -aspect 320:240 -g 30 -s 320x240 44_500-00005.ts
>
> Rephrasing the question: Is it possible that FFmpeg will generate the
> three different files in one run, so that I don't need to run it three
> times?
If you have a triple or quad-core you can run all three in parallel :-)
>
> Thanks
> Ferenc
> _______________________________________________
> ffmpeg-user mailing list
> [hidden email]
> https://lists.mplayerhq.hu/mailman/listinfo/ffmpeg-user

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

Re: Multiple output files

Dave P-3
On Fri, Apr 30, 2010 at 12:57, belcampo <[hidden email]> wrote:

> Ferenc Deak wrote:
>>
>> On 04/30/2010 04:21 PM, Mike Scheutzow wrote:
>>>
>>> Ferenc Deak wrote:
>>>>
>>>> I have one input file, and I want to generate three output files from
>>>> it, but the only difference between these files is only the bitrate (in the
>>>> command line). So, right now I call ffmpeg three times. I would like to ask
>>>> is it possible to make one ffmpeg call to generate three files?
>>>
>>> The short answer is "No, FFmpeg does not support that."
>>>
>>> You don't tell us what it is you are trying to optimize, and you do not
>>> tell us the input format or the output format. Without any information, no
>>> one can make any helpful suggestions for you.
>>>
>>
>> Sorry for not being more explicit about this, so here are the missing
>> details:
>>
>> I have 1 master file: 44_master-00005.ts (1Mbit, 720x486, 96k audio)
>>
>> and I need to obtain three different bitrates for iphone streaming:
>>
>> 44_100-00005.ts for (100Kbit, 320x240)
>> 44_300-00005.ts for (300Kbit, 320x240)
>> 44_500-00005.ts for (500Kbit, 320x240)
>>
>> I am running the following commands to obtain the three different files
>>
>> ffmpeg -i 44_master-00005.ts -b 100000 -f mpegts -acodec libfaac -ar 48000
>> -ab 64k -vcodec h264 -flags +loop -cmp +chroma -subq 5 -trellis 1 -refs 1
>> -coder 0 -me_range 16 -keyint_min 25 -sc_threshold 40 -i_qfactor 0.71 -bt
>> 200k -maxrate 96k -bufsize 96k -qcomp 0.6 -qmin 10 -qmax 51 -qdiff 4 -level
>> 30 -aspect 320:240 -g 30 -s 320x240 44_100-00005.ts
>>
>> ffmpeg -i 44_master-00005.ts -b 300000 -f mpegts -acodec libfaac -ar 48000
>> -ab 64k -vcodec h264 -flags +loop -cmp +chroma -subq 5 -trellis 1 -refs 1
>> -coder 0 -me_range 16 -keyint_min 25 -sc_threshold 40 -i_qfactor 0.71 -bt
>> 200k -maxrate 96k -bufsize 96k -qcomp 0.6 -qmin 10 -qmax 51 -qdiff 4 -level
>> 30 -aspect 320:240 -g 30 -s 320x240 44_300-00005.ts
>>
>> ffmpeg -i 44_master-00005.ts -b 500000 -f mpegts -acodec libfaac -ar 48000
>> -ab 64k -vcodec h264 -flags +loop -cmp +chroma -subq 5 -trellis 1 -refs 1
>> -coder 0 -me_range 16 -keyint_min 25 -sc_threshold 40 -i_qfactor 0.71 -bt
>> 200k -maxrate 96k -bufsize 96k -qcomp 0.6 -qmin 10 -qmax 51 -qdiff 4 -level
>> 30 -aspect 320:240 -g 30 -s 320x240 44_500-00005.ts
>>
>> Rephrasing the question: Is it possible that FFmpeg will generate the
>> three different files in one run, so that I don't need to run it three
>> times?
>
> If you have a triple or quad-core you can run all three in parallel :-)

if not, use a for loop
_______________________________________________
ffmpeg-user mailing list
[hidden email]
https://lists.mplayerhq.hu/mailman/listinfo/ffmpeg-user
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Multiple output files

Ramiro Polla-3
On Fri, Apr 30, 2010 at 2:05 PM, Dave P <[hidden email]> wrote:

> On Fri, Apr 30, 2010 at 12:57, belcampo <[hidden email]> wrote:
>> Ferenc Deak wrote:
>>> On 04/30/2010 04:21 PM, Mike Scheutzow wrote:
>>>> Ferenc Deak wrote:
>>>>> I have one input file, and I want to generate three output files from
>>>>> it, but the only difference between these files is only the bitrate (in the
>>>>> command line). So, right now I call ffmpeg three times. I would like to ask
>>>>> is it possible to make one ffmpeg call to generate three files?
>>>>
>>>> The short answer is "No, FFmpeg does not support that."
>>>>
>>>> You don't tell us what it is you are trying to optimize, and you do not
>>>> tell us the input format or the output format. Without any information, no
>>>> one can make any helpful suggestions for you.
>>>>
>>>
>>> Sorry for not being more explicit about this, so here are the missing
>>> details:
>>>
>>> I have 1 master file: 44_master-00005.ts (1Mbit, 720x486, 96k audio)
>>>
>>> and I need to obtain three different bitrates for iphone streaming:
>>>
>>> 44_100-00005.ts for (100Kbit, 320x240)
>>> 44_300-00005.ts for (300Kbit, 320x240)
>>> 44_500-00005.ts for (500Kbit, 320x240)
>>>
>>> I am running the following commands to obtain the three different files
>>>
>>> ffmpeg -i 44_master-00005.ts -b 100000 -f mpegts -acodec libfaac -ar 48000
>>> -ab 64k -vcodec h264 -flags +loop -cmp +chroma -subq 5 -trellis 1 -refs 1
>>> -coder 0 -me_range 16 -keyint_min 25 -sc_threshold 40 -i_qfactor 0.71 -bt
>>> 200k -maxrate 96k -bufsize 96k -qcomp 0.6 -qmin 10 -qmax 51 -qdiff 4 -level
>>> 30 -aspect 320:240 -g 30 -s 320x240 44_100-00005.ts
>>>
>>> ffmpeg -i 44_master-00005.ts -b 300000 -f mpegts -acodec libfaac -ar 48000
>>> -ab 64k -vcodec h264 -flags +loop -cmp +chroma -subq 5 -trellis 1 -refs 1
>>> -coder 0 -me_range 16 -keyint_min 25 -sc_threshold 40 -i_qfactor 0.71 -bt
>>> 200k -maxrate 96k -bufsize 96k -qcomp 0.6 -qmin 10 -qmax 51 -qdiff 4 -level
>>> 30 -aspect 320:240 -g 30 -s 320x240 44_300-00005.ts
>>>
>>> ffmpeg -i 44_master-00005.ts -b 500000 -f mpegts -acodec libfaac -ar 48000
>>> -ab 64k -vcodec h264 -flags +loop -cmp +chroma -subq 5 -trellis 1 -refs 1
>>> -coder 0 -me_range 16 -keyint_min 25 -sc_threshold 40 -i_qfactor 0.71 -bt
>>> 200k -maxrate 96k -bufsize 96k -qcomp 0.6 -qmin 10 -qmax 51 -qdiff 4 -level
>>> 30 -aspect 320:240 -g 30 -s 320x240 44_500-00005.ts
>>>
>>> Rephrasing the question: Is it possible that FFmpeg will generate the
>>> three different files in one run, so that I don't need to run it three
>>> times?
>>
>> If you have a triple or quad-core you can run all three in parallel :-)
>
> if not, use a for loop

This way he'll have to decode and resize 3 times. It *should* be
possible to output to 3 files at the same time. If it's not possible
it should be considered a bug. For example, this works:

./ffmpeg -i ../input.avi -y -b 100k output.mpg -b 200k output2.mpg -b
300k output3.mpg

Try doing something similar for your command line:
ffmpeg -i 44_master-00005.ts <bunch of options> -b 100000
44_100-00005.ts -b 300000 44_300-00005.ts -b 500000 44_500-00005.ts
_______________________________________________
ffmpeg-user mailing list
[hidden email]
https://lists.mplayerhq.hu/mailman/listinfo/ffmpeg-user
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Multiple output files

Rodney Baker
On Sat, 1 May 2010 02:45:00 Ramiro Polla wrote:

> On Fri, Apr 30, 2010 at 2:05 PM, Dave P <[hidden email]> wrote:
> > On Fri, Apr 30, 2010 at 12:57, belcampo <[hidden email]> wrote:
> >> Ferenc Deak wrote:
> >>> On 04/30/2010 04:21 PM, Mike Scheutzow wrote:
> >>>> Ferenc Deak wrote:
> >>>>> I have one input file, and I want to generate three output files from
> >>>>> it, but the only difference between these files is only the bitrate
> >>>>> (in the command line). So, right now I call ffmpeg three times. I
> >>>>> would like to ask is it possible to make one ffmpeg call to generate
> >>>>> three files?
> >>>>
> >>>> The short answer is "No, FFmpeg does not support that."
> >>>>
> >>>> You don't tell us what it is you are trying to optimize, and you do
> >>>> not tell us the input format or the output format. Without any
> >>>> information, no one can make any helpful suggestions for you.
> >>>
> >>> Sorry for not being more explicit about this, so here are the missing
> >>> details:
> >>>
> >>> I have 1 master file: 44_master-00005.ts (1Mbit, 720x486, 96k audio)
> >>>
> >>> and I need to obtain three different bitrates for iphone streaming:
> >>>
> >>> 44_100-00005.ts for (100Kbit, 320x240)
> >>> 44_300-00005.ts for (300Kbit, 320x240)
> >>> 44_500-00005.ts for (500Kbit, 320x240)
> >>>
> >>> I am running the following commands to obtain the three different files
> >>>
> >>> ffmpeg -i 44_master-00005.ts -b 100000 -f mpegts -acodec libfaac -ar
> >>> 48000 -ab 64k -vcodec h264 -flags +loop -cmp +chroma -subq 5 -trellis
> >>> 1 -refs 1 -coder 0 -me_range 16 -keyint_min 25 -sc_threshold 40
> >>> -i_qfactor 0.71 -bt 200k -maxrate 96k -bufsize 96k -qcomp 0.6 -qmin 10
> >>> -qmax 51 -qdiff 4 -level 30 -aspect 320:240 -g 30 -s 320x240
> >>> 44_100-00005.ts
> >>>
> >>> ffmpeg -i 44_master-00005.ts -b 300000 -f mpegts -acodec libfaac -ar
> >>> 48000 -ab 64k -vcodec h264 -flags +loop -cmp +chroma -subq 5 -trellis
> >>> 1 -refs 1 -coder 0 -me_range 16 -keyint_min 25 -sc_threshold 40
> >>> -i_qfactor 0.71 -bt 200k -maxrate 96k -bufsize 96k -qcomp 0.6 -qmin 10
> >>> -qmax 51 -qdiff 4 -level 30 -aspect 320:240 -g 30 -s 320x240
> >>> 44_300-00005.ts
> >>>
> >>> ffmpeg -i 44_master-00005.ts -b 500000 -f mpegts -acodec libfaac -ar
> >>> 48000 -ab 64k -vcodec h264 -flags +loop -cmp +chroma -subq 5 -trellis
> >>> 1 -refs 1 -coder 0 -me_range 16 -keyint_min 25 -sc_threshold 40
> >>> -i_qfactor 0.71 -bt 200k -maxrate 96k -bufsize 96k -qcomp 0.6 -qmin 10
> >>> -qmax 51 -qdiff 4 -level 30 -aspect 320:240 -g 30 -s 320x240
> >>> 44_500-00005.ts
> >>>
> >>> Rephrasing the question: Is it possible that FFmpeg will generate the
> >>> three different files in one run, so that I don't need to run it three
> >>> times?
> >>
> >> If you have a triple or quad-core you can run all three in parallel :-)
> >
> > if not, use a for loop
>
> This way he'll have to decode and resize 3 times. It *should* be
> possible to output to 3 files at the same time. If it's not possible
> it should be considered a bug. For example, this works:
>
> ./ffmpeg -i ../input.avi -y -b 100k output.mpg -b 200k output2.mpg -b
> 300k output3.mpg
>
> Try doing something similar for your command line:
> ffmpeg -i 44_master-00005.ts <bunch of options> -b 100000
> 44_100-00005.ts -b 300000 44_300-00005.ts -b 500000 44_500-00005.ts
> __________________________________________

But without multiple processor cores will be it be faster than calling it 3
times? I can see with multiple cores and multi-threading it should speed it
up, but with a single core doing the work it might actually be slower (but I
haven't tried it, so YMMV).

--
===================================================
Rodney Baker VK5ZTV
[hidden email]
===================================================

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

Re: Multiple output files

Ramiro Polla-3
On Sat, May 1, 2010 at 6:06 AM, Rodney Baker <[hidden email]> wrote:
> On Sat, 1 May 2010 02:45:00 Ramiro Polla wrote:
>> On Fri, Apr 30, 2010 at 2:05 PM, Dave P <[hidden email]> wrote:
>> > On Fri, Apr 30, 2010 at 12:57, belcampo <[hidden email]> wrote:
>> >> Ferenc Deak wrote:
[...]

>> >>> Rephrasing the question: Is it possible that FFmpeg will generate the
>> >>> three different files in one run, so that I don't need to run it three
>> >>> times?
>> >>
>> >> If you have a triple or quad-core you can run all three in parallel :-)
>> >
>> > if not, use a for loop
>>
>> This way he'll have to decode and resize 3 times. It *should* be
>> possible to output to 3 files at the same time. If it's not possible
>> it should be considered a bug. For example, this works:
>>
>> ./ffmpeg -i ../input.avi -y -b 100k output.mpg -b 200k output2.mpg -b
>> 300k output3.mpg
>>
>> Try doing something similar for your command line:
>> ffmpeg -i 44_master-00005.ts <bunch of options> -b 100000
>> 44_100-00005.ts -b 300000 44_300-00005.ts -b 500000 44_500-00005.ts
>
> But without multiple processor cores will be it be faster than calling it 3
> times? I can see with multiple cores and multi-threading it should speed it
> up, but with a single core doing the work it might actually be slower (but I
> haven't tried it, so YMMV).

FFmpeg has no output file level parallelism. If his aim is better
performance he'd have to try running multiple process in parallel or
using -threads.
_______________________________________________
ffmpeg-user mailing list
[hidden email]
https://lists.mplayerhq.hu/mailman/listinfo/ffmpeg-user
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Multiple output files

Ferenc Deak
Hi all,

thanks for the replies, it's working. I will share it here the final
command line, maybe it will be useful for somebody:

/usr/local/bin/ffmpeg -threads 3 -i 44_master-00034.ts -b 100000 -f
mpegts -acodec libfaac -ar 48000 -ab 64k -vcodec libx264 -flags +loop
-cmp +chroma -subq 5 -trellis 1 -refs 1 -coder 0 -me_range 16
-keyint_min 25 -sc_threshold 40 -i_qfactor 0.71 -bt 200k -maxrate 96k
-bufsize 96k -rc_eq 'blurCplx^(1-qComp)' -qcomp 0.6 -qmin 10 -qmax 51
-qdiff 4 -level 30 -aspect 320:240 -g 30 -s 320x240 44s_100-00034.ts -b
300000 -f mpegts -acodec libfaac -ar 48000 -ab 64k -vcodec libx264
-flags +loop -cmp +chroma -subq 5 -trellis 1 -refs 1 -coder 0 -me_range
16 -keyint_min 25 -sc_threshold 40 -i_qfactor 0.71 -bt 200k -maxrate 96k
-bufsize 96k -rc_eq 'blurCplx^(1-qComp)' -qcomp 0.6 -qmin 10 -qmax 51
-qdiff 4 -level 30 -aspect 320:240 -g 30 -s 320x240 44s_300-00034.ts -b
500000 -f mpegts -acodec libfaac -ar 48000 -ab 64k -vcodec libx264
-flags +loop -cmp +chroma -subq 5 -trellis 1 -refs 1 -coder 0 -me_range
16 -keyint_min 25 -sc_threshold 40 -i_qfactor 0.71 -bt 200k -maxrate 96k
-bufsize 96k -rc_eq 'blurCplx^(1-qComp)' -qcomp 0.6 -qmin 10 -qmax 51
-qdiff 4 -level 30 -aspect 320:240 -g 30 -s 320x240 44s_500-00034.ts

as a general rule: you will have to specify <bunch of options> (see
below for what this is) for each output file separately, it's not
working without.

Thanks for helping.
frc


On 05/01/2010 05:47 PM, Ramiro Polla wrote:

> On Sat, May 1, 2010 at 6:06 AM, Rodney Baker<[hidden email]>  wrote:
>    
>> On Sat, 1 May 2010 02:45:00 Ramiro Polla wrote:
>>      
>>> On Fri, Apr 30, 2010 at 2:05 PM, Dave P<[hidden email]>  wrote:
>>>        
>>>> On Fri, Apr 30, 2010 at 12:57, belcampo<[hidden email]>  wrote:
>>>>          
>>>>> Ferenc Deak wrote:
>>>>>            
> [...]
>    
>>>>>> Rephrasing the question: Is it possible that FFmpeg will generate the
>>>>>> three different files in one run, so that I don't need to run it three
>>>>>> times?
>>>>>>              
>>>>> If you have a triple or quad-core you can run all three in parallel :-)
>>>>>            
>>>> if not, use a for loop
>>>>          
>>> This way he'll have to decode and resize 3 times. It *should* be
>>> possible to output to 3 files at the same time. If it's not possible
>>> it should be considered a bug. For example, this works:
>>>
>>> ./ffmpeg -i ../input.avi -y -b 100k output.mpg -b 200k output2.mpg -b
>>> 300k output3.mpg
>>>
>>> Try doing something similar for your command line:
>>> ffmpeg -i 44_master-00005.ts<bunch of options>  -b 100000
>>> 44_100-00005.ts -b 300000 44_300-00005.ts -b 500000 44_500-00005.ts
>>>        
>> But without multiple processor cores will be it be faster than calling it 3
>> times? I can see with multiple cores and multi-threading it should speed it
>> up, but with a single core doing the work it might actually be slower (but I
>> haven't tried it, so YMMV).
>>      
> FFmpeg has no output file level parallelism. If his aim is better
> performance he'd have to try running multiple process in parallel or
> using -threads.
> _______________________________________________
> ffmpeg-user mailing list
> [hidden email]
> https://lists.mplayerhq.hu/mailman/listinfo/ffmpeg-user
>    
_______________________________________________
ffmpeg-user mailing list
[hidden email]
https://lists.mplayerhq.hu/mailman/listinfo/ffmpeg-user
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Multiple output files

samir amzani
Hi,
It's usefull, but what about encoding time, it is the same as encoding three
time ?

Samir,

2010/5/3 Ferenc Deak <[hidden email]>

> as a general rule: you will have to specify <bunch of options> (see below
> for what this is) for each output file separately, it's not working without.
_______________________________________________
ffmpeg-user mailing list
[hidden email]
https://lists.mplayerhq.hu/mailman/listinfo/ffmpeg-user
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Multiple output files

Henk D. Schoneveld
In reply to this post by Ferenc Deak
Ferenc Deak wrote:

> Hi all,
>
> thanks for the replies, it's working. I will share it here the final
> command line, maybe it will be useful for somebody:
>
> /usr/local/bin/ffmpeg -threads 3 -i 44_master-00034.ts -b 100000 -f
> mpegts -acodec libfaac -ar 48000 -ab 64k -vcodec libx264 -flags +loop
> -cmp +chroma -subq 5 -trellis 1 -refs 1 -coder 0 -me_range 16
> -keyint_min 25 -sc_threshold 40 -i_qfactor 0.71 -bt 200k -maxrate 96k
> -bufsize 96k -rc_eq 'blurCplx^(1-qComp)' -qcomp 0.6 -qmin 10 -qmax 51
> -qdiff 4 -level 30 -aspect 320:240 -g 30 -s 320x240 44s_100-00034.ts -b
> 300000 -f mpegts -acodec libfaac -ar 48000 -ab 64k -vcodec libx264
> -flags +loop -cmp +chroma -subq 5 -trellis 1 -refs 1 -coder 0 -me_range
> 16 -keyint_min 25 -sc_threshold 40 -i_qfactor 0.71 -bt 200k -maxrate 96k
> -bufsize 96k -rc_eq 'blurCplx^(1-qComp)' -qcomp 0.6 -qmin 10 -qmax 51
> -qdiff 4 -level 30 -aspect 320:240 -g 30 -s 320x240 44s_300-00034.ts -b
> 500000 -f mpegts -acodec libfaac -ar 48000 -ab 64k -vcodec libx264
> -flags +loop -cmp +chroma -subq 5 -trellis 1 -refs 1 -coder 0 -me_range
> 16 -keyint_min 25 -sc_threshold 40 -i_qfactor 0.71 -bt 200k -maxrate 96k
> -bufsize 96k -rc_eq 'blurCplx^(1-qComp)' -qcomp 0.6 -qmin 10 -qmax 51
> -qdiff 4 -level 30 -aspect 320:240 -g 30 -s 320x240 44s_500-00034.ts
>
> as a general rule: you will have to specify <bunch of options> (see
> below for what this is) for each output file separately, it's not
> working without.
>
> Thanks for helping.
> frc
I'm suggesting a short test of above '-threads' based test versus 3
individual but parallel running encodings, but also set a '-threads 0'
in each command, I bet it will be > 30% faster.
_______________________________________________
ffmpeg-user mailing list
[hidden email]
https://lists.mplayerhq.hu/mailman/listinfo/ffmpeg-user
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Multiple output files

Ferenc Deak
Dear all,

I have observed that the one-step ffmpeg command is faster than the
three separate runs, however right now I don't have time to run
exhaustive tests since I need to write another mail to the list ... (the
output file of the command is not working as supposed to) :(

If anyone of you is having some extra-time, please fetch the master file
from http://dev.adactus.no:10080/ffmpegfiles/ and please feel free to
play with it. I would be really curious to see some charts and comparisons.

Cheers,
f.

On 05/03/2010 11:40 AM, belcampo wrote:
> I'm suggesting a short test of above '-threads' based test versus 3
> individual but parallel running encodings, but also set a '-threads 0'
> in each command, I bet it will be > 30% faster.
> _______________________________________________
> ffmpeg-user mailing list
> [hidden email]
> https://lists.mplayerhq.hu/mailman/listinfo/ffmpeg-user
_______________________________________________
ffmpeg-user mailing list
[hidden email]
https://lists.mplayerhq.hu/mailman/listinfo/ffmpeg-user
Loading...