Author Topic: Mplayer Not Playing Audio (& Other Stuff)  (Read 6243 times)

grog

  • Hero Member
  • *****
  • Posts: 692
    • View Profile
    • http://
Mplayer Not Playing Audio (& Other Stuff)
« on: January 29, 2006, 01:11:32 pm »
Hi all. I'm having trouble getting mplayer 1.0pre6-3.4.3 from playing producing any audio output. The mp3's I have play fine with opie-mediaplaye2 & xmms, and mplayer plays the video portions of the files I've converted using PocketDivXEncoder (I tried the instructions for using mencoder from here, but mplayer couldn't find the codec used, even when I specified mpeg. I'd much prefer to use mencoder if I could, though. Much more flexible). Mplayer says it finds the mp3 decoder:

Code: [Select]
Opening audio decoder: [mp3lib] MPEG layer-2, layer-3
AUDIO: 22050 Hz, 2 ch, 16 bit (0x10), ratio: 3000->88200 (24.0 kbit)
Selected audio codec: [mp3] afm:mp3lib (mp3lib MPEG layer-2, layer-3)
Any ideas I could try? thks
GROG!

lardman

  • Hero Member
  • *****
  • Posts: 4512
    • View Profile
    • http://people.bath.ac.uk/enpsgp/Zaurus/
Mplayer Not Playing Audio (& Other Stuff)
« Reply #1 on: January 30, 2006, 06:12:33 am »
Either specify -ac mad explicitly, or put 'ac mad' in the mplayer conf file (whose name escapes me I'm afraid).

Si
C750 OZ3.5.4 (GPE, 2.6.x kernel)
SL5500 OZ3.5.4 (Opie)
Nokia 770
Serial GPS, WCF-12, Socket Ethernet & BT, Ratoc USB
WinXP, Mandriva

grog

  • Hero Member
  • *****
  • Posts: 692
    • View Profile
    • http://
Mplayer Not Playing Audio (& Other Stuff)
« Reply #2 on: January 30, 2006, 07:14:32 am »
Quote
Either specify -ac mad explicitly, or put 'ac mad' in the mplayer conf file (whose name escapes me I'm afraid).[div align=\"right\"][a href=\"index.php?act=findpost&pid=112957\"][{POST_SNAPBACK}][/a][/div]
Worked like a charm. For the record, the file is /home/root/.mplayer/config, and the option needs to be specified as 'ac=mad' there.

Thanks
GROG!

lardman

  • Hero Member
  • *****
  • Posts: 4512
    • View Profile
    • http://people.bath.ac.uk/enpsgp/Zaurus/
Mplayer Not Playing Audio (& Other Stuff)
« Reply #3 on: January 30, 2006, 07:30:58 am »
I would be tempted to conclude that this is a bug (the fact that it's not using mad by default, or that the config file isn't auto-generated), however it is bad form for a program to make any alterations to files in the home directories, so I'm not sure what the answer is.

Might be worth a bug tracker report anyway,


Si
C750 OZ3.5.4 (GPE, 2.6.x kernel)
SL5500 OZ3.5.4 (Opie)
Nokia 770
Serial GPS, WCF-12, Socket Ethernet & BT, Ratoc USB
WinXP, Mandriva

alan

  • Full Member
  • ***
  • Posts: 221
    • View Profile
Mplayer Not Playing Audio (& Other Stuff)
« Reply #4 on: January 30, 2006, 08:46:56 am »
Same thing using mplayer-atty (on zaurus, far much better than mplayer, and i hope atty version will become the officially recomanded mplayer version for openzaurus, by the way).

On OZ 3.5.4 RC GPE, i also had to

# chmod 666 /dev/mem

(thanks XorA)

Cheers.

lardman

  • Hero Member
  • *****
  • Posts: 4512
    • View Profile
    • http://people.bath.ac.uk/enpsgp/Zaurus/
Mplayer Not Playing Audio (& Other Stuff)
« Reply #5 on: January 30, 2006, 10:46:36 am »
Good point, the atty version is optimised better afaik and should work fine on grog's 5600 (though it won't work on the SA machines - collies)


Si
C750 OZ3.5.4 (GPE, 2.6.x kernel)
SL5500 OZ3.5.4 (Opie)
Nokia 770
Serial GPS, WCF-12, Socket Ethernet & BT, Ratoc USB
WinXP, Mandriva

grog

  • Hero Member
  • *****
  • Posts: 692
    • View Profile
    • http://
Mplayer Not Playing Audio (& Other Stuff)
« Reply #6 on: January 30, 2006, 10:47:30 am »
Quote
Might be worth a bug tracker report anyway,[div align=\"right\"][{POST_SNAPBACK}][/a][/div]
I'll put one in. I can't seem to get to the bugzilla page right now, though. Site problems?

Quote
Same thing using mplayer-atty (on zaurus, far much better than mplayer, and i hope atty version will become the officially recomanded mplayer version for openzaurus, by the way).
What's the diff?

Quote
On OZ 3.5.4 RC GPE, i also had to

# chmod 666 /dev/mem[div align=\"right\"][a href=\"index.php?act=findpost&pid=112965\"][{POST_SNAPBACK}][/a][/div]
That's just because in GPE you're probably not running as root.

So, any suggestions on how I can encode my vids? I'm looking at [a href=\"http://home.earthlink.net/~cresho/start.htm]cresho's page[/url] right now, but he uses a lot of different software. Can't I just make due with mencoder somehow? I'm looking to the not too distant future where I might be able to dump the 'doze desktop & move to linux.
GROG!

grog

  • Hero Member
  • *****
  • Posts: 692
    • View Profile
    • http://
Mplayer Not Playing Audio (& Other Stuff)
« Reply #7 on: January 30, 2006, 12:49:58 pm »
Quote
Good point, the atty version is optimised better afaik and should work fine on grog's 5600 (though it won't work on the SA machines - collies)[div align=\"right\"][a href=\"index.php?act=findpost&pid=112984\"][{POST_SNAPBACK}][/a][/div]
Any chance to make it available in the poodle machine feed?
GROG!

lardman

  • Hero Member
  • *****
  • Posts: 4512
    • View Profile
    • http://people.bath.ac.uk/enpsgp/Zaurus/
Mplayer Not Playing Audio (& Other Stuff)
« Reply #8 on: January 30, 2006, 01:11:09 pm »
You can get a copy from XorA's feed iirc - look at the encoding/playing howto on the oz.org website.

Si
C750 OZ3.5.4 (GPE, 2.6.x kernel)
SL5500 OZ3.5.4 (Opie)
Nokia 770
Serial GPS, WCF-12, Socket Ethernet & BT, Ratoc USB
WinXP, Mandriva

grog

  • Hero Member
  • *****
  • Posts: 692
    • View Profile
    • http://
Mplayer Not Playing Audio (& Other Stuff)
« Reply #9 on: January 30, 2006, 01:34:30 pm »
Quote
You can get a copy from XorA's feed iirc - look at the encoding/playing howto on the oz.org website.[div align=\"right\"][{POST_SNAPBACK}][/a][/div]
There's no link off the [a href=\"http://openzaurus.org/wordpress/howto/encoding-and-playing-video-for-c7x0-devices/]howto[/url] (but I am going to try some of the encoding tips there, thanks ) and can't find any other ipk sources, either on oz.org, oesf.org, ipkgfind or google. Is it something that could be added to the oz feeds? Alan, do you have a copy I could try?

thks
GROG!

grog

  • Hero Member
  • *****
  • Posts: 692
    • View Profile
    • http://
Mplayer Not Playing Audio (& Other Stuff)
« Reply #10 on: January 31, 2006, 08:16:30 am »
If anybody can offer assistance, I've tried encoding with the instructions off of the OZ howto:

Code: [Select]
mencoder FILE-IN.avi -srate 24000 -ofps 15 -sws 2 -ovc lavc -vf scale=320:240,eq2=1.0:0.6:0.1:0.7 -lavcopts vcodec=mpeg4:vhq:vbitrate=150 -lameopts cbr:br=64:mode=3 -vop scale=320:240 -oac mp3lame -o FILE-OUT.avibut while mplayer plays the sound fine, there's no video. mplayer's output has the following:

Code: [Select]
Cannot find codec matching selected -vo and video format 0x34504D46.mplayer itself doesn't seem to offer an mpeg4 codec. Am I reading this right?

Code: [Select]
grog:$ mplayer -vo help
MPlayer 1.0pre6-3.4.3 (C) 2000-2004 MPlayer Team
CPU: ARM

Available video output drivers:
        fbdev   Framebuffer Device
        fbdev2  Framebuffer Device
        null    Null video output
        mpegpes Mpeg-PES to DVB card
        yuv4mpeg        yuv4mpeg output for mjpegtools
        tga     Targa output
        pnm     PPM/PGM/PGMYUV file
        md5sum  md5sum of each frame

thks in advance
GROG!

lardman

  • Hero Member
  • *****
  • Posts: 4512
    • View Profile
    • http://people.bath.ac.uk/enpsgp/Zaurus/
Mplayer Not Playing Audio (& Other Stuff)
« Reply #11 on: January 31, 2006, 09:00:54 am »
The codec support is a compile-time option. It may be that the version you're using dosen't support mpeg4. Alternatively it may have support (e.g. DivX) but not for the specific fourCC you've given it. I'm not sure whether this can be changed at run-time, but I doubt it (though it may be possible to force it to use a certain codec and not try to determine it itself).


Si
C750 OZ3.5.4 (GPE, 2.6.x kernel)
SL5500 OZ3.5.4 (Opie)
Nokia 770
Serial GPS, WCF-12, Socket Ethernet & BT, Ratoc USB
WinXP, Mandriva

grog

  • Hero Member
  • *****
  • Posts: 692
    • View Profile
    • http://
Mplayer Not Playing Audio (& Other Stuff)
« Reply #12 on: January 31, 2006, 09:45:15 pm »
Quote
The codec support is a compile-time option. It may be that the version you're using dosen't support mpeg4. Alternatively it may have support (e.g. DivX) but not for the specific fourCC you've given it. I'm not sure whether this can be changed at run-time, but I doubt it (though it may be possible to force it to use a certain codec and not try to determine it itself)[div align=\"right\"][{POST_SNAPBACK}][/a][/div]
Ok, so given this:

Code: [Select]
grog:$ mplayer -vo help
MPlayer 1.0pre6-3.4.3 (C) 2000-2004 MPlayer Team
CPU: ARM

Available video output drivers:
        fbdev   Framebuffer Device
        fbdev2  Framebuffer Device
        null    Null video output
        mpegpes Mpeg-PES to DVB card
        yuv4mpeg        yuv4mpeg output for mjpegtools
        tga     Targa output
        pnm     PPM/PGM/PGMYUV file
        md5sum  md5sum of each frame
I would assume that neither mpeg4 nor divx are supported. This is the only mplayer in the oz feed. Is there anywhere else I can get another version, or is there a way I can add codecs? Can I just create a /home/root/.mplayer/codecs (for example) & place the [a href=\"http://ftp5.mplayerhq.hu/mplayer/releases/codecs/essential-20050412.tar.bz2]essential codecs[/url] there & mplayer will recongnize them?
GROG!

lardman

  • Hero Member
  • *****
  • Posts: 4512
    • View Profile
    • http://people.bath.ac.uk/enpsgp/Zaurus/
Mplayer Not Playing Audio (& Other Stuff)
« Reply #13 on: February 01, 2006, 06:33:14 am »
I fear I'm now getting a bit out of my depth (certainly without looking into these things!), but:

Quote
grog:<pts/0>$ mplayer -vo help

I think you want something else - vo is for video output (e.g. to the screen). Try -vc instead.

Quote
or is there a way I can add codecs? Can I just create a /home/root/.mplayer/codecs (for example) & place the essential codecs there & mplayer will recongnize them?

I'm not sure about this, however I thought that mplayer had to have its codecs built in.... (in any case see above, -vc, and see what that says).


Si
C750 OZ3.5.4 (GPE, 2.6.x kernel)
SL5500 OZ3.5.4 (Opie)
Nokia 770
Serial GPS, WCF-12, Socket Ethernet & BT, Ratoc USB
WinXP, Mandriva

grog

  • Hero Member
  • *****
  • Posts: 692
    • View Profile
    • http://
Mplayer Not Playing Audio (& Other Stuff)
« Reply #14 on: February 01, 2006, 06:53:25 am »
Quote
I fear I'm now getting a bit out of my depth (certainly without looking into these things!), but:
You're efforts are greatly appreciated, nonetheless

Quote
Quote
grog:<pts/0>$ mplayer -vo help
I think you want something else - vo is for video output (e.g. to the screen). Try -vc instead.[div align=\"right\"][a href=\"index.php?act=findpost&pid=113239\"][{POST_SNAPBACK}][/a][/div]
You're absolutely right. That command shows about 190 codecs installed, amongst them various mpeg & divx ones. So mplayer seems good to go in that department.

So I can only assume that there's something wrong with the method I'm using to encode. I'll try some more things there & see how it goes. I the mean time if anybody else can think of something, please feel free. I'l post back with a solution otherwise.

Thanks lardman.
GROG!