Linux 常用工具之 VLC

Ubuntu 安装 VLC

安装 VLC

参考 VLC media player for Ubuntu

1
2
huzhifeng@Ubuntu16041:~$ sudo apt-get update
huzhifeng@Ubuntu16041:~$ sudo apt-get install vlc browser-plugin-vlc

设置 VLC 为默认播放器

进入 System Settings -> Details -> Default Applications -> Video,从下拉菜单中选择 VLC media player 即可

创建桌面快捷图标

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
huzhifeng@Ubuntu16041:~$ dpkg-query --listfiles vlc | grep desktop
/usr/share/applications/vlc.desktop
/usr/share/kde4/apps/solid/actions/vlc-openvcd.desktop
/usr/share/kde4/apps/solid/actions/vlc-opencda.desktop
/usr/share/kde4/apps/solid/actions/vlc-opendvd.desktop
/usr/share/kde4/apps/solid/actions/vlc-openbd.desktop
huzhifeng@Ubuntu16041:~$ cp /usr/share/applications/vlc.desktop ~/Desktop/
huzhifeng@Ubuntu16041:~$ vim ~/Desktop/vlc.desktop
huzhifeng@Ubuntu16041:~$ chmod a+x ~/Desktop/vlc.desktop
huzhifeng@Ubuntu16041:~$ cat ~/Desktop/vlc.desktop
[Desktop Entry]
Version=1.0
Name=VLC media player
Exec=/usr/bin/vlc --started-from-file %U
Icon=vlc
Terminal=false
Type=Application
huzhifeng@Ubuntu16041:~$

CentOS 安装 VLC

参考
How to setup multimedia on CentOS 7
How To Install VLC On CentOS 7
Install VLC Media Player in RHEL/CentOS 7/6 and Fedora 23-20
Install VLC Media Player on CentOS 7 / RHEL 7 / Fedora 20

安装 nux-dextop-release

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
[huzhifeng@CentOS72 ~]$ sudo rpm -Uvh http://li.nux.ro/download/nux/dextop/el7/x86_64/nux-dextop-release-0-5.el7.nux.noarch.rpm
[huzhifeng@CentOS72 ~]$ rpm -ql nux-dextop-release
/etc/pki/rpm-gpg
/etc/pki/rpm-gpg/RPM-GPG-KEY-nux.ro
/etc/yum.repos.d
/etc/yum.repos.d/nux-dextop.repo
[huzhifeng@CentOS72 ~]$ cat /etc/yum.repos.d/nux-dextop.repo
[nux-dextop]
name=Nux.Ro RPMs for general desktop use
baseurl=http://li.nux.ro/download/nux/dextop/el7/$basearch/ http://mirror.li.nux.ro/li.nux.ro/nux/dextop/el7/$basearch/
enabled=1
gpgcheck=1
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-nux.ro
protect=0
[nux-dextop-testing]
name=Nux.Ro RPMs for general desktop use - testing
baseurl=http://li.nux.ro/download/nux/dextop-testing/el7/$basearch/
enabled=0
gpgcheck=1
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-nux.ro
protect=0
[huzhifeng@CentOS72 ~]$

安装 VLC

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
[huzhifeng@CentOS72 ~]$ yum search vlc
vlc-core.x86_64 : VLC media player core
vlc-debuginfo.x86_64 : Debug information for package vlc
vlc-devel.x86_64 : Development files for vlc
vlc-extras.x86_64 : VLC media player with extras modules
vlc-plugin-jack.x86_64 : JACK audio plugin for VLC
vlc.x86_64 : The cross-platform open-source multimedia framework, player and server
[huzhifeng@CentOS72 ~]$ sudo yum install -y vlc
Installed:
vlc.x86_64 1:2.2.4-1.el7.nux
Dependency Installed:
SDL.x86_64 0:1.2.15-14.el7 SDL_image.x86_64 0:1.2.12-11.el7 a52dec.x86_64 0:0.7.4-18.el7.nux aalib-libs.x86_64 0:1.4.0-0.22.rc5.el7 faac.x86_64 0:1.28-6.0.el7.nux
faad2-libs.x86_64 1:2.7-5.el7.nux fdk-aac.x86_64 0:0.1.4-1 ffmpeg-libs.x86_64 0:2.6.8-3.el7.nux freeglut.x86_64 0:2.8.1-3.el7 fribidi.x86_64 0:0.19.4-6.el7
ftgl.x86_64 0:2.1.3-0.8.rc5.el7 gamin.x86_64 0:0.1.10-16.el7 gnome-vfs2.x86_64 0:2.24.4-14.el7 kde-filesystem.x86_64 0:4-47.el7 lame-libs.x86_64 0:3.99.5-2.el7
libass.x86_64 0:0.13.4-1.el7 libcaca.x86_64 0:0.99-0.17.beta17.el7 libcddb.x86_64 0:1.3.2-12.el7.nux libchromaprint.x86_64 0:1.0-1.el7 libdc1394.x86_64 0:2.2.2-3.el7
libdvbpsi.x86_64 0:1.3.0-3.el7 libebml.x86_64 0:1.3.3-3.el7 libkate.x86_64 0:0.4.1-5.el7 libmad.x86_64 0:0.15.1b-19.el7 libmatroska.x86_64 0:1.4.1-1.el7
libmfx.x86_64 0:1.16-1.20160317git7adf2e4.el7 libmng.x86_64 0:1.0.10-14.el7 libmodplug.x86_64 1:0.8.8.5-3.el7 libmpeg2.x86_64 0:0.5.1-10.el7.nux libprojectM.x86_64 0:2.1.0-2.el7
libtiger.x86_64 0:0.3.4-7.el7 libupnp.x86_64 0:1.6.19-2.el7 libva.x86_64 0:1.2.1-3.el7 libvncserver.x86_64 0:0.9.9-9.el7_0.1 lirc-libs.x86_64 0:0.9.1a-4.el7
live555.x86_64 0:2013.11.26-1.el7.nux lzo-minilzo.x86_64 0:2.06-8.el7 minizip.x86_64 0:1.2.7-17.el7 qt.x86_64 1:4.8.5-13.el7 qt-settings.noarch 0:19-23.5.el7.centos
qt-x11.x86_64 1:4.8.5-13.el7 schroedinger.x86_64 0:1.0.11-4.el7 soxr.x86_64 0:0.1.2-1.el7 twolame-libs.x86_64 0:0.3.13-3.el7.nux vlc-core.x86_64 1:2.2.4-1.el7.nux
x264-libs.x86_64 0:0.142-11.20141221git6a301b6.el7.nux x265-libs.x86_64 0:1.9-1.el7.nux xvidcore.x86_64 0:1.3.2-5.el7.nux zvbi.x86_64 0:0.2.35-1.el7
Complete!
[huzhifeng@CentOS72 ~]$ vlc /data/BigBuckBunny/big_buck_bunny_1080p_h264.mov

Fedora 安装 VLC

参考 VLC media player for Fedora

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
Fedora 22 and later (dnf)
Use RPM Fusion for Fedora (available for x86, x86_64, armhfp)
Install rpmfusion-free-release-stable.noarch.rpm for currently maintained fedora.
$> su -
#> dnf install https://download1.rpmfusion.org/free/fedora/rpmfusion-free-release-$(rpm -E %fedora).noarch.rpm
#> dnf install vlc
#> dnf install python-vlc npapi-vlc (optionals)
Fedora 14 up to 21
Use RPM Fusion (available for x86, x86_64 and ppc)
Install rpmfusion-free-release-stable.noarch.rpm
$> su -
#> yum localinstall --nogpgcheck https://download1.rpmfusion.org/free/fedora/rpmfusion-free-release-$(rpm -E %fedora).noarch.rpm
#> yum install vlc
#> yum install python-vlc npapi-vlc (optionals)

EOF