Sam Spilsbury | 1 Jan 2010 17:21
Picon
Gravatar

Taking the input from a USB microphone in mplayer

Hi everyone,

I'm recording analogue video from a v4l2 device (EasyCap D60) - it
works great with mplayer. Inside the device there is a syntek
framegrabber but also a USB line in device which converts dual channel
RCA sound to DSP on the same bus. Currently, I am using the command:

mplayer tv:// driver=v4l2:width=640:height=640:fps=25:outfmt=rgb24:device=/dev/video0

To grab frames from the video device and pipe it to MPlayer which
works great. I'm aware that MPlayer supports audio streams from a
separate source, as a verified worked with -audiofile. Is there any
way that I would be able to use the inbuilt USB microphone as an audio
stream while playing along with the video? I did not see anything in
the man pages about this. I have verified that the USB line in device
works with the GNOME sound recorder (and I PulseAudio I have the USB
microphone with the correct inputs set as the default recording
device).

I have already tried using :alsa:samplerate=128000 but that just
produces no audio. I also  tried adevice=/dev/*dsp* where *dsp* is
each one of the dsp devices and that produces no audio as well.

If anyone could come up with a unified command line that would be
great. Hopefully such arguments would be similar in mencoder as well.

--

-- 
Sam Spilsbury
Reimar Döffinger | 1 Jan 2010 18:16
Picon
Picon

Re: Taking the input from a USB microphone in mplayer

On Sat, Jan 02, 2010 at 12:21:46AM +0800, Sam Spilsbury wrote:
> I have already tried using :alsa:samplerate=128000 but that just
> produces no audio. I also  tried adevice=/dev/*dsp* where *dsp* is
> each one of the dsp devices and that produces no audio as well.

For MPlayer you at least need immediatemode=0 , you'll probably have to
set adevice for ALSA as well, and I can't imagine that your microphone
supports a sample rate of 128000 unless you got it from an alternative
reality where dogs or a creature with similarly good hearing rules the world...
Nezmer | 1 Jan 2010 19:06

MP4 file(s) stutter at a certain point

Hi,

I've been facing a weird issue with some mp4 files. The playback starts
to stutter(plays discontinuously as If CPU or IO is maxed out) at
a certain point. This happens with mplayer-mt linux x86_64 and with
mplayer in a 32bit chroot. Not all files suffer from this. The files
that do suffer at certain points. The files play just fine with ffplay
Totem(gstreamer) and VLC.

Today I decided to save logs.

With -msglevel all=5
http://pastebin.com/f4bce5249

With -msglevel all=9
http://pastebin.com/f32c0e274

Is anyone suffering from similar playback issues?

Crash in draw_alpha_rgb32 (mplayer with vaapi patch)

Hi all,
I am building mplayer with the vaapi patches using the kanotix script (
http://www.kanotix.com/files/fix/mplayer-vaapi-latest.txt). It uses the
patches from
http://www.splitted-desktop.com/~gbeauchesne/mplayer-vaapi/mplayer-vaapi-latest.tar.bz2,
and I've been having this problem at least with the 20091209, 20091221 and
20091228 versions of the patches. I can watch mkv/x264 films using vaapi
acceleration, but as soon as I try to add subtitles, I get SIGSEGV crashes.
The svn revisions of mplayer, ffmpeg, and dvdnav used are 30134, 20947 and
1188 respectively.
I am using kubuntu 9.10 (karmic)
$ uname -a
Linux 1101ha-j 2.6.31-17-lpia #54-Ubuntu SMP Thu Dec 10 16:18:14 UTC 2009
i686 GNU/Linux
$ ls -l /lib/libc[.-]*
-rwxr-xr-x 1 root root 1393092 2009-10-07 04:55 /lib/libc-2.10.1.so
lrwxrwxrwx 1 root root      14 2009-10-07 14:24 /lib/libc.so.6 ->
libc-2.10.1.so
$ X -version

X.Org X Server 1.6.4
Release Date: 2009-9-27
X Protocol Version 11, Revision 0
Build Operating System: Linux 2.6.24-23-server i686 Ubuntu
Current Operating System: Linux 1101ha-j 2.6.31-17-lpia #54-Ubuntu SMP Thu
Dec 10 16:18:14 UTC 2009 i686
Kernel command line: BOOT_IMAGE=/boot/vmlinuz-2.6.31-17-lpia
root=UUID=d6fd38ae-05ca-4858-9091-5ee51989bde1 ro quiet splash irqpoll
mem=2000mb
Build Date: 14 November 2009  05:47:39PM
(Continue reading)

Uoti Urpala | 1 Jan 2010 19:41
Picon
Picon

Re: MP4 file(s) stutter at a certain point

On Fri, 2010-01-01 at 20:06 +0200, Nezmer <at> allurelinux.org wrote:
> I've been facing a weird issue with some mp4 files. The playback starts
> to stutter(plays discontinuously as If CPU or IO is maxed out) at
> a certain point. This happens with mplayer-mt linux x86_64 and with
> mplayer in a 32bit chroot. Not all files suffer from this. The files
> that do suffer at certain points. The files play just fine with ffplay
> Totem(gstreamer) and VLC.
> 
> Today I decided to save logs.
> 
> With -msglevel all=5
> http://pastebin.com/f4bce5249

That log shows problems a lot worse than "stutter" - the status line
values indicate a 18 second desync between video and audio due to
playback being too slow!

The problem is that you've specified -cache either on the command line
or in config files. MPlayer's cache mechanism has problems with mp4/mov
files because playing them involves a lot of seeking around in the file
and the cache doesn't handle that well. Don't enable cache by default.
Reimar Döffinger | 1 Jan 2010 19:45
Picon
Picon

Re: MP4 file(s) stutter at a certain point

On Fri, Jan 01, 2010 at 08:06:47PM +0200, Nezmer <at> allurelinux.org wrote:
> Hi,
> 
> I've been facing a weird issue with some mp4 files. The playback starts
> to stutter(plays discontinuously as If CPU or IO is maxed out) at
> a certain point. This happens with mplayer-mt linux x86_64 and with
> mplayer in a 32bit chroot. Not all files suffer from this. The files
> that do suffer at certain points. The files play just fine with ffplay
> Totem(gstreamer) and VLC.

Most likely those files are not properly interleaved.
Try playing them with -nocache.
RC | 1 Jan 2010 22:41
Picon

Re: -vo jpeg

On Wed, 30 Dec 2009 10:10:46 +0100 (CET)
"Oliver Seitz" <info <at> vtnd.de> wrote:

> Perhaps MPlayer would have to be re-started regularly, because the
> manpage seems to tell me that mplayer won't be willing to write an
> unlimited number of jpegs to just one directory.

maxfiles=0 should take care of that.

--

-- 
Ha. I'm the idiot.
Nezmer | 2 Jan 2010 00:30

Re: MP4 file(s) stutter at a certain point

On Fri, Jan 01, 2010 at 08:41:02PM +0200, Uoti Urpala wrote:
> On Fri, 2010-01-01 at 20:06 +0200, Nezmer <at> allurelinux.org wrote:
> > I've been facing a weird issue with some mp4 files. The playback starts
> > to stutter(plays discontinuously as If CPU or IO is maxed out) at
> > a certain point. This happens with mplayer-mt linux x86_64 and with
> > mplayer in a 32bit chroot. Not all files suffer from this. The files
> > that do suffer at certain points. The files play just fine with ffplay
> > Totem(gstreamer) and VLC.
> > 
> > Today I decided to save logs.
> > 
> > With -msglevel all=5
> > http://pastebin.com/f4bce5249
> 
> That log shows problems a lot worse than "stutter" - the status line
> values indicate a 18 second desync between video and audio due to
> playback being too slow!
> 
> The problem is that you've specified -cache either on the command line
> or in config files. MPlayer's cache mechanism has problems with mp4/mov
> files because playing them involves a lot of seeking around in the file
> and the cache doesn't handle that well. Don't enable cache by default.

That was it. Thank you.

I played with cache, cache-min and cache-seek-min. I never thought
caching itself was the problem.
Sam Spilsbury | 2 Jan 2010 04:02
Picon
Gravatar

Re: Taking the input from a USB microphone in mplayer

On Sat, Jan 2, 2010 at 1:16 AM, Reimar Döffinger
<Reimar.Doeffinger <at> gmx.de> wrote:
> On Sat, Jan 02, 2010 at 12:21:46AM +0800, Sam Spilsbury wrote:
>> I have already tried using :alsa:samplerate=128000 but that just
>> produces no audio. I also  tried adevice=/dev/*dsp* where *dsp* is
>> each one of the dsp devices and that produces no audio as well.
>
> For MPlayer you at least need immediatemode=0 , you'll probably have to
> set adevice for ALSA as well,

So something like:

alsa:immediatemode=0:adevice=/dev/dsp:samplerate=300 then?

> and I can't imagine that your microphone
> supports a sample rate of 128000 unless you got it from an alternative
> reality where dogs or a creature with similarly good hearing rules the world...

Yeah, I don't really know too much about Sample Rates so I read up
about them on Wikipedia.

Regards,

Sam

> _______________________________________________
> MPlayer-users mailing list
> MPlayer-users <at> mplayerhq.hu
> https://lists.mplayerhq.hu/mailman/listinfo/mplayer-users
>
(Continue reading)

RC | 2 Jan 2010 04:23
Picon

Re: Taking the input from a USB microphone in mplayer

On Sat, 2 Jan 2010 11:02:53 +0800
Sam Spilsbury <smspillaz <at> gmail.com> wrote:

> alsa:immediatemode=0:adevice=/dev/dsp:samplerate=300 then?

An Elephant microphone then?

> Yeah, I don't really know too much about Sample Rates so I read up
> about them on Wikipedia.

The standard rates are 48000, 44100 & 32000. Derive lower rates (eg.
voice-only) by dividing them by 2, 3, or 4 at most.  Your sound card is
almost certainly 48,000.

 -- 
Ha. I'm the idiot.

Gmane