Re: mjpegtools to dvdauthor (was Re: [Mjpeg-users] Too late?)

2004-08-29 Thread Selva Nair
On Sun, 29 Aug 2004, Anne Wilson wrote:

> 
> VIDEO_TS lists as:
> VIDEO_TS.BUP  VTS_01_0.BUP  VTS_01_1.VOB
> VIDEO_TS.IFO  VTS_01_0.IFO  VTS_01_2.VOB
> 
> Is this what you would expect?  The two files seem to be split purely because 

Yes. You have the three mpg files authored as a single title so everything
goes into VTS_01_x.VOB (x= 1 to 9) split into 1GB chunks as necessary.

> of size.  I have tried each separately and the content of all three files is 
> there.
> 
> Now I need to check the structure.  Either there is a problem,or I can't get 
> the xine command right.  Which directory should I be in to run the xine 
> command?  I'm sorry, I must be totally thick!  This worked perfectly well 
> with the short one yesterday but I keep getting error messages - can't find 
> the mrl, and no plugin to handle dvd.  We know this is rubbish - it worked 
> yesterday - so it has to be me.

xine sometimes acts up for me too.. The command for your case would be

$ xine dvd:/Data/Movies/

Does n't matter where you run it from if you specify the full-path to the
directory that contains VIDEO_TS and AUDIO_TS as above. Include the
trailing slash.

Selva




---
This SF.Net email is sponsored by BEA Weblogic Workshop
FREE Java Enterprise J2EE developer tools!
Get your free copy of BEA WebLogic Workshop 8.1 today.
http://ads.osdn.com/?ad_id=5047&alloc_id=10808&op=click
___
Mjpeg-users mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/mjpeg-users


Re: [Mjpeg-users] Creating a large mp2

2004-08-28 Thread Selva Nair

On Sat, 28 Aug 2004, Anne Wilson wrote:

> -BEGIN PGP SIGNED MESSAGE-
> Hash: SHA1
> 
> I have a series of files created by lavrec using the form cottingley%02d.avi.  
> Before I can encode these I have to split off the file, but I can't work out 
> how to get lav2wav to read the series as one long file.  How do I do that, 
> please?  Using the name format as in lavrec wasn't recognised by lav2wav, and 

I am not sure I understand. If you want to concatenate the sound track in
several files, yes lav2wav can take several files as input -- for example,

lav2wav file1.avi file2.avi file3.avi | mp2enc ...

Or as one or more  editlists

lav2wav movie1.eli movie2.eli | mp2enc ..

Selva



---
This SF.Net email is sponsored by BEA Weblogic Workshop
FREE Java Enterprise J2EE developer tools!
Get your free copy of BEA WebLogic Workshop 8.1 today.
http://ads.osdn.com/?ad_id=5047&alloc_id=10808&op=click
___
Mjpeg-users mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/mjpeg-users


Re: [Mjpeg-users] Re: skip first frame, y4mcut, debian

2004-08-28 Thread Selva Nair
On Sat, 28 Aug 2004 [EMAIL PROTECTED] wrote:

> [In July I asked how to skip the first frame in a yuv stream, because mplayer
> was putting a green frame at the beginning. I apologize to Steven Shultz and
> Selva Nair for not having answered earlier to their helpful messages.]
> 
> 
> On Wed, 14 Jul 2004, Steven M. Schultz wrote:
> > I thought that problem had been fixed in MPlayer quite a while ago.
> > Are you running the latest CVS version or an older version of MPlayer?
> 
> Thanks! I've upgraded my version of mplayer and I don't see those green frames
> anymore.
> 
> 
> On the same day Selva Nair wrote:
> > Here is a utility that I use to trim yuv4mpeg streams. Link it with
> > -lmjpegutils and try "y4mcut -h" for usage.
> 
> This is a nice program, thank you! It works quite well.
> Note: I had to changes some double quotes to single quotes for the file to
> compile:
> case "v" -> case 'v'
> etc...

That was an old program I wrote, never rebuilt in a long time -- I 
probably "polished it up" and posted without testing -- sorry about that.
Having said that, I have no idea from where that double quote crept in,
I have case 'v' in my copy !

> otherwise gcc would print "y4mcut.c:64: error: case label does not reduce to an
> integer constant".
> 
> Also, I got the following errors:
> y4mcut.c:98: error: structure has no member named `width'
> y4mcut.c:99: error: structure has no member named `height'

There has been several changes in YUV4MPEG API and direct accessing
of stream_info structure is now not supported.

> 
> I just changed "int Y4MPRIVATIZE(width);" and "int Y4MPRIVATIZE(height);" to
> "int width;" and "int height;" in the struct _y4m_stream_info (in yuv4mpeg.h)
> and it compiled, but I wonder why this dirty change was necessary... was it a
> problem with my gcc version? (I use gcc 3.3.4)

Oh no, y4mcut should be updated by replacing istream.width and
istream.height by y4m_si_get_width(istream) and
y4m_get_si_height(istream), respectively. 

Selva



---
This SF.Net email is sponsored by BEA Weblogic Workshop
FREE Java Enterprise J2EE developer tools!
Get your free copy of BEA WebLogic Workshop 8.1 today.
http://ads.osdn.com/?ad_id=5047&alloc_id=10808&op=click
___
Mjpeg-users mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/mjpeg-users


Re: mjpegtools to dvdauthor (was Re: [Mjpeg-users] Too late?)

2004-08-28 Thread Selva Nair
On Fri, 27 Aug 2004, Anne Wilson wrote:

> 
> > Check the authoring using xine (version 0.9.2x if possible :)
> >
> > $ xine dvd:/$PWD/my-dvd/
> > (the trailing / is important)
> >
> Despite the fact that xine could not play the .mpg properly it had no problems 
> at all with this.

!!

> > Burn my-dvd.raw to a dvd+/-rw disk using dvd+rw tools
> > or dvdrecord/cdrecord as appropriate for your dvd drive.
> >
> Sadly my dvd-rw disks are -R - and they are not read by my player, so I had to 
> burn a full DVD+R to prove the point.

Get an RW disk supported by your player. Get a decent brand, you wont
regret it.

> 
> > For +RW (recent versions of growisofs are supposed to with -RW too,
> > I haven't tried)
> >
> > $ dvd+rw-format /dev/scd0
> >
> > $ growisofs -dvd-compat -Z /dev/scd0=my-dvd.raw
> >
> > ( - replace /dev/scd0 by the appropriate device
> >   - need permission to write to /dev/scd0
> >   - avoid gui front ends that tie you to a mouse and spoil all fun :)
> >   - not -dvd-compat is needed or not )
> >
> I've never used growisofs before, but it was entirely painless.
 
If it was on linux, I think whatever you used before must have  
invoked growisofs behind the hoods.. There is indeed a way that does not
use growisofs -- "mksiofs .. | dd /dev/scd0" but I doubt any of the front
ends out there really do that.

Selva
 



---
This SF.Net email is sponsored by BEA Weblogic Workshop
FREE Java Enterprise J2EE developer tools!
Get your free copy of BEA WebLogic Workshop 8.1 today.
http://ads.osdn.com/?ad_id=5047&alloc_id=10808&op=click
___
Mjpeg-users mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/mjpeg-users


Re: [Mjpeg-users] Interlacing question

2004-08-27 Thread Selva Nair

Hi, 

> I can see that this is interlaced, but how do I know whether it is top- or 
> bottom-field-first?

video_inter = 1 means top-field-first, 2 for bottom-field-first.
I think it is documented somewhere..

FWIW, here is a patch for lavinfo.c that  replaces the interlacing and 
chroma numbers by more explicit mnemonics. 

--- lavinfo.c.orig  Tue Jul  6 17:53:48 2004
+++ lavinfo.c   Fri Aug 27 15:01:21 2004
@@ -42,13 +42,29 @@
printf("video_frames=%li\n",el.video_frames);
printf("video_width=%li\n",el.video_width);
printf("video_height=%li\n",el.video_height);
-   printf("video_inter=%li\n",el.video_inter);
-   printf("video_norm=%s\n",el.video_norm=='n'?"NTSC":"PAL");
+   printf("video_inter=");
+   switch (el.video_inter) {
+  case Y4M_ILACE_NONE: printf("p\n");  break;
+  case Y4M_ILACE_TOP_FIRST:  printf("t\n"); break;
+  case Y4M_ILACE_BOTTOM_FIRST:  printf("b\n"); break;
+  case Y4M_UNKNOWN:  printf("?\n"); break;
+  default:
+printf("?\n"); break;
+   }
+   printf("video_norm=%s\n",el.video_norm=='n'?"NTSC":"PAL");
printf("video_fps=%f\n",el.video_fps);
printf("video_sar_width=%i\n",el.video_sar_width);
printf("video_sar_height=%i\n",el.video_sar_height);
printf("max_frame_size=%li\n",el.max_frame_size);
-   printf("MJPG_chroma=%i\n",el.MJPG_chroma);
+   printf("MJPG_chroma=");
+   switch (el.MJPG_chroma) {
+  case CHROMA420: printf("420\n"); break;
+  case CHROMA422: printf("422\n"); break;
+  case CHROMA444: printf("444\n"); break;
+  case CHROMAUNKNOWN: printf("?\n"); break;
+  default:
+printf("?\n"); break;
+   }
/* Audio */
printf("has_audio=%i\n",el.has_audio);
printf("audio_bps=%i\n",el.audio_bps);

 
Selva




---
This SF.Net email is sponsored by BEA Weblogic Workshop
FREE Java Enterprise J2EE developer tools!
Get your free copy of BEA WebLogic Workshop 8.1 today.
http://ads.osdn.com/?ad_id=5047&alloc_id=10808&op=click
___
Mjpeg-users mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/mjpeg-users


Re: mjpegtools to dvdauthor (was Re: [Mjpeg-users] Too late?)

2004-08-27 Thread Selva Nair

Hi Anne,

> > May be we should move this thread to dvdauthor..
> >
> No - it worked perfectly.  I burned the -q 8 version and it plays on my 
> stand-alone player.  QED.  

Wonderful !

>Now I go for the new, improved version of my 
> production ;-)  Thanks for all the help.

Good luck.

Selva



---
This SF.Net email is sponsored by BEA Weblogic Workshop
FREE Java Enterprise J2EE developer tools!
Get your free copy of BEA WebLogic Workshop 8.1 today.
http://ads.osdn.com/?ad_id=5047&alloc_id=10808&op=click
___
Mjpeg-users mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/mjpeg-users


Re: mjpegtools to dvdauthor (was Re: [Mjpeg-users] Too late?)

2004-08-27 Thread Selva Nair
On Fri, 27 Aug 2004, Anne Wilson wrote:

> -BEGIN PGP SIGNED MESSAGE-
> Hash: SHA1
> 
> On Thursday 26 Aug 2004 20:52, Selva Nair wrote:
> >
> > For basic dvd you only need to do
> >
> I'm either blind or just plain stupid.  I built my-dvd.xml like this:
> 
> 

Be sure that /Data/Movies is empty and clean. It would be
better to use a project specific directory name /Data/Movies/coda
for book-keeping.

>   
>
>   
>   

   
Misplaced quote.  That line above should be 

>   
>
> 
> 
> but when I attempted to use it I got
> 
> dvdauthor -x ../my-dvd.xml
> DVDAuthor::dvdauthor, version 0.6.8.  Build options: gnugetopt magick
> Send bugs to <[EMAIL PROTECTED]>
> 
> ../my-dvd.xml:6: parser error : Opening and ending tag mismatch: vob line 0 
> and pgc
> 
>   ^
> ERR:  Error in parsing XML

May be we should move this thread to dvdauthor..

Selva




---
SF.Net email is sponsored by Shop4tech.com-Lowest price on Blank Media
100pk Sonic DVD-R 4x for only $29 -100pk Sonic DVD+R for only $33
Save 50% off Retail on Ink & Toner - Free Shipping and Free Gift.
http://www.shop4tech.com/z/Inkjet_Cartridges/9_108_r285
___
Mjpeg-users mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/mjpeg-users


mjpegtools to dvdauthor (was Re: [Mjpeg-users] Too late?)

2004-08-26 Thread Selva Nair
On Thu, 26 Aug 2004, Anne Wilson wrote:

> On Thursday 26 Aug 2004 19:10, Selva Nair wrote:

> > The moment of truth is when it plays on your standalone dvd player.
> > Then you will have something to tell everyone :)
> >
> But I need dvdauthor for that - right?  I managed it once, with a small
> stream, before my box had a melt-down, but I haven't got to grips with it
> again yet.  I will, though.

For basic dvd you only need to do

$ cd where-the-mpg-files-reside

$ dvdauthor -x my-dvd.xml

where my-dvd.xml looks like

   
  
   
 

  
 
   


That will layout the dvd file structure in
the directory ./my-dvd/ Make sure that ./my-dvd
is either empty or does not exist: dvdauthor keeps
appending titles to the destination directory,
so it is important to start from a clean state.

Check the authoring using xine (version 0.9.2x if possible :)

$ xine dvd:/$PWD/my-dvd/
(the trailing / is important)

Make an raw disk image using mkisofs

$ mkisofs -dvd-video -o my-dvd.raw ./my-dvd
 
( - you need a recent version of mkisofs for -dvd-video support
version >= 2.0 ?
  - you can combine this step with the burning step below to save
disk space and typing, but for the first try its better to
make the raw image and then burn. )

Burn my-dvd.raw to a dvd+/-rw disk using dvd+rw tools
or dvdrecord/cdrecord as appropriate for your dvd drive.

For +RW (recent versions of growisofs are supposed to with -RW too,
I haven't tried)

$ dvd+rw-format /dev/scd0

$ growisofs -dvd-compat -Z /dev/scd0=my-dvd.raw

( - replace /dev/scd0 by the appropriate device
  - need permission to write to /dev/scd0 
  - avoid gui front ends that tie you to a mouse and spoil all fun :)
  - not -dvd-compat is needed or not )

For -RW with dvdrecord

$ dvdrecord -dao dev=0,0,0 -v my-dvd.raw
 
 The resulting dvd should play main.mpg followed by ending.mpg with no
menus or other frills. It gets authored as two chapters corresponding to
the two sources as a single title. The playback may not be seamless
between the two sources, so it is recommended that you encode and mplex
the source for each title as a single file.

Make sure you have enough free disk space before you start -- the above
procedure with raw image saved requires free space of a little over twice
the size of all mpeg files being authored.

Selva




---
SF.Net email is sponsored by Shop4tech.com-Lowest price on Blank Media
100pk Sonic DVD-R 4x for only $29 -100pk Sonic DVD+R for only $33
Save 50% off Retail on Ink & Toner - Free Shipping and Free Gift.
http://www.shop4tech.com/z/Inkjet_Cartridges/9_108_r285
___
Mjpeg-users mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/mjpeg-users


Re: [Mjpeg-users] Too late?

2004-08-26 Thread Selva Nair
On Thu, 26 Aug 2004, Anne Wilson wrote:

> On Thursday 26 Aug 2004 16:49, Bernhard Praschinger wrote:
> > As mentionend mpeg2enc and mplex should do the job rather well.
> > I did not have a single message like the one you get, in the 0.9.23
> > version I use.
> >
> Hmm - I shall have to think how I can tactfully tell the xine people ;-)

The moment of truth is when it plays on your standalone dvd player.
Then you will have something to tell everyone :)

cheers,

Selva



---
SF.Net email is sponsored by Shop4tech.com-Lowest price on Blank Media
100pk Sonic DVD-R 4x for only $29 -100pk Sonic DVD+R for only $33
Save 50% off Retail on Ink & Toner - Free Shipping and Free Gift.
http://www.shop4tech.com/z/Inkjet_Cartridges/9_108_r285
___
Mjpeg-users mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/mjpeg-users


Re: [Mjpeg-users] Too late?

2004-08-25 Thread Selva Nair
On Wed, 25 Aug 2004, Anne Wilson wrote:

> I took the problem to the xine mailing list, and after making the file 
> available for download I got this reply:
> 
> The problem is caused by the video PTS values.
> xine tries to predict what the correct PTS value is.
> Then some video frames might have PTS values on them, and if these 
> differ from the predicted PTS, xine resets the buffers and jumps to the 
> new PTS value. xine lets the video PTS values dominate. Now, if the 
> Audio PTS values are correct, but the video PTS values are wrong, xine 
> will correct itself to the video, and this will result in xine thinking 
> the audio PTS values are wrong.
> 
> Extract of running xine with "xine --verbose=3"
> audio discontinuity #12, type is 2, disc_off 3904619
> waiting for in_discontinuity update #12
> fixing sound card drift by 1898 pts
> video discontinuity #12, type is 2, disc_off 3904619
> fixing sound card drift by 1425 pts
> audio discontinuity #13, type is 2, disc_off 4768619
> waiting for in_discontinuity update #13
> video discontinuity #13, type is 2, disc_off 4768619
> audio vpts adjusted to audio vpts
> audio jump, diff=75600
> 
> So, xine is seeing jumps in audio and video pts values.
> 
> Another possible reason for the problems, could be that the audio and 
> video are not multiplexed close enough together, so even with xine's 
> large buffers, it cannot fit the audio and video with the same PTS in 
> the buffer.
> 
> You need to redo the PTS values in the stream so that xine does not see 
> any discontinuities.
> 
> 
> What are PTS values?  What do I need to read?  I googled, but got a huge 
> number of replies and very little seemed to have much to do with it.  If you 
> haven't any additional words it's hard to sort wheat from chaff ;-)

The presentation times stamps are generated by mplex. Its the job of mplex
to multiplex audio and video closely together and generate appropriate
decode (DTS) and presentation (PTS) time stamps. I doubt that mplex is
generating wrong PTS values, but it is possible that you have found a
situation where the audio and video are not closely (close in terms of
sectors not time) multiplexed. Andrew could clarify that, but it seems
he does not frequent this list these days.

Selva



---
SF.Net email is sponsored by Shop4tech.com-Lowest price on Blank Media
100pk Sonic DVD-R 4x for only $29 -100pk Sonic DVD+R for only $33
Save 50% off Retail on Ink & Toner - Free Shipping and Free Gift.
http://www.shop4tech.com/z/Inkjet_Cartridges/9_108_r285
___
Mjpeg-users mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/mjpeg-users


Re: [Mjpeg-users] Too late?

2004-08-24 Thread Selva Nair
On Tue, 24 Aug 2004, Steven M. Schultz wrote:

> 
> On Tue, 24 Aug 2004, Selva Nair wrote:
> 
> > Agreed, if its sampling at 14.75Mhz no scaling is needed, only a 1
> > pixel padding.
> 
>   Oops - slight misunderstanding there.  For PAL if it was sampling at
>   13.5MHz there would be no need for scaling because the card would be

Oh no, in this context I was not referring to scaling required to burn
dvds, but to scaling (and padding) during capture -- I thought we were
debating on my statement that I do not like cards that _scale_ from
non-square to square pixels to which you pointed out that DC10 or its
driver does not _scale_ but simply sample at 14.75MHz to generate square
pixels.

In the first place I should have written that as I prefer cards that
sample at 13.5MHz as my destination is almost always dvds and that would
have avoided all this confusion. 

Of course, the 14.75MHz sampled "square-pixel" PAL sources have to be
appropriately scaled (with padding/clipping as necessary) to a valid dvd
frame size before encoding to dvds. 

Selva







---
SF.Net email is sponsored by Shop4tech.com-Lowest price on Blank Media
100pk Sonic DVD-R 4x for only $29 -100pk Sonic DVD+R for only $33
Save 50% off Retail on Ink & Toner - Free Shipping and Free Gift.
http://www.shop4tech.com/z/Inkjet_Cartridges/9_108_r285
___
Mjpeg-users mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/mjpeg-users


Re: [Mjpeg-users] Too late?

2004-08-24 Thread Selva Nair
On Tue, 24 Aug 2004, Steven M. Schultz wrote:

> 
> On Tue, 24 Aug 2004, Selva Nair wrote:
> 
> > I know, but I avoid capture cards that generate "square pixels" from
> > non-square pixel sources. As you know PAL or for that matter NTSC frames 
> 
>   It's not generating square from non-square.  It's sampling the
>   analog waveform at a frequency which gives 768 square pixels per line.
> 
>   A card is free to sample the analog at any frequency it wants.  The
>   DC10+ just happens to be sampling at the rate which gives 768 active
>   samples per line.
> 
> > are not exactly 4:3. I hope the card is padding the frame correctly before 
> > scaling.
> 
>   If it's sampling at 14.75MHz then no padding is required - the card
>   is delivering a 4/3 aspect picture at 768 pixels per line.

Agreed, if its sampling at 14.75Mhz no scaling is needed, only a 1
pixel padding.

> 
>   Even though I switched to the DV capture method quite some time ago
>   I still use y4mscaler a lot when converting HDTV to widescreen DVD
>   (the scaling's actually more cpu intense than the mpeg2 encoding as
>   it turns out) and thus need to convert from square pixels to 40:33
>   for 16/9 DVD.

Oh, HDTV.. well, so its getting harder and harder to avoid scaling, eh?

Thanks for the info.

Selva




---
SF.Net email is sponsored by Shop4tech.com-Lowest price on Blank Media
100pk Sonic DVD-R 4x for only $29 -100pk Sonic DVD+R for only $33
Save 50% off Retail on Ink & Toner - Free Shipping and Free Gift.
http://www.shop4tech.com/z/Inkjet_Cartridges/9_108_r285
___
Mjpeg-users mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/mjpeg-users


Re: [Mjpeg-users] Too late?

2004-08-24 Thread Selva Nair
On Tue, 24 Aug 2004, Steven M. Schultz wrote:

> > > Out of curiosity, how did you end up with a 768x576 interlaced PAL avi?
> 
> 
>   That's the square pixel PAL full frame size of course ;)
> 
>   768/576 = 4/3

I know, but I avoid capture cards that generate "square pixels" from
non-square pixel sources. As you know PAL or for that matter NTSC frames 
are not exactly 4:3. I hope the card is padding the frame correctly before 
scaling.

> 
> > My capture card is a DC10+ under v4l - that's the resolution it captures at 
> > full size.  On my previous small project I used -d 2, but I think on this one 
> > I used -d 1 in lavrec.
> 
>   Yep - and DC10+ cards generate square pixels (or, if they can provide
>   Rec.601 pixels then the drivers/software aren't requesting that 
>   format).  Thus the need to resample/scale to the DVD frame size.

Funny that it cant be convinced to deliver 704x576 or padded 720x576 
frames.

Selva



---
SF.Net email is sponsored by Shop4tech.com-Lowest price on Blank Media
100pk Sonic DVD-R 4x for only $29 -100pk Sonic DVD+R for only $33
Save 50% off Retail on Ink & Toner - Free Shipping and Free Gift.
http://www.shop4tech.com/z/Inkjet_Cartridges/9_108_r285
___
Mjpeg-users mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/mjpeg-users


Re: [Mjpeg-users] Too late?

2004-08-24 Thread Selva Nair
On Tue, 24 Aug 2004, Anne Wilson wrote:

> 
> I did try it in totem, but that yielded no info at all.  The result was at 
> least as bad as with xine, possibly worse.

totem is just another front-end to xine that uses the
same xine-library for playback, isn't it?

Selva




---
SF.Net email is sponsored by Shop4tech.com-Lowest price on Blank Media
100pk Sonic DVD-R 4x for only $29 -100pk Sonic DVD+R for only $33
Save 50% off Retail on Ink & Toner - Free Shipping and Free Gift.
http://www.shop4tech.com/z/Inkjet_Cartridges/9_108_r285
___
Mjpeg-users mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/mjpeg-users


Re: [Mjpeg-users] Too late?

2004-08-24 Thread Selva Nair
On Tue, 24 Aug 2004, Anne Wilson wrote:

> It isn't that I de-interlaced.  I wanted a series of 5-second-ish stills 
> pulled from the main video - a sort of summary to pull things together 
> instead of the abrupt ending.  I started each of these from a single frame 
> pulled from the main recording.
> 
> Since this project is very much a learning experience I'm quite prepared to do 
> the whole lot again.  Would that be a matter of adding -I t -L 1 to jpeg2yuv?

Yes "-I t" if the rest of the video is top-field-first (check with
lavinfo), and "-L 1" if the jpeg is an interleaved frame, not one field
after the other. I seldom use jpeg2yuv, so I am copying from the manpage.
(ppmtoy4m is the way to go, but I digress :)

> 
> > > Or is it maybe that I didn't get a good quality sound grab in the
> > > first place?
> >
> > I am not sure I understand. You mean audio quality?
> >
> Yes - I was wondering whether I could have got a faster sampling rate or 
> something, to make it less of a gap.

Sorry, I am missing here something. Which gap ?

> If I re-create all the avis in an interlaced mode, will the blends 
> automatically be interlaced?

Generally blending is a pixel-wise operation so interlacing should
not be affected. In particular, if you are using transit.flt to generate
the transition, then yes interlacing will be preserved.

> Now there's another question.  The main avis are in 768x576, whereas I want 
> 720x576.  I was expecting to use yuvscaler just prior to encoding.  Of course 

Out of curiosity, how did you end up with a 768x576 interlaced PAL avi?

> I had used yuvscaler on the coda, so that I could check that it was working.  
> I guess that it would be better to take it on trust and then convert them all 
> at the same time when encoding?

I think so.

> 
> Sorry for so many questions, but I am trying to get the concepts clear.  And 
> thanks to both you and Steven for clarifying so many things.

You are welcome! 

Selva



---
SF.Net email is sponsored by Shop4tech.com-Lowest price on Blank Media
100pk Sonic DVD-R 4x for only $29 -100pk Sonic DVD+R for only $33
Save 50% off Retail on Ink & Toner - Free Shipping and Free Gift.
http://www.shop4tech.com/z/Inkjet_Cartridges/9_108_r285
___
Mjpeg-users mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/mjpeg-users


Re: [Mjpeg-users] Too late?

2004-08-24 Thread Selva Nair
On Tue, 24 Aug 2004, Anne Wilson wrote:

> OK - I prepared a coda_q4.mpg and launched xine from a console.  I saw exactly 
> what you have both been suggesting:
> 
> xine: found demuxer plugin: MPEG program stream demux plugin
> av_offset=0 pts
> spu_offset=0 pts
> fixing sound card drift by -1453 pts
> video_out: throwing away image with pts 2962135 because it's too old (diff : 
> 3703).
> 200 frames delivered, 0 frames skipped, 1 frames discarded
> fixing sound card drift by 3365 pts
> fixing sound card drift by 2534 pts
> fixing sound card drift by 1899 pts
> fixing sound card drift by 1423 pts
>   #lots more of these

Occasional drifts are okay, but this is far too many..

Although these messages suggest problem with the sound card driver or
unusual clock drifts, it could well be something wrong with this version
of xine. Tuning some of the xine configuration parameters such as
audio.av_sync_method and others in the .xine/config file may help, but I
would first check with the xine mailing list.

Selva




---
SF.Net email is sponsored by Shop4tech.com-Lowest price on Blank Media
100pk Sonic DVD-R 4x for only $29 -100pk Sonic DVD+R for only $33
Save 50% off Retail on Ink & Toner - Free Shipping and Free Gift.
http://www.shop4tech.com/z/Inkjet_Cartridges/9_108_r285
___
Mjpeg-users mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/mjpeg-users


Re: [Mjpeg-users] Too late?

2004-08-24 Thread Selva Nair

Hi,

> 
> Tutorial time again, though ;-)  First, what do these parameters mean (it's 
> not obvious from the man page)?
> - -4 2 -2 1

I dont know much about mpeg2 encoding to comment on that; I can only say
that -4 and -2 takes an argument in the range 1 to 4, smaller numbers lead 
to a more thorough motion estimation search which means better quality at
the expense of speed. From my own experience and from what I have learned 
from this list -4 2 -2 1 runs much faster than -4 1 -2 1 and still 
produces almost as good an output as the latter. Hopefully you will get 
more expert explanations from others.

> 
> Then, the problems I've had appear to be caused by the way I have created the 
> avi.  This was done by grabbing a series of single frames, creating 25fps 
> avis from them, creating transition avis, then writing an eli that could 
> bring them together into one.  Is there any way I could have lessened the 
> chances of the problems I've had?  Could they, for instance, be made 
> interlaced in some way?  And would it have helped?

Not that it would have helped, but in general its not a good idea to
de-interlace unless absolutely necessary. Was there any special reason to
deinterlace the input? I would have kept it all interlaced if the source
is interlaced.  You lose quality when you de-interlace.

> 
> Or is it maybe that I didn't get a good quality sound grab in the 
> first place?  

I am not sure I understand. You mean audio quality?

> If so, again, recommendations would help.
> 
> Finally, the main recording is in the form of a series of avis 
> (filename02%.avi), interlaced.  The coda is formed from a series of 
> non-interlaced avis.  I know I can't create a transition between the, but 
> will I encounter problems when I try to stitch them together into one long 
> production?

lav2yuv will complain if you try to mix interlaced and progressive
sources. One can think of some ways of handling this without re-encoding
but it may be easier to re-encode coda as interlaced with the same field
order, frame size, aspect ratio and fps as the rest of the video.

Selva



---
SF.Net email is sponsored by Shop4tech.com-Lowest price on Blank Media
100pk Sonic DVD-R 4x for only $29 -100pk Sonic DVD+R for only $33
Save 50% off Retail on Ink & Toner - Free Shipping and Free Gift.
http://www.shop4tech.com/z/Inkjet_Cartridges/9_108_r285
___
Mjpeg-users mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/mjpeg-users


Re: [Mjpeg-users] Too late?

2004-08-24 Thread Selva Nair
On Tue, 24 Aug 2004, Anne Wilson wrote:

> -BEGIN PGP SIGNED MESSAGE-
> Hash: SHA1
> 
> On Tuesday 24 Aug 2004 04:16, Selva Nair wrote:
> > Hi Anne,
> >
> Hi, Selva
> 
> >   At last I managed to reproduce your stuttering audio on another machine
> > with the latest xine (xine-lib-1-rc5, xine-ui-0.99.2). The older
> > version of xine plays it fine, though.
> >
> Interesting.
> 
> >   After some experimentation this is what I have concluded. The audio
> > stutters when the average bitrate is much below the dvd rate (see below)
> > but is mplexed at the dvd rate (with -f 8).  This could be something
> > peculiar about this version of xine, may be not. xine-0.9.20, mplayer and
> > vlc play the clip fine.

I do not understand why multiplex rate should affect playback, that's why
I left it for your experimentaion instead of spamming the list 
with my half-baked conclusions ;)

By the way, later (> 1.6.1 release?) versions of mplex can be forced to
use a lower bitrate than the default of 10.08Mbps with -f 8. That may be
another way to multiplex low bit-rate streams. 

I really do not know whether its important to keep the mplex rate not too
much higher than the actual video+audio rate. Also is there a practical
lower limit for dvd bitrate? 

> >
> I've left the whole quoted, because it will be useful in the archives, I 
> think.  This is definitely the right track.  Encoding at -q 4 brought fewer 
> stutters, -q 3 didn't seem much better - the file size was not much bigger, 
> and there were still quite a few stutters.  At -q  the file size shot up to 
> around 56 MB, and the only stutters were one at the beginning, where there 
> was a fault in the input file, so unavoidable, and in the last 2-3 seconds.  
> Although it's not perfect I could live with that.

Even if the issue was with the mplex rate, that much fine tuning should
not be required. I never had any audio problem with mpeg2enc/mplex
although I haven't used used extreme values of bit rates. Possibly
something is wrong with xine too: if you run xine with --verbose you may
get some messages on audio drifts, if any.

Selva



---
SF.Net email is sponsored by Shop4tech.com-Lowest price on Blank Media
100pk Sonic DVD-R 4x for only $29 -100pk Sonic DVD+R for only $33
Save 50% off Retail on Ink & Toner - Free Shipping and Free Gift.
http://www.shop4tech.com/z/Inkjet_Cartridges/9_108_r285
___
Mjpeg-users mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/mjpeg-users


Re: [Mjpeg-users] Too late?

2004-08-23 Thread Selva Nair

Hi Anne,


On Mon, 23 Aug 2004, Anne Wilson wrote:

> -BEGIN PGP SIGNED MESSAGE-
> Hash: SHA1
> 
> On Monday 23 Aug 2004 21:13, Steven M. Schultz wrote:
> >
> > If you have a system monitoring tool available it would be interesting
> > to start that and observe the system's behaviour.   'xosview' is a good
> > tool with color coded status indicators - if you see a high percentage
> > of "system"  (kernel) time then you have found the problem area.
> >
> I'll play around tomorrow and see if I can get more info.
> 
> Anne
> - -- 
> Registered Linux User No.293302
> Have you visited http://twiki.mdklinuxfaq.org yet?
> -BEGIN PGP SIGNATURE-
> Version: GnuPG v1.2.4 (GNU/Linux)
> 
> iD8DBQFBKlpSkFAvMr/nNX8RAt32AJsF2Gu7rJKqreT2QpNE3v9Js/b7ZwCeNxLH
> UbEpF8bHBpx/3Wp2LKvkqxE=
> =05nG
> -END PGP SIGNATURE-
> 
> 
> ---
> SF.Net email is sponsored by Shop4tech.com-Lowest price on Blank Media
> 100pk Sonic DVD-R 4x for only $29 -100pk Sonic DVD+R for only $33
> Save 50% off Retail on Ink & Toner - Free Shipping and Free Gift.
> http://www.shop4tech.com/z/Inkjet_Cartridges/9_108_r285
> ___
> Mjpeg-users mailing list
> [EMAIL PROTECTED]
> https://lists.sourceforge.net/lists/listinfo/mjpeg-users
> 



---
SF.Net email is sponsored by Shop4tech.com-Lowest price on Blank Media
100pk Sonic DVD-R 4x for only $29 -100pk Sonic DVD+R for only $33
Save 50% off Retail on Ink & Toner - Free Shipping and Free Gift.
http://www.shop4tech.com/z/Inkjet_Cartridges/9_108_r285
___
Mjpeg-users mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/mjpeg-users


Re: [Mjpeg-users] Too late?

2004-08-23 Thread Selva Nair

Hi Anne,

> it plays.  One problem, though.  By now I don't have the original file, and 
> I'm pretty confused about which of the myriad commands I've tried is the one 
> to give me a clean, basic DVD write.  Could you please remind me?  Is it just 
> lav2yuv coda.eli | yuvscaler -O DVD | yuvdenoise | mpeg2enc -f 8 -q 7 -4 1 -2 
> 1 -o coda.m2v

Looks okay, except that I would use -4 2 -2 1 instead of -4 1 -2 1. Also
if the original coda.eli is 720x576, you do not need yuvscaler[*] and for 
the
test run you can leave out yuvdenoise -- keep it simple.

> then
> mplex -f 8 coda.mp2 coda.m2v -o filename.mpg ?

Yes.

> 
> Is there any way of checking whether I have got both files in the correct 
> format before mplexing?  Maybe I should build them both again to be sure.

The mplex output contains a number of parameters that you can check  --
frame size (720x576), fps (25), number of video pictures (fps x length of
the video in seconds), audio sampling frequency and mode (48000 Hz,
stereo), audio bitrate (224000/8 = 28600bytes/sec) audio stream length 
(approx. = bitrate in bytes x length in seconds), average and peak
bitrates of the mplexed stream (should be less than 10.08 Mbps).
Finally make sure  mplex completes without any errors, especially 
buffer under-runs. The o/p you posted in the morning looked
fine in all these respects.

Selva

[*] The last time I used yuvscaler it did not support -O DVD,
but I haven't touched it after y4mscaler appeared. Make sure
it generates 720x576 frames for PAL.




---
SF.Net email is sponsored by Shop4tech.com-Lowest price on Blank Media
100pk Sonic DVD-R 4x for only $29 -100pk Sonic DVD+R for only $33
Save 50% off Retail on Ink & Toner - Free Shipping and Free Gift.
http://www.shop4tech.com/z/Inkjet_Cartridges/9_108_r285
___
Mjpeg-users mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/mjpeg-users


Re: [Mjpeg-users] Too late?

2004-08-23 Thread Selva Nair

On Mon, 23 Aug 2004, Anne Wilson wrote:

>> Try mplexing the 44100 khz sound with the DVD size mpeg2 using -f 8.
>> The resulting file wont be dvd complaint, but is a valid mpeg2, so
>> mplayer (and possibly xine) should play it correctly. That way you can
>> confirm whether the trouble is with 48k sampling.
>>
>> Selva

> I'm tired, and maybe not thinking clearly.  I tried mplexing the m2v
> with the SVCD sound - is that what you intended?  Anyway, the result is
> the same.  Still the stutters.  (BTW, yes, there was a little noise on 
> the original, a few clicks, but that's not important, as long as we can
> get the music working).

Hmm.. As I wrote earlier, the short clip (6 seconds) plays fine here..

> Could it be disk access that's too slow?  I keep meaning to try hdparm on it, 
> as it's probably running at the slowest basic speed.  Certainly the system is 

What is the o/p of  

# hdparm -iv /dev/hda
(replace /dev/hda with the appropriate device)

> fast enough to handle professional dvds, so I don't think it's cpu or 
> graphics card.  Hard disk sounds more likely to me.  What do you think?

Have you tried playing any dvd-rate mpeg2 file from disk? You
can copy, say, a short chapter from a dvd and try. If you have ogle, 
mplayer or vlc, try those too. Or author it on a dvd-rw and see whether
your standalone dvd-player can play it! Be sure to author it using,
say, dvdauthor, not simply copy the mpg to the disk.

Selva






---
SF.Net email is sponsored by Shop4tech.com-Lowest price on Blank Media
100pk Sonic DVD-R 4x for only $29 -100pk Sonic DVD+R for only $33
Save 50% off Retail on Ink & Toner - Free Shipping and Free Gift.
http://www.shop4tech.com/z/Inkjet_Cartridges/9_108_r285
___
Mjpeg-users mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/mjpeg-users


Re: [Mjpeg-users] Too late?

2004-08-23 Thread Selva Nair
On Mon, 23 Aug 2004, Anne Wilson wrote:

> -BEGIN PGP SIGNED MESSAGE-
> Hash: SHA1
> 
> On Monday 23 Aug 2004 16:17, Steven M. Schultz wrote:
> > On Mon, 23 Aug 2004, Anne Wilson wrote:
> > > I forgot to say that the reason I would try an SVCD was because I had
> > > tried playing the mpg back in both xine and totem with the same result. 
> > > I suppose
> >
> > I'm wondering if it's a soundcard/driver issue ...
> >

me too.. more below.

>   It's a Creative Audigy Platinum, and I'm not convinced all is well 
> with this alsa driver.

..

> 
> You were quite right, of course.  I've now done the whole thing again for svcd 
> and it plays perfectly in totem.  Not a stutter to be heard.  So - we still 
> need to find why SCVD will do it properly, but DVD won't.  I have to assume 

The clip you sent me plays fine on my machine (except for some noise, 
that I guess is from the original..) May be your sound card/driver has 
problem playing 48KHz sound. I  vaguley recall having trouble with 48k on 
some sound cards.

Try mplexing the 44100 khz sound with the DVD size mpeg2 using -f 8.
The resulting file wont be dvd complaint, but is a valid mpeg2, so 
mplayer (and possibly xine) should play it correctly. That way you can
confirm whether the trouble is with 48k sampling.

Selva



---
SF.Net email is sponsored by Shop4tech.com-Lowest price on Blank Media
100pk Sonic DVD-R 4x for only $29 -100pk Sonic DVD+R for only $33
Save 50% off Retail on Ink & Toner - Free Shipping and Free Gift.
http://www.shop4tech.com/z/Inkjet_Cartridges/9_108_r285
___
Mjpeg-users mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/mjpeg-users


Re: [Mjpeg-users] Too late?

2004-08-23 Thread Selva Nair

Hi Anne,

> I forgot to say that the reason I would try an SVCD was because I had tried  
> playing the mpg back in both xine and totem with the same result.  I suppose 
> I could burn a cd with the file, but for a 2-minute test I didn't want to be 
> bothered. Perhaps I should.

Most dvd players wont play dvd filesystem burned into a cd, so if you
are testing with a CD-R/RW use vcd or svcd profile.

> 
> Meanwhile, I have tried the SVCD test.  I just do not understand this.
> 
> mplex -f4 coda.m2v coda_soundSVCD.mp2 -o codaSVCD.mpg

Your bit rate 4500kbps is far above standard SVCD rate, mplex -f 4
will not work. If you want to make a standard SVCD, use
 mpeg2enc -f 4 -q 8 (later you can experiment with -q value for 
optimal quality).

>INFO: [mplex] mplex version 1.6.2 (2.2.3 $Date: 2004/01/13 20:45:26 $)
>INFO: [mplex] File coda.m2v looks like an MPEG Video stream.
>INFO: [mplex] File coda_soundSVCD.mp2 looks like an MPEG Audio stream.
>INFO: [mplex] Video stream 0: profile 4 selected - ignoring non-standard 
> options!
>INFO: [mplex] Found 1 audio streams and 1 video streams
>INFO: [mplex] Selecting SVCD output profile
>INFO: [mplex] Multiplexing video program stream!
>INFO: [mplex] Scanning for header info: Video stream e0 (coda.m2v)
>INFO: [mplex] VIDEO STREAM: e0
>INFO: [mplex] Frame width : 720
>INFO: [mplex] Frame height: 576
>INFO: [mplex] Aspect ratio: 4:3 display
>INFO: [mplex] Picture rate: 25.000 frames/sec
>INFO: [mplex] Bit rate: 450 bits/sec
>INFO: [mplex] Vbv buffer size : 229376 bytes
>INFO: [mplex] CSPF: 0
>INFO: [mplex] Scanning for header info: Audio stream c0 
> (coda_soundSVCD.mp2)
>INFO: [mplex] MPEG AUDIO STREAM: c0
>INFO: [mplex] Audio version  : 1.0
>INFO: [mplex] Layer  :2
>INFO: [mplex] CRC checksums  :   no
>INFO: [mplex] Bit rate   :28672 bytes/sec (224 kbit/sec)
>INFO: [mplex] Frequency  : 44100 Hz
>INFO: [mplex] Mode   :0 stereo
>INFO: [mplex] Mode extension :0
>INFO: [mplex] Copyright bit  :0 no copyright
>INFO: [mplex] Original/Copy  :0 copy
>INFO: [mplex] Emphasis   :0 none
>INFO: [mplex] SYSTEMS/PROGRAM stream:
>INFO: [mplex] rough-guess multiplexed stream data rate: 4827544
>INFO: [mplex] target data-rate specified   : 2788800

The target data rate is fixed by -f 4 to svcd limit but the actual bitrate
of your stream is much larger.

> ++ WARN: [mplex] Target data rate lower than computed requirement!
> ++ WARN: [mplex] N.b. a 20% or so discrepancy in variable bit-rate
> ++ WARN: [mplex] streams is common and harmless provided no time-outs will 
> occur
>INFO: [mplex] Run-in Sectors = 78 Video delay = 46800 Audio delay = 50400
>INFO: [mplex] New sequence commences...
>INFO: [mplex] Video e0: buf= 235520 frame=00 sector=
>INFO: [mplex] Audio c0: buf=   4096 frame=00 sector=
> ++ WARN: [mplex] Stream e0: data will arrive too late sent(SCR)=591000 
> required(DTS)=591000
> ++ WARN: [mplex] Video e0: buf= 220298 frame=000151 sector=0504
> ++ WARN: [mplex] Audio c0: buf=   2424 frame=000232 sector=0074
> ++ WARN: [mplex] Stream e0: data will arrive too late sent(SCR)=1181400 
> required(DTS)=1181400
> ..
> **ERROR: [mplex] Too many frame drops -exiting

If you want to make a nonstd svcd with video bitrate of 4500 kbps,
pass -f 5 to mplex. You can leave out -r option and let mplex
compute the required bitrate, but if that fails try with -r 4900
or so. But be warned that most standalone players will not play
such high bitrate svcd streams correctly.

Selva




---
SF.Net email is sponsored by Shop4tech.com-Lowest price on Blank Media
100pk Sonic DVD-R 4x for only $29 -100pk Sonic DVD+R for only $33
Save 50% off Retail on Ink & Toner - Free Shipping and Free Gift.
http://www.shop4tech.com/z/Inkjet_Cartridges/9_108_r285
___
Mjpeg-users mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/mjpeg-users


Re: [Mjpeg-users] Too late?

2004-08-23 Thread Selva Nair

Hi Anne,

  I cant see anything obviously wrong with your mplex output. 


On Mon, 23 Aug 2004, Anne Wilson wrote:

> I just don't get it, Selva. I've rebuilt the soundtrack then mplexed it again, 
> and I still have stuttering sound.  I'm posting the entire output of mplex, 
> in case it gives you any clues:
> 
> mplex -f8 coda.m2v coda_sound.mp2 -o coda.mpg

>INFO: [mplex] No. Pictures: 2909

2909 frames/ 25fps = 116.36 seconds of video

>INFO: [mplex] Audio stream length 3258528 bytes.

3258528*8bits/(224 kbits/sec) = 116.37 seconds of audio
 
>INFO: [mplex] Syncwords  : 4849
>INFO: [mplex] Frames : 4849 padded
>INFO: [mplex] Frames :0 unpadded
>INFO: [mplex] BUFFERING min 15 Buf max 683
>INFO: [mplex] MUX STATUS: no under-runs detected.

The video and and audio matches well, the minor difference 
in length may be due to padding of audio packets. All other
parameters also look right.

Probably something wrong with your mpeg2 player? 

Selva






---
SF.Net email is sponsored by Shop4tech.com-Lowest price on Blank Media
100pk Sonic DVD-R 4x for only $29 -100pk Sonic DVD+R for only $33
Save 50% off Retail on Ink & Toner - Free Shipping and Free Gift.
http://www.shop4tech.com/z/Inkjet_Cartridges/9_108_r285
___
Mjpeg-users mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/mjpeg-users


Re: [Mjpeg-users] Too late?

2004-08-22 Thread Selva Nair

On Sun, 22 Aug 2004, Anne Wilson wrote:

> >
> Hi, Selva.  That went through without a hicough, thanks, but the soundtrack is 
> terrible in both xine and totem.  It drops out all over.  Any idea what might 
> have caused that?

Could be that your sound track is sampled at 44100 but xine expects 48000 
when you playing it as a dvd stream. mp2enc defaults to 44100, so
you may want to try

lav2wav coda.avi | mp2enc -r 48000 -o coda.mp2

I think xine can play generic mpeg2 with sound sampled at non-dvd rates,
so your problem could be something else.

Selva



---
SF.Net email is sponsored by Shop4tech.com-Lowest price on Blank Media
100pk Sonic DVD-R 4x for only $29 -100pk Sonic DVD+R for only $33
Save 50% off Retail on Ink & Toner - Free Shipping and Free Gift.
http://www.shop4tech.com/z/Inkjet_Cartridges/9_108_r285
___
Mjpeg-users mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/mjpeg-users


Re: [Mjpeg-users] Too late?

2004-08-22 Thread Selva Nair
On Sun, 22 Aug 2004, Anne Wilson wrote:

> -BEGIN PGP SIGNED MESSAGE-
> Hash: SHA1
> 
> On Sunday 22 Aug 2004 15:18, Bernhard Praschinger wrote:
> >
> > I guess you have used the -b option when you encoded the mpg movie.
> > And you have to add that option +audio bitrate to mplex with the -r
> > option.
> >
> I'm still working at a very simple level, starting from settings you gave me 
> and adapting only a little at a time ;-) - so on checking back I find that I 
> do have -b 4500 in the mpg encoding command.
> 
> > So you command should llook like that:
> > mplex -r 4750 -V coda.m2v coda_sound.mp2 -o coda.mpg
> >
> I'm still getting similar errors.  I think this bit of output is the bit you 
> need to see:

Its much easier to use one of the presets unless you really really want
to fine-tune the bitrate (-r ) video buffer size etc.. In your case

mplex -f 8 coda.m2v coda_sound.mp2 -o coda.mpg

should. It will produce a DVD compliant stream, hope that cant hurt. Same
with mpeg2enc:

lav2yuv movie.eli   | mpeg2enc -f 8 -q 6 -o coda.m2v

should give you something to start with. Later you can play with
-q, -r etc.. I have not been following this thread closely, so sorry if 
I missed out something.

Selva



---
SF.Net email is sponsored by Shop4tech.com-Lowest price on Blank Media
100pk Sonic DVD-R 4x for only $29 -100pk Sonic DVD+R for only $33
Save 50% off Retail on Ink & Toner - Free Shipping and Free Gift.
http://www.shop4tech.com/z/Inkjet_Cartridges/9_108_r285
___
Mjpeg-users mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/mjpeg-users


Re: [Mjpeg-users] skip first frame

2004-07-14 Thread Selva Nair
On Wed, 14 Jul 2004, Jérémie Knuesel wrote:

> Hello,
> 
> How can I skip the first frame in a yuv stream?
> 
> I pipe the data from mplayer through y4mscaler to mpeg2enc. The problem
> is that mplayer often puts a plain green frame at the beginning of the
> stream. How can I skip it in the encoding?

Here is a utility that I use to trim yuv4mpeg streams. Link it with 
-lmjpegutils and try 'y4mcut -h' for usage.

Selva
/*
 *    Copyright (C) 2001 Selva Nair <[EMAIL PROTECTED]>
 *
 *This program is free software; you can redistribute it and/or modify
 *it under the terms of the GNU General Public License as published by
 *the Free Software Foundation; either version 2 of the License, or
 *(at your option) any later version.
 *
 *This program is distributed in the hope that it will be useful,
 *but WITHOUT ANY WARRANTY; without even the implied warranty of
 *MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 *GNU General Public License for more details.
 *
 *You should have received a copy of the GNU General Public License
 *along with this program; if not, write to the Free Software
 *Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
 *
 */
/* Build instructions
 * gcc -Wall -O2 -DHAVE_STDINT_H -I /usr/local/include/mjpegtools -o y4mcut \
 *  y4mcut.c -lmjpegutils
 */ 
#include 
#include 
#include 
#include 
#include 
#include 

static void usage(char *name )
{
fprintf(stderr,
   "A filter to select specified number of YUV4MPEG\n"
   "frames from input stream. Reads input from stdin\n"
   "and outputs to stdout as a YUV4MPEG stream.\n"
   "Usage: %s: [-h] [-v num] [-s num] [-o num]\n"
   "   -h - print this help\n"
   "   -v - verbosity [0..2]\n\n"
   "   -s num - skip num frames (0)\n"
   "   -o num - output num frames only -- use\n"
   "  a negative  number for all (-1)\n"
"Author: Selva Nair\n", name);
}

int main(int argc, char *argv[])
{
int verbose = 1;
int nskip = 0;
int nout = -1;

char *prog = "y4mcut";
int i;
int input_fd = 0;
int output_fd = 1;
int c;
int frames_in, frames_out;
int horz, vert;
unsigned char   *frame[3];
y4m_stream_info_t istream;
y4m_frame_info_t iframe;

while((c = getopt(argc, argv, "hv:s:o:")) != EOF) {
switch(c) {
case 'v':
verbose = atoi (optarg);
if( verbose < 0 || verbose >2 )
{
usage (argv[0]);
exit (1);
}
(void)mjpeg_default_handler_verbosity(verbose);
break;

case 'h':
usage (argv[0]);
exit(0);  
case 's':
if(sscanf(optarg, "%d", 
 &nskip) != 1) usage(argv[0]);
break;
case 'o':
if(sscanf(optarg, "%d", 
 &nout) != 1) usage(argv[0]);
break;
default:
exit(0);
}
}

y4m_init_stream_info(&istream);
y4m_init_frame_info(&iframe);

i = y4m_read_stream_header(input_fd, &istream);
i = y4m_write_stream_header(output_fd, &istream);
if (i != Y4M_OK)
mjpeg_error_exit1("Input stream error: %s", y4m_strerr(i));

horz = istream.width;
vert = istream.height;
frame[0] = alloca(horz * vert);
frame[1] = alloca((horz / 2) * (vert / 2));
frame[2] = alloca((horz / 2) * (vert / 2));

frames_in = 0;
frames_out = 0;
while (y4m_read_frame(input_fd, &istream, &iframe, frame) == Y4M_OK) {
   frames_in++;
   if(frames_in <= nskip) continue;
   if (nout < 0 || frames_out < nout ) {
 if(y4m_write_frame(output_fd, &istream, &iframe, frame) == Y4M_OK) 
frames_out++;
 else {
mjpeg_warn("%s: error writing output frame", prog);
break;
}
   }
   else {
 mjpeg_info("%s: Skipped %d frames"

Re: [Mjpeg-users] problems with lavtrans generating bad jpegs

2003-10-02 Thread Selva Nair
On Thu, 2 Oct 2003, M G wrote:

> It seems there is a problem with the jpeg headers, the original 
> video plays fine and I get the same results for any video I try. 
> Does anyone know what causing this? Is there any software out there 
> that can fix jpeg headers? I'm really tearing my hair out over 
> this one as I need to find some way of splitting these video files 
> into indevidual frames. Any help would be greatly appreciated.

I would urge you to use y4mtoppm :

lav2yuv movie.avi | y4mtoppm -L | pnmsplit - image-%d.ppm 

(if you have progressive frames you dont need -L )

Well, this gives you ppm frames, but you can easily convert those
ppms to jpegs if need be. Although I have previously extracted valid jpeg
frames using lavtrans, it never worked the way I expect it to..

HTH,

Selva



---
This sf.net email is sponsored by:ThinkGeek
Welcome to geek heaven.
http://thinkgeek.com/sf
___
Mjpeg-users mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/mjpeg-users


Re: [Mjpeg-users] max bitrate

2003-08-15 Thread Selva Nair
On 14 Aug 2003, Florin Andrei wrote:

> Quoting from the HOWTO, the "Creating DVD's" section:
> 
> "The maximum bitrate is set to 7500kBps" (it talks about mpeg2enc)
 
  ??
> 
> Is that true? I ran mpeg2enc with -b 9800 and it didn't complain. Or is
> the max bitrate set automatically when -b goes beyond it?

The last time I looked (1.6.?) the default for -f 8 was 7500kbps
(kilobits/sec, not kBps), or the -b value if specified (again, in kbps)
with a max cut-off of 1kbps. If you use vbr, this refers to the peak
video rate. These numbers could be different in the current CVS version.

IIRC, in versions 1.6.0 and probably 1.6.1 the mplex mux rate for DVD
profile is hard coded to 1008000kbps irrespective of the -r value
specified on the command line. I think this has been "corrected" in the
CVS.

Selva



---
This SF.Net email sponsored by: Free pre-built ASP.NET sites including
Data Reports, E-commerce, Portals, and Forums are available now.
Download today and enter to win an XBOX or Visual Studio .NET.
http://aspnet.click-url.com/go/psa0013ave/direct;at.aspnet_072303_01/01
___
Mjpeg-users mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/mjpeg-users


Re: [Mjpeg-users] mjpeg-tools and DVDs

2003-07-11 Thread Selva Nair
On Fri, 11 Jul 2003, Bernhard Frühmesser wrote:

> Hello,
>
> Does anybody know if the programs tocgen and ifogen come with the
> program dvdauthor?
>

Hi,

 dvdauthor is all that you need. 

See README in the distribution.

Selva



---
This SF.Net email sponsored by: Parasoft
Error proof Web apps, automate testing & more.
Download & eval WebKing and get a free book.
www.parasoft.com/bulletproofapps1
___
Mjpeg-users mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/mjpeg-users


Re: [Mjpeg-users] movies from PPM?

2003-06-11 Thread Selva Nair

On Wed, 11 Jun 2003, Matto Marjanovic wrote:

>  >
>  >Ah, but if you read Martin Sitter's DVD Studio Pro book (or take a look
>  >at books on Adobe Photoshop) it would seem that NTSC TVs use 9:10
> 
> I guess Martin Sitter read a lot of books on Photoshop, instead of reading
>  books on video engineering.  NTSC TV's use 10:11 (as referenced to the
>  "industry standard" square pixel aspect ratio).

Precisely. 

I was hiding that complication of "industry standard" square pixels
(396/395 for NTSC) versus true square pixels. While scaling from computer
graphics, I personally use 648x486 true square pixel frames, scale by
79/72 (11/10 times 395/396 = 79/72) to 711x486 and then crop/pad to
720x480.  But I wont dare mention that in public..!

Selva




---
This SF.NET email is sponsored by: eBay
Great deals on office technology -- on eBay now! Click here:
http://adfarm.mediaplex.com/ad/ck/711-11697-6916-5
___
Mjpeg-users mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/mjpeg-users


Re: [Mjpeg-users] movies from PPM?

2003-06-11 Thread Selva Nair
On Wed, 11 Jun 2003, Steven M. Schultz wrote:

> Hi -
> 
> > From: Selva Nair <[EMAIL PROTECTED]>
> > The general advice is to avoid vertical scaling mainly because vertical
> > scalers should be interlacing-aware -- also for interlaced frames the
> 
>   and y4mscaler is, I believe, interlacing aware ;)
> 
>   Downscaling feels more correct.  Removing information is preferable
>   to synthesizing it.
> 
> > may not matter much, though. In any case, you will get proper aspect ratio
> > only if you scale by the correct SAR value: 10:11 in case of NTSC. So
> 
>   Ah, but if you read Martin Sitter's DVD Studio Pro book (or take a look
>   at books on Adobe Photoshop) it would seem that NTSC TVs use 9:10

I wont touch those books..

>   pixels and there are a couple NTSC frame sizes to contend with.   The
>   use of 720x534 when designing menus and overlays is mentioned several
>   times with a note that 720x540 is not correct unless you're going to
>   D1 NTSC (720x486).
> 
> > 640x480 --> 704x480 or 720x540 --> 704x480, if you prefer 540. This need
> > to scale in both directions is another reason to keep away from 720x540.
> 
>   But since DVDs are 720x480 there's no scaling in the horizontal
>   dimension - that stays at 720.

Not if you want correct aspect ratios. Well, when it comes to aspect 
ratios, there is a lot of misinformation out there, hard to find who
is right. As Matto suggested, simply use y4mscaler -O preset=DVD and
that will take care of all necessary padding and scaling. 

> 
> > 720x534 makes no sense to me. Apparently, the popularity of 720x540 is
> > because it appears related to both PAL and NTSC by a vertical scaling
> > factor -- scale to 720x480 in one case and 720x576 in the other. But that
> 
>   It's a bit more complicated than that I think. 
> 
>   .9 * 534 = 480.6 while 540*.9 = 486

I have seen such arguments elsewhere. The 9/10 ratio, I think, has 
originated from the misconception that 720x486 is 4:3.  

Selva




---
This SF.NET email is sponsored by: eBay
Great deals on office technology -- on eBay now! Click here:
http://adfarm.mediaplex.com/ad/ck/711-11697-6916-5
___
Mjpeg-users mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/mjpeg-users


Re: [Mjpeg-users] movies from PPM?

2003-06-11 Thread Selva Nair

Hi there,

On Wed, 11 Jun 2003, Steven M. Schultz wrote:

> > If you use 24000:1001 and pulldown instead of 3:1001, the encoder will
> > keep switching between top_field_first = true/false to generate the
> > pulldown sequence.
> 
>   Now it's my turn to ask why would I want to do a pulldown when I have
>   ~30fps interlaced with is what I wanted all along?

Ah.. I thought you have a progressive source and wanted to make a dvd 
compliant stream from it.. I misread your original post.

> 
> > You have the full 444 chroma info at the ppm stage so isn't it  best 
> > to subsample it directly to 420_mpeg2 from the ppm? Otherwise you go 
> > through 444 -> 420_jpeg -> 420_mpeg2 -- looks more lossy to me.
> 
>   Hmmm, possible but I have a feeling that the jpeg->mpeg2 conversion's
>   "loss" is so small you'd need Golden Eyeballs to notice it ;)  Certainly
>   it'd be a lot less of a loss than the 444 -> xxx conversion.


I haven't done any tests. As you say the difference could be small in
practice, but in "theory" any subsampling change is lossy ;) Subsampling
is basically scaling so the quality also depends on the software --
y4mscaler is indeed a good scaler.

Cheers,

Selva



---
This SF.NET email is sponsored by: eBay
Great deals on office technology -- on eBay now! Click here:
http://adfarm.mediaplex.com/ad/ck/711-11697-6916-5
___
Mjpeg-users mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/mjpeg-users


Re: [Mjpeg-users] movies from PPM?

2003-06-11 Thread Selva Nair
On Tue, 10 Jun 2003, Steven M. Schultz wrote:

> Hi -
> 
> > From: Selva Nair <[EMAIL PROTECTED]>
> > 
> > Forgot to mention that if this is meant to be 4:3 aspect, you should 
> > scale to 704x480 and then pad to 720x480. You can avoid vertical scaling 
> > using 640x480 ---(scale)--> 704x480 ---pad--> 720x480.
> 
>   Hmmm, I was told (at one time) to avoid horizontal scaling up and that
>   it was better to start out bigger and scale down.  But perhaps that's 
>   just another bit of advice that wasn't exactly right (wouldn't be 
>   the first time ;)) 

The general advice is to avoid vertical scaling mainly because vertical
scalers should be interlacing-aware -- also for interlaced frames the
vertical samples per field is only half as much. For progressive frames it
may not matter much, though. In any case, you will get proper aspect ratio
only if you scale by the correct SAR value: 10:11 in case of NTSC. So
640x480 --> 704x480 or 720x540 --> 704x480, if you prefer 540. This need
to scale in both directions is another reason to keep away from 720x540.
For more reasons see Jukka Aho's page at
http://www.uwasa.fi/~f76998/video/conversion/

> 
>   Actually since some of the files being created are for DVD menus
>   a number of tools have presets for dealing with the 'action safe'
>   and 'title safe' zones of a 720x540 frame.Actually a couple
>   places say to use 720x534 and scale to 720x480 for creating menus

720x534 makes no sense to me. Apparently, the popularity of 720x540 is
because it appears related to both PAL and NTSC by a vertical scaling
factor -- scale to 720x480 in one case and 720x576 in the other. But that
is a myth. If the idea is to avoid horizontal scaling, one should start
with a an odd sized 720x527 frame -- guess what would happen to
interlacing and chroma subsmapling with such frames...

>   and overlays (something about "D1 NTSC" vs "DVD/DV NTSC"). It's
>   all very confusing ;)

Very confusing indeed;) Take a look at Aho's page (the link above), you 
may find some logic behind all those convoluted and confusing standards.

Selva




---
This SF.NET email is sponsored by: eBay
Great deals on office technology -- on eBay now! Click here:
http://adfarm.mediaplex.com/ad/ck/711-11697-6916-5
___
Mjpeg-users mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/mjpeg-users


Re: [Mjpeg-users] movies from PPM?

2003-06-11 Thread Selva Nair
On Tue, 10 Jun 2003, Steven M. Schultz wrote:

> Hi -
> 
> > From: Selva Nair <[EMAIL PROTECTED]>
> > As the source is progressive ppm frames, better keep it that way. 
> > Use -F 24000:1001 and encode with pull down flag:
> 
>   Well, as it turns out it seems that the encoder is "doing the right
>   thing" for me (despite my being confused ;)).
> 
>   I remembered I had a copy of 'dvdview' installed and using that I can
>   see that mpeg2enc is generating 'top field first' :

But why do you care about top_field first when the source is progressive? 
If you use 24000:1001 and pulldown instead of 3:1001, the encoder will
keep switching between top_field_first = true/false to generate the
pulldown sequence.

> 
> PictureHeader:
>   temporal reference:3
>   picture_coding_type:   B
>   vbv_delay: 65535
>   fullpel forward mv:false
>   fullpel backward mv:   false
>   fcode[0][0] (fw/h):3
>   fcode[0][1] (fw/v):2
>   fcode[1][0] (bw/h):4
>   fcode[1][1] (bw/v):3
>   intra dc precision:9
>   picture structure: frame picture
>   top field first:   true
>   frame pred frame dct:  false
>   concealment mvs:   false
>   q-scale type:  1
>   intra vlc format:  1
>   alternate scan:true
>   repeat first field:false
>   chroma420type(obsolet):0
>   progressive frame: false
> 
>   This does raise the (idle) question of how would one create
>   a MPEG-2 progressive encoded movie? HD-TV can use 1280x768 
>   progressive as one of its resolutions.

By progressive if you mean progressive_frame flagged as true, again, 
use 24000:1001 and pulldown you will have it.
But if you want a progressive sequence the dvd preset wont allow it
as DVDs are for interlaced displays by design. I think mpeg2enc will
generate progressive sequences with a generic mpeg2 preset plus -I 0.

> 
> > I would use -S 420_mpeg2 at the ppmtoy4m stage instead of 
> > resampling by y4mscaler as above. 
> 
>   Why?  I have to rescale from 720x540 to 720x480 which means going
>   thru y4mscaler.  Seemed logical to have it do the chroma conversion
>   at the same time.

You have the full 444 chroma info at the ppm stage so isn't it  best 
to subsample it directly to 420_mpeg2 from the ppm? Otherwise you go 
through 444 -> 420_jpeg -> 420_mpeg2 -- looks more lossy to me.

Selva



---
This SF.net email is sponsored by:  Etnus, makers of TotalView, The best
thread debugger on the planet. Designed with thread debugging features
you've never dreamed of, try TotalView 6 free at www.etnus.com.
___
Mjpeg-users mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/mjpeg-users


Re: [Mjpeg-users] movies from PPM?

2003-06-10 Thread Selva Nair
> 
>   Anyone used ppmtoy4m to create composited from PPM images 
>   (for example from a scanner/camera) for a DVD?
> 
>   It's working - but what I'm ending up with is 720x480 progressive
>   and that's not, as far as I know, legal for use in making a DVD.
> 
>   What I'm doing so far is:
> 
> (generate 720x540 PPM frames) | ppmtoy4m -F 3:1001 | \

Forgot to mention that if this is meant to be 4:3 aspect, you should 
scale to 704x480 and then pad to 720x480. You can avoid vertical scaling 
using 640x480 ---(scale)--> 704x480 ---pad--> 720x480.

Selva



---
This SF.net email is sponsored by:  Etnus, makers of TotalView, The best
thread debugger on the planet. Designed with thread debugging features
you've never dreamed of, try TotalView 6 free at www.etnus.com.
___
Mjpeg-users mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/mjpeg-users


Re: [Mjpeg-users] movies from PPM?

2003-06-10 Thread Selva Nair
On Tue, 10 Jun 2003, Steven M. Schultz wrote:

> Hi -
> 
>   Anyone used ppmtoy4m to create composited from PPM images 
>   (for example from a scanner/camera) for a DVD?
> 
>   It's working - but what I'm ending up with is 720x480 progressive
>   and that's not, as far as I know, legal for use in making a DVD.
> 
>   What I'm doing so far is:
> 
> (generate 720x540 PPM frames) | ppmtoy4m -F 3:1001 | \
> y4mscaler -O size-720x480 -S option=sinc8lan -O chromass=420_MPEG2 | \
> mpeg2enc -f 8 -o intro.m2v 
> 
>   Am I correct that I need to generate interlaced PPM frames for input?

As the source is progressive ppm frames, better keep it that way. 
Use -F 24000:1001 and encode with pull down flag:

 ..|ppmtoy4m -F 24000:1001 -S 420_mpeg2 | y4mscaler -O size-720x480 
-S option=sinc8lan | mpeg2enc -I 0 -f 8 -p -o .. 

-L option to ppmtoy4m will not make any difference in this case as the
input is progressive. Its used to indicate interleaving when the 
source is interlaced (ie with -I b or -I t).

I would use -S 420_mpeg2 at the ppmtoy4m stage instead of 
resampling by y4mscaler as above. 

Selva 



---
This SF.net email is sponsored by:  Etnus, makers of TotalView, The best
thread debugger on the planet. Designed with thread debugging features
you've never dreamed of, try TotalView 6 free at www.etnus.com.
___
Mjpeg-users mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/mjpeg-users


Re: [Mjpeg-users] mjpeg_play - autogen.sh: cannot find input file:config.h.in

2003-06-07 Thread Selva Nair

>   autogen.sh hasn't been modified, that I can see, since
>   February 2 of this year.   I haven't run into the problem (on
>   either my BSD systems or on SuSE 8.2) so I'm not sure why
>   autogen.sh isn't running autoheader for some folks.   Perhaps

That prompted me to look why lately it has stopped working for me too. I
was thinking that my autoconf update messed things up. 

well, it appears autogen.sh was not updated to match with the replacement
AM_CONFIG_HEADER --> AM_CONFIG_HEADER in configure.in.  Here is a "one
line" patch.

--- autogen.sh.orig Sat Jun  7 11:47:17 2003
+++ autogen.sh  Sat Jun  7 11:50:01 2003
@@ -126,7 +126,7 @@
   fi
   echo "Running aclocal $aclocalinclude ..."
   aclocal $aclocalinclude
-  if grep "^AM_CONFIG_HEADER" configure.in >/dev/null; then
+  if grep "^AC_CONFIG_HEADER" configure.in >/dev/null; then
echo "Running autoheader..."
autoheader
   fi

Wonder why this does not affect everyone? May be because config.h.in will
be absent only for fresh cvs trees or after a "make maintainer-clean"..

Selva



---
This SF.net email is sponsored by:  Etnus, makers of TotalView, The best
thread debugger on the planet. Designed with thread debugging features
you've never dreamed of, try TotalView 6 free at www.etnus.com.
___
Mjpeg-users mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/mjpeg-users


Re: [Mjpeg-users] lavrec and "at"

2003-06-05 Thread Selva Nair
On Wed, 4 Jun 2003, Dirk wrote:

> Well, it works. Thansk for all the tips. 
> 
> The problem is the batch option. For some reason -b doesn't work for me
> but -B and --batch do. So, there is no need for "nice" or changing
> priorities for at. The environment for at is also okay. (well, in my
> case). 
..

> I don't know what's wrong with the B and b. Is this just a typo in the
> source? 

Its is -B or --batch, -b is for specifying mjpeg-buffer-size. -b/--batch
is typo present in some old (pre-1.6.0 ?) versions.

Selva
man lav



---
This SF.net email is sponsored by:  Etnus, makers of TotalView, The best
thread debugger on the planet. Designed with thread debugging features
you've never dreamed of, try TotalView 6 free at www.etnus.com.
___
Mjpeg-users mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/mjpeg-users


Re: Fwd: Re: [Mjpeg-users] Audio sync problems

2003-06-02 Thread Selva Nair
On Fri, 30 May 2003, Stuart Hodges wrote:

> Hi,
> 
>   There are problems with this fix. Although with 3:1001 its watchable,
>  the audio is off from the start.

A constant delay is easy to fix: specify a sync offset using the -O or
--sync-offset option of mplex. I think the value specified in milli
seconds, and is +ve if the video is to be delayed relative to audio.

Selva



---
This SF.net email is sponsored by: eBay
Get office equipment for less on eBay!
http://adfarm.mediaplex.com/ad/ck/711-11697-6916-5
___
Mjpeg-users mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/mjpeg-users


Re: [Mjpeg-users] dvd with progressive_sequence set

2003-05-31 Thread Selva Nair
On Thu, 29 May 2003 [EMAIL PROTECTED] wrote:

> 
> 
>   I toggled the progressive sequence bit to zero on every system header
>   and the resulting stream now plays correctly with mplayer! Haven't yet
>   checked on the Poineer standalone.  
> 
>   Has anyone seen this? I believe dvd is not supposed to be marked as
>   progressive sequence, but why does that lead to such a strange playback
>   behaviour? 
> 
>   I know this is probably a wrong list for this question, I am posting it
>   here because I recall a previous discussion on audio sync problems with a
>   stream encoded with pull-down---one that plays correctly only at 40fps 
>   or so.
> 
> (Finally gets around to replying...)
> 
> I've seen exactly this problem before, so I think you recalled my
> post.  My problem was caused by a tiny bug in mpeg2enc, since fixed in
> CVS (and not present at all in 1.6.x) that screwed up the headers as
> you described when using -f 8 rather than -f 9 for DVD w/ 2:3
> pulldown.

You are right, mpeg2enc.cc revision 1.5 on cvs has progresssive_sequence 
set to 1 if -I 0 (for pulldown, for example) is specified. That's exactly
the kind of header I have, but mine is from a commercial dvd :) I will
have to re-author it to make it play :(

I still wonder why players don't ignore that bit.. May be I should ask on
mplayer or xine list

Thanks,

Selva



---
This SF.net email is sponsored by: eBay
Get office equipment for less on eBay!
http://adfarm.mediaplex.com/ad/ck/711-11697-6916-5
___
Mjpeg-users mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/mjpeg-users


Re: [Mjpeg-users] Multiplexing one video and multiple audio tracks

2003-05-31 Thread Selva Nair

On Wed, 28 May 2003, Tim Hewett wrote:

> Hello,
> 
> I am trying to use mplex to create a DVD stream with one video
> track and 3 audio tracks. This is to use as input to dvdauthor
> which claims to support streams with multiple audio tracks
> created by mplex.
> 
> This is the mplex command I am using:
> 
> mplex -V -f 8 -M -S 5000 -o out.mpg video.mpv audio1.ac3 audio2.ac3 
> audio3.ac3
> 
> Any attempt to use this mpg file with dvdauthor produces the
> following output:
> 
> % dvdauthor -f out.mpg -o .
> INFO: dvdauthor creating VTS
> STAT: Picking VTS 01
> 
> STAT: Processing out.mpg...
> WARN: System header found, but PCI/DSI information is not where expected
>  (make sure your system header is 18 bytes!)

Which version of mplex? For anything other than 1 video + 1 adio 
streams, I think you need the cvs version of mplex to get a header
that dvdauthor understands..

Selva 



---
This SF.net email is sponsored by: eBay
Get office equipment for less on eBay!
http://adfarm.mediaplex.com/ad/ck/711-11697-6916-5
___
Mjpeg-users mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/mjpeg-users


Re: [Mjpeg-users] Audio sync problems

2003-05-30 Thread Selva Nair
On Thu, 29 May 2003, Stuart Hodges wrote:

> Hi,
> 
>   yuvfps reports:
> cat stream.yuv | yuvfps -v2 > debout
>INFO: [yuvfps] yuv2fps (version 0.1) is a general frame resampling utility 
> for yuv streams
>INFO: [yuvfps] (C) 2002 Alfonso Garcia-Patino Barbolani 
> <[EMAIL PROTECTED]>
>INFO: [yuvfps] yuv2fps -h for help, or man yuv2fps
>INFO: [yuvfps] Converting from 2996:50 to 2996:50

2996:50 works out to be 6:1001 (well almost), ie NTSC 
field rate.

If that is really the frame rate at which mplayer outputs the yuv4mpeg2
stream, converting by yuvfps -r 3:1001 should give you the 
right NTSC frame rate. I dont know whether 2996:50 is confusing
yuvfps. Try specifying -s 6:1001 instead.

If the resulting stream does not play at the right speed, you have to find
out the real frame rate of the source. One way to do that would be 
to convert a short clip as an mjpeg avi (you will have to flag the fps 
as 3:1001 for that to work -- use 'yuvfps -s 3:1001 -r 3:1001 
-c' to only change the header..)  and play it back using mplayer -fps xxx 
to determine the frame rate by trial error. May be there is a smarter 
way..

You _have_ to get the source frame rate accurately and then use yuvfps -s 
source_fps -r 3:1001 to get a stream that can be synced with audio
after mpeg2enc -F 4. 

I recall you mentioning only a small audio delay with yuvfps -r 30:1. So I
wonder why changing that to -r 3:1001 makes such a big difference as
playing at half speed.

Selva



---
This SF.net email is sponsored by: eBay
Get office equipment for less on eBay!
http://adfarm.mediaplex.com/ad/ck/711-11697-6916-5
___
Mjpeg-users mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/mjpeg-users


Re: [Mjpeg-users] XSVCD audio out-of-sync

2003-05-29 Thread Selva Nair
On Wed, 28 May 2003, Matti Haveri wrote:

> Some of my longish PAL XSVCD's audio tend to be out-of-sync.
> 
> The ordinary ~2500 kb/s SVCDs and corresponding 37-45 minute 352x576 
> XSVCDs have been OK. But the in the few ~60 minute XSVCDs I have made 
> the audio has been  ad 1 second out-of-sync with the video and the 
> error seems to somewhat fluctuate in time so some parts the audio is 
> almost in sync.
> 
> I have used 224 kb/s 48 kHz audio with the XSVCD with either 48 kHz 
> AIF or WAF as input but both are somewhat out-of-sync so the input 
> seems to be not the problem.
> 
> The video and audio lengths are identical (with at least 1 second 
> precision on a 60 minute video -- how can I check them more 
> precisely?) before multiplexing.

Depends on the format. For mjpeg avi lavinfo gives you the frame count.
For wav audio there are several utilities out there (eg, wavprint) that
outputs the playtime or number of samples. mpeg2enc also prints out
the total input audio length in bytes from which its easy to calculate the
duration.

But any difference between the audio and video lengths does not 
necessarily indicate a sync problem. 
 
> 
> For example, I have encodeded 59 minute video with:
> ppmtoy4m -v 0 -S 420_mpeg2 -L -I b -F 25:1
> mpeg2enc -v 0 -f 5 -F 3 -n p -a 2 -b 1484 -I 1 -r 16 -q 7 -V 224 -g 9 -G 15

Wow, ppms worth of 59mins video must be taking a lot of disk space, eh:)

What is the source of your video? How do you extract audio and video
out of the source?

> 
> I have noticed that extremely large video buffers tend to get audio 
> out-of-sync but I guess -V 224 should be OK.

Which players do you use?

Selva



---
This SF.net email is sponsored by: eBay
Get office equipment for less on eBay!
http://adfarm.mediaplex.com/ad/ck/711-11697-6916-5
___
Mjpeg-users mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/mjpeg-users


Re: [Mjpeg-users] Audio sync problems

2003-05-27 Thread Selva Nair


> HI,
> 
>   Sorry for the confused options. Its the effect of a weekend tweeking. I 
> switched to the options I use for encoding my video camera to DVD.
> 
> mplayer -vo yuv4mpeg -ao pcm long.mpg
> cat audiodump.wav | mp2enc -r 48000 -o mpegsoundfile
> cat stream.yuv | yuvdenoise -F -f | yuvfps -r 30:1 | mpeg2enc -f 8 -q 7 -4 1 
> -2 1 -P -I 0 -N -o svcd_stream.m2v


Why do you change the frame rate to 30:1 ? If your input is ntsc (frame 
rate = 3:1001 = 29.97..), that change will definitely lead to audio
delay - a drift of 1 msec per second; at that rate you will start noticing
lip sync problem by atleast 100 seconds or so into video. 

If you are trying to over-write the 29.97... frame rate put out by 
mplayer's yuv4mpeg plugin, try using the -c option of yuvfps. Be sure
to specify the rate as 3:1001

> mplex -f 8 mpegsoundfile svcd_stream.m2v -o long.conv.mpg
> 
>   The audio sync problem is still there, although less pronounced. Its fine up 
> to this point and then over about 30 seconds it drifts.
> 
>   It all plays fine on mplayer from the original captured using GATOS.
> 

> 
>   Any other ideas ?

Can't think of anything else..

Selva



---
This SF.net email is sponsored by: ObjectStore.
If flattening out C++ or Java code to make your application fit in a
relational database is painful, don't do it! Check out ObjectStore.
Now part of Progress Software. http://www.objectstore.net/sourceforge
___
Mjpeg-users mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/mjpeg-users


Re: [Mjpeg-users] Audio sync problems

2003-05-27 Thread Selva Nair

> > I'm trying to convert a mpg file, from GATOS, its mpeg1 video, mp2
> > audio in an mpg file.
> > 
> > I extracted the tracks and reencoded like this:
> > 
> > mplayer -vo yuv4mpeg -ao pcm long.mpg
> > cat stream.yuv | mpeg2enc -I 1 -f 1 -q 9  -V 230 -P -F 7 -a 1 -o
> > svcd_stream.m2v

Unusual options: -f 1 means you are encoding as a vcd. In that case the
input should be progressive and -I 1 makes no sense. -F 7 means
6.0/1001.0 (ntsc field rate), which, I guess, is not consistent with
-f 1. -a 1 means square pixels: make sure that your source has square
pixels and that the you are encoding for computer playback only. Also -V
230 will be overridden by the default (46). If you want to tune these
parameters you will need to use -f 2. Please take a look at the
mjpeg-tools for recommended settings for vcd and dvd encodings.

> > cat audiodump.wav | mp2enc -r 48000 -o mpegsoundfile
> > mplex -f 8 mpegsoundfile svcd_stream.m2v -o long.conv.mpg

Guess you are trying to make a dvd compliant mpeg1. Never tried that
myself... I think you will need to use a frame rate that is valid
for dvd (-F 3 for PAL, -F 4 for NTSC).

> > 
> > Everything is fine for about 10 minutes then the audio starts to drift.
> > 
> > Is there anything I can do about this ?

What playback software/hardware do you use?

As Bernhard wrote:
> Is it till that time perfect in sync and starts than to drift ?
> 
> If you have NTSC it could be that the framerate changes between about
> 29,97FPS and about 23,97FPS. 

That is a possibility. Please try again with a more standard frame rate  
and provide more info on your input stream if you still get A/V sync 
problems.

Selva



---
This SF.net email is sponsored by: ObjectStore.
If flattening out C++ or Java code to make your application fit in a
relational database is painful, don't do it! Check out ObjectStore.
Now part of Progress Software. http://www.objectstore.net/sourceforge
___
Mjpeg-users mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/mjpeg-users


Re: [Mjpeg-users] mplex question

2003-04-05 Thread Selva Nair
On Sat, 5 Apr 2003, Matti Haveri wrote:

> >  The default for vcd/svcd presets is equivalent to -S 700 -B 230
> 
> Thanks for the info. I've been wondering what the -4/5 default for 
> mpeg2enc -B is. Some old post on the list indicated that it was 224 
> but it is 230 for mplex overhead, right?
> 
> And the -f 4/5 default for mpeg2enc -S is 730, right?

The last time I looked it was -S 700 (not 730) and -B 230.

Selva



---
This SF.net email is sponsored by: ValueWeb: 
Dedicated Hosting for just $79/mo with 500 GB of bandwidth! 
No other company gives more support or power for your dedicated server
http://click.atdmt.com/AFF/go/sdnxxaff00300020aff/direct/01/
___
Mjpeg-users mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/mjpeg-users


Re: [Mjpeg-users] mplex question

2003-04-04 Thread Selva Nair


On Sat, 5 Apr 2003, Selva Nair wrote:

> 
> On Sat, 5 Apr 2003, Matti Haveri wrote:
> 
> > >  mpeg2enc always introduces breaks for SVCD, you can only change the size
> > >  to a very large value.
> > 
> > So does mpeg2enc -S 650 insert break points to _both_ 650 and 730 MB points?
> 
> No it doesn't. The default for vcd/svcd presets is equivalent to -S 700 -B 
> 230,  but the command line settings override the defaults. I generally 
> use -S 790 for 80mins cds. Note that here MB is 1024*1024 bytes, not 
> 100 bytes so 700MB sequence length implies 73400 bytes, close to
> what can fit on 74 min CD.

Ooops.. ignore the last part of  -- 74min CD can indeed take
as much as 738MB as Matti pointed out. Sorry about that, I shouldn't
be writing emails past midnight.

Selva



---
This SF.net email is sponsored by: ValueWeb: 
Dedicated Hosting for just $79/mo with 500 GB of bandwidth! 
No other company gives more support or power for your dedicated server
http://click.atdmt.com/AFF/go/sdnxxaff00300020aff/direct/01/
___
Mjpeg-users mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/mjpeg-users


Re: [Mjpeg-users] mplex question

2003-04-04 Thread Selva Nair

On Sat, 5 Apr 2003, Matti Haveri wrote:

> >  mpeg2enc always introduces breaks for SVCD, you can only change the size
> >  to a very large value.
> 
> So does mpeg2enc -S 650 insert break points to _both_ 650 and 730 MB points?

No it doesn't. The default for vcd/svcd presets is equivalent to -S 700 -B 
230,  but the command line settings override the defaults. I generally 
use -S 790 for 80mins cds. Note that here MB is 1024*1024 bytes, not 
100 bytes so 700MB sequence length implies 73400 bytes, close to
what can fit on 74 min CD.

Selva



---
This SF.net email is sponsored by: ValueWeb: 
Dedicated Hosting for just $79/mo with 500 GB of bandwidth! 
No other company gives more support or power for your dedicated server
http://click.atdmt.com/AFF/go/sdnxxaff00300020aff/direct/01/
___
Mjpeg-users mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/mjpeg-users


Re: [Mjpeg-users] mplex question

2003-04-04 Thread Selva Nair
On Fri, 4 Apr 2003, richard koppenaal wrote:

> i have some 650 mb cds so thats why i would like to learn how to split files 
> at 630mb thats my reason .

As Bernhard wrote 650 MB CDs (ie 74 mins CDs) can take upto about 730 MB 
of data when burned as a vcd/svcd (MODE2_FORM2 sectors). 

> 
> thanks for answering.
> 
> ps i tryto read the manual and have tried several settings with %2d without 
> etc , so thats the reason why iam now asking here , hope that somebody could 
> help me out ..

To paraphrase what Bernhard already wrote:
 
'mpeg2enc -f4 ..' inserts a sequence split marker at 700 MB or so, and
mplex splits the sequence at that point. If you really want to change the
sequence length to, say, 650 MB you need to specify -S 650 to mpeg2enc,
not mplex. If you are using a non-standard audio rate you may also need to
specify the -B option (see man mpeg2enc).  Splitting the multiplexed
stream using -S option to mplex is not recommended for vcd/svcd streams
(see man mplex). In any case if you specify -S  to mplex it will
split the stream at sequence split marks inserted by mpeg2enc as well as
at the specified  megabytes and that explains the lengths of the 3
files you got.

The whole thing could be a bit confusing for the uninitiated, so I 
strongly recommend you to read the mjpeg-HOWTO. Its a very educative
document.

Selva



---
This SF.net email is sponsored by: ValueWeb: 
Dedicated Hosting for just $79/mo with 500 GB of bandwidth! 
No other company gives more support or power for your dedicated server
http://click.atdmt.com/AFF/go/sdnxxaff00300020aff/direct/01/
___
Mjpeg-users mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/mjpeg-users


Re: [Mjpeg-users] yuvfps and sound

2003-03-25 Thread Selva Nair
On Mon, 24 Mar 2003, Edouard Chalaron wrote:

> Hi 
> Got a fabulous NTSC video from USA and  would like to make it a PAL DV file.
> Acquisition is Ok, no worries, thanks to Canopus. Although I am not sure if I 
> have to use AVI1 or 2 to use it with lav2yuv.

lav2yuv needs type 2 AVI. I prefer to use

> 
> The frame rate : should I use yuvfps 25000:1000 or 25:1 (it has to go back 
> onto video)

I do this as:

smil2wav -a video.wav  video_ntsc.dv 
smil2yuv video_ntsc.dv | yuvfps -r 25:1 | yuvscaler -O SIZE_720x576 |  \
  y4mtopgm | encodedv -i pgm -a wav - video.wav > video_pal.dv

yuvfps resamples the framerate by simply dropping/duplicating frames, so
the resulting video may show some jerkiness and interlacing artifacts at
high motion scenes (deinterlacing may help..). Also there is the issue of
chroma subsampling difference between NTSC and PAL DV. Having said that I
have done such pal->ntsc and ntsc->pal conversion a couple of times with
acceptable results.

y4mtopgm in the pipeline above is a simple utility I wrote to convert
a yuv4mpeg stream into a pgm stream that is accepted by encodedv. If you
want I can send it you.

> I guess the sound will have to be resampled, I know we people came around
> this question already but can not find it in my archives.
> 
> Thanks a lot for your help
> Edouard

Selva



---
This SF.net email is sponsored by:
The Definitive IT and Networking Event. Be There!
NetWorld+Interop Las Vegas 2003 -- Register today!
http://ads.sourceforge.net/cgi-bin/redirect.pl?keyn0001en
___
Mjpeg-users mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/mjpeg-users


Re: [Mjpeg-users] attempting to get LVS to work...

2003-03-15 Thread Selva Nair
On Wed, 12 Mar 2003, Martin Collins wrote:

> On Wed, 12 Mar 2003 14:16:45 -0500 (EST)
> Selva Nair <[EMAIL PROTECTED]> wrote:
> 
> > You can select and cut all the ads and then save the rest 
> > by "save all" to a single editlist. That's what I do. Or am I
> > missing something?
> 
> Doh! I've been trying to save the bits I do want when all along
> I should have been cutting out the bits I don't want. And of
> course now I can't find the bit in the howto that made me think
> it had to be that way. I probably misread it totally.
> Thanks Selva (and James). I don't suppose you've spotted some
> blindingly obvious way of getting LVS to work with a Marvel too?
> 

Indeed there is an easy way to switch-off tv display on LVS so that
capture and on card playback works with Marvel: simply leave out 
Load "v4l" from your XF86Config ! You may have to delete the Xv port
number from studio.conf to avoid it querying the previously configured
port. Without v4l extension on X, LVS will spit out some warning messages
and simply show a black screen for the tv display. I dont use gui for
capture, so I am not sure how useful this is.

I have hacked studio to switch off TV during capture, but TV overlay
with XV does not work properly on my system (marvel G200) so I haven't 
used this much either. If you want I can send you the patch.

Selva



---
This SF.net email is sponsored by:Crypto Challenge is now open! 
Get cracking and register here for some mind boggling fun and 
the chance of winning an Apple iPod:
http://ads.sourceforge.net/cgi-bin/redirect.pl?thaw0031en
___
Mjpeg-users mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/mjpeg-users


Re: [Mjpeg-users] attempting to get LVS to work...

2003-03-12 Thread Selva Nair
On Wed, 12 Mar 2003, Martin Collins wrote:

> On Wed, 12 Mar 2003 18:17:00 +0100
> Bernhard Praschinger <[EMAIL PROTECTED]> wrote:
> 

> 
> > You can use more files running it that way:
> > glav -p S *.avi
> > glav -p S file1.avi file2.avi ... filex.avi
> > 
> > But you cannot load a file edit it and than load a other file
> > without restarting.
> 
> Right, but the problem is not editing more than one file it is saving
> more than one edit. For example if I have some video that has an ad
> break that I wish to remove I have to save two separate editlists then
> combine them manually. Unless I'm doing it wrong, though the howto
> mentions this shortcoming.

You can select and cut all the ads and then save the rest 
by "save all" to a single editlist. That's what I do. Or am I
missing something?

Selva



---
This SF.net email is sponsored by:Crypto Challenge is now open! 
Get cracking and register here for some mind boggling fun and 
the chance of winning an Apple iPod:
http://ads.sourceforge.net/cgi-bin/redirect.pl?thaw0031en
___
Mjpeg-users mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/mjpeg-users


Re: [Mjpeg-users] is there a way to do inverse telecine in additionto -p?

2003-03-01 Thread Selva Nair
On 1 Mar 2003, Davros wrote:

> Hi Selva,
> 
> You've got me worried now!  Just when I thought I had a handle on this
> process...
> 
> No, my source material is not exactly 24, it's from an ntsc DVD and it's
> 23.9 something - i thought that the target rate to shoot for was 29.9
> something as well! Aren't these fairly common values?

If your source is 23.97 it will play back at the correct ntsc 
rate of  29.97 with the pulldown tag. So no need to worry. As I worte 
earlier you don't need yuvkineco, your source is already at the ntsc
film rate. Just go ahead and encode with -F 1 -p. 

> 
> If I need to, how can I skip every thousandth frame or so as you
> suggested??

I wrote:

> > [*] I am assuming that the source is actually 24000:1001 fps. Else
> > you may have to skip 1 frame every 1001 frames to keep the audio in sync. 

24000:1001 = 23.97.. Framedrop is needed only for true 24fps sources.

Selva




---
This sf.net email is sponsored by:ThinkGeek
Welcome to geek heaven.
http://thinkgeek.com/sf
___
Mjpeg-users mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/mjpeg-users


Re: [Mjpeg-users] is there a way to do inverse telecine in additionto -p?

2003-02-27 Thread Selva Nair
On 27 Feb 2003, Davros wrote:

> Yes, that helps in a sense, though it doesn't solve my problem...
> 
> if mpeg2dec spits out 24fps, then, according to the yuvkineco man page,
> this effectively means I cannot use yuvkeneco unless I convert to
> another, intermediate format or something, since it insists on 30fps as
> input...

yuvkineco is used to extract the orginal 24fps frames out of a 30fps
stream obtained by a telecine process such as 2-3 pulldown. If you have
a 24fps stream you dont need yuvkineco. You would instead encode the 24fps 
stream as[*] 

cat stream.yuv | yuvscaler -OSVCD | mpeg2enc -f 4 -F 1 -p -o stream.m2v

The player will play such a stream at the NTSC field rate 60fields/sec by
repeating appropriate fields (3-2 pull down), but the encoder does not 
waste any bits on the repeated feilds.

Selva

--
[*] I am assuming that the source is actually 24000:1001 fps. Else
you may have to skip 1 frame every 1001 frames to keep the audio in sync. 



---
This sf.net email is sponsored by:ThinkGeek
Welcome to geek heaven.
http://thinkgeek.com/sf
___
Mjpeg-users mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/mjpeg-users


Re: [Mjpeg-users] Mplex fails (too many dropped frames), Sizzle/ffmpegX

2003-02-13 Thread Selva Nair
On Thu, 13 Feb 2003 [EMAIL PROTECTED] wrote:

> Should I just try dropping this bitrate down?  Forgive me if I'm wrong, but I
> thought 9800 kbps was the best quality you could do for DVD and since I only had
> 30 mins of footage, thought there would be no problem in using this?
> 
> As far as the mplex bitrate, (-r arguement, muxbitrate) I've left this as the
> default, i.e that it is calculated from the input.  I've just tried with this

with -f 8, the default is not taken from input but set at something like 
1008 mb/s that may be just a little less than your video+audio rate.

> set at 9800 and the mplex failed as before.  Should I try changing this to

-r option of mplex takes the total (video+audio) bit rate so you need a
value atleast equal to you max video rate+audio rate -- mplex usually 
prints out the estimated bit rate requirement.

Selva



---
This SF.NET email is sponsored by: FREE  SSL Guide from Thawte
are you planning your Web Server Security? Click here to get a FREE
Thawte SSL guide and find the answers to all your  SSL security issues.
http://ads.sourceforge.net/cgi-bin/redirect.pl?thaw0026en
___
Mjpeg-users mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/mjpeg-users



Re: [Mjpeg-users] How to extract 1 frame from MPEG file to JPEG file

2003-02-11 Thread Selva Nair
On Tue, 11 Feb 2003, Robert Kesterson wrote:

> 
> Or you could do:
> 
>mplayer -vo png -frames 1 movie.mpg
> 
> to save the first frame as a png, or
> 
>mplayer -vo png -ss 60 -frames 10 movie.png
> 
> to seek 60 seconds into the movie, then dump 10 frames as png images.

Does that really work for you? For me -ss  always seeks to some
odd fraction of  seconds, off by 10% or more and the first few frames 
is always junk.. May be I am doing something wrong

Selva



---
This SF.NET email is sponsored by:
SourceForge Enterprise Edition + IBM + LinuxWorld = Something 2 See!
http://www.vasoftware.com
___
Mjpeg-users mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/mjpeg-users



Re: [Mjpeg-users] How to extract 1 frame from MPEG file to JPEG file

2003-02-11 Thread Selva Nair

On Tue, 11 Feb 2003, CAULIER Gilles wrote:

> I want make a preview frame for some MPEG files in a KDE application. 
> There is some issue to extract to a JPEG file just one frame from MPEG file ?
> 

try mpeg -> yuv -> ppm using mpeg2dec and y4mtoppm. To give you
an idea

mpeg2dec -s -o YUV movie.mpg | y4mtoppm -L | cjpeg > frame0.jpg

will extract the first frame, in principle[*]. To get an arbitrary
frame, you either need to extract the frame from the yuv stream before
feeding to y4mtoppm or pipe the output y4mtoppm through pnmsplit and
select the required frame. If you are interested, I have a small utility
(y4mcut)  that can select a specified interval of frames from a yuv
stream:

mpeg2dec -s -o YUV movie.mpg |y4mcut -s n -o 1| \
y4mtoppm -L -v 2 | cjpeg > frame_n.jpg

will extract the nth frame. Its not very efficient if n is large,
though. It will be nice to have an option to skip frames in mpeg2dec.

Selva

[*] assuming the first GOP is closed.



---
This SF.NET email is sponsored by:
SourceForge Enterprise Edition + IBM + LinuxWorld = Something 2 See!
http://www.vasoftware.com
___
Mjpeg-users mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/mjpeg-users



Re: [Mjpeg-users] MJPEG encoding performances

2003-02-09 Thread Selva Nair
On Sun, 9 Feb 2003, Martin Collins wrote:

> On Sun, 9 Feb 2003 10:08:17 +0100 (CET)
> [EMAIL PROTECTED] wrote:
> 
> > On Sat, 8 Feb 2003, Laurent Pinchart wrote:
> > > I've been asked today by my boss to see if I can find a way to get
> > > software MJPEG encoding for PAL-size (768x576) RGB images at a
> > > double real-time rate(50fps).
> >
> > Well, the fastest realtime encoder that I know of exists in mplayer,
> ...
> > On my Athlon XP 1800+ it can encode at >25fps
> 
> On my Athlon 1500+ encoding 672x576 PAL I get this:
> 
> lav2yuv ./mjpeg.avi | \
> mencoder - -ovc lavc -lavcopts vcodec=mjpeg -o ~/mjpeg.avi
> 38fps (interlaced)
> 
> lav2yuv ./mjpeg.avi | \
> mencoder - -ovc lavc -lavcopts vcodec=mjpeg -vop pp=md -o ~/mjpeg.avi
> 37fps (deinterlaced)

yuv2lav performs almost as good as that on my athlon XP1800+.
To eliminate decompressing overhead I use a 720x576 yuv4mpeg stream:

cat video.yuv | yuv2lav -o video.avi
39.9 fps

The resulting avi is, of course, mjpegtools compatible unlike mencoder's.
By the way, only 80% of the cpu gets used, dont know why.

Selva




---
This SF.NET email is sponsored by:
SourceForge Enterprise Edition + IBM + LinuxWorld = Something 2 See!
http://www.vasoftware.com
___
Mjpeg-users mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/mjpeg-users



Re: [Mjpeg-users] mplex error: INTERNAL ERROR: additional datarequired

2003-02-07 Thread Selva Nair
On Fri, 7 Feb 2003, davros wrote:

> >> I'm trying to mplex together a video and an audio file, both produced by
> >> transcode.  I used dvd::rip to generate the transcode commands, but pasted
> >>them onto the command line.  Transcoding seems to have worked; I can view the
> >> video and it looks fine.  The next command to execute is the following
> >> command, also constructed via dvd::rip:
>  mplex -f 4 -V -o
> >>/mnt/davros/40gigger/tmp/unnamed/avi/001/unnamed-001-%d.mpg
> >> /mnt/davros/40gigger/tmp/unnamed/avi/001/unnamed-001.m2v
> >> /mnt/davros/40gigger/tmp/unnamed/avi/001/unnamed-001.mpa
>  This creates an mpg file ~ 200 megs (I expect one ~ 1.5G) and then gives
> >>this

snip ...

> >> error:
>  **ERROR: [mplex] INTERNAL ERROR: additional data required but no free space
> >>in

snip..

> >> The (mostly) complete output is below.  If this is perhaps Transcode
> >>generating a bad output, here is the transcode command used (i'm transcoding
> >> vob files to svcd):
> >> transcode --psu_mode --export_asr 2 -s 1.557 -g 720x480 -z -w 2279 -k -i
> >> /mnt/davros/40gigger/tmp/unnamed/vob/001 --no_split --nav_seek
> >>/mnt/davros/40gigger/tmp/unnamed/tmp/unnamed-001-nav.log -y mpeg2enc,mp2enc -M
> >>2 -Z 480x480 -F '5, -S 643 -B 226' --a52_drc_off -E 44100 -x vob -b 224 -a 0
> >> -o /mnt/davros/40gigger/tmp/unnamed/avi/001/unnamed-001 -C 3 -I 3 -f 30,4

If you could translate that transcode command to explicitly show what
options are passed to mpeg2enc and mp2enc, may be you will get more
response. What does -F '5, -S 643 -B 226' mean? Are you passing -f 5 to
mpeg2enc and -f 4 to mplex? If you are not using the svcd preset (ie -f 4)
what bitrate and video buffer size are passed on to mpeg2enc?

Selva




---
This SF.NET email is sponsored by:
SourceForge Enterprise Edition + IBM + LinuxWorld = Something 2 See!
http://www.vasoftware.com
___
Mjpeg-users mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/mjpeg-users



Re: [Mjpeg-users] Quality from my old video camera and the -d setting

2003-02-05 Thread Selva Nair
On Wed, 5 Feb 2003, Robert Kesterson wrote:

> On Wed, 5 Feb 2003, Selva Nair wrote:
> >
> > I too have often wondered about moving all my dvd tapes into DVD-R in
> > dv format. For archiving, which medium is more reliable? DVD or
> > tape?
> 
> You're kidding, right?

:)

Oh, no I am not going to move my tapes onto optical media -- atleast not
until those high-density optical disks like DVR's become available at an
affordable price. But I am curious about the shelf-life of recorded dv
tapes. Reading about data archiving practices of tape strorage in
controlled atmosphere, regular wind/rewind/retension procedures and the
real paranoids even suggesting to make copies onto fresh tapes every few
years or so, I do wonder whether my precious little mini-dv recording of
1997 summer vacation in St. Petersburg will play fine 25 years down the
line.. My oldest tapes are already 5 years old and haven't touched some of
them for a year atleast.

Selva



---
This SF.NET email is sponsored by:
SourceForge Enterprise Edition + IBM + LinuxWorld = Something 2 See!
http://www.vasoftware.com
___
Mjpeg-users mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/mjpeg-users



Re: [Mjpeg-users] Quality from my old video camera and the -d setting

2003-02-05 Thread Selva Nair
On Wed, 5 Feb 2003, Derek Fountain wrote:

> > > I want to
> > > capture and archive onto DVD+R the tapes I have - quite a few. In order
> > > to fit one 60 minute tape onto one DVD, I need to get the recording to
> > > about 1MB/sec
> >
> > Why do you don't want to create a video DVD ?
> > You can easily fit 3 hours in a very high quality to on disk.
> 
> Because if I want to go back to it in a year's time and edit together a video 
> from selected clips, it's already been encoded. The re-encoding will look 
> pretty terrible, won't it?

If you want to fit 60 mins into a DVD you have little choice but to use an
mpeg-like compression. If you want to keep the DV quality and ability
to edit at a later time, I would stick to DV -- ie 3 to 4 DVDs for a
1 hour tape. Reducing 

> My question was really about archiving MJPEG material for future use. I'll 
> reread that section of the FAQ though.

I too have often wondered about moving all my dvd tapes into DVD-R in 
dv format. For archiving, which medium is more reliable? DVD or
tape?

Selva





---
This SF.NET email is sponsored by:
SourceForge Enterprise Edition + IBM + LinuxWorld = Something 2 See!
http://www.vasoftware.com
___
Mjpeg-users mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/mjpeg-users



Re: [Mjpeg-users] DV standard / more

2003-02-04 Thread Selva Nair
On Wed, 5 Feb 2003, Edouard Chalaron wrote:

> Hi Vladimir
> 
> Thanks for the mail.
> My question was in fact : can I encode the same DV file into PAL or NTSC  
> knowing that the camera that has been used to record the DV files is a NZ 
> one, NZ being in PAL standard, eg is the DV format independant from any NTSC 
> or PAL or SECAM ?

As others have pointed out, DV does have multiple standards, usually
referred to as NTSC and PAL in the sense that they share some
characteristics of analog NTSC and PAL standards. Basically PAL-DV is
720x576 frames at 25 fps (50 fields/sec) while NTSC-DV is 720x480 at 29.97
fps (59.9.. fields/sec). Also the chroma subsampling is different:  4:2:0
for PAL and 4:1:1 for NTSC. 

Given that you may

(i) convert PAL-DV to NTSC-DV using a software converter as
Robert Keterson mentioned, and then transcode to NTSC-DVD.
The quality would depend on the conversion tool.. Unless
you use one of those $$$ motion compensating conversions tools,
I think option (ii) below is as good as this one. 

(ii) de-interlace your PAL-DV source, scale it to 720x480, mpeg2enc  as 
a 24fps movie (actually, 24000/1001), and multiplex with audio stretched 
by  25/24 using sox, for example. Of course, you lose some details by
de-interlacing. This can be done using the mjpegtool chain as:

lav2yuv movie.avi | yuvdenoise -I | yuvscaler -O SIZE_720x480 |
  mpeg2enc -F 1 -a 2 -p 
(or -a 3 if you have 16:9) 
These days I use y4mscaler -I norm=NTSC -I chromass=420_PALDV 
-O preset=DVD instead of yuvscaler.

(iii) Remain in the PAL land and  make a PAL-DVD -- most NTSC dvd
players I have come across play PAL DVDs just fine (ie on an NTSC TV),
but some scale the picture correctly, some simply drop lines 480 to 576,
thus vertically stretching the movie.. 

I have used (i), (ii) and (iii) with "acceptable" results.. YMMV. 

> As for the region, it should be Ok, I burn my own DVD.

Selva




---
This SF.NET email is sponsored by:
SourceForge Enterprise Edition + IBM + LinuxWorld = Something 2 See!
http://www.vasoftware.com
___
Mjpeg-users mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/mjpeg-users



RE: [Mjpeg-users] Inserted frames are corrupted

2003-02-04 Thread Selva Nair
On Tue, 4 Feb 2003, Vladimir Shved wrote:

> > > any way to fix that? And what would cause those 
> > curruptions? I'm using G400,
> > > 512Mb ram, 1.4G CPU, HPT370 RAID0, SA6R. I ran several 
> > tests and was able to
> > > record about 8 hours of video with these options "-in -q80 -d1 -s",
> > > resulting about 2 frame insertions and few deletions, 
> > no more than 5
> > > frames were deleted, no errors from lavrec nor from kernel 
> > nor from drivers.
> > > Also lower quality settings do the same thing, lots of 
> > inserted frames and
> > > they are corrupted. Or maybe its normal thing?

2500 frame insertions per hour is not normal. I normally record at -q 40
-d 1 with 10 or so insertions/deletions per hour, but I haven't done much
recording from the composite in (-i n). -q 80 -d 1 also works fine for me
except that I dont think the increased disk space usage is worth the extra
quality. Are you recording from VHS?  May be something to do with your VHS
signal/tape quality? Have you tried recording from the tuner?

What harddrives do you have? -- if IDE, check you have DMA enabled. Also, 
try  measuring the drive performance by, say, hdparm -t. I have come 
across disk related bottlenecks in the past.

Selva

P.S. You may want to move this discussion to the marvel-linux
list.



---
This SF.NET email is sponsored by:
SourceForge Enterprise Edition + IBM + LinuxWorld = Something 2 See!
http://www.vasoftware.com
___
Mjpeg-users mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/mjpeg-users



Re: [Mjpeg-users] Mpeg field order diagnosis

2003-01-30 Thread Selva Nair
> This trial and error is costing me a fortune in CDs.
> Please help.

Use CD-RW ;)



---
This SF.NET email is sponsored by:
SourceForge Enterprise Edition + IBM + LinuxWorld = Something 2 See!
http://www.vasoftware.com
___
Mjpeg-users mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/mjpeg-users



Re: [Mjpeg-users] Transcoding/scaling from 720x480 to (S)VCD

2003-01-07 Thread Selva Nair
On Tue, 7 Jan 2003, Andrew Stevens wrote:

> Dear Selva,
> 
> > > cat video.m1v | mpeg2dec -o YUVh | yuvscaler -n n -O VCD | mpeg2enc -f 1
> > > -o video_vcd.m1v
> > >
> > > (I've also tried -F 1 -F 4 and -I 1)
> >
> > -I 1 is needed as VCD frames (only 240 vertical lines) are not
> > interlaced. Even otherwise your input appears to be converted film and
> > so progressive to start with (mpeg1 is for progressive video)
> 
> Please try to make sure you really know the answer about before giving 
> advice.   -I 1 is *completely ignored* for MPEG-1 encoding.  It activates 

That was typo ( a missing negative) in my mail -- may be you missed 
my correction mail...

> various MPEG-2 only features.  Even if MPEG-2 were being used it would be 
> nonsense as the half-resolution YUVh format drops the odd fields.
> 
> 
> Andrew
> 



---
This SF.NET email is sponsored by:
SourceForge Enterprise Edition + IBM + LinuxWorld = Something 2 See!
http://www.vasoftware.com
___
Mjpeg-users mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/mjpeg-users



Re: [Mjpeg-users] How to make mpeg files for DVD creation?

2003-01-07 Thread Selva Nair
On Tue, 7 Jan 2003, Wolfgang Goeller wrote:

> Hello Gregoire
> 
> > i reccord data with VDR:
> > http://www.cadsoft.de/people/kls/vdr/download.htm
> > 
> > And then, I demux the recording with ds.jar:
> > http://home.arcor.de/matt2/dvb.matt/
> 
> 
> The second is great but time-consuming: transcode
> (On a 2GHz-Athlon it demuxes about 14 frames/sec)
>   www.theorie.physik.uni-goettingen.de/~ostreich/transcode/
> 
> With transcode you can create avi-files conforming to the
> mjpegtools. You can cut, paste, split

my oh my! why go through mjpeg? why not simply

mpeg2dec -o YUV old.m2v | mpeg2enc -f 8 -o new.m2v 

Selva

> 
> Then you have to reencode this avifiles or the edit.lists.
> 
> The options for transcode that work for me are:
> 
> transcode -N 0x1 -i your_mpeg-file -y mjpeg -k -z -t7000,your_output_name
> 
> This will create avi-files with a length of roughly 1.7 Giga.
> 
> Since the avi-files you create this way have next to no noise you
> need only few options for mpeg2enc - and no yuvdenoise.
> 
> 
> regards
> Wolfgang
> 
> 
> ---
> This SF.NET email is sponsored by:
> SourceForge Enterprise Edition + IBM + LinuxWorld = Something 2 See!
> http://www.vasoftware.com
> ___
> Mjpeg-users mailing list
> [EMAIL PROTECTED]
> https://lists.sourceforge.net/lists/listinfo/mjpeg-users
> 



---
This SF.NET email is sponsored by:
SourceForge Enterprise Edition + IBM + LinuxWorld = Something 2 See!
http://www.vasoftware.com
___
Mjpeg-users mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/mjpeg-users



Re: [Mjpeg-users] How to make mpeg files for DVD creation?

2003-01-07 Thread Selva Nair
On Tue, 7 Jan 2003, Gregoire Favre wrote:

> 
> After that, using mplex, I mux the files together, if I split it using
> the -S option, dvdauthor: http://dvdauthor.sourceforge.net/ finds errors
> in the second file (and without the -S as there is a 2Gb limit, I also
> get errors...on following files) (I use -f 8, -f 9 only gives errors...).

As you mention -f 9, I guess you are using mplex from cvs. Have you 
tried the stable version (1.6.x) with the patch for fixing -S that 
I sent you the otherday? It works fine for me.

Selva 

> 
> Is there a way to have "real" split?
> 
> Thank you very much and have a great day,
> 
>   Grégoire



---
This SF.NET email is sponsored by:
SourceForge Enterprise Edition + IBM + LinuxWorld = Something 2 See!
http://www.vasoftware.com
___
Mjpeg-users mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/mjpeg-users



Re: [Mjpeg-users] Question about SVCD aspect

2003-01-06 Thread Selva Nair
On Tue, 7 Jan 2003, Cameron Kerr wrote:

> Hi all. I'm creating my first SVCD (30 minutes). After mpeg2enc (I'm
> following the steps in the HOWTO), I preview it with mplayer, and it
> shows up as a strange aspect, taller than it ought to be, and and with
> thick black side borders. Also, the image isn't terribly great on the
> bottom (colour out of whack, a bit, ahhh, streaky???).

Hard to comment on that unless you give more details on the input source,
command line used etc..

> 
> Is this normal for a SVCD (captured using PAL, if it matters).

No

> 
> I've yet to burn it (I'll need to go to a friends place to test it on
> his DVD player (plays SVCD also)).

I wouldn't burn it if mplayer cant play it correctly..

> 
> Also, is it normal for a 30 minute recoding to take about 12 hours for
> mpeg2enc to process?

Depends on the hardware and whether you are denoising or not.. On
an Athlon 1800 with 512MB RAM I get about 11fps for mpeg2enc: ie about 85 
minutes encoding time for a 30minute movie. Add to that the time to 
decode, scale and possibly denoise the input avi, it may take anywhere 
from 2 to 4  hours. 

Selva



---
This SF.NET email is sponsored by:
SourceForge Enterprise Edition + IBM + LinuxWorld = Something 2 See!
http://www.vasoftware.com
___
Mjpeg-users mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/mjpeg-users



Re: [Mjpeg-users] Transcoding/scaling from 720x480 to (S)VCD

2003-01-06 Thread Selva Nair

Typo..


On Mon, 6 Jan 2003, Selva Nair wrote:

> On Sun, 5 Jan 2003, beatrice wrote:

> -I 1 is needed as VCD frames (only 240 vertical lines) are not 

Sorry, I meant _not_ needed..

Selva



---
This sf.net email is sponsored by:ThinkGeek
Welcome to geek heaven.
http://thinkgeek.com/sf
___
Mjpeg-users mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/mjpeg-users



Re: [Mjpeg-users] Transcoding/scaling from 720x480 to (S)VCD

2003-01-06 Thread Selva Nair
On Sun, 5 Jan 2003, beatrice wrote:

> Hi all.
> 
> I have a mpg file and I'd like to make a VCD (a SVCD will be ok just the
> same) out of it but I didn't succeed so far.
> 
> The file is a MPEG1 video 720x480 NTSC 29.97 fps 3750kbps (that's what
> mplayer tells)
> 
> I demuxed it with bbdmux, and the video stream I got plays well.
> 
> Then to get a VCD format I tried several commands, none of them worked.
> Here's the command I used (I played a lot with the options but that's
> the basic command I've used)
> 
> cat video.m1v | mpeg2dec -o YUVh | yuvscaler -n n -O VCD | mpeg2enc -f 1
> -o video_vcd.m1v
> 
> (I've also tried -F 1 -F 4 and -I 1)

-I 1 is needed as VCD frames (only 240 vertical lines) are not 
interlaced. Even otherwise your input appears to be converted film and
so progressive to start with (mpeg1 is for progressive video)

> 
> When I try to watch the output video file "video_vcd.m1v" it's all
> filled with colored vertical lines.  Looks like the original video is
> deformed.
> 
> At the bottom of this message there's the first part of the command's
> ouput.

looks alright to me  -- actually you dont need yuvscaler in the
chain: -o YUVh generates 352x240 frames needed for VCD. Pass -I 0
-a 2 to mpeg2enc as mpeg2dec may not set the progressive flag and
aspect ratio correctly. None of these will explain the colored vertical
lines you see so check the input to mpeg2enc using yuvplay:

mpeg2dec -s -o YUVh video.mpg | yuvplay

> 
> Maybe I'm messing something with the framerate (becomes 23.97, don't know
> why); I really don't know where to start, the more I read the more I get
> confused: any hint will be much appreciated.

23.97 is most probably the correct frame rate as detected by mpeg2dec..

> 
> Thanks in advance,
>beatrice.
> 

Selva

> P.S. I wish to all of you a great 2003!!

Happy new year to you too !

> 
> --- command output starts here
> 
> mpeg2dec-0.2.1-mjpegtools-0.6 - by Michel Lespinasse <[EMAIL PROTECTED]>
> and Aaron
> +Holtzman
> Using MMX for IDCT transform
> Using 3DNOW for motion compensation
>INFO: [yuvscaler] yuvscaler (version 1.6.0) is a general scaling
>utility for
> +yuv frames
>INFO: [yuvscaler] (C) 2001 Xavier Biquard <[EMAIL PROTECTED]>
>INFO: [yuvscaler] yuvscaler -h for help, or man yuvscaler
>INFO: [yuvscaler] VCD output format requested in NTSC norm
>INFO: [yuvscaler] yuvscaler input:   frame size:  352x240 pixels
>(126720 bytes)
>INFO: [yuvscaler] yuvscaler input:   frame rate:  24000/1001 fps
>(~23.976024)   INFO: [yuvscaler] yuvscaler input:interlace:
>anyone's guess
>INFO: [yuvscaler] yuvscaler input: sample aspect ratio:  2000:1523
>INFO: [yuvscaler] from 352x240, take 352x240+0+0
>INFO: [yuvscaler] scale to 352x240, 352x240 being 
>displayed,NOT_INTERLACED/PROGRESSIVE
>INFO: [yuvscaler] Scaling uses the RESAMPLE algorithm,
>INFO: [yuvscaler] without line switching,
>INFO: [yuvscaler] without time forwarding.
>INFO: [yuvscaler] frame rate: 23.976 fps
>INFO: [yuvscaler] Scaling ratio for width is 1 to 1
>INFO: [yuvscaler] and is 1 to 1 for height
>INFO: [yuvscaler] Specific downscaling routing number 4
>INFO: [yuvscaler] yuvscaler output:   frame size:  352x240 pixels
>(126720
> +bytes)
>INFO: [yuvscaler] yuvscaler output:   frame rate:  24000/1001 fps
> +(~23.976024)
>INFO: [yuvscaler] yuvscaler output:interlace:  none/progressive
>INFO: [yuvscaler] yuvscaler output: sample aspect ratio:  2000:1523
>INFO: [mpeg2enc] VCD default options selected
>INFO: [mpeg2enc] Selecting VCD output profile
>INFO: [mpeg2enc] Assuming norm NTSC
> ++ WARN: [mpeg2enc] No aspect ratio specifed and no guess possible:
> assuming 4:3+display aspect!
>INFO: [mpeg2enc] Encoding MPEG-1 video to video_vcd.m1v
>INFO: [mpeg2enc] Horizontal size: 352 pel
>INFO: [mpeg2enc] Vertical size: 240 pel
>INFO: [mpeg2enc] Aspect ratio code: 12 = 1:1.1250 (4:3 NTSC for
> +720x480/352x240 images)
>INFO: [mpeg2enc] Frame rate code:   1 = 24000.0/1001.0 (NTSC 3:2
>pulldown
> +converted FILM)
>INFO: [mpeg2enc] Bitrate: 1151 KBit/s
>INFO: [mpeg2enc] Field order for input: none/progressive
>INFO: [mpeg2enc] New Sequence every 700 Mbytes
>INFO: [mpeg2enc] Assuming non-video stream of 230 Kbps
>INFO: [mpeg2enc] Search radius: 16
>INFO: [mpeg2enc] GOP SIZE RANGE 9 TO 15
>INFO: [mpeg2enc] Setting colour/gamma parameters to "NTSC"
>INFO: [mpeg2enc] Progressive format frames = 1
>INFO: [mpeg2enc] mpeg1 - setting intra_dc_precision = 0
>INFO: [mpeg2enc] Buffering 39 frames
>INFO: [yuvscaler] Frame number 0
>INFO: [mpeg2enc] SETTING 3DNOW and MMX for QUANTIZER!
>INFO: [mpeg2enc] SETTING MMX for MOTION!
>INFO: [mpeg2enc] SETTING MMX for TRANSFORM!
>INFO: [mpeg2enc] SETTING MMX for PREDICTION!
>INFO: [yuvscaler] Frame number 1
>INFO: [yuvscaler] Frame number 2
> ...
> ..
> 
> 

Re: [Mjpeg-users] How to use the "-S" option of mplex?

2003-01-06 Thread Selva Nair
On Sun, 5 Jan 2003, Gregoire Favre wrote:

> On Sun, Jan 05, 2003 at 12:49:12PM +0100, Andrew Stevens wrote:
> 
> > Sounds like your using an older version.  There was a bug where the size for 
> > -f 8 was effectively hard-wired to 2GB.  
> > 
> > This is certainly fixed in the development version and I think I also merged 
> > in the (1 line) fix into the 1.6.1 stable release.
> 
> Well, no, mplex gives me:
> 
> mjpegtools mplex version 1.6.1
> Usage: mplex [params] -o  ...
> 
> Prior to that, I was using version 1.6.0 with same result.
> 
> Thank you for your answer ;-)
> 
> Please keep CC to me as I am not on this ml!!!
> 
>   Grégoire

Here is what I did to mplex/multplex.cc to get -S working..
(this patch is for 1.6.0, but its is essentially a 1 line
change easily applied by hand on other versions if needed..)

--- multplex.cc.old Mon Apr 29 12:30:56 2002
+++ multplex.cc Sun Nov 24 13:35:59 2002
@@ -271,7 +271,9 @@
 timestamp_iframe_only = true;
 video_buffers_iframe_only = true;
vbr = true;
-opt_max_segment_size = 2000*1024*1024;
+// opt_max_segment_size = 2000*1024*1024;
+// changed to activate the -S option 
+if(opt_max_segment_size <= 0) opt_max_segment_size = 2000*1024*1024;
 opt_multifile_segment = true;
 break;
 
Selva



---
This sf.net email is sponsored by:ThinkGeek
Welcome to geek heaven.
http://thinkgeek.com/sf
___
Mjpeg-users mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/mjpeg-users



Re: [Mjpeg-users] can't mplex large files

2002-12-17 Thread Selva Nair
On 16 Dec 2002, Florin Andrei wrote:

> > mpeg2enc -S 790 -B 250 -f 4  -o video.m2v
> 
> BTW, what's the maximum value for -S when writing a SVCD on a 700MB CD?
> Is it 795?
> 


The maximum I biurned on to a 80 minutes CD is 805 MB but that 
was hairy -- involved a 1 minute overburn.. I wont do it again..
CD-R are cheap these days.. Well, unless the proposed Canadian levy 
increase to 59c goes through..

For an 80 minutes CD:

80*60*75*2324 = 83664 bytes or 797.882080078125MB. But
remember you need to leave a little space aside for PBC, and space for any
segment items that may be present.  Also many 80 minutes CDs are actually
marked to be a few seconds short of 80 minutes, though most can be
overburned a little.. 795MB looks like a safe choice.

Selva



---
This sf.net email is sponsored by:
With Great Power, Comes Great Responsibility 
Learn to use your power at OSDN's High Performance Computing Channel
http://hpc.devchannel.org/
___
Mjpeg-users mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/mjpeg-users



Re: [Mjpeg-users] can't mplex large files

2002-12-16 Thread Selva Nair

On 16 Dec 2002, Florin Andrei wrote:

> On Sun, 2002-12-15 at 23:54, Markus Plail wrote:
> > * Florin Andrei writes:
> > > [mplex trying to split a file]
> > >If that's useful, here's the mpeg2enc command line i used to generate
> > >the video stream:
> > >mpeg2enc -v 0 -f 4 -F 4 -n n  -o "cass1".m2v -a 2 -I 1
> > 
> > How about using the -S parameter?
> 
> Yes, i added -S 795 to the mplex command line, but that didn't change
> anything, mplex still tried to split the file. That's why i asked on the
> mailing list.

You need to add -S option to mpeg2enc. The way mplex splits stream is 
determined by where mpeg2enc inserts sequence splits in the video stream.
mplex -S parameter is useful only for DVD like streams. See
the manual pages of mpeg2enc and mplex for more details. 

mpeg2enc -S 790 -B 250 -f 4  -o video.m2v

mplex -f 4 video.m2v audio.m2a -o video.mpg 

should work.

Selva



---
This sf.net email is sponsored by:
With Great Power, Comes Great Responsibility 
Learn to use your power at OSDN's High Performance Computing Channel
http://hpc.devchannel.org/
___
Mjpeg-users mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/mjpeg-users



Re: [Mjpeg-users] Re: too many frame drops

2002-12-11 Thread Selva Nair
On Wed, 11 Dec 2002, Matti Haveri wrote:

> Selva Nair:
> 
> >  Well, if you are targetting a particular player it makes sense to use
> >  the maximum supported bit rate.  My Pioneer HTD510 is quite linient when
> >  it comes to VCD/SVCD playback (it even plays 720x480 or 720x576 mpegs
> >  burned as an SVCD), but it can't handle more than 3000kb/s muxed rate. I
> >  have a philips 623 player that I am yet to stress test, but I know that
> >  2000kb/s VCD is very jerky on it. With this and simpilar philips players
> >  this is not a concern as it can play almost all kinds of mpeg1/mpeg2
> >  files simply burned on to a ISO data track on a CD-R -- I have tried
> >  peak bit rates up to 6000kb/s.
> 
> My Pioneer 444 PAL DVD player plays (X)SVCDs at 480x576, 352x576, 
> 720x576 and even a VCD-like 352x288 MPEG2 with both 44.1 and 48 kHz 
> audio from about 1455-2500 kb/s.
> 
> But if I go above 2500 kb/s the playback always stutters no matter 
> what I do (mplex with various -r values, for example).
> 
> Is this just a limitation of the player or is there any trick that 
> can enable 3000-5000 kb/s playback?

I dont know for sure, but it appears that a lot of players out there max
out at around 2700-2800 kb/sec ie at ~2x CD speed. It could be that the CD
drive in these players cannot read at a higher speed or it could be a
firmware limitation. In the case of philips 623 I mentioned above, I know
it can read a CD-R at 4x or may be even faster as it plays a 6000kb/s
mpeg2 file pretty smooth. Nevertheless it stammers with a 2000kb/s VCD. So
I tend to think that player limitations are more often determined by the
built-in software rather than the drive hardware. But I could be wrong as
my Pioneer player is an old model -- may be it simply cant read CDs faster
than ~2x.

Sorry I dont know how to make these players handle higher bit rates.

Selva



---
This sf.net email is sponsored by:
With Great Power, Comes Great Responsibility 
Learn to use your power at OSDN's High Performance Computing Channel
http://hpc.devchannel.org/
___
Mjpeg-users mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/mjpeg-users



Re: [Mjpeg-users] Re: too many frame drops

2002-12-11 Thread Selva Nair

On Wed, 11 Dec 2002, Steven M. Schultz wrote:

> Hi!
> 
> > From: Matti Haveri <[EMAIL PROTECTED]>
> > 
> > My Pioneer 444 PAL DVD player plays (X)SVCDs at 480x576, 352x576, 
> > 720x576 and even a VCD-like 352x288 MPEG2 with both 44.1 and 48 kHz 
> > audio from about 1455-2500 kb/s.
> > 
> > But if I go above 2500 kb/s the playback always stutters no matter 
> > what I do (mplex with various -r values, for example).
> 
>   ~2500kb/s uses a 2X drive mechanism.  To go higher than that the
>   player would have to have the equivalent of a 4X CD drive inside.
> 
>   Standard VCDs (~1150kb/s) only require a 1X CD drive transport.
> 
>   One of my DVD players can handle up to about 4500kb/s on a XSVCD 
>   before it starts having stuttering problems.  
> 
> > Is this just a limitation of the player or is there any trick that 
> > can enable 3000-5000 kb/s playback?
> 
>   It's a limitation of the CD drive - if it's a 2X rated drive then
>   it can only go up to about 2500kb/s or so.
> 

>From what I have seen on philips 623 player I dont think it's simply
the drive capability. See my previous post. Could you please share your
experience on philips 724? Does it play an SVCD with rates as high as
a dvd that it can support when burned on to a CD-R ISO track? 

>It would be real nice if the DVD player makers would simply use
>computer 16x DVDROM drives :)

And as hackable as computers are ;)

Cheers,

Selva



---
This sf.net email is sponsored by:
With Great Power, Comes Great Responsibility 
Learn to use your power at OSDN's High Performance Computing Channel
http://hpc.devchannel.org/
___
Mjpeg-users mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/mjpeg-users



[Mjpeg-users] AC3 muxing

2002-12-11 Thread Selva Nair

Hi,

  I tried out some variations of dvd quality mpeg streams burned on a
CD-R data track using a philips 623 player. As I wrote last time,
with mpeg audio both video and audio plays well (audio channel has to be
manually selected as C0). 

With AC3 I have less success: 

(i) muxed using mplex on 1.6.0: the video plays well but no audio

(ii) using mplex from CVS (checked out at 11 Dec, 01:30 UTC): the player 
identifies the file as VCD (!), but plays the video just fine. No audio,
again.

Mplayer plays both files fine and I cant find anything obviously wrong
with the video/audio parametrs that mplayer finds in the stream. In either
case, the video was made using mpeg2enc -f 8 and audio was converted from
a 48K wav file using mp2enc -b 384 in one case and ffmpeg -vn -ab 384
for ac3.

Any ideas on what could be going wrong?

Selva
 



---
This sf.net email is sponsored by:
With Great Power, Comes Great Responsibility 
Learn to use your power at OSDN's High Performance Computing Channel
http://hpc.devchannel.org/
___
Mjpeg-users mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/mjpeg-users



Re: [Mjpeg-users] too many frame drops

2002-12-11 Thread Selva Nair
On Wed, 11 Dec 2002, Bernhard Praschinger wrote:

> Hallo

..

> 
> > > Sometimes I find it useful to denoise the video by piping the
> > > output of lav2yuv to yuvdenoise -l 1.
> > Yes, good idea, i'll try that.
> If you denoise, I hope you also use --interlace-mode|-I 0 because else
> mpeg2enc will spend time for motion estimation for a interlaced video
> you don't have any more. 

I thought you can denoise without de-interlacing. Isn't it what
yuvdenoise do unless -F is specified?

Cheers,

Selva



---
This sf.net email is sponsored by:
With Great Power, Comes Great Responsibility 
Learn to use your power at OSDN's High Performance Computing Channel
http://hpc.devchannel.org/
___
Mjpeg-users mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/mjpeg-users



Re: [Mjpeg-users] too many frame drops

2002-12-11 Thread Selva Nair
On 10 Dec 2002, Florin Andrei wrote:

> On Mon, 2002-12-09 at 08:00, Selva Nair wrote: 
> > 
> > On 8 Dec 2002, Florin Andrei wrote:
> > > 
> > > [export_mpeg2enc.so] cmd=mpeg2enc -v 0 -q 3 -f 5 -4 2 -2 3 -b 2900 -F 4
> > > -n n  -V 230 -o "casa".m2v -a 2
> > > [export_mp2enc.so] (44/4096) cmd=mp2enc -v 0 -r 44100 -b 128 -s -o
> > > "casa".mpa
> > 
> > Bit rate of 2900 is out of specs for SVCD and may not play well on many
> > stand alone players.
> 
> Hmmm... 
> I'm by no means an expert, but i've heard people saying that the
> "non-standard" SVCDs will actually play just fine on most standalone
> players. 
> I did a bit of testing myself, and indeed my SVCDs can be played almost
> anywhere. 

Well, if you are targetting a particular player it makes sense to use the
maximum supported bit rate.  My Pioneer HTD510 is quite linient when it
comes to VCD/SVCD playback (it even plays 720x480 or 720x576 mpegs burned
as an SVCD), but it can't handle more than 3000kb/s muxed rate. I have a
philips 623 player that I am yet to stress test, but I know that 2000kb/s
VCD is very jerky on it. With this and simpilar philips players this is
not a concern as it can play almost all kinds of mpeg1/mpeg2 files
simply burned on to a ISO data track on a CD-R -- I have tried peak bit
rates up to 6000kb/s.

> 
> > Also -q 3 is too low a value -- you will most
> > certainly get a better output with -q 8 or so.
> 
> But isn't "lower" supposed to be "better"? 

Yes low values of q mean higher quality, but specifying a lower q does not
translate into a higher quality video. I am no expert either, but my
understanding is that -q specifies a quantisation floor and allowing q to
dip down to as low as 3 within the bit rate contsraint of 2900 would leave
little room for rate control. The encoder first estimates the required q
value using maximum allowed bit rate and then clamps it to be above the
user specified quantisation floor, saving bits on simple scenes. Thus
if the floor value is too low, one would end up with a virtually CBR
stream.

I am most probably wrong here, but I think if one is not concerned about
the final size of the movie, but only constrained by the maximum bit rate
the player can handle, a CBR stream with that maximum bit rate should be
as good or even better than a VBR stream. Can someone correct me?

Selva



---
This sf.net email is sponsored by:
With Great Power, Comes Great Responsibility 
Learn to use your power at OSDN's High Performance Computing Channel
http://hpc.devchannel.org/
___
Mjpeg-users mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/mjpeg-users



Re: [Mjpeg-users] from transcode-ml: fooling dvd player to playsvcd's (fwd)

2002-12-10 Thread Selva Nair
On Tue, 10 Dec 2002, Andrew Stevens wrote:

> On Monday 25 Nov 2002 6:49 pm, Aaron Newsome wrote:
> > On Mon, 2002-11-25 at 09:06, Steven M. Schultz wrote:
> > >   If it's still within its "return period" I'd get a Philips 724 that
> > >   does handle SVCDs (as well as all the rewriteable formats).   Also plays
> > >   .mpg files burned into an ISO filesystem - no SVCD/DVD authoring
> > >   involved
> > >
> > >   :)
> >
> > I second that,.. on Steven's recommendation I picked up one of these.
> > It's lived up to everything Steven said it would. I would recommend one
> > to anyone looking for a do-all DVD player.
> 
> I'll third it.   Buy Philips buy Philips... 

:)

I have a Philips 623 player that plays DVD/VCD/SVCD and mp3, jpeg and dvd 
quality mpeg2 streams (made by mpeg2enc, of course) burned into an ISO9660
track on a CD-R. All good except for some minor glitches with non 
pbc VCD/SVCD disks.

Bracing up for my dvd writer shopping, I have been busy testing mpeg2
streams on CD-R data tracks mainly with mpeg audio. One problem I face is
that to hear the sound one has to manually set the audio "channel"  to C0.
By default the palyer seems (??) to look at 0x80-0x87 for AC3 audio
(depending on the audio language setting). Is there a way to force the
player to automatically play a particular audio stream -- some flag on the
mpeg header or whatever?

Cheers,

Selva 




---
This sf.net email is sponsored by:
With Great Power, Comes Great Responsibility 
Learn to use your power at OSDN's High Performance Computing Channel
http://hpc.devchannel.org/
___
Mjpeg-users mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/mjpeg-users



Re: [Mjpeg-users] Expectations, Doubts, Basic Concepts

2002-12-10 Thread Selva Nair
On Tue, 10 Dec 2002, Javier Hernandez wrote:

> Hi All,
> 

> 
> I got some DV raw material [Analog Camera --> Canopus Box --> Firewire]
> with kino (I know it can be done also with dvgrab).
> 
> I did run that DV raw material with MPlayer in my computer:
> - Audio is great aceptable.
> - Video quality is not perfect but it is acceptable.

A decent analog->dv box, which I think Canopus is, should give you very
good quality. I am not sure I understand what is "not perfect" about your
video. Is it interlacing artifacts that troubles you? Video for TV
(including DV) is interlaced with alternating lines differing in time and
best suited for display on TV. When shown on a computer monitor the two
fields differing in time are displayed together into as a single frame, so
you may see combing effects at fast motion scenes. (see
http://www.lukesvideo.com/interlacing.html) Try playing with mplayer's
deinterlacing option (-npp lb ?) for a smoother looking display.

If your final mpeg or divx movie is meant for viewing on a TV monitor you
need not worry about the interlacing artifacts, but if you are more
concerned about smoother display on a computer monitor you can deinterlace
the video using yuvdenoise -F before transcoding.  Deinterlacing is a
lossy process so do it only if you really need progressive video. Most
software players can do some primitive deinterlacing on the fly.

If you are talking of quality issues other than interlacing artifacts,
try to describe what you see in more detail -- someone on the list may be
able to help you.

Cheers,

Selva




---
This sf.net email is sponsored by:ThinkGeek
Welcome to geek heaven.
http://thinkgeek.com/sf
___
Mjpeg-users mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/mjpeg-users