Scheduled Maintenance: We are aware of an issue with Google, AOL, and Yahoo services as email providers which are blocking new registrations. We are trying to fix the issue and we have several internal and external support tickets in process to resolve the issue. Please see: viewtopic.php?t=158230

 

 

 

MPlayer/MEncoder Tips and Tricks

Share your HowTo, Documentation, Tips and Tricks. Not for support questions!.
Message
Author
corra
Posts: 43
Joined: 2008-04-20 22:10
Location: Catania, Italy

#31 Post by corra »

Hi,
congratulations for this nice how-to...I'd like to know if it's possible to jump from a track to another (by keyboard) when you listen to an audio cd with mplayer. I read the manual but ->, -<, Pg up and pg down are what I'm looking for...
Thank you,
Corra

User avatar
garrincha
Posts: 2335
Joined: 2006-06-02 16:38

#32 Post by garrincha »

corra wrote:Hi,
congratulations for this nice how-to...I'd like to know if it's possible to jump from a track to another (by keyboard) when you listen to an audio cd with mplayer. I read the manual but ->, -<, Pg up and pg down are what I'm looking for...
Thank you,
Corra
If you play audio cd like this:

Code: Select all

 $ mplayer -identify cdda://
it will list numbers of track and spew out information about each track (though not the title). From man mplayer:

Code: Select all

! and @
                   Seek to the beginning of the previous/next chapter
So holding down the SHIFT key and pressing @ will make mplayer jump to next track, while holding SHIFT and pressing ! will make it jump to previous.
Maurice Green on Usain Bolt's 9.58: "The Earth stopped for a second, and he went to Mars."

corra
Posts: 43
Joined: 2008-04-20 22:10
Location: Catania, Italy

#33 Post by corra »

It doesn't work...here is what happens when I press @:

Code: Select all

corrado@corrado:~$ mplayer -identify -cache 512 cdda://
MPlayer 1.0rc1-4.1.2-DFSG-free (C) 2000-2006 MPlayer Team
CPU: Intel(R) Pentium(R) M processor 1.86GHz (Family: 6, Model: 13, Stepping: 8)CPUflags:  MMX: 1 MMX2: 1 3DNow: 0 3DNow2: 0 SSE: 1 SSE2: 1
Compiled with runtime CPU detection.
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 cdda://.
ID_CDDA_TRACKS=17
ID_CDDA_TRACK_1_MSF=03:07:27
ID_CDDA_TRACK_2_MSF=03:06:34
ID_CDDA_TRACK_3_MSF=03:34:68
ID_CDDA_TRACK_4_MSF=04:08:04
ID_CDDA_TRACK_5_MSF=02:58:53
ID_CDDA_TRACK_6_MSF=04:29:33
ID_CDDA_TRACK_7_MSF=03:54:30
ID_CDDA_TRACK_8_MSF=03:53:02
ID_CDDA_TRACK_9_MSF=04:55:34
ID_CDDA_TRACK_10_MSF=04:35:10
ID_CDDA_TRACK_11_MSF=03:21:03
ID_CDDA_TRACK_12_MSF=03:05:07
ID_CDDA_TRACK_13_MSF=03:50:67
ID_CDDA_TRACK_14_MSF=04:59:08
ID_CDDA_TRACK_15_MSF=03:18:03
ID_CDDA_TRACK_16_MSF=04:02:46
ID_CDDA_TRACK_17_MSF=08:37:44
Found audio CD with 17 tracks.
Cache fill:  0.00% (0 bytes)
Track 1
ID_CDDA_TRACK=1

rawaudio file format detected.
ID_AUDIO_ID=0
ID_FILENAME=cdda://
ID_DEMUXER=rawaudio
ID_AUDIO_FORMAT=1
ID_AUDIO_BITRATE=0
ID_AUDIO_RATE=44100
ID_AUDIO_NCH=2
ID_LENGTH=0.00
==========================================================================
Opening audio decoder: [pcm] Uncompressed PCM audio decoder
AUDIO: 44100 Hz, 2 ch, s16le, 1411.2 kbit/100.00% (ratio: 176400->176400)
ID_AUDIO_BITRATE=1411200
ID_AUDIO_RATE=44100
ID_AUDIO_NCH=2
Selected audio codec: [pcm] afm: pcm (Uncompressed PCM)
==========================================================================
AO: [oss] 44100Hz 2ch s16le (2 bytes per sample)
ID_AUDIO_CODEC=pcm
Video: no video
Position: 0 %
A:   0.0 (unknown) of 4197.3 ( 1:09:57.2) ??,?% 0%

Exiting... (End of file)

User avatar
garrincha
Posts: 2335
Joined: 2006-06-02 16:38

#34 Post by garrincha »

It worked fine with my svn mplayer however the debian-multimedia's mplayer seems to be struck. I'm not sure what's the difference in the mplayer I compiled and the one from debian repository.
Maurice Green on Usain Bolt's 9.58: "The Earth stopped for a second, and he went to Mars."

RoyFokker
Posts: 209
Joined: 2008-07-05 10:56

#35 Post by RoyFokker »

Unfortunately due to the inflexible linux sound implementation if you want to use mplayer to watch a video only and listen to audio only in another program, the audio will mix together from both apps. If you mute the PCM level on mplayer it will mute on every other running program as well.

I have found the commandline option:
mplayer -ao 0
is useful so you can listen to mp3 or flash audio with other programs while watching a muted video in mplayer.

User avatar
garrincha
Posts: 2335
Joined: 2006-06-02 16:38

#36 Post by garrincha »

Maurice Green on Usain Bolt's 9.58: "The Earth stopped for a second, and he went to Mars."

User avatar
garrincha
Posts: 2335
Joined: 2006-06-02 16:38

#37 Post by garrincha »

Maurice Green on Usain Bolt's 9.58: "The Earth stopped for a second, and he went to Mars."

User avatar
glore2002
Posts: 101
Joined: 2008-07-19 16:33

#38 Post by glore2002 »

TonyT wrote:Good post!
re the debian-multimedia key, this is the key, the preceding characters are unnecessary:
# gpg --keyserver pgp.mit.edu --recv-keys 07DC563D1F41B907
# gpg --armor --export 1F41B907 | apt-key add -

You can also use this pgp url:
gpg --keyserver hkp://wwwkeys.eu.pgp.net --recv-keys 1F41B907
gpg --armor --export 1F41B907 | apt-key add
Sorry for waking up this old thread but it fits what I need to know:
When adding a repository, it asks for a key How do you know what that key is? Besides that What does that key mean?

Thanks in advance,
Glore2002

Athlon X2 4200. HD: 320Gb. Video: nVidia 9500GT. RAM: 4Gb. Samsung 732nPlus. Brother 2130 Printer. LiteOn DVD R/W. System: Trying to get back to Debian.

User avatar
garrincha
Posts: 2335
Joined: 2006-06-02 16:38

Re: MPlayer/MEncoder Tips and Tricks

#39 Post by garrincha »

Speed up the playback of 1080 H.264 files in MPlayer - see Addendum in the Troubleshooting Section in the 1st post.
Maurice Green on Usain Bolt's 9.58: "The Earth stopped for a second, and he went to Mars."

User avatar
garrincha
Posts: 2335
Joined: 2006-06-02 16:38

Re: MPlayer/MEncoder Tips and Tricks

#40 Post by garrincha »

Maurice Green on Usain Bolt's 9.58: "The Earth stopped for a second, and he went to Mars."

Bulkley
Posts: 6387
Joined: 2006-02-11 18:35
Has thanked: 2 times
Been thanked: 39 times

Re: MPlayer/MEncoder Tips and Tricks

#41 Post by Bulkley »

Great thread. Is it worth converting from Totem to Mplayer?

User avatar
garrincha
Posts: 2335
Joined: 2006-06-02 16:38

Re: MPlayer/MEncoder Tips and Tricks

#42 Post by garrincha »

Bulkley wrote:Great thread. Is it worth converting from Totem to Mplayer?
I don't know - it's up to you. You could always keep Totem, but it could get conflicting especially when playing the plugins in Iceweasel/Firefox. In one of my installation that also included full Gnome desktop that has Totem by default, I simply make sym linksof mplayer plugins in /usr/lib/mozilla/plugins/ to /usr/lib/iceweasel/plugins/ for example:

Code: Select all

ln -s /usr/lib/mozilla/plugins/mplayerplug-in-dvx.so /usr/lib/iceweasel/plugins/
Make sym links for all mplayer plugins *.so files. So when I start up iceweasel, it'll be mplayer plugin that it's using not totem.
Maurice Green on Usain Bolt's 9.58: "The Earth stopped for a second, and he went to Mars."

Bulkley
Posts: 6387
Joined: 2006-02-11 18:35
Has thanked: 2 times
Been thanked: 39 times

Re: MPlayer/MEncoder Tips and Tricks

#43 Post by Bulkley »

When I first tried mplayer, several years ago, I just couldn't get it working well. I tried several different systems then and settled on Totem. Now, however, I'm wondering if mplayer has caught up with or passed Totem. Is there any sign that Debian might switch from default Totem?

User avatar
garrincha
Posts: 2335
Joined: 2006-06-02 16:38

Re: MPlayer/MEncoder Tips and Tricks

#44 Post by garrincha »

Bulkley wrote:When I first tried mplayer, several years ago, I just couldn't get it working well. I tried several different systems then and settled on Totem. Now, however, I'm wondering if mplayer has caught up with or passed Totem. Is there any sign that Debian might switch from default Totem?
Not in standard Debian installation, at least there is no media player installed by default. If you install desktop like Gnome, Totem will be installed as one of dependencies. I install just barebone system with multimedia stuffs from Debian-multimedia repository. So far MPlayer (and Mencoder) never gave me any problem. It is highly versatile, stable and does about everything for me.
Maurice Green on Usain Bolt's 9.58: "The Earth stopped for a second, and he went to Mars."

L4m3b0yz
Posts: 3
Joined: 2009-06-26 10:20

Re: MPlayer/MEncoder Tips and Tricks

#45 Post by L4m3b0yz »

I found a couple of interesting tips about mplayer here:
http://xt7-player.sourceforge.net/xt7fo ... p?f=5&t=81
http://xt7-player.sourceforge.net/xt7fo ... p?f=5&t=10

In particular about audio options tuning, channel mapping, and realtime audio normalization using ladspa, impressive!

User avatar
garrincha
Posts: 2335
Joined: 2006-06-02 16:38

Re: MPlayer/MEncoder Tips and Tricks

#46 Post by garrincha »

L4m3b0yz wrote:I found a couple of interesting tips about mplayer here:
http://xt7-player.sourceforge.net/xt7fo ... p?f=5&t=81
http://xt7-player.sourceforge.net/xt7fo ... p?f=5&t=10

In particular about audio options tuning, channel mapping, and realtime audio normalization using ladspa, impressive!
Thanks. It's quite interesting especially for anyone who want to map 5.1 sound to 2.0 speaker system. As usual, mplayer by itself has options like pan and channels.

See, Chapter 4. Advanced audio usage in MPlayer's online documentation:

http://www.mplayerhq.hu/DOCS/HTML-singl ... l#advaudio

Btw, as an example to play 5.1 sound from first title of a DVD film in a 2.0 speaker system using the pan filter options given in the link above:

Code: Select all

mplayer dvd://1 -channels 6 -af pan=2:0.5:0:0:0.5:0.5:0:0:0.5:1:1:0.5:0.5
Maurice Green on Usain Bolt's 9.58: "The Earth stopped for a second, and he went to Mars."

L4m3b0yz
Posts: 3
Joined: 2009-06-26 10:20

Re: MPlayer/MEncoder Tips and Tricks

#47 Post by L4m3b0yz »

I'm reading the man page right now, and the pan filter syntax is driving me crazy, Not even that xt7-player has a gui for it, but i think i will succeed :evil: .

...Or maybe it's time to buy a 5.1 system...

oldboy
Posts: 724
Joined: 2007-08-09 12:45

Re: MPlayer/MEncoder Tips and Tricks

#48 Post by oldboy »

This is an old post, but I'll post here anyway in case some newbie search for answer.

I am a pretty new newbie. Had been trying for a few days to get mplayer working. I cannot follow the instruction here, e.g., I don't know where is "my path to video". Search LQ and mplayer.org and can't get it to work. :oops:

What I did to make it work was this:

In gnome desktop, add media to sources.list as stated in post 1.
Using Synaptic package manager, check (search) if mplayer has been installed, if not mark and install it.
Again check if w64codec or w32codec (depending on your system) has been installed, if not install it.
Again check if smplayer has been installed, if not, install it. This is the front end to mplayer (a gui interface).
Next, execute smplayer (applications->sound & video->smplayer
Next option->preferences-general tab-video In this menu here choose what you wish to use. I use vx since it has hardware acceleration. For audio, I use OSS (I use alsamixer to configure my sound)
Next, under the video tab I checked all options, but for some dvd's postprocessing does more bad than good, if so, uncheck it.
Next under options-drives select cd devices, I use /dev/cdrom for both cd and dvd.

That is all, should work like a charm. :lol:
This oldboy has a lot of time in his hands
Linux slows down my Alzheimer and dementia :lol:

L4m3b0yz
Posts: 3
Joined: 2009-06-26 10:20

Re: MPlayer/MEncoder Tips and Tricks

#49 Post by L4m3b0yz »

"my path to video" is actually "your path to video".
:mrgreen:

User avatar
stevepusser
Posts: 12930
Joined: 2009-10-06 05:53
Has thanked: 41 times
Been thanked: 72 times

Re: MPlayer/MEncoder Tips and Tricks

#50 Post by stevepusser »

I see that debian-multimedia has added mplayer-mt (multicore playback for h.264 and mpeg2 codecs) to the testing and unstable repository. I tried a backport of the deb on 64 bit to a "safe" Lenny version (no restricted encoding ability, such as h.264 or mpeg4; plays back those files just fine, which is OK with the patent holders, more business for their content)

I did add some safe opensource libraries to build against:

libvdpau1 from debian-multimedia stable for accelerated hardware video for newer nvidia cards.
libopencore-amrnb and -amrwb from Squeeze, these can be directly installed into Lenny without any other updating needed.
libasound2 from lenny-backports, the Lenny version is just too old to work with the latest source code.

If anyone is interested, I could build a 32 bit version, too, and put the debs, plus the other deb files, into a zip archive. That way, you could just extract the archive and install them all with

dpkg -i *.deb
apt-get -f install

Edit: I could throw the latest SMplayer front-end deb builds from svn in there while I'm at it...
MX Linux packager and developer

Post Reply