Hello Bernie, thanks. Here is what happened:

janos@andraslinux ~/tmp $ cat stream.yuv | yuvscaler -O SVCD | mpeg2enc
-f 4 -o video_svcd.m2v & mplayer -nosound -noframedrop -vo yuv4mpeg
ezcap0001.avi 

[1] 21535 INFO: [yuvscaler] yuvscaler 2.2.1 11-Dec-2007
   INFO: [yuvscaler] (C) 2001-2004 Xavier Biquard <xbiqu...@free.fr>,
yuvscaler -h for help, or man yuvscaler INFO: [mpeg2enc] SETTING
EXTENDED MMX for MOTION! INFO: [mpeg2enc] SETTING SSE and MMX for
TRANSFORM! INFO: [mpeg2enc] SETTING EXTENDED MMX for PREDICTION!
MPlayer 1.4-11.3.0 (C) 2000-2019 MPlayer Team

Playing ezcap0001.avi.
libavformat version 58.76.100 (external)
AVI file format detected.
[aviheader] Video stream found, -vid 0
[aviheader] Audio stream found, -aid 1
VIDEO:  [XVID]  800x592  24bpp  30.000 fps  896.5 kbps (109.4 kbyte/s)
Error opening/initializing the selected video_out (-vo) device.
No stream found.


Exiting... (End of file)
janos@andraslinux ~/tmp $ ls
ezcap0001.avi  stream.yuv

I don't understand. if I issue command

janos@andraslinux ~/tmp $ mplayer ezcap0001.avi 

MPlayer 1.4-11.3.0 (C) 2000-2019 MPlayer Team

Playing ezcap0001.avi.
libavformat version 58.76.100 (external)
AVI file format detected.
[aviheader] Video stream found, -vid 0
[aviheader] Audio stream found, -aid 1
VIDEO:  [XVID]  800x592  24bpp  30.000 fps  896.5 kbps (109.4 kbyte/s)
==========================================================================
Opening video decoder: [ffmpeg] FFmpeg's libavcodec codec family
libavcodec version 58.134.100 (external)
[mpeg4 @ 0x7ff6ba3a8f60]Requested frame threading with a custom
get_buffer2() implementation which is not marked as thread safe. This
is not supported anymore, make your callback thread-safe. Selected
video codec: [ffodivx] vfm: ffmpeg (FFmpeg MPEG-4)
==========================================================================
Load subtitles in ./
==========================================================================
Opening audio decoder: [mpg123] MPEG 1.0/2.0/2.5 layers I, II, III
AUDIO: 44100 Hz, 2 ch, s16le, 64.0 kbit/4.54% (ratio: 8000->176400)
Selected audio codec: [mpg123] afm: mpg123 (MPEG 1.0/2.0/2.5 layers I,
II, III)
==========================================================================
AO: [alsa] 48000Hz 2ch s16le (2 bytes per sample)
Starting playback...
Movie-Aspect is undefined - no prescaling applied.
VO: [xv] 800x592 => 800x592 Planar YV12 
Movie-Aspect is 1.35:1 - prescaling to correct movie aspect.
VO: [xv] 800x592 => 800x592 Planar YV12 
A:  16.2 V:  16.2 A-V: -0.001 ct:  0.012 486/486 27%  0%  0.9% 17 0 

Exiting... (Quit)
janos@andraslinux ~/tmp $ 

the file starts to play almost imediately in a new window, perfectly
with sound and picture. So the video-out (-vo) device works
automatically with mplayer.

Janos
P.S. I'm sending this message from my other email address, a mailserver
on my fitlet machine where I try glav, etc.

On Thu, 06 Oct 2022 08:06:19 -0400
"Janos G. Komaromi" <ja...@jankom.net> wrote:

> -------- Forwarded Message --------
> From: Bernhard Praschinger <bernh...@griesbach.at>
> To: Janos G. Komaromi <ja...@jankom.net>, MJPEG-tools user list
> <mjpeg-users@lists.sourceforge.net>
> Subject: Re: [Mjpeg-users] glav error opening .avi file
> Date: Thu, 6 Oct 2022 06:27:00 +0200
> Mailer: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101
> Firefox/68.0 SeaMonkey/2.53.13
> 
> Hallo,
> 
> mkfifo creates a file where one file/process reads it's content, and 
> another process puts data into. You need is when program data can't
> pipe 
> direct to each other. So you create the named pipe. You start
> afterwards 
> the process that reads the data and as last step you put the data into
> it.
> 
> The commands for the video would than be in one terminal window:
>  > mkfifo stream.yuv
>  > cat stream.yuv │ yuvscaler -O SVCD │ mpeg2enc -f 4 -o
> video_svcd.m2v &
>  > mplayer -nosound -noframedrop -vo yuv4mpeg ezcap0001.avi  
> 
> Don't forget to add the & in the 2nd line to start the process in the 
> background. You don't need to start mplayer in the background.
> 
> For audio:
>  > mplayer -vo null -ao pcm:file=audio.wav ezcap0001.avi
>  > cat audio.wav │ mp2enc -v 2 -V -o sound.mp2  
> 
> Afterwards mutiplex the files together with:
> mplex -f 4 sound.mp2 video_svcd.m2v -o SVCD.mpg
> 
> You have then a encoded MPEG file with ist suitable for SVCD. You
> need to change the commands for you need.
> What do you want with the AVI file ?
> 
> If you encounter errors please add the output to the mail.
> 
> Janos G. Komaromi wrote:
> > Hi Bernie, thanks for your answer. Sorry, I have not been doing
> > video edits lately, so I need a little more help. Lat time I used
> > Cinelerra for video edit on my old FC-3 desktop.
> > 
> > I tried
> > Quote  
> > > mkfifo stream.yuv
> > >   >cat stream.yuv │ yuvdenoise │ yuvscaler -O SVCD │ mpeg2enc -f 4
> > > -o
> > > video_svcd.m2v
> > >   >mplayer -nosound -noframedrop -vo yuv4mpeg anyfile.mpg
> > > 
> > > For Audio:
> > >   >mplayer -vo null -ao pcm:file=anyfile.wav anyfile.mpg
> > >   > cat anyfile.wav │ mp2enc -v 2 -V -o sound.mp2
> > >   
> > Unquote
> > 
> > but did not get far.
> > 
> > My video clip is "ezcap0001.avi" as shown in DETAILS below. What are
> > the exact commands I need to issue? How do I make the "stream.yuv"?
> > If
> > I just issue the command "mkfifo stream.yuv" it creates a zero byte
> > pipe file that the next command uses: "cat stream.yuv |
> > yuvdenoise....
> > etc", but it does not do anything. And what is the "anyfile.mpg"
> > output? Is it the file that can be edited with glav? If it is only
> > the
> > picture content of my video how the edited version will be
> > synchronized
> > with the unedited sound part of the original clip?
> > 
> > Sorry, these may be stupid questions but I'd like to understand the
> > whole thing better. OK, there is the RTFM principle, and I read
> > MJPEG HOWTO document 4.1 through 4.3 but still don't know how to
> > edit my "ezcap0001.avi" video file with glav.
> > 
> > PLease, explain - Janos
> > P.S. tried other opensource linux video editors on my Gentoo
> > machine, but openshot does not run, and could not compile flowblade
> > yet. I like
> > the simplicity of your glav.
> > 
> > On Thu, 2022-09-29 at 19:20 +0200, Bernhard Praschinger wrote:
> > ...  
> > > > 
> > > > DETAILS:
> > > > janos@andraslinux ~/tmp $ lavplay -p S -v 2 ezcap0001.avi
> > > > lavplay2.2.1
> > > > lavtools version 2.2.1
> > > > --DEBUG: [lavplay] Opening video file ezcap0001.avi ...
> > > > **ERROR: [lavplay] Error opening ezcap0001.avi
> > > > 
> > > > janos@andraslinux ~/tmp $ file ezcap0001.avi
> > > > ezcap0001.avi: RIFF (little-endian) data, AVI, 800 x 592, 30.00
> > > > fps,
> > > > video: XviD, audio: MPEG-1 Layer 3 (stereo, 44100 Hz)
> > > > 
> > > > janos@andraslinux ~/tmp $ ffprobe ezcap0001.avi
> > > > ffprobe version 4.4.2 Copyright (c) 2007-2021 the FFmpeg
> > > > developers
> > > >     built with gcc 11.3.0 (Gentoo 11.3.0 p4)
> > > > ...
> > > > Input #0, avi, from 'ezcap0001.avi':
> > > >     Duration: 01:48:51.67, start: 0.000000, bitrate: 967 kb/s
> > > >     Stream #0:0: Video: mpeg4 (Advanced Simple Profile) (XVID /
> > > > 0x44495658), yuv420p, 800x592 [SAR 1:1 DAR 50:37], 896 kb/s, 30
> > > > fps, 30
> > > > tbr, 30 tbn, 30 tbc Stream #0:1: Audio: mp3 (U[0][0][0] /
> > > > 0x0055),
> > > > 44100 Hz, stereo, fltp, 64 kb/sThe mjpegtools can only handle a
> > > > few
> > > > AVI Codecs. For example: dvvideo  
> > > and mjpeg it can't decode the encoded MPEG4
> > > 
> > > I don't know if ffmpeg can decode it in a format the mjpegtools
> > > understand. But mplayer can (should) do it, here is are example
> > > commands
> > > for video:  
> > >   >mkfifo stream.yuv
> > >   >cat stream.yuv │ yuvdenoise │ yuvscaler -O SVCD │ mpeg2enc -f
> > > 4 -o
> > > video_svcd.m2v  
> > >   >mplayer -nosound -noframedrop -vo yuv4mpeg anyfile.mpg  
> > > 
> > > For Audio:  
> > >   >mplayer -vo null -ao pcm:file=anyfile.wav anyfile.mpg
> > >   > cat anyfile.wav │ mp2enc -v 2 -V -o sound.mp2  
> > > 
> > > You find a section in the: mjpegtools manpage called: Decoding
> > > streams
> > > with mplayer that should explain it in more detail. I hope the
> > > program  
> auf hoffentlich bald,
> 
> Berni the Chaos of Woodquarter
> 
> Email: bernh...@griesbach.at
> www: http://www.lysator.liu.se/~gz/bernhard



_______________________________________________
Mjpeg-users mailing list
Mjpeg-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/mjpeg-users

Reply via email to