Hallo

> > > There is dropped frames between for excample first and second parts...
> > > So, lavrec can't record sequence without frame loss...
> > > And it is bad...
> > lavrec records without a losing frames. You have to use mjpegtools
> > lav2yuv file%01d.avi | mpeg2enc -f 8 -o video.m2v
> > lav2wav file%01d.avi | mp2enc -o audio.mp2
> > mplex -f 8 audio.mp2 video.m2v -o all.mpg
> >
> > Which command did you use for generating the single mpeg parts ?
> 
> I wrote little pascal program (www.freepascal.org) that did :
I wrote some things in pascal some time ago that time in Boland Turbo
Pascal :)

> uses Unix;
> Var
>   I : Longint;
    j : integer;
    filename : String;
>   outputfilename : String;
> begin
> //    Writeln (paramstr(0),' : Got ',ParamCount,' command-line parameters:
> ');

Why don't you check the length of the given argument with something like
that: 
.....
  for i:=1 to ParamCount do
  begin
    j = length(paramstr(i));
    if j > 0 then 
      begin
         filename = concat(filename, paramstr(i);
      end     
  end

  if length(filename) > 0
    begin
      Shell ('lav2yuv ' + filename + .....
      ......
    end
....

You cann extend that examples as much as you like ;)

>     For i:=1 to ParamCount do
>     begin
>     Writeln (' Converting ' + ParamStr (i) + ' to mpeg 2' );
>     end;
>     Shell ('lav2yuv ' + ParamStr(1) + ' | yuvdenoise -F | mpeg2enc
> --no-constraints -f 3 -b 4500 -o video_temp.m2v');
>     Shell ('lav2wav ' + ParamStr(1) + ' | mp2enc -b 128 -o
> sound_temp.mp2');
>     outputfilename := ParamStr(1) + '.mpg';
>     Shell ('mplex -f 3 -V sound_temp.mp2 video_temp.m2v -o ' +
> outputfilename);
>     Shell ('rm -f video_temp.m2v');
>     Shell ('rm -f sound_temp.mp2');
> 
> end.
> 
> So I do:
> lav2yuv + 00000001.avi + | yuvdenoise -F | mpeg2enc --no-constraints -f
> 3 -b 4500 -o video_temp.m2v
> lav2wav 00000001.avi | mpeg2enc -b 128 -o sound_temp.mp2
> mplex -f 3 -V sound_temp.mp2 video_temp.m2v -o 0000001.avi.mpg
> 
> Then I add file to each other with mpgtx
> 
> mpgtx -j 00000001.avi.mpg 0000000.2.avi.mpg -o all.mpg
> 
> ...
> May it will be good join files with some utility from mjpegtools package?
> Not already converted ones?
You should never put encoded mpeg movies together. That will cause
problems. 
Use the version where you encode severals single AVI's to one bigger
mpegvideo. 

If your programm only works with on single input file (I think it works
that way). Edit you recorded movie to one editlistfile with:
glav -p S file*.avi
Select the thing you want to encode and save it. And use that single
file afterwards as input for your programm. 

> But it requires more free disk space...
No because you don't need the space for the multiplexed mpeg files. 

auf hoffentlich bald,

Berni the Chaos of Woodquarter

Email: [EMAIL PROTECTED]
www: http://www.lysator.liu.se/~gz/bernhard


-------------------------------------------------------
This SF.Net email sponsored by Black Hat Briefings & Training.
Attend Black Hat Briefings & Training, Las Vegas July 24-29 - 
digital self defense, top technical experts, no vendor pitches, 
unmatched networking opportunities. Visit www.blackhat.com
_______________________________________________
Mjpeg-users mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/mjpeg-users

Reply via email to