Install Mplayer and centosmplayer in CentOS

Source: Internet
Author: User

Install Mplayer (reprinted) and centosmplayer in CentOS
I. Preparations

Required installation packages and:
1w.mplayersource code package (mplayer-1.0rc4.tar.bz2) download: http://www.mplayerhq.hu/MPlayer/releases/
2nd release code installation package (all-20110131.tar.bz2) download: http://www.mplayerhq.hu/MPlayer/releases/codecs/
3、win32decoder installation package (windows-all-20071007.zip) download: http://www.mplayerhq.hu/MPlayer/releases/codecs/
4、skin installation package (blue-1.8.tar.bz2) download: http://www.mplayerhq.hu/MPlayer/skins/

Mplayer encoding packages should be installed in/usr/local/lib/codecs/by default. win32 encoding is installed in/usr/local/lib/win32 by default. If it is installed in another directory, when installing MPlayer ,. the/configure parameter specifies the path. The parameter is -- codecsdir = "package path" and -- win32libdir = "package path ".

Decompress the MPlayer decoder:
# Tar-jxvf all-20110131.tar.bz2
# Mkdir/usr/local/lib/codecs/
# Mv-f all-20110131/*/usr/local/lib/codecs/

Note: all files in all-20110131 are copied to/usr/loc-al/lib/codecs instead of folders. Otherwise, the files cannot be played after compilation.

Decompress the win32 decoder:
# Unzip windows-all-20071007.zip
# Mkdir/usr/local/lib/win32
# Mv window-all-20071007/*/usr/local/lib/win32

Ii. Install Mplayer

All the software packages here are downloaded to the/usr/local/directory. The specific directory is defined as needed.

Install theme file:
# Tar-jxvf MPlayer-1.0rc4.tar.bz2
# Cd MPlayer-1.0rc4
#. /Configure -- prefix =/usr -- codecsdir =/usr/local/lib/codecs -- enable-gui -- enable-largefiles -- enable-menu -- language = zh_CN, en -- charset = utf8 -- confdir =/usr/local/mplayer

The following parameters are explained:
-- Enable-gui is used to open the graphical interface, which is generally required
-- Enalbe-largefiles: large files that can be played more than 2 GB. Note: You may be prompted that this option is not supported. just remove it.
-- Enable-menu
-- Prefix =/usr if this sentence is added, mplayer and gmplayer are put in the/usr/bin/directory. If this sentence is not found, it is in the installation directory/bin.
-- Confdir =/usr/local/mplayer: the installation directory of mplayer.
-- Disable-gcc-checking does not check the gcc version. No, MPlayer-1.0rc1 is gcc4.1 and CentOS 5 is gcc4.1
-- Language = zh_CN install the Chinese interface.

Supplement: Compilation Error

1) yasm missing

Baidu yasm or http://pkgs.org/download/yasm, according to the actual situation to download the required ysam version, after downloading rpm-ivh yasm-1.2.0.4.el7.x86_64.rpm

2) zlib missing

Run yum install zlib-devel libpng-devel

3) Error: X11 support required for GUI compilation.

The gtk2-devel and glib2-devel are missing and the yum install gtk2-devel needs to be executed

If there is no compilation error, execute:
# Make
# Make install

 

3. Install skin:

The default installation path is/usr/share/mplayer/skins/. The default skin directory is default.
# Tar-jxvf Blue-1.8.tar.bz2
# Cd/usr/share/mplayer/skins
# Mkdir default
# Cd Blue
# Cp./*/usr/share/mplayer/skins/default

Here we have installed the blue skin and set it as the default one. After installation, you can also find the skin of various mplayers, you can modify the Skin on the mplayer interface without unzipping and put it under/usr/share/mplayer/Skin.

Step 4: place the mplayer icon

Then, you can place an mplayer icon on the desktop. Right-click the initiator (for gnome) on the desktop and choose mplayer. The command is/usr/bin/gmplayer, the default icon location for mplayer is in/usr/share/pixmaps/mplayer-desktop.xpm or use command # cp/usr/share/pixmaps/mplayer-desktop.xpm/root/Desktop/

After installation, you can start MPlayer.

Step 5: startup Error

After the installation is normal, the following error occurs when the terminal runs gmplayer after it is restarted.
[Root @ www ~] # Gmplayer xxx. rmvb
Option equ_channel_1 needs a parameter at line 11
Option equ_channel_2 needs a parameter at line 12
Option equ_channel_3 needs a parameter at line 13
Option equ_channel_4 needs a parameter at line 14
Option equ_channel_5 needs a parameter at line 15
Option equ_channel_6 needs a parameter at line 16
Configuration File Error

Exiting... (fatal error)
However, [root @ www ~] # The mplayer xxx. rmvb can be played normally.
Solution: After mplayer is run ~ /. Mplayer/to generate gui. conf. The error is caused by 11 ~ 16 Behavior:
Equ_channel_1 = front right
Equ_channel_2 = front left
Equ_channel_3 = back right
Equ_channel_4 = left
Equ_channel_5 = middle
Equ_channel_6 = subwoofer
You can directly Delete gui. conf and run mplayer again. At the same time, the New gui. conf will be generated again, but the files generated this time do not have these six lines.

Main reference:

Http://www.cnblogs.com/jackluo/archive/2013/02/06/2908203.html

Http://www.bubuko.com/infodetail-501317.html

 

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.