Commit Graph

2978 Commits

Author SHA1 Message Date
wm4 130beda407 configure: add version check for libquvi
I do not know what exactly is the minimum working version. Require the
latest version currently released, which is about half a year old.
2012-09-18 21:07:29 +02:00
Uoti Urpala 435d7c97c9 cleanup: remove pointless #defines
Remove the following #defines, which should never change in practice:

CONFIG_FAKE_MONO, OUTBURST, FAST_OSD, FAST_OSD_TABLE
The configure script hardcoded these to particular values in config.h.
They could only be changed by manually editing it. I don't think
anyone would want to.

X11_FULLSCREEN
This once did something, but became meaningless years ago and was now
always set to true if the files using it were compiled at all.

Conflicts:
	configure
	libvo/osd.c
	libvo/vo_gl.c

Merged from mplayer2. The OSD defines were already removed in this fork.
2012-09-18 21:04:46 +02:00
wm4 3a0f40afb4 configure: disable optimization if --enable-debug is used
Enabling optimization _still_ causes annoyances when using a debugger,
and it increaes compilation times too.

Now --enable-debug basically replaces the -O2 flag with -g.
2012-08-25 20:04:32 +02:00
wm4 6c13b694fb configure: minor improvement to summary output
Remove printing VO modules that were removed earlier, but were enabled
by configure tests that are still needed.

Print "libavcodecs" with the "Codecs: " output.
2012-08-25 20:03:25 +02:00
wm4 89e7631483 configure: restore DVB support
The code defining CONFIG_DVB[IN] was accidentally removed some time ago.
2012-08-25 19:49:01 +02:00
wm4 6a26b4a665 libmpcodecs: remove redundant audio and video decoders
Probably all of these are supported by libavcodec. Missing things can
be added back.

Also remove qtpalette.h. It was used by demux_mov.c, and should have
been deleted with commit 1fde09db6f.
2012-08-20 15:36:04 +02:00
wm4 6f7ba66817 Remove support for libdv
This removes the libdv demuxer and audio/video decoders. FFmpeg has
support for it, and it's even preferred over the internal decoders.
2012-08-20 15:36:03 +02:00
wm4 e181547db1 Remove support for libnemesi RTSP streaming
Removed due to being a maintainance burden.
Support for FFmpeg is available.
2012-08-20 15:36:03 +02:00
wm4 3a5d5f01d4 Remove support for LIVE555 RTSP streaming
The main excuse for removing this is that LIVE555 deprecated the API
the mplayer implementation was using. The old API still seems to be
somewhat supported, but must be explicitly enabled at LIVE555
compilation, so mplayer won't always work on any user installation.

The implementation was also very messy, in C++, and FFmpeg support is
available as alternative.

Remove it completely.
2012-08-20 15:36:03 +02:00
wm4 fc2ea37694 build: remove leftover bits for internal libdvdread support
Support for internal libdvdread has been removed in commit 41fbcee1f5,
but some bits have been missed in Makefile/configure.

Support for libdvdread as normal library is left unchanged.
2012-08-20 15:36:02 +02:00
wm4 0e2c48a3ce VO: remove vo_directfb2 and vo_directx
While being able to play videos on a framebuffer device would be nice,
I didn't need it, and couldn't even test it (buggy nvidia binary
drivers that disable framebuffers, buggy DirectFB that crashes when
using the X11 backend). It's just dead weight, get rid of it.

vo_directx was very horrible, and by today it's mostly useless. I didn't
remove it, because there was that-guy who told me in amazement how
awesome mplayer was, because it was the only video player fast enough
for fast playback on his system when using vo_directx. Sorry, that-guy.
2012-08-16 17:17:50 +02:00
wm4 41fbcee1f5 Remove dvdnav support (DVD menus)
When the internal mplayer MPEG demuxer was removed (commit 1fde09db),
the default demuxer when using dvdnav was set to libavformat. Now it
turns out that this doesn't work with libavformat. It will terminate
playback right after the audio runs out (instead of looping it like the
video, or whatever it's supposed to do). I'm not sure what exactly the
problem is, but since 1. even mplayer-svn can't handle DVD menus
directly (missing highlights), 2. DVD menus are essentially worthless,
and 3. I don't directly watch DVDs, don't bother with it and remove it.

For basic playback, there's still libdvdread support.

Also, use pkg-config for libdvdread, and drop support for in-tree
libdvdread. Remove support for in-tree libdvdcss as well.
2012-08-16 17:17:49 +02:00
wm4 aebfbbf2bd Remove win32/qt/xanim/real binary codecs loading
Remove the win32 loader - the win32 emulation layer, as well as the
code for using DirectShow/DMO/VFW codecs. Remove loading of xanim,
QuickTime, and RealMedia codecs.

The win32 emulation layer is based on a very old version of wine.
Apparently, wine code was copied and hacked until it was somehow able
to load a limited collection of binary codecs. It poked around in the
code segment of some known binary codecs to disable unsupported win32
API calls to make them work. Example from module.c:

    for (i=0;i<5;i++)  RVA(0x19e842)[i]=0x90; // make_new_region ?
    for (i=0;i<28;i++) RVA(0x19e86d)[i]=0x90; // call__call_CreateCompatibleDC ?
    for (i=0;i<5;i++)  RVA(0x19e898)[i]=0x90; // jmp_to_call_loadbitmap ?
    for (i=0;i<9;i++)  RVA(0x19e8ac)[i]=0x90; // call__calls_OLE_shit ?
    for (i=0;i<106;i++) RVA(0x261b10)[i]=0x90; // disable threads

Just to show how utterly insane this code is. You wouldn't want even
your worst enemy to have to maintain this. In fact, it seems nobody
made major changes to this code ever since it was committed.

Most formats can be decoded by libavcodecs these days, and the loader
couldn't be used on 64 bit platforms anyway. The same is (probably)
true for the other binary codecs.

General note about how support for win32 codecs could be added back:

It's not possible to replace the win32 loader code by using wine as
library, because modern wine can not be linked with native Linux
programs for certain reasons. It would be possible to to move DirectShow
video decoding into a separate process linked with wine, like the
CoreAVC-for-Linux patches do. There is also the mplayer-ww fork, which
uses the dshownative library to use DirectShow codecs on Windows.
2012-08-16 17:16:33 +02:00
Rudolf Polzer 850f2b4511 configure: check for python3 existence 2012-08-16 17:16:05 +02:00
Stefano Pigozzi 6879d1162c vo_sharedbuffer: remove this VO
Since slave mode is not planned to be kept, this VO is useless and I'm
removing it.

This VO was useful for OSX GUIs. Since in cocoa you can't embed views in
windows from other processes, this VO was writing to a sharedbuffer with
mmap. The OSX GUIs would then read from the buffer and render the image
with an external renderer.

If in the future we will want to support GUIs we will need to reasearch the
IOSurface framework. This allows to share kernel managed image data
across processes and integrates well with OpenGL.
2012-08-15 22:01:39 +02:00
wm4 477af1c777 osd: remove FAST_OSD code
This code has never been active by default, ever since it was added
back in 2001. You had to edit config.h or configure manually to enable
it.
2012-08-07 02:21:19 +02:00
wm4 89b7cb0331 win32: fix compilation on MinGW
The commit 74df1d8e05 (and f752212c62) replaced the configure
endian check with byte order macros defined by standard headers. It
turns out that MinGW-w64 actually doesn't define these macros in the
sys/types.h system header. (I assumed it does, because a quick test
seemed to work. But that was because gcc -W -Wall doesn't warn against
undefined macros. You need -Wundef for that.) MinGW-w64 has a
sys/params.h header defining these macros, but sys/types.h doesn't
include it, so it's useless without special casing the mplayer code.
Add a hack top configure instead. Define the macros directly, and
assume MinGW-w64 only works on little endian machines.

The other changes are basically random typos and superficial oversights.
2012-08-07 01:09:42 +02:00
wm4 c113e6ed7d Remove V4L2 decoder support (vo_v4l2 and ao_v4l2)
The removed VO and AO took MPEG data and decoded it with V4L2. I'm not
exactly sure what's the use of this today, but get rid of it.

As far as feeding video data to V4L2 is concerned, there are other
ways. For example, there is this script, that feeds yuv4mpeg formatted
raw video data to V4L2:

    https://raw.github.com/umlaeute/v4l2loopback/master/examples/yuv4mpeg_to_v4l2.c
2012-08-07 01:09:30 +02:00
wm4 6ecfa42a46 VO: remove vo_gif89a, vo_md5sum, vo_yuv4mpeg
The encoding branch by divverent can handle of these via libavformat.

Note: for some reason, libav/ffmpeg have a GIF muxer only, and no
demuxer. The gif configure checks needef for the mplayer internal gif
demuxer can't be removed yet.
2012-08-06 18:58:17 +02:00
wm4 44f23e36e8 VO: remove vo_jpeg, vo_png, vo_pnm, vo_tga
All of these have been replaced by vo_image.
2012-08-06 18:49:35 +02:00
mplayer-svn 772d93c81a configure: fix directx check on Cygwin
build: Fix vo directx configure check on Cygwin

  Without windows.h included syntax errors will
arise inside (some versions of) the ddraw.h header.

  The wine-based ddraw.h header was reported to not
have this problems.

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@34953 b3059339-0415-0410-9bf9-f77b7e298cf2
Author: al
2012-08-03 03:34:38 +02:00
mplayer-svn 254e291a66 configure: try linking in libmad test
Try linking when testing for libmad.

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@34880 b3059339-0415-0410-9bf9-f77b7e298cf2
Author: cehoyos
2012-08-03 03:34:38 +02:00
mplayer-svn 2934b22c80 configure: add -D__STDC_FORMAT_MACROS to CXXFLAGS
This is required to safely #include inttypes.h in .cpp files.

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@34231 b3059339-0415-0410-9bf9-f77b7e298cf2
Author: diego
2012-08-03 01:31:19 +02:00
mplayer-svn 8a9348b079 configure: drop extra standard compiler/linker flags for *BSD systems
Adding the standard library locations to the search path is doubtful
behavior and unnecessary at least on FreeBSD.

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@34128 b3059339-0415-0410-9bf9-f77b7e298cf2
Author: diego
2012-08-03 01:26:54 +02:00
wm4 b0e695cf79 Remove leftover BeOS support stuff
As by mplayer-svn commit 33972. Their BeOS removal was more thorough.
2012-08-03 01:20:51 +02:00
wm4 9dc8d891d1 configure: drop check for -lposix4
This was needed for ancient Solaris systems.
mplayer-svn dropped this check in r33892.
2012-08-03 01:10:48 +02:00
wm4 debca22212 loader: remove weird kstat thing
Apparently the win32 binary codec loader used this to retrieve the
CPU frequency on Solaris.
2012-08-03 01:00:55 +02:00
wm4 dfbfc7e75e configure: remove some unused checks 2012-08-03 00:59:39 +02:00
wm4 2aef9e2ef3 stream: remove V4L TV input and V4L radio support
There are V4L2 drivers, and the old V4L stuff seems plain unnecessary.
2012-08-02 23:51:54 +02:00
wm4 4b8fa8a597 build: remove references to cpuinfo
This was a horrible little tool to detect the host CPU at build time.
Forgotten in commit 74df1d8e05.

Also remove forgotten codec-cfg entry in .gitignore .
2012-08-01 23:05:59 +02:00
wm4 59b938c8aa stream: remove native RTSP/RTP/PNM support
There are still various other RTSP implementations available, such as
libnemesi, live555, and libav. The mplayer native version was a huge
chunk of old unmaintained code.
2012-08-01 17:47:14 +02:00
wm4 6e020e66e0 mp_msg: remove filename_recode
This was intended for translating filenames from filesystem charset to
the terminal charset. Modern sane platforms use UTF-8 for everything,
and on Windows we use unicode APIs, so this is not needed anymore.

Remove filename_recode, all uses of it, options and configure checks
related to terminal output charset, and code that tries to determine
the same.
2012-07-31 01:35:53 +02:00
wm4 6e8633c734 configure: remove checks for malloc.h and alloca()
Including <malloc.h>, especially if all you want is malloc(), has no
legitimate uses (on sane platforms at least). Remove the check for it,
and remove all uses in the code.

Remove unused check for alloca().
2012-07-30 22:14:33 +02:00
wm4 261243496e configure: remove memalign check
Also, replace the only use of memalign: use av_malloc instead in sub.c.
(av_malloc allocates with the required alignment restrictions.)
2012-07-30 22:14:33 +02:00
wm4 1fde09db6f Remove some demuxers and decoders
Most of these demuxers and decoders are provided in better form by
libav, while the mplayer builtin ones are essentially unmaintained. The
only legimitate use case for not using the libav ones was working around
libav bugs or bugs related to the way mplayer uses libav. Instead of
trying to keep dead code alive, development effort should go into
improving libav or the mplayer libav glue code.

Note that the libav demuxer have been preferred over the mplayer builtin
ones for a while in mplayer2. There were some exceptions: playing DVDs
with dvdnav or playing network sources. (That's because some stream
modules and network.c requested explicit file formats, such as
DEMUXER_TYPE_MPEG_PS, which mapped to builtin demuxers.) With this
commit, they are switched to use libav. One caveat is that the requested
format is not passed to libavformat, instead we rely on the auto probing
to select the correct libav demuxer (see code in demux_open_stream()).
2012-07-30 22:14:32 +02:00
wm4 6b4cdfe1c8 Remove XMMS plugin support
XMMS has been dead since 2007.
2012-07-30 02:19:50 +02:00
wm4 614f847516 mplayer: remove Linux RTC support
This used /dev/rtc for timing. /dev/rtc root only by default, and I
have a hard time believing that the standard OS functions are not good
enough. (Even if not, support for POSIX high resolution timers should
be added instead, see clock_gettime() and others.)
2012-07-30 01:42:54 +02:00
wm4 7349d39938 configure, mp_msg.h: get rid of MP_DEBUG
The function mp_dbg() was silent if MP_DEBUG was not defined. MP_DEBUG
was defined only if configure was invoked with --enable-debug. Remove
it and make mp_dbg an alias to mp_msg. This has the advantage tha
--enable-debug changes less. (It only adds -g now and disables stripping
the binary on installation.)

Using log levels is the better way to silence annoying debug messages.
2012-07-30 01:40:42 +02:00
wm4 6009965cdd sub: remove unrar_exec
This removes the ability to open compressed bitmap subtitles from rar
files. The code makes me afraid, and I never needed this feature.
2012-07-30 01:40:42 +02:00
wm4 897d1c01bc mplayer: remove crash handler stuff
mplayer tries to catch all signals by default, and displays a "nice"
crash message if a signal is caught. This is mostly useless for
diagnosing problems, and it's extremely fragile. It's likely to cause
more harm than it possibly solves.

Also remove the current_module variable, which was supposed to give a
hint which submodule was being run. This was far from accurate or
useful.

mplayer also caught SIG_CHILD, and tried to wait for any children. This
potentially gets rid of zombies, but I'm not sure which ones. The only
places that fork(), cache2.c and unrar_exec.c, seem to wait for their
child processes properly. Just get rid of it.

Note that we don't even catch SIGTERM. Maybe this will have to be added
back in order to re-enable screensavers and such when the user
terminates mplayer with ^C on the terminal.
2012-07-30 01:38:53 +02:00
wm4 43da1e78c4 Rip out 3DNOW support
Ancient AMD specific enhancement to the MMX instruction set. Officually
discontinued by AMD.

Note that support for this was already disabled in the previous commit.
This commit removes the actual code.
2012-07-30 01:38:14 +02:00
wm4 74df1d8e05 Remove compile time/runtime CPU detection, and drop some platforms
mplayer had three ways of enabling CPU specific assembler routines:
a) Enable them at compile time; crash if the CPU can't handle it.
b) Enable them at compile time, but let the configure script detect
   your CPU. Your binary will only crash if you try to run it on a
   different system that has less features than yours.
   This was the default, I think.
c) Runtime detection.

The implementation of b) and c) suck. a) is not really feasible (it
sucks for users). Remove all code related to this, and use libav's CPU
detection instead. Now the configure script will always enable CPU
specific features, and disable them at runtime if libav reports them
not as available.

One implication is that now the compiler is always expected to handle
SSE (etc.) inline assembly at runtime, unless it's explicitly disabled.

Only checks for x86 CPU specific features are kept, the rest is either
unused or barely used.

Get rid of all the dump -mpcu, -march etc. flags. Trust the compiler
to select decent settings.

Get rid of support for the following operating systems:
- BSD/OS (some ancient BSD fork)
- QNX (don't care)
- BeOS (dead, Haiku support is still welcome)
- AIX (don't care)
- HP-UX (don't care)
- OS/2 (dead, actual support has been removed a while ago)

Remove the configure code for detecting the endianness. Instead, use
the standard header <endian.h>, which can be used if _GNU_SOURCE or
_BSD_SOURCE is defined. (Maybe these changes should have been in a
separate commit.)

Since this is a quite violent code removal orgy, and I'm testing only
on x86 32 bit Linux, expect regressions.
2012-07-30 01:37:28 +02:00
wm4 273a6623e7 libvo: remove custom assembler memcpy implementations (aka fastmemcpy)
aclib[_template].c contained inline assembler versions of memcpy using
MMX/SSE/3dnow etc. instructions. It's possible that this gave quite a
speed a decade ago, but it's unlikely to have any use on modern
systems. Also, libc implementations already have their own
optimizations for the native memcpy function.

I did not verify my assumptions eith benchmarks, so I could be wrong.

Also note that some platforms have extremely crappy libc
implementations, and it's well possible that these might suffer from a
major performance loss (hello Windows). Unfortunately, I do not care.
2012-07-30 01:33:40 +02:00
wm4 94b7db20bc configure: remove pointless checks for yasm etc.
mplayer doesn't use yasm, as or ranlib. They were only needed to
build with internal libav, which is gone.

Also, get rid of nm. nm was used to find out how external symbols are
mangled. Replace this by a platform check in mangle.h. As far as I
know, sane systems don't mangle symbols. Windows prefixes them with
an underscore ("_symbol"). I don't know about OSX.
2012-07-29 00:22:13 +02:00
wm4 806461c5b6 ad_faad: include neaacdec.h instead of faad.h
The faad.h header printed a warning that this header is outdated.
The header neaacdec.h is probably the proper header, so use that.
2012-07-28 23:51:38 +02:00
wm4 ca0979a5db configure: disable win32 emulation by default
The win32 emulation code can be used to load Windows binary codecs.
Unfortunately, this code is extremely whacky and unmaintained. It
consists of an ancient copy of wine, that was hacked to death and
back. It does super-whacky stuff like patching the loaded codecs at
fixed memory offsets to make them work.

Not removing yet, because it still has some limited use, and some of
the code is needed to load codecs when running natively on Windows.
(Actually, I only care because mplayer can get video input from the
webcam of that-one-latop under Windows, which I find far too neat to
just kill all the code.)
2012-07-28 23:36:08 +02:00
wm4 85a3a0d5bc osd: remove freetype font rendering code
The previous commit made libass the default OSD renderer. This commit
removes the disabled freetype renderer completely. The commits were
done separately to make rolling back easier, because using libass for
OSD rendering is a risky choice.

Also remove freetype/fontconfig/fribidi code. This is all done by
libass now.

If mplayer is compiled without libass, no OSD is displayed.
2012-07-28 23:36:08 +02:00
wm4 74e7a1e937 osd: use libass for OSD rendering
The OSD will now be rendered with libass. The old rendering code, which
used freetype/fontconfig and did text layout manually, is disabled. To
re-enable the old code, use the --disable-libass-osd configure switch.

Some switches do nothing with the new code enabled, such as -subalign,
-sub-bg-alpha, -sub-bg-color, and many more. (The reason is mostly that
the code for rendering unstyled subtitles with libass doesn't make any
attempts to support them. Some of them could be supported in theory.)

Teletext rendering is not implemented in the new OSD rendering code. I
don't have any teletext sources for testing, and since teletext is
being phased out world-wide, the need for this is questionable.

Note that rendering is extremely inefficient, mostly because the libass
output is blended with the extremely strange mplayer OSD format. This
could be improved at a later point.

Remove most OSD rendering from vo_aa.c, because that was extremely
hacky, can't be made work with osd_libass, and didn't work anyway in
my tests.

Internally, some cleanup is done. Subtitle and OSD related variable
declarations were literally all over the place. Move them to sub.h and
sub.c, which were hoarding most of these declarations already. Make the
player core in mplayer.c free of concerns like bitmap font loading.

The old OSD rendering code has been moved to osd_ft.c. The font_load.c
and font_load_ft.c are only needed and compiled if the old OSD
rendering code is configured.
2012-07-28 23:36:07 +02:00
wm4 7a06095dc3 Add support for playing video from streaming sites with libquvi
This enables playing URLs from libquvi supported streaming sites
directly, e.g. "mplayer http://www.youtube.com/watch?v=...."

Anything opened with mplayer is checked with libquvi. If it looks like
a URL of a supported streaming site, libquvi is used to extract the
media URL, which is then passed to the lower level mplayer code
instead of the HTML URL. Hopefully the libquvi URL checker works well
enough that it doesn't cause any problems with normal URLs, files, or
whatever else mplayer's stream layer accepts.

Add the --libquvi-format option. the option value is directly passed to
libquvi as requested format. The only values that seem to work for any
streaming site seem to be "best" (best quality) and "default" (lowest
quality). The mplayer option defaults to "best" (overriding libquvi's
default).

Outstanding issues:
- Does libquvi checking every opened file really not cause problems?
  Should there be a runtime option to disable libquvi use?
  (Probably not an issue.)
- Should we check/set the supported protocol? By default libquvi has
  support for all protocols enabled. In the worst case, it might return
  an URL using a protocol not supported by mplayer, even though it
  could extract URLs with other protocols too.
  (Probably not an issue.)
- Somehow export metadata (like media title) to the mplayer frontend?
2012-07-28 22:05:34 +02:00
wm4 16145ff43f libvo, libao: remove useless video and audio output drivers
Some of these have only limited use, and some of these have no use at
all. Remove them. They make maintainance harder and nobody needs them.
It's possible that many of the removed drivers were very useful a dozen
of years ago, but now it's 2012.

Note that some of these could be added back, in case they were more
useful than I thought. But right now, they are just a burden.

Reason for removal for each module:
    vo_3dfx, vo_dfbmga, vo_dxr3, vo_ivtv, vo_mga, vo_s3fb,
    vo_tdfxfb, vo_xmga, vo_tdfx_vid:
        All of these are for very specific and outdated hardware. Some
        of them require non-standard kernel drivers or do direct HW
        access.
    vo_dga: the most crappy and ancient way to get fast output on X.
    vo_aa: there's vo_caca for the same purpose.
    vo_ggi: this never lived, and is entirely useless.
    vo_mpegpes: for DVB cards, I can't test this and it's crappy.
    vo_fbdev, vo_fbdev2: there's vo_directfb2
    vo_bl: what is this even? But it's neither important, nor alive.
    vo_svga, vo_vesa: you want to use this? You can't be serious.
    vo_wii: I can't test this, and who the hell uses this?
    vo_xvr100: some Sun thing.
    vo_xover: only useful in connection with xvr100.
    ao_nas: still alive, but I doubt it has any meaning today.
    ao_sun: Sun.
    ao_win32: use ao_dsound or ao_portaudio instead.
    ao_ivtv: removed along vo_ivtv.

Also get rid of anything SDL related. SDL 1.x is total crap for video
output, and will be replaced with SDL 2.x soon (perhaps), so if you
want to use SDL, write output drivers for SDL 2.x.

Additionally, I accidentally damaged Sun support, which made me
completely remove Sun/Solaris support. Nobody cares about this anyway.

Some left overs from previous commits removing modules were cleaned up.
2012-07-28 20:44:59 +02:00