converting Geovision AVI files with mencoder
I'm new to mencoder and mplayer. I am trying to convert Geovision AVI files (from a CCTV system) into MPEG4 or any other format that can be played without needing access to Geovision's software. I'm using Ubuntu 10.10 (x86, 32 bit) and MPlayer 1.0rc4-4.4.5 from the Maverick repositories. The Geovision files can be viewed with mplayer without any problems. But when I try to use mencoder to convert or copy out the video, I get "duplicate frame" errors as shown below in the sample attempt to extract a few seconds of video. An output file is created, but it is always 4108 bytes in size and contains no video. Two listings below - first, the errors from mencoder, and after that the output from mplayer when it successfully plays the Geovision file. Any suggestions on how to proceed? Thanks, -- Ed -------------------------------------------------- $ mencoder -ni -ovc copy -oac copy -ss 400 -endpos 2 testin.avi -o testout.avi MEncoder 1.0rc4-4.4.5 (C) 2000-2010 MPlayer Team success: format: 0 data: 0x0 - 0x168ee00 AVI file format detected. [aviheader] Video stream found, -vid 0 [aviheader] Audio stream found, -aid 2 Badly interleaved AVI file detected - switching to -ni mode... AVI: No audio stream found -> no sound. VIDEO: [GEOV] 320x240 24bpp 30.000 fps 270.3 kbps (33.0 kbyte/s) [V] filefmt:3 fourcc:0x564F4547 size:320x240 fps:30.000 ftime:=0.0333 ========================================================================== Opening audio decoder: [pcm] Uncompressed PCM audio decoder AUDIO: 8000 Hz, 1 ch, u8, 64.0 kbit/100.00% (ratio: 8000->8000) Selected audio codec: [pcm] afm: pcm (Uncompressed PCM) ========================================================================== videocodec: framecopy (320x240 24bpp fourcc=564f4547) audiocodec: framecopy (format=1 chans=1 rate=8000 bits=8 B/s=8000 sample-1) Pos: 0.7s 21f (41%) 0.00fps Trem: 0min 0mb A-V:-0.067 [0:0] 1 duplicate frame(s)! Pos: 1.1s 31f (41%) 0.00fps Trem: 0min 0mb A-V:-0.067 [182:0] 1 duplicate frame(s)! Pos: 1.4s 41f (41%) 0.00fps Trem: 0min 0mb A-V:-0.067 [171:0] 1 duplicate frame(s)! Pos: 1.8s 51f (41%) 0.00fps Trem: 0min 0mb A-V:-0.067 [165:0] 1 duplicate frame(s)! Writing index...57f (41%) 0.00fps Trem: 0min 0mb A-V:-0.053 [161:0] Writing header... ODML: Aspect information not (yet?) available or unspecified, not writing vprp header. Video stream: 161.532 kbit/s (20191 B/s) size: 41056 bytes 2.033 secs 57 frames Audio stream: -nan kbit/s (-2147483648 B/s) size: 0 bytes 0.000 secs -------------------------------------------------- $ mplayer -ss 400 -endpos 2 testin.avi MPlayer 1.0rc4-4.4.5 (C) 2000-2010 MPlayer Team mplayer: could not connect to socket mplayer: No such file or directory Failed to open LIRC support. You will not be able to use your remote control. Playing testin.avi. AVI file format detected. [aviheader] Video stream found, -vid 0 [aviheader] Audio stream found, -aid 2 Badly interleaved AVI file detected - switching to -ni mode... AVI: No audio stream found -> no sound. VIDEO: [GEOV] 320x240 24bpp 30.000 fps 270.3 kbps (33.0 kbyte/s) open: No such file or directory [MGA] Couldn't open: /dev/mga_vid open: No such file or directory [MGA] Couldn't open: /dev/mga_vid [VO_TDFXFB] Can't open /dev/fb0: Permission denied. [VO_3DFX] Unable to open /dev/3dfx. Failed to open VDPAU backend libvdpau_nvidia.so: cannot open shared object file: No such file or directory [vdpau] Error when calling vdp_device_create_x11: 1 ========================================================================== Opening video decoder: [vfw] Win32/VfW video codecs Loading codec DLL: 'GeoCodec.dll' Loaded DLL driver GeoCodec.dll at 10000000 [PP] Using codec's postprocessing, max q = 9. Could not find matching colorspace - retrying with -vf scale... Opening video filter: [scale] Opening video filter: [flip] Movie-Aspect is undefined - no prescaling applied. [swscaler @ 0x940ab70]using unscaled bgr24 -> yuv420p special converter VO: [xv] 320x240 => 320x240 Planar YV12 Selected video codec: [geov] vfm: vfw (GeoCodec) ========================================================================== ========================================================================== Opening audio decoder: [pcm] Uncompressed PCM audio decoder AUDIO: 8000 Hz, 1 ch, u8, 64.0 kbit/100.00% (ratio: 8000->8000) Selected audio codec: [pcm] afm: pcm (Uncompressed PCM) ========================================================================== AO: [pulse] 8000Hz 1ch u8 (1 bytes per sample) Starting playback... A: 0.0 V: 402.0 A-V:-402.000 ct:-60.100 12061/12061 8% 12% 0.0% 0 0 Exiting... (End of file)
On 3/2/12 10:08 AM, "Ed Ravin" <eravin@panix.com> wrote:
I'm new to mencoder and mplayer. I am trying to convert Geovision AVI files (from a CCTV system) into MPEG4 or any other format that can be played without needing access to Geovision's software. I'm using Ubuntu 10.10 (x86, 32 bit) and MPlayer 1.0rc4-4.4.5 from the Maverick repositories.
The Geovision files can be viewed with mplayer without any problems. But when I try to use mencoder to convert or copy out the video, I get "duplicate frame" errors as shown below in the sample attempt to extract a few seconds of video. An output file is created, but it is always 4108 bytes in size and contains no video.
Two listings below - first, the errors from mencoder, and after that the output from mplayer when it successfully plays the Geovision file.
Any suggestions on how to proceed?
Thanks,
-- Ed
--------------------------------------------------
$ mencoder -ni -ovc copy -oac copy -ss 400 -endpos 2 testin.avi -o testout.avi MEncoder 1.0rc4-4.4.5 (C) 2000-2010 MPlayer Team success: format: 0 data: 0x0 - 0x168ee00 AVI file format detected. [aviheader] Video stream found, -vid 0 [aviheader] Audio stream found, -aid 2
Badly interleaved AVI file detected - switching to -ni mode... AVI: No audio stream found -> no sound. VIDEO: [GEOV] 320x240 24bpp 30.000 fps 270.3 kbps (33.0 kbyte/s) [V] filefmt:3 fourcc:0x564F4547 size:320x240 fps:30.000 ftime:=0.0333 ========================================================================== Opening audio decoder: [pcm] Uncompressed PCM audio decoder AUDIO: 8000 Hz, 1 ch, u8, 64.0 kbit/100.00% (ratio: 8000->8000) Selected audio codec: [pcm] afm: pcm (Uncompressed PCM) ========================================================================== videocodec: framecopy (320x240 24bpp fourcc=564f4547) audiocodec: framecopy (format=1 chans=1 rate=8000 bits=8 B/s=8000 sample-1) Pos: 0.7s 21f (41%) 0.00fps Trem: 0min 0mb A-V:-0.067 [0:0] 1 duplicate frame(s)! Pos: 1.1s 31f (41%) 0.00fps Trem: 0min 0mb A-V:-0.067 [182:0] 1 duplicate frame(s)! Pos: 1.4s 41f (41%) 0.00fps Trem: 0min 0mb A-V:-0.067 [171:0] 1 duplicate frame(s)! Pos: 1.8s 51f (41%) 0.00fps Trem: 0min 0mb A-V:-0.067 [165:0] 1 duplicate frame(s)! Writing index...57f (41%) 0.00fps Trem: 0min 0mb A-V:-0.053 [161:0] Writing header... ODML: Aspect information not (yet?) available or unspecified, not writing vprp header.
Video stream: 161.532 kbit/s (20191 B/s) size: 41056 bytes 2.033 secs 57 frames
Audio stream: -nan kbit/s (-2147483648 B/s) size: 0 bytes 0.000 secs
--------------------------------------------------
$ mplayer -ss 400 -endpos 2 testin.avi MPlayer 1.0rc4-4.4.5 (C) 2000-2010 MPlayer Team mplayer: could not connect to socket mplayer: No such file or directory Failed to open LIRC support. You will not be able to use your remote control.
Playing testin.avi. AVI file format detected. [aviheader] Video stream found, -vid 0 [aviheader] Audio stream found, -aid 2
Badly interleaved AVI file detected - switching to -ni mode... AVI: No audio stream found -> no sound. VIDEO: [GEOV] 320x240 24bpp 30.000 fps 270.3 kbps (33.0 kbyte/s) open: No such file or directory [MGA] Couldn't open: /dev/mga_vid open: No such file or directory [MGA] Couldn't open: /dev/mga_vid [VO_TDFXFB] Can't open /dev/fb0: Permission denied. [VO_3DFX] Unable to open /dev/3dfx. Failed to open VDPAU backend libvdpau_nvidia.so: cannot open shared object file: No such file or directory [vdpau] Error when calling vdp_device_create_x11: 1 ========================================================================== Opening video decoder: [vfw] Win32/VfW video codecs Loading codec DLL: 'GeoCodec.dll' Loaded DLL driver GeoCodec.dll at 10000000 [PP] Using codec's postprocessing, max q = 9. Could not find matching colorspace - retrying with -vf scale... Opening video filter: [scale] Opening video filter: [flip] Movie-Aspect is undefined - no prescaling applied. [swscaler @ 0x940ab70]using unscaled bgr24 -> yuv420p special converter VO: [xv] 320x240 => 320x240 Planar YV12 Selected video codec: [geov] vfm: vfw (GeoCodec) ========================================================================== ========================================================================== Opening audio decoder: [pcm] Uncompressed PCM audio decoder AUDIO: 8000 Hz, 1 ch, u8, 64.0 kbit/100.00% (ratio: 8000->8000) Selected audio codec: [pcm] afm: pcm (Uncompressed PCM) ========================================================================== AO: [pulse] 8000Hz 1ch u8 (1 bytes per sample) Starting playback... A: 0.0 V: 402.0 A-V:-402.000 ct:-60.100 12061/12061 8% 12% 0.0% 0 0
Exiting... (End of file)
Can you get a current version of MPlayer? Can you try the entire duration without the -ni, -ss, and -endpos options? Laine Lee
On Fri, Mar 02, 2012 at 03:46:52PM -0600, L. Lee wrote:
On 3/2/12 10:08 AM, "Ed Ravin" <eravin@panix.com> wrote: ...
--------------------------------------------------
$ mencoder -ni -ovc copy -oac copy -ss 400 -endpos 2 testin.avi -o testout.avi MEncoder 1.0rc4-4.4.5 (C) 2000-2010 MPlayer Team ... Pos: 0.7s 21f (41%) 0.00fps Trem: 0min 0mb A-V:-0.067 [0:0] 1 duplicate frame(s)! Pos: 1.1s 31f (41%) 0.00fps Trem: 0min 0mb A-V:-0.067 [182:0] 1 duplicate frame(s)! Pos: 1.4s 41f (41%) 0.00fps Trem: 0min 0mb A-V:-0.067 [171:0] 1 duplicate frame(s)! Pos: 1.8s 51f (41%) 0.00fps Trem: 0min 0mb A-V:-0.067 [165:0] 1 duplicate frame(s)! ... Can you get a current version of MPlayer? Can you try the entire duration without the -ni, -ss, and -endpos options?
The results are the same with or without -ni, and with our without the -ss/-endpos options. I used them in the example to keep the number of error messages down. Playback works fine with or without -ni and with or without the -ss/-endpos options. By "current version", do you mean build it from the latest source snapshot?
On 3/2/12 4:09 PM, "Ed Ravin" <eravin@panix.com> wrote:
The results are the same with or without -ni, and with our without the -ss/-endpos options. I used them in the example to keep the number of error messages down.
Playback works fine with or without -ni and with or without the -ss/-endpos options.
By "current version", do you mean build it from the latest source snapshot?
Afraid so... Laine Lee
participants (2)
-
Ed Ravin -
L. Lee