终端环境使用w3m访问视频站点的正确方式
source link: https://www.lujun9972.win/blog/2017/04/30/%E7%BB%88%E7%AB%AF%E7%8E%AF%E5%A2%83%E4%BD%BF%E7%94%A8w3m%E8%AE%BF%E9%97%AE%E8%A7%86%E9%A2%91%E7%AB%99%E7%82%B9%E7%9A%84%E6%AD%A3%E7%A1%AE%E6%96%B9%E5%BC%8F/index.html
Go to the source link to view the article. You can view the picture content, updated content and better typesetting reading experience. If the link is broken, please click the button below to view the snapshot at that time.
终端环境使用w3m访问视频站点的正确方式
w3m是一款不错的文本浏览器,可惜它并不支持flash控件,这使得用它来访问视频站点显得很无力.
不过只要借助you-get,mplayer这两个工具,也能实现在在w3m中播放视频站点中的视频.
步骤如下(我使用的是archlinux,而且由于机器太烂跑不动Xwindow所以选择了纯文本终端环境):
安装you-get和mplayer
sudo pacman -S you-get mplayer
配置w3m,修改它的第一外部浏览器为
you-get --player "mplayer -vo fbdev2 -x 1024 -y 768 -zoom"
有二种方法可以修改w3m的配置:
第一种方法,打开w3m,然后按下
o
键,在随后打开的配置页面中修改External browser
的值. 然后在后面的OK
按钮出按下保存.第二种方法是直接修改
~/.w3m/config
配置文件,在最后增加一行extbrowser you-get --player "mplayer -vo fbdev2 -x 1024 -y 768 -zoom"
这里有必要说明一下,由于我是要在终端环境下播放视频,因此mplayer中用了
-vo fbdev2
参数.这里的
-x 1024 -y 768
指明了播放视频的大小,且-zoom
说明了让mplayer进行缩放,这因为我的分辨率就是1024*768的. 若没有配置这些参数,则在播放较大分辨率的视频时会提示screensize is smaller than video size
- 使用w3m 浏览youku等视频网站,然后在播放页面按下
M
键,就能通过mplayer播放当前视频了.
Related Issues not found
Please contact @lujun9972 to initialize the comment
Generated by Emacs 27.x(Org mode 9.x)
Copyright © 2014 - 2021 lujun9972
-
Powered by EGO
Themed with emacs_love
Recommend
About Joyk
Aggregate valuable and interesting links.
Joyk means Joy of geeK