Showing posts with label application. Show all posts
Showing posts with label application. Show all posts

Thursday, July 16, 2009

mplayer notes

Mplayer is my favourite media player as it plays nearly every kind of media file and is the most powerful media player I know in terms of functionality (like filters) and flexibility. I also like the UI (command line and a simple window, no stupid controls, everything goes by the keyboard, I hate the GUI's for it). It just happens to have one of the longest manual pages I ever saw too, and it takes some time to find something in there. That's why I'm writing up the options that I happen to find useful, kind of like a filter for the manpage.

Setting aspect radio:
  • -aspect 16:9
  • -aspect 2.3
Setting deinterlancer:
  • -vf pp=lb
Rebuild index for partial videos:
  • -idx
  • -forceidx
Replay media in loops:
  • -loop
  • -loop 0 ## endless loop
  • -loop 5 ## repeat 5 times
Shuffle media:
  • -shuffle
Seek and cut specified position:
  • -ss 10 ## skip the first 10 seconds
  • -ss 1:30:00 ## seek to stream position 1:30:00
  • -endpos 50 ## stop after 50 seconds of playback
  • -endpos 1:40:00 ## stop at stream position 1:40:00
Play sound only (don't play video):
  • -vo null
Here is an example of how to extract only the sound track of a video file from position 0:24 to 1:54:
  • mplayer -vo null -ss 0:24 -endpos 1:32 [input-filename] -ao pcm:file=[out-filename]