- 论坛徽章:
- 0
|
今天在看dvd的时候,无论如何也不能正常播放影片。
所以,就man了一下mplayer。看到些例子,就贴出来。
如果希望把man或者info的信息转成文本,可以使用下面的命令
>man tcsh | col -b > tcsh.txt
>info tcsh -o tcsh.txt -s
这两条命令是从Linux版的“一句话精彩”抄来的。
http://linux.chinaunix.net/bbs/thread-16141-1-1.html
EXAMPLES OF MPLAYER USAGE
Quickstart DVD playing:
mplayer dvd://1
Play in Japanese with English subtitles:
mplayer dvd://1 -alang ja -slang en
Play only chapters 5, 6, 7:
mplayer dvd://1 -chapter 5-7
Play only titles 5, 6, 7:
mplayer dvd://5-7
Play a multiangle DVD:
mplayer dvd://1 -dvdangle 2
Play from a different DVD device:
mplayer dvd://1 -dvd-device /dev/dvd2
Play DVD video from a directory with VOB files:
mplayer dvd://1 -dvd-device /path/to/directory/
Copy a DVD title to hard disk, saving to file title1.vob :
mplayer dvd://1 -dumpstream -dumpfile title1.vob
Stream from HTTP:
mplayer http://mplayer.hq/example.avi
Stream using RTSP:
mplayer rtsp://server.example.com/streamName
Convert subtitles to MPsub format:
mplayer dummy.avi -sub source.sub -dumpmpsub
Convert subtitles to MPsub format without watching the movie:
mplayer /dev/zero -rawvideo pal:fps=xx -demuxer rawvideo -vc null -vo null -noframedrop -benchmark -sub source.sub -dumpmpsub
input from standard V4L:
mplayer tv:// -tv driver=v4l:width=640:height=480:outfmt=i420 -vc rawi420 -vo xv
Playback on Zoran cards (old style, deprecated):
mplayer -vo zr -vf scale=352:288 file.avi
Playback on Zoran cards (new style):
mplayer -vo zr2 -vf scale=352:288,zrmjpeg file.avi
Play a 6-channel AAC file with only two speakers:
mplayer -rawaudio format=0xff -demuxer rawaudio -af pan=2:.32:.32:.39:.06:.06:.39:.17:-.17:-.17:.17:.33:.33 adts_he-aac160_51.aac
You might want to play a bit with the pan values (e.g multiply with a
value) to increase volume or avoid clipping.
checkerboard invert with geq filter:
mplayer -vf geq='128+(p(XY)-128)*(0.5-gt(mod(X/SW128)64))*(0.5-gt(mod(Y/SH128)64))*4'
EXAMPLES OF MENCODER USAGE
Encode DVD title #2, only selected chapters:
mencoder dvd://2 -chapter 10-15 -o title2.avi -oac copy -ovc lavc -lavcopts vcodec=mpeg4
Encode DVD title #2, resizing to 640x480:
mencoder dvd://2 -vf scale=640:480 -o title2.avi -oac copy -ovc lavc -lavcopts vcodec=mpeg4
Encode DVD title #2, resizing to 512xHHH (keep aspect ratio):
mencoder dvd://2 -vf scale -zoom -xy 512 -o title2.avi -oac copy -ovc lavc -lavcopts vcodec=mpeg4
The same, but with bitrate set to 1800kbit and optimized macroblocks:
mencoder dvd://2 -o title2.avi -oac copy -ovc lavc -lavcopts vcodec=mpeg4:mbd=1:vbitrate=1800
Play a 6-channel AAC file with only two speakers:
mplayer -rawaudio format=0xff -demuxer rawaudio -af pan=2:.32:.32:.39:.06:.06:.39:.17:-.17:-.17:.17:.33:.33 adts_he-aac160_51.aac
You might want to play a bit with the pan values (e.g multiply with a
value) to increase volume or avoid clipping.
checkerboard invert with geq filter:
mplayer -vf geq='128+(p(XY)-128)*(0.5-gt(mod(X/SW128)64))*(0.5-gt(mod(Y/SH128)64))*4'
EXAMPLES OF MENCODER USAGE
Encode DVD title #2, only selected chapters:
mencoder dvd://2 -chapter 10-15 -o title2.avi -oac copy -ovc lavc -lavcopts vcodec=mpeg4
Encode DVD title #2, resizing to 640x480:
mencoder dvd://2 -vf scale=640:480 -o title2.avi -oac copy -ovc lavc -lavcopts vcodec=mpeg4
Encode DVD title #2, resizing to 512xHHH (keep aspect ratio):
mencoder dvd://2 -vf scale -zoom -xy 512 -o title2.avi -oac copy -ovc lavc -lavcopts vcodec=mpeg4
The same, but with bitrate set to 1800kbit and optimized macroblocks:
mencoder dvd://2 -o title2.avi -oac copy -ovc lavc -lavcopts vcodec=mpeg4:mbd=1:vbitrate=1800
The same, but with MJPEG compression:
mencoder dvd://2 -o title2.avi -oac copy -ovc lavc -lavcopts vcodec=mjpeg:mbd=1:vbitrate=1800
Encode all *.jpg files in the current directory:
mencoder "mf://*.jpg" -mf fps=25 -o output.avi -ovc lavc -lavcopts vcodec=mpeg4
Encode from a tuner (specify a format with -vf format):
mencoder -tv driver=v4l:width=640:height=480 tv:// -o tv.avi -ovc raw
Encode from a pipe:
rar p test-SVCD.rar | mencoder -ovc lavc -lavcopts vcodec=mpeg4:vbitrate=800 -ofps 24 -
本文来自ChinaUnix博客,如果查看原文请点:http://blog.chinaunix.net/u/122/showart_474783.html |
|