Commit Graph

32907 Commits

Author SHA1 Message Date
Uoti Urpala 1bdb0e4cc3 configure: fix --enable-3dfx override without dga
If --enable-3dfx is specified but dga is not available then 3dfx is
disabled nonetheless. However, this disabling is not done properly,
and libvo/vo_3dfx.c is still compiled (but cannot be used). Fix.

The behavior of automatically disabling vo_3dfx despite --enable-3dfx
is itself questionable, but I'm not changing that now.
2011-04-20 20:37:10 +03:00
Uoti Urpala c33fafd6f1 Update libav API uses
Update various code to use newer alternatives instead of deprecated
functions/fields that are being dropped at libav API bump. An
exception is avcodec_thread_init() which is being dropped even though
it's still _necessary_ with fairly recent libav versions, so there's
no good alternative which would work with both those recent versions
and latest libavcodec. I think there are grounds to consider the drop
premature and revert it for now; if that doesn't happen I'll add a
version-test #if check around it later.
2011-04-20 04:36:05 +03:00
Uoti Urpala 726c28dd9b manpage: restore -lavfdopts doc accidentally removed in d76ad5f2
For some reason the -lavfdopts option was documented under MEncoder
options (despite not being MEncoder-specific), and was removed
together with MEncoder documentation in commit d76ad5f227. Restore the
documentation and convert it from its own section to normal option
documentation form. Also fix the example to actually work with current
lavf.
2011-04-20 04:29:01 +03:00
Clément Bœsch d10b54fc2e config: remove pointless cfg-mplayer-def.h file 2011-04-20 04:22:53 +03:00
Clément Bœsch 79bb565038 options: merge cfg-mplayer.h and cfg-common.h
Remove obsolete extern declarations for demuxer_type,
audio_demuxer_type, sub_demuxer_type and noconfig_opts in the
process.
2011-04-20 04:22:53 +03:00
Clément Bœsch 699bf9dcd3 vo_dga: replace xf86dga.h with Xxf86dga.h
xf86dga.h is deprecated and may be removed in the future.
2011-04-20 04:22:53 +03:00
Clément Bœsch 52743acba3 cleanup: avoid various GCC warnings 2011-04-20 04:22:53 +03:00
Clément Bœsch b17a1cf70c ao_alsa: remove warning by simplifying error handling case
Avoid a gcc warning about potentially uninitialized variable 'err'
(there was no actual problem with the code).
2011-04-20 04:22:53 +03:00
Uoti Urpala a2d28010cc cleanup: find_subfiles.c: simplify (mainly using bstr) 2011-04-20 04:22:53 +03:00
Clément Bœsch 52d60a7334 cleanup: find_subfiles.c: simplify declarations and allocations
Also clarify compare_sub_priority() and remove a typedef for the subfn
structure in the process.
2011-04-20 04:22:53 +03:00
Clément Bœsch 549177c105 find_subfiles: select subtitle files matching -slang
Also simplify subtitle selection a bit.
2011-04-20 04:22:53 +03:00
Clément Bœsch 1a152eadaf find_subfiles: try to determine if a .sub file is text or vobsub
A file with the ambiguous extension .sub could be either VOBsub or
MicroDVD. If there's a corresponding .idx file it's certainly VOBsub,
so don't add it to the list of potential text subtitles. This will
avoid the annoying warning "SUB: Could not determine file format".
2011-04-20 04:22:53 +03:00
Clément Bœsch 1c6995d76c subs: options: add -sub-paths 2011-04-20 04:22:52 +03:00
Uoti Urpala 2db33ab48c options: support string list separators other than ','
Allow specifying a custom separator character for options of string
list type, and use that to define OPT_PATHLIST which takes a list of
strings separated by ':' (or ';' on Windows).
2011-04-20 04:22:52 +03:00
Clément Bœsch acc187cd20 find_subfiles: allow subtitle search in multiple directories 2011-04-20 04:22:52 +03:00
Uoti Urpala bdfdece245 subs: move vobsub loading logic down to find_subfiles.c
Analogously to the previous commit, move path handling logic for
loading external vobsub files from mplayer.c to find_subfiles.c.

Based on a commit from Clément Bœsch but fixed and simplified.
2011-04-20 04:22:52 +03:00
Clément Bœsch 7221e28fe3 subs: move text sub loading logic down to find_subfiles.c
Move path handling for loading external subtitle files from mplayer.c
to find_subfiles.c. Now the remaining code in mplayer.c only gets a
list of potential filenames and tries opening those.
2011-04-20 04:22:52 +03:00
Clément Bœsch 9bcfbe4d4f find_subfiles: move sub_filenames() here
Move sub_filenames() and related code from subreader.c to new file
find_subfiles.c. This function is used to find subtitle files that
should be loaded for the current video; this functionality is not
specific to the particular kind of text subtitle handling implemented
in subreader.c.

Also reindent and prettify the moved code a bit.
2011-04-20 04:22:52 +03:00
Clément Bœsch 4587f030cc options: move sub_name, sub_auto and vobsub_name to struct 2011-04-20 04:22:52 +03:00
Clément Bœsch 59fff90d94 options: change -alang and -slang to use string list type
There is no reason to use manual language list splitting when an
automatic split function is already available.

Some types change from "unsigned char" to "char", but this shouldn't
cause issues since [as]lang settings are unlikely to have characters
above 127.
2011-04-20 04:22:42 +03:00
zuxy 78bdc33b48 vd_ffmpeg: require aligned stride in get_buffer()
Change MP_IMGFLAG_ACCEPT_STRIDE to MP_IMGFLAG_ACCEPT_ALIGNED_STRIDE in
get_buffer() as various FFmpeg assembly routines assume aligned input.

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@33097 b3059339-0415-0410-9bf9-f77b7e298cf2
2011-04-13 03:36:56 +03:00
cehoyos c824034689 codecs.conf: only list 4:2:0 colorspace fourccs for VDPAU
VDPAU hardware decoding does not support colorspaces other than 4:2:0.

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@33096 b3059339-0415-0410-9bf9-f77b7e298cf2
2011-04-13 03:35:26 +03:00
cehoyos 42f97b2b82 codecs.conf, stheader.h: support CrystalHD decoding (libavcodec)
Add the various decoders to codecs.conf and increase the maximum
number of buffered pts in stheader.h (apparently CrystalHD can have
very high decoder lag).

Patch by Philip Langdale, philipl overt org

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@33095 b3059339-0415-0410-9bf9-f77b7e298cf2
2011-04-13 03:21:41 +03:00
compn b49b4e6ef9 codecs.conf: add xd55 isom for mpeg2 video from fcp
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@33094 b3059339-0415-0410-9bf9-f77b7e298cf2

Conflicts:

	etc/codecs.conf
2011-04-13 03:18:57 +03:00
cehoyos c99d8fc898 stream: http: Allow setting custom http header
Patch by Nikolay Nikolaev, nicknickolaev yahoo com

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@33082 b3059339-0415-0410-9bf9-f77b7e298cf2
2011-04-13 03:17:05 +03:00
cehoyos 4b5a86c78e stream_dvdnav: output ID_DVD_VOLUME_ID also for dvdnav://
Patch by Mike Castle, dalgoda+mplayer gmail

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@33081 b3059339-0415-0410-9bf9-f77b7e298cf2
2011-04-13 03:17:05 +03:00
cehoyos 3cb235736e codecs.conf: Use fourcc instead of format where appropriate
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@33077 b3059339-0415-0410-9bf9-f77b7e298cf2
2011-04-13 03:17:05 +03:00
cehoyos e43e0de9e6 ad_pcm, codecs.conf: support 'lpcm' in mov and float in aiff
Support 'lpcm' in mov files, has audible (clipping?) artefacts on some
systems.

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@33075 b3059339-0415-0410-9bf9-f77b7e298cf2

Support 32bit big endian float pcm in aiff.

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@33076 b3059339-0415-0410-9bf9-f77b7e298cf2
2011-04-13 03:17:05 +03:00
cehoyos cb61c0f2d4 options: add -gamma (was only accessible from slave mode before)
Patch by Kevin DeKorte, kdekorte at gmail

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@33064 b3059339-0415-0410-9bf9-f77b7e298cf2
2011-04-13 03:15:42 +03:00
cehoyos 2c2f620e7a codecs.conf: Add FourCC ai12 for AVC Intra 100 / 1080.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@33061 b3059339-0415-0410-9bf9-f77b7e298cf2
2011-04-13 03:15:05 +03:00
reimar 55dbd183e3 ad_liba52: Fix -ac a52 with tags other than 0x2000 or dnet
Audio with all codec tags other than 0x2000 was byte-swapped, while
only "dnet" should be.

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@33028 b3059339-0415-0410-9bf9-f77b7e298cf2
2011-04-13 03:15:05 +03:00
reimar 7a3fd839ef audio: do not run the AC-3 parser on byte-swapped AC-3
Libavcodec has no parser that would work on byte-swapped AC3, but at
least don't run the normal AC-3 one which would only break things.

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@33026 b3059339-0415-0410-9bf9-f77b7e298cf2

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@33027 b3059339-0415-0410-9bf9-f77b7e298cf2
2011-04-13 03:10:33 +03:00
reimar 4496b90f8b configure: print correct result variable for armv6t2 test
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@32996 b3059339-0415-0410-9bf9-f77b7e298cf2
2011-04-13 02:19:54 +03:00
cehoyos fa0d14555d codecs.conf, mp_taglists.c: add LXF PCM and dvvideo
Support audio in Leitch/Harris' VR native stream format (LXF).

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@32990 b3059339-0415-0410-9bf9-f77b7e298cf2

Support dvvideo in Leitch/Harris' VR native stream format (LXF).

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@32991 b3059339-0415-0410-9bf9-f77b7e298cf2
2011-04-12 19:39:30 +03:00
cehoyos 85fb21f7a2 stream_dvdnav: identify: show more title information
Add ID_DVD_TITLE_x_CHAPTERS and ID_DVD_CURRENT_TITLE to the output of
dvdnav:// -identify.

Patch by Mike Castle, dalgoda+mplayer A gmail

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@32982 b3059339-0415-0410-9bf9-f77b7e298cf2
2011-04-12 19:24:58 +03:00
reimar 67f5ef670c stream: try to reset stream once if read fails
When reading from a stream fails, try one more time after a reset.
This should re-establish for example timed-out network connections.
Fixes bug #1841.

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@32954 b3059339-0415-0410-9bf9-f77b7e298cf2

100l, fix incorrect len when retrying read.

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@32957 b3059339-0415-0410-9bf9-f77b7e298cf2

Improve stream reset on read error, should now fix bug #1841 in more
cases, e.g. also with -cache.

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@32977 b3059339-0415-0410-9bf9-f77b7e298cf2

Add ugly hack to compensate DVDNAV's ugly hacks and fix seeking.

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@33122 b3059339-0415-0410-9bf9-f77b7e298cf2
2011-04-12 19:21:23 +03:00
compn 989694678d codecs.conf: add ai5q and ai1q fourccs for h264 decoders
ported from ffmpeg

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@32948 b3059339-0415-0410-9bf9-f77b7e298cf2
2011-04-12 18:45:11 +03:00
cehoyos 76bc005580 stream_dvdnav: don't skip last title for dvdnav:// -identify
Patch by Mike Castle, dalgoda+mplayer gmail

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@32944 b3059339-0415-0410-9bf9-f77b7e298cf2
2011-04-12 18:43:52 +03:00
reimar c246c09b03 vo_gl: fix "gamma" equalizer setting
The "gamma" setting only changed red gamma. Fix it to change all of
red, green and blue gamma.

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@32895 b3059339-0415-0410-9bf9-f77b7e298cf2
2011-04-12 18:41:26 +03:00
cehoyos 4726be4314 codecs.conf: clarify XAN DPCM comment
At least for Wing Commander 4 files, -demuxer lavf is needed to
play XAN DPCM audio (while Wing Commander 3 avi plays fine with
-demuxer avi, although it also contains the video codec we call "XAN
wc4").

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@32894 b3059339-0415-0410-9bf9-f77b7e298cf2
2011-04-12 18:35:38 +03:00
cehoyos c4814bc8b6 codecs.conf: Support 0x594A as format value for XAN DPCM audio
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@32885 b3059339-0415-0410-9bf9-f77b7e298cf2
2011-04-12 18:34:50 +03:00
ranma f8c32fc953 stream: Make stream_write_buffer() check for short writes
None of the calling sites to stream_write_buffer were checking the
return value to see if all bytes got written (nothing in current code
actually calls it any more after MEncoder was removed).

This was causing (very occasionally) problems with mencoder when using
output pipes AND running under a sandbox or when being straced (ptrace
is the culprit). Theoretically this problem can happen without pipes
or ptrace.

Only stream_file, stream_smb and stream_ffmpeg implement
write_buffer and ffmpeg already handles this internally.

Original patch by Sang-Uok Kum.

Signed-off-by: Tobias Diedrich <ranma@google.com>

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@32881 b3059339-0415-0410-9bf9-f77b7e298cf2
2011-04-12 18:23:43 +03:00
Uoti Urpala 7fe2856fd9 OSD: support displaying fractional part of current position
Add option -osd-fractions which enables display of fractional seconds
when showing the current playback time on OSD.

Based on a patch from Christian <herr.mitterlehner@gsmpaaiml.com> but
with several modifications.
2011-04-12 18:11:28 +03:00
Uoti Urpala 2a7c5a1365 audio: change external AO interface to "ao_[method](ao, ...)"
Make the outside interface of audio output handling similar to the
video output one. An AO object is first created, and then methods
called with ao_[methodname](ao, args...). However internally libao2/
still holds all data in globals, and trying to create multiple
simultaneous AO instances won't work.
2011-04-09 03:03:22 +03:00
Uoti Urpala 9ef15ac4fc Merge branch 'edl'
* edl:
  core: support timeline with audio-only files
  core: wake up a bit less often for audio-only files
  core: audio: cut audio writes at end of timeline part
  EDL: add support for new EDL file format
  stream.[ch], ass_mp: new stream function for whole-file reads
  tl_matroska.c: move the find_files() function here
  bstr.[ch], path.[ch]: add string and path handling functions
  core: ordered chapters: move timeline creation to timeline/
  options: drop support for numeric -demuxer values
  cleanup: demuxer.[ch]: remove unused code, make functions static
  cleanup: reindent demuxer.h, use struct names for types
2011-04-08 22:50:06 +03:00
Uoti Urpala dc3471780d core: support timeline with audio-only files 2011-04-08 05:15:43 +03:00
Uoti Urpala cbeed30ae8 core: wake up a bit less often for audio-only files
Sleep 100 ms between filling audio output buffers. Also do the
sleeping in input read functions to enable immediate wakeups on new
input.
2011-04-08 04:05:57 +03:00
Uoti Urpala 511498818f demux_lavf: disable support for byte-based seeking
libavformat returns nonsense per-stream bitrate values for some MPEG
files (0 or many times higher than the overall bitrate of the file),
which triggered the heuristic to enable byte-based seeking in
demux_lavf and then made the byte-based seeks wildly inaccurate.
Disable the support for byte-based seeks. This will avoid problems
with files that have consistent timestamps, but on the other hand will
completely break seeking in MPEG files that have timestamp resets.
I'll probably add at least an option to manually enable byte-based
seeking later.
2011-04-08 02:47:02 +03:00
Uoti Urpala d4b5ee2cd5 demux_mkv: support runtime video track switching
Add code identical to the audio case to also support switching video
tracks at runtime.

Patch by "Hermi".
2011-04-08 02:33:57 +03:00
Uoti Urpala ca5399d04f VO: don't wait for map event in X VO initialization
After creating a video window the common X code waited for a MapNotify
event before proceeding. This meant that if the window was opened on
another workspace the player would be stuck until the user switched to
that workspace and the window could become actually visible. Remove
this waiting code. I don't know why it was there or if it was actually
beneficial/needed for some setup (at least common uses seem to work
fine without it); it comes from the earliest MPlayer versions visible
in VCS history.
2011-04-08 02:30:13 +03:00