前回、
その後、
通常、
Plamo Linux上のマルチメディアプレイヤー
最近では多数のマルチメディアプレイヤーがオープンソースソフトウェア
以下に各メディアプレイヤーの特徴を簡単に紹介しましょう。
MPlayer
MPlayerは元々ハンガリーで開発が始まったメディアプレイヤーです。前回も紹介したように、
前回、
以下はMPlayerのソースコードを展開した直下のディレクトリです。
$ ls
AUTHORS cfg-mencoder.h drivers/ libmenu/ mencoder.h osdep/ snapshot_version
Changelog cfg-mplayer-def.h edl.c libmpcodecs/ metadata.h parser-cfg.c stream/
Copyright cfg-mplayer.h edl.h libmpdemux/ mixer.c parser-cfg.h sub/
DOCS/ codec-cfg.c etc/ libmpeg2/ mixer.h parser-mecmd.c subopt-helper.c
LICENSE codec-cfg.h ffmpeg/ libvo/ mp3lib/ parser-mecmd.h subopt-helper.h
...
av_opts.c configure* libao2/ m_property.h mpbswap.h playtreeparser.c xvid_vbr.h
av_opts.h cpudetect.c libass/ m_struct.c mpcommon.c playtreeparser.h
bstr.c cpudetect.h libdvdcss/ m_struct.h mpcommon.h pnm_loader.c
bstr.h cpuinfo.c libdvdnav/ mangle.h mplayer.c pnm_loader.h
cfg-common.h debian/ libdvdread4/ mencoder.c mplayer.h rpm/
ここにあるファイルのうち、
$ head libdvdcss/libdvdcss.c
/* libdvdcss.c: DVD reading library.
*
* Authors: Stephane Borel <[email protected]>
* Sam Hocevar <[email protected]>
* Hakan Hjort <[email protected]>
*
* Copyright (C) 1998-2008 VideoLAN
* $Id: libdvdcss.c 31883 2010-08-01 13:52:17Z reimar $
*
* This library is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
* (at your option) any later version.
また、
$ ls ffmpeg/
COPYING.GPLv2 Changelog Makefile common.mak ffplay.c libavcodec/ libavutil/ tools/
COPYING.GPLv3 Doxyfile README config.mak ffpresets/ libavcore/ libpostproc/ version.sh*
COPYING.LGPLv2.1 INSTALL cmdutils.c configure* ffprobe.c libavdevice/ libswscale/
COPYING.LGPLv3 LICENSE cmdutils.h doc/ ffserver.c libavfilter/ subdir.mak
CREDITS MAINTAINERS cmdutils_common_opts.h ffmpeg.c ffserver.h libavformat/ tests/
もちろん、
xine
xineもMPlayer同様、

xineの特徴は、
xine-libのソースコードには、
$ ls src/
Makefile.am demuxers/ libdts/ libmpeg2/ libspucc/ libspuhdmv/ libxinevdec/ xine-utils/
Makefile.in dxr3/ libfaad/ libmpeg2new/ libspucmml/ libsputext/ post/
audio_out/ input/ libffmpeg/ libmusepack/ libspudec/ libw32dll/ video_out/
combined/ liba52/ libmad/ libreal/ libspudvb/ libxineadec/ xine-engine/
これらのディレクトリに含まれるソースコードは、
なお、
VLCメディアプレイヤー
VLCメディアプレイヤーは、

一方、
たとえば、
$ less modules/codec/avcodec/avcodec.c
*****************************************************************************
* avcodec.c: video and audio decoder and encoder using libavcodec
*****************************************************************************
* Copyright (C) 1999-2008 the VideoLAN team
* $Id: 7313a9b503291939af63bb02bd9eb16b2560841b $
*
* Authors: Laurent Aimar <[email protected]>
* Gildas Bazin <[email protected]>
*
* This program is free software; you can redistribute it and/or modify
...
libavcodecライブラリはバージョンによって機能の違いがあるため、
if LIBAVCODEC_VERSION_INT < AV_VERSION_INT( 51, 48, 0 )
# error You must update libavcodec to a version >= 51.48.0
#elif LIBAVCODEC_VERSION_INT < AV_VERSION_INT( 52, 25, 0 )
# warning You should update libavcodec to get subtitle support
#endif
VLCのmodules/
$ ls modules/codec/
Makefile.am aes3.c cvdsub.c fake.c libmpeg2.c quicktime.c speex.c twolame.c
Makefile.in araw.c dirac.c flac.c lpcm.c rawvideo.c spudec/ vorbis.c
Modules.am avcodec/ dmo/ fluidsynth.c mash.cpp realvideo.c subtitles/ wmafixed/
a52.c cc.c dts.c invmem.c mpeg_audio.c schroedinger.c svcdsub.c x264.c
a52.h cc.h dvbsub.c kate.c omxil/ sdl_image.c telx.c zvbi.c
adpcm.c cdg.c faad.c libass.c png.c shine/ theora.c
このような設計にした結果、
$ ./configure
checking build system type... x86_64-unknown-linux-gnu
checking host system type... x86_64-unknown-linux-gnu
...
checking for mad.h... no
configure: error: Could not find libmad on your system: you may get it from http://www.underbit.com/products/mad/.\
Alternatively you can use --disable-mad to disable the mad plugin.
この例ではMPEG形式のオーディオファイルを処理するlibmadが無い、
Totem/GStreamer
Plamoで採用しているもう1つのマルチメディアプレイヤーはTotemですが、
GStreamerはGNOMEプロジェクトが採用しているマルチメディアフレームワークで、
マルチメディアデータの処理機能をライブラリとして提供するという目的は先に紹介したxine-libと共通しますが、
「実際の処理は外部のライブラリに委ねる」
そのため、
このうち、
./configure
checking for a BSD-compatible install... /usr/bin/install -c
checking whether build environment is sane... yes
...
configure: *** checking feature: alsa plug-ins ***
configure: *** for plug-ins: gstalsa ***
checking for ALSA... yes
configure: *** These plugins will be built: gstalsa
configure: *** checking feature: ASS/SSA renderer ***
configure: *** for plug-ins: assrender ***
checking for ASSRENDER... no
no
configure: *** These plugins will not be built: assrender
...
configure: *** Plug-ins with dependencies that will be built:
apexsink
bz2
cog
dvb
exif
...
configure: *** Plug-ins with dependencies that will NOT be built:
acm
amrwbenc
assrender
cdaudio
...
GStreamerの場合、
設計思想から見た各マルチメディアプレイヤーの比較
以上、
そのひとつは
MPlayerやxineのように外部のソフトウェアを取り込んで主要な機能を自前で用意するようにすれば、
共有ライブラリを使って外部のソフトウェアを積極的に使っているVLCやGStremerはこの逆で、
このような特徴のため、
もうひとつの軸は
上述のように、
この2つの軸を元に、

このように比較してみると、