Differences between revisions 1 and 79 (spanning 78 versions)
Revision 1 as of 2005-10-08 03:47:57
Size: 1843
Editor: RobStoffers
Comment:
Revision 79 as of 2014-02-20 21:23:56
Size: 10651
Comment: Clarifying the conflict.
Deletions are marked like this. Additions are marked like this.
Line 1: Line 1:
= What Are Codecs? = #language en
[[Software]] > Codecs
----
~-[[DebianWiki/EditorGuide#translation|Translation(s)]]: English - [[it/MultimediaCodecs|Italiano]] - [[fr/MultimediaCodecs|Français]] - [[pt/MultimediaCodecs|Português]] - [[ru/MultimediaCodecs|Русский]] -~
----
Line 3: Line 7:
Simply put for most users a codec is a program capable of compressing/decompressing data streams to make them more manageable and consume less bandwidth. To view files that are compressed by codecs, you will need to install a program capable of decompressing them for you. == What Is A Codec? ==
Line 5: Line 9:
= How to Install Codecs = As the page on codecs at [[WikiPedia:|Wikipedia]] says: "A codec is a device or computer program capable of encoding or decoding a digital data stream or signal. The word codec is a portmanteau of "compressor-decompressor" or, more commonly, "coder-decoder". A codec (the program) should not be confused with a coding or compression format or standard – a format is a document (the standard), a way of storing data, while a codec is a program (an implementation) which can read or write such files. In practice, however, "codec" is sometimes used loosely to refer to formats."
Line 7: Line 11:
To install common codecs included in the Debian repositories: See WikiPedia:Codec for more information about codecs.

== Codec Installations ==

=== Available Codecs for Debian ===

Many codecs are already available in the official Debian archive. These include codecs for MP3, H264, and AAC encoding and decoding. These codecs are made available through libraries such as the libav/ffmpeg libraries. Media players available in Debian such as VLC and Mplayer make use of these libraries in order to provide support for playback of files encoded through these many different codecs.

In summary, when you install a media player available from Debian, many different codecs the media player supports will be automatically installed. Chances are, the codecs you will ever wish to use will be the ones automatically installed with the media player. If however, you find that a codec you need isn't available from your media player, you may need to install a few extra packages. How to install these extra packages, some from Debian and some available through third parties, is explained below.

==== Extra codec packages from Debian ====

===== Testing/Unstable Suite =====

As mentioned in the previous section, the libav/ffmpeg libraries are used to provide codecs for many different media players. There are alternate versions of these library packages that provide extra codecs.

The extra codecs provided by the DebianPkg:libavcodec-extra-54 package are:

 * OpenCORE Adaptive Multi-Rate (AMR) Narrow-Band (AMRNB Encoder/Decoder)
 * OpenCORE Adaptive Multi-Rate (AMR) Wide-Band (AMRWB Decoder)
 * Android !VisualOn AAC (AAC Encoder)
 * Android !VisualOn Adaptive Multi-Rate (AMR) Wide-Band (AMRWB Encoder)

This package is available through Debian main. To install it simply run (as root) the following command:
Line 9: Line 37:
apt-get update
apt-get install gstreamer0.8-plugins gstreamer0.8-ffmpeg gstreamer0.8-mpeg2dec
apt-get install vorbis-tools toolame sox ffmpeg gstreamer0.8-misc
gst-register-0.8
apt-get install libavcodec-extra-54
Line 15: Line 40:
To install other codecs not included with Debian (such as mp3 codecs): The part to remember though is if you install the extra codecs package, they would conflict with libavcodec54 if you decide to install later.
Line 17: Line 42:
 1. Depending on your chosen release, add one of the following lines to your ''/etc/apt/sources.list' file:
Line 19: Line 43:
    deb ftp://ftp.nerim.net/debian-marillat/ unstable main
    deb ftp://ftp.nerim.net/debian-marillat/ sarge main
    deb ftp://ftp.nerim.net/debian-marillat/ etch main
    deb ftp://ftp.nerim.net/debian-marillat/ sid main
$ dpkg -l libavcodec-extra-54
Desired=Unknown/Install/Remove/Purge/Hold
| Status=Not/Inst/Conf-files/Unpacked/halF-conf/Half-inst/trig-aWait/Trig-pend
|/ Err?=(none)/Reinst-required (Status,Err: uppercase=bad)
||/ Name Version Architecture Description
+++-============================-===================-===================-==============================================================
ii libavcodec-extra-54:amd64 6:9.11-1 amd64 Libav codec library (additional codecs)


$ sudo apt-get install libavcodec54
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following packages will be REMOVED:
  libavcodec-extra-54
The following NEW packages will be installed:
  libavcodec54
0 upgraded, 1 newly installed, 1 to remove and 0 not upgraded.
Need to get 2,396 kB of archives.
After this operation, 9,216 B disk space will be freed.
Do you want to continue? [Y/n] n
Abort.
Line 25: Line 67:
This repository has packages for mplayer, gmplayer, and other codecs also. So at any one time, only one of the two packages can function/sit in a user's system.
Line 27: Line 69:
 1.#2 Then do the following:
{{{
apt-get update
apt-get install lame lame-extras faad
gst-register-0.8
==== Codec packages from third parties ====

{{{#!wiki warning
'''Warning'''

Installation of third party packages is not recommended. Use at your own risk.
Line 34: Line 77:
= WMA Codec = This section describes installation of packages from third party repositories. The packages in these repositories are not as thoroughly tested as packages in the official Debian archive. The problems with third party packages can include, but is not limited to
Line 36: Line 79:
There is no WMA codec available in Debian, but you can compile one yourself. Note that this procedure is only known to work with Beep Media Player, for more information see BeepMediaPlayerHowTo.  * Package conflicts between packages in the Debian archive and packages in third party repositories.
 * Bad package upgrades between Debian releases.
 * Difficulty removing third party packages once installed.
 * Removal of unrelated packages to satisfy dependencies for third party packages.
 * Third party packages overriding/ignoring local system/user configurations.
Line 38: Line 85:
 1.#1 Open up a terminal and download the WMA Plugin: As such, it is not recommended to install packages from third party repositories.

In any case, some codecs are only available through third party repositories. There are various reasons why they are not included within Debian. The reasons include some codecs are currently only available in the form of binary blobs and licensed under terms that prevent their redistribution.

===== deb-multimedia.org =====

There is at least one extra codec package available for amd64 and i386 machines that is not available from Debian. On amd64, the package is w64codecs, and on i386, the package is w32codecs. These extra packages provide support for a few rarely used codecs and the only software that makes use of them are xine and mplayer. If you are not using xine or mplayer or find that you don't need these codecs at all, there is no point in installing these packages.

These packages are made available from the [[UnofficialRepositories|unofficial repository]] deb-multimedia.org. This repository can be added to apt sources list but is known to cause problems on users' systems, including all the problems mentioned above. Because of this, and since only one package from this repository provides extra codecs, this section will only describe how to download the extra codec package and install it. Below are the two commands that will install this codec package, depending on your system (you need to be root).
Line 40: Line 96:
wget http://download.berlios.de/bmp-plugins/bmp-wma-0.1.1.tar.gz # Type these commands for amd64 machines.
wget http://www.deb-multimedia.org/pool/non-free/w/w64codecs/w64codecs_20071007-dmo2_amd64.deb
dpkg -i w64codecs_20071007-dmo2_amd64.deb
Line 43: Line 101:
 1.#2 Extract the files:
Line 45: Line 102:
tar -xvzf bmp-wma-0.1.1.tar.gz # Type these commands for i386 machines.
wget http://www.deb-multimedia.org/pool/non-free/w/w32codecs/w32codecs_20110131-dmo2_i386.deb
dpkg -i w32codecs_20110131-dmo2_i386.deb
Line 48: Line 107:
 1.#3 Change to the directory that was created and compile: '''Note''': Installing these packages directly using dpkg saves polluting your APT sources with potentially untrustworthy third-party repositories; however, these packages won't be updated automatically if there is a new version on the repository.

== DVD Playback ==
DVDs are usually encrypted with CSS. CSS is not a codec. In any case, here is some information on playback of encrypted DVDs. All media players use libdvdcss2 in order to playback these encrypted DVDs.

libdvdcss2 is not available in the official Debian repositories. Details on where to get libdvdcss2 from are described at [[CDDVD#DVD]].
## * at the '''[[UnofficialRepositories|unofficial repository]]''' deb-multimedia.org.
## * from ubuntu.

## === deb-multimedia.org (risky) ===
## In this subsection, installation from deb-multimedia.org is explained.
##
## To install libdvdcss2, run these commands (as root).
##
## {{{
## Type these commands for amd64 machines.
## wget http://www.deb-multimedia.org/pool/main/libd/libdvdcss/libdvdcss2_1.2.13-dmo1_amd64.deb
## dpkg -i libdvdcss2_1.2.13-dmo1_amd64.deb
## }}}
##
## {{{
## Type these commands for i386 machines.
## wget http://www.deb-multimedia.org/pool/main/libd/libdvdcss/libdvdcss2_1.2.13-dmo1_i386.deb
## dpkg -i libdvdcss2_1.2.13-dmo1_i386.deb
## }}}
##
## '''Note''': while adding an unofficial repository to APT sources can be a risk, please note that APT package management system doesn't know anything about packages installed directly #with dpkg. These packages won't be updated automatically if there is a new version on the repository.
##
## === Ubuntu ===
## Installation from Ubuntu needs some work. The instruction here is written in May 2012, but this may not be valid in future.
##
## To install libdvdcss2, get the source package of libdvd'''read'''4, unpack it, and go to `debian/scripts`. Do `$ chmod 755 install-css.sh`.
##
## By running this script, the binary is downloaded from medibuntu. But Ubuntu and Debian are not necessary binary compatible, so it may not work. But you can also install the source ## with this script. Rewrite these lines:
## {{{
## available="i386 amd64 powerpc lpia"
## available_old="sparc"
## }}}
## to
## {{{
## available=""
## available="i386 amd64 powerpc lpia"
## available_old="sparc"
## }}}
## Then run this script. It automatically builds libdvdcss2. Then install the package with dpkg -i <pkg>.

== MP3 encoding ==

=== Wheezy ===
If you want to rip audio CD's to MP3's with e.g. Sound Juicer, install the [[DebianPkg:wheezy/gstreamer0.10-plugins-ugly|gstreamer0.10-plugins-ugly]] package: {{{
apt-get install gstreamer0.10-plugins-ugly
}}}
=== Squeeze ===
If you want to rip audio CD's to MP3's with e.g. Sound Juicer, you want to have the "gstreamer0.10-lame" package from e.g. www.deb-multimedia.org.
Line 50: Line 162:
cd bmp-wma-0.1.1
./configure
make
make install
# Type these commands for amd64 machines.
wget http://www.deb-multimedia.org/pool/main/g/gst-plugins-ugly/gstreamer0.10-lame_0.10.17-0.0_amd64.deb
dpkg -i gstreamer0.10-lame_0.10.17-0.0_amd64.deb
}}}
{{{
# Type these commands for i386 machines.
wget http://www.deb-multimedia.org/pool/main/g/gst-plugins-ugly/gstreamer0.10-lame_0.10.17-0.0_i386.deb
dpkg -i gstreamer0.10-lame_0.10.17-0.0_i386.deb
Line 56: Line 172:
Note: You cannot play WMA files with DRM. == Legal Issues ==
Line 58: Line 174:
= Links = As long time users of Debian may know, there has been a long history of legal concerns when it comes to using various multimedia related software due to software patents. Because of this, various multimedia codecs could not be made available within Debian. However, Debian's position on software patents has changed, resulting in the inclusion of these various multimedia codecs within Debian.
Line 60: Line 176:
From ["http://www.debianguide.org"] For information on Debian's position with regards to software patents, see the following.
 * http://www.debian.org/legal/patent
 * http://www.debian.org/reports/patent-faq

As with any topic involving legal issues, if you have any legal concerns, it is recommended you seek your own legal counsel.

= More information =
[[WindowsMediaVideo|Windows Media Video playback]]

Software > Codecs


Translation(s): English - Italiano - Français - Português - Русский


What Is A Codec?

As the page on codecs at Wikipedia says: "A codec is a device or computer program capable of encoding or decoding a digital data stream or signal. The word codec is a portmanteau of "compressor-decompressor" or, more commonly, "coder-decoder". A codec (the program) should not be confused with a coding or compression format or standard – a format is a document (the standard), a way of storing data, while a codec is a program (an implementation) which can read or write such files. In practice, however, "codec" is sometimes used loosely to refer to formats."

See Codec for more information about codecs.

Codec Installations

Available Codecs for Debian

Many codecs are already available in the official Debian archive. These include codecs for MP3, H264, and AAC encoding and decoding. These codecs are made available through libraries such as the libav/ffmpeg libraries. Media players available in Debian such as VLC and Mplayer make use of these libraries in order to provide support for playback of files encoded through these many different codecs.

In summary, when you install a media player available from Debian, many different codecs the media player supports will be automatically installed. Chances are, the codecs you will ever wish to use will be the ones automatically installed with the media player. If however, you find that a codec you need isn't available from your media player, you may need to install a few extra packages. How to install these extra packages, some from Debian and some available through third parties, is explained below.

Extra codec packages from Debian

Testing/Unstable Suite

As mentioned in the previous section, the libav/ffmpeg libraries are used to provide codecs for many different media players. There are alternate versions of these library packages that provide extra codecs.

The extra codecs provided by the libavcodec-extra-54 package are:

  • OpenCORE Adaptive Multi-Rate (AMR) Narrow-Band (AMRNB Encoder/Decoder)
  • OpenCORE Adaptive Multi-Rate (AMR) Wide-Band (AMRWB Decoder)
  • Android VisualOn AAC (AAC Encoder)

  • Android VisualOn Adaptive Multi-Rate (AMR) Wide-Band (AMRWB Encoder)

This package is available through Debian main. To install it simply run (as root) the following command:

apt-get install libavcodec-extra-54

The part to remember though is if you install the extra codecs package, they would conflict with libavcodec54 if you decide to install later.

$ dpkg -l libavcodec-extra-54
Desired=Unknown/Install/Remove/Purge/Hold
| Status=Not/Inst/Conf-files/Unpacked/halF-conf/Half-inst/trig-aWait/Trig-pend
|/ Err?=(none)/Reinst-required (Status,Err: uppercase=bad)
||/ Name                         Version             Architecture        Description
+++-============================-===================-===================-==============================================================
ii  libavcodec-extra-54:amd64    6:9.11-1            amd64               Libav codec library (additional codecs)


$ sudo apt-get install libavcodec54
Reading package lists... Done
Building dependency tree       
Reading state information... Done
The following packages will be REMOVED:
  libavcodec-extra-54
The following NEW packages will be installed:
  libavcodec54
0 upgraded, 1 newly installed, 1 to remove and 0 not upgraded.
Need to get 2,396 kB of archives.
After this operation, 9,216 B disk space will be freed.
Do you want to continue? [Y/n] n
Abort.

So at any one time, only one of the two packages can function/sit in a user's system.

Codec packages from third parties

Warning

Installation of third party packages is not recommended. Use at your own risk.

This section describes installation of packages from third party repositories. The packages in these repositories are not as thoroughly tested as packages in the official Debian archive. The problems with third party packages can include, but is not limited to

  • Package conflicts between packages in the Debian archive and packages in third party repositories.
  • Bad package upgrades between Debian releases.
  • Difficulty removing third party packages once installed.
  • Removal of unrelated packages to satisfy dependencies for third party packages.
  • Third party packages overriding/ignoring local system/user configurations.

As such, it is not recommended to install packages from third party repositories.

In any case, some codecs are only available through third party repositories. There are various reasons why they are not included within Debian. The reasons include some codecs are currently only available in the form of binary blobs and licensed under terms that prevent their redistribution.

deb-multimedia.org

There is at least one extra codec package available for amd64 and i386 machines that is not available from Debian. On amd64, the package is w64codecs, and on i386, the package is w32codecs. These extra packages provide support for a few rarely used codecs and the only software that makes use of them are xine and mplayer. If you are not using xine or mplayer or find that you don't need these codecs at all, there is no point in installing these packages.

These packages are made available from the unofficial repository deb-multimedia.org. This repository can be added to apt sources list but is known to cause problems on users' systems, including all the problems mentioned above. Because of this, and since only one package from this repository provides extra codecs, this section will only describe how to download the extra codec package and install it. Below are the two commands that will install this codec package, depending on your system (you need to be root).

# Type these commands for amd64 machines.
wget http://www.deb-multimedia.org/pool/non-free/w/w64codecs/w64codecs_20071007-dmo2_amd64.deb
dpkg -i w64codecs_20071007-dmo2_amd64.deb

# Type these commands for i386 machines.
wget http://www.deb-multimedia.org/pool/non-free/w/w32codecs/w32codecs_20110131-dmo2_i386.deb
dpkg -i w32codecs_20110131-dmo2_i386.deb

Note: Installing these packages directly using dpkg saves polluting your APT sources with potentially untrustworthy third-party repositories; however, these packages won't be updated automatically if there is a new version on the repository.

DVD Playback

DVDs are usually encrypted with CSS. CSS is not a codec. In any case, here is some information on playback of encrypted DVDs. All media players use libdvdcss2 in order to playback these encrypted DVDs.

libdvdcss2 is not available in the official Debian repositories. Details on where to get libdvdcss2 from are described at CDDVD#DVD.

MP3 encoding

Wheezy

If you want to rip audio CD's to MP3's with e.g. Sound Juicer, install the gstreamer0.10-plugins-ugly package:

apt-get install gstreamer0.10-plugins-ugly

Squeeze

If you want to rip audio CD's to MP3's with e.g. Sound Juicer, you want to have the "gstreamer0.10-lame" package from e.g. www.deb-multimedia.org.

# Type these commands for amd64 machines.
wget http://www.deb-multimedia.org/pool/main/g/gst-plugins-ugly/gstreamer0.10-lame_0.10.17-0.0_amd64.deb
dpkg -i gstreamer0.10-lame_0.10.17-0.0_amd64.deb

# Type these commands for i386 machines.
wget http://www.deb-multimedia.org/pool/main/g/gst-plugins-ugly/gstreamer0.10-lame_0.10.17-0.0_i386.deb
dpkg -i gstreamer0.10-lame_0.10.17-0.0_i386.deb

As long time users of Debian may know, there has been a long history of legal concerns when it comes to using various multimedia related software due to software patents. Because of this, various multimedia codecs could not be made available within Debian. However, Debian's position on software patents has changed, resulting in the inclusion of these various multimedia codecs within Debian.

For information on Debian's position with regards to software patents, see the following.

As with any topic involving legal issues, if you have any legal concerns, it is recommended you seek your own legal counsel.

More information

Windows Media Video playback