Commit Graph

271 Commits

Author SHA1 Message Date
diego 21c200e767 FFmpeg now uses different (unified) #include paths.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@26101 b3059339-0415-0410-9bf9-f77b7e298cf2
2008-02-25 15:46:36 +00:00
diego ae66c7536e Replace silly check for config.h inclusion, just include it.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@26096 b3059339-0415-0410-9bf9-f77b7e298cf2
2008-02-24 23:44:35 +00:00
diego 8efb2fa21c Add MPLAYER_ prefix to multiple inclusion guards.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@26061 b3059339-0415-0410-9bf9-f77b7e298cf2
2008-02-22 09:09:46 +00:00
diego c7577cd703 This header should not have multiple inclusion guards, it is meant
to be included multiple times.
patch by Alexander Stege  mplayer a legale-software d com


git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@26026 b3059339-0415-0410-9bf9-f77b7e298cf2
2008-02-18 21:07:33 +00:00
diego 835c654bb0 typo fix: inited --> initialized
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@25994 b3059339-0415-0410-9bf9-f77b7e298cf2
2008-02-14 14:23:55 +00:00
ulion 85941859b2 Fix buffer overflow bug by calculate the buffer size accurately.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@25670 b3059339-0415-0410-9bf9-f77b7e298cf2
2008-01-11 10:15:46 +00:00
diego 2b6af2000b Add multiple inclusion guards to all header files that lack them.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@25581 b3059339-0415-0410-9bf9-f77b7e298cf2
2008-01-01 21:35:58 +00:00
diego baee7815d5 Replace multiple inclusion guards with leading underscores by default names.
Leading underscores are reserved for system identifiers.


git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@25579 b3059339-0415-0410-9bf9-f77b7e298cf2
2008-01-01 20:21:20 +00:00
diego fba0b66ff9 Add explanatory comments to the #endif part of multiple inclusion guards.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@25563 b3059339-0415-0410-9bf9-f77b7e298cf2
2007-12-31 16:15:50 +00:00
diego 496f7332a7 Relicense GPL v2 files as GPL v2+ and add proper license headers.
Done with permission from Michael Niedermayer, the author.


git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@25557 b3059339-0415-0410-9bf9-f77b7e298cf2
2007-12-31 10:41:20 +00:00
ulion 66abcc42af Add new audio filter for encoding multi-channel audio into ac3 at runtime.
And if set first parameter of this filter to 1, it will do ac3 passthrough
like hwac3 did.


git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@25385 b3059339-0415-0410-9bf9-f77b7e298cf2
2007-12-13 12:38:17 +00:00
ulion 1ed6e96cfb Fix all current known multi-channel wrong order problems by adding
common functions for channel reordering.
This fixes these modules by adding channel reordering code for 5.0/5.1 audio:
ao: pcm
ad: dmo, faad, ffmpeg(ac3, dca, libfaad, liba52), pcm
ae: faac, lavc(ac3, libfaac), pcm


git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@25343 b3059339-0415-0410-9bf9-f77b7e298cf2
2007-12-10 16:53:30 +00:00
ulion 0fe9266445 Fix my wrong code in r25530.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@25334 b3059339-0415-0410-9bf9-f77b7e298cf2
2007-12-10 11:08:27 +00:00
ulion 920a892892 Fix missing command line bug by making the input parameter constant.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@25330 b3059339-0415-0410-9bf9-f77b7e298cf2
2007-12-10 01:43:33 +00:00
reimar def649b0e4 100l, bzero is deprecated, use memset instead
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@25216 b3059339-0415-0410-9bf9-f77b7e298cf2
2007-11-30 21:29:45 +00:00
ivo 89308b1105 Remove redundant changelog from comments. There's always svn log.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@25199 b3059339-0415-0410-9bf9-f77b7e298cf2
2007-11-29 14:30:03 +00:00
diego df58d5f00d Fix multiple inclusion guards, identifiers starting with __ are reserved
for the system.


git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@25198 b3059339-0415-0410-9bf9-f77b7e298cf2
2007-11-29 14:23:24 +00:00
ulion 70e7acda26 Prevent from using data->len when data is NULL (when play() return NULL).
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@25143 b3059339-0415-0410-9bf9-f77b7e298cf2
2007-11-23 05:50:34 +00:00
reimar ce11ba5de5 Add padding and unroll loop 4x for at least another 10% speedup
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@25104 b3059339-0415-0410-9bf9-f77b7e298cf2
2007-11-18 22:13:49 +00:00
reimar 0f0e2f5f5b Change to a 64 bit accumulation variable instead of shifting.
Changing the way the loop is done is necessary to reduce register pressure.
About 20% speedup even on 32 bit x86.


git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@25103 b3059339-0415-0410-9bf9-f77b7e298cf2
2007-11-18 18:52:51 +00:00
reimar 13a205e075 100l, *ppc++ was supposed to be replaced by ppc[i] in r25100, but that is not any faster.
Just removing the += s->samples_overlap - s->num_channels; still provides a
ca. 20% speedup on x86 (AThlon X2 64) with gcc 3.4 (compiler stupidity?)


git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@25102 b3059339-0415-0410-9bf9-f77b7e298cf2
2007-11-18 18:33:45 +00:00
reimar 66c4759992 Use "long" instead of "int" for innermost loop variable.
About 12% faster on x86_64


git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@25101 b3059339-0415-0410-9bf9-f77b7e298cf2
2007-11-18 17:44:11 +00:00
reimar 0bc7ce3b04 Rearrange scaletempo inner loop.
Speedup on x86 with gcc 3.4 36%, on x86_64 with gcc 4.1 5%


git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@25100 b3059339-0415-0410-9bf9-f77b7e298cf2
2007-11-18 17:28:27 +00:00
reimar 1c05db4406 100l, someone mixed up && and ||, so if allocation of only one buffers failed
that would not be detected.


git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@25098 b3059339-0415-0410-9bf9-f77b7e298cf2
2007-11-18 15:48:20 +00:00
reimar 4112aa7bcd Avoid some casts by changing int8_t* to void* in af_scaletempo
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@25097 b3059339-0415-0410-9bf9-f77b7e298cf2
2007-11-18 14:57:59 +00:00
uau d7f6cb23de A/V sync: take audio filter buffers into account
Substract the delay caused by filter buffering when calculating
currently playing audio position. This matters for af_scaletempo which
buffers significant and varying amounts of data. For other current
filters the effect is normally insignificant.

Instead of the old time-based filter delay field (which was ignored)
this version stores the per-filter delay in units of bytes input read
without corresponding output. This allows the current scaletempo
behavior where other filters before and after it can see the same
nominal samplerate even though the real duration of the data varies;
in this case the other filters can not know the delay they're causing
in terms of real time.


git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@24928 b3059339-0415-0410-9bf9-f77b7e298cf2
2007-11-01 06:52:50 +00:00
uau de034ce87f af_scaletempo: code cleanup
Make internal functions static and remove leading '_' from some
function names. Cast pointers to compatible 8-bit pointer types
instead of ints when calculating their difference.


git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@24927 b3059339-0415-0410-9bf9-f77b7e298cf2
2007-11-01 06:52:47 +00:00
uau e803711bbd af_scaletempo: Fix crash in option parsing
The value of the "speed" suboption was not initialized before calling
subopt_parse(). If the command line had suboptions but "speed" was not
one of them then the code accessed an uninitialized pointer and
possibly crashed. Fixed by initializing the option value.


git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@24926 b3059339-0415-0410-9bf9-f77b7e298cf2
2007-11-01 06:52:44 +00:00
uau ff1568af58 af_scaletempo: Fix audio copy position
Because of a missing *num_channels factor the filter copied audio from
an incorrect position. This mixed up the channel order and hurt audio
quality even if the channels had identical content.


git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@24925 b3059339-0415-0410-9bf9-f77b7e298cf2
2007-11-01 06:52:41 +00:00
uau d33703496c Add audio filter scaletempo
Patch by Robert Juliano, juliano.1 osu edu


git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@24924 b3059339-0415-0410-9bf9-f77b7e298cf2
2007-11-01 06:52:38 +00:00
uau 1844e1dd0c Change decode_audio() interface
Rewrite decode_audio to better deal with filters that handle input in
large blocks. It now always places output in sh_audio->a_out_buffer
(which was always given as a parameter before) and reallocates the
buffer if needed. After the changes filters can return arbitrarily
large blocks of data without some of it being lost. The new version
also allows simplifying some code.


git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@24920 b3059339-0415-0410-9bf9-f77b7e298cf2
2007-11-01 06:52:19 +00:00
uau 5bfedc0a2d Remove some pointless 'inline' qualifiers
Most of these functions aren't even used in the same translation unit.


git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@24918 b3059339-0415-0410-9bf9-f77b7e298cf2
2007-11-01 06:52:10 +00:00
uau ab2237c15a libaf: Remove rational number implementation
Remove the mul/cancel/gcd functions and some related code. Use ff_gcd
instead of the removed af_gcd in af_resample.c.


git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@24917 b3059339-0415-0410-9bf9-f77b7e298cf2
2007-11-01 06:52:06 +00:00
uau 7deec05ea0 libaf: change filter input/output ratio calculations
Change the audio filters to use a double instead of rationals for the
ratio of output to input size. The rationals could overflow when
calculating the overall ratio of a filter chain and gave no real
advantage compared to doubles.


git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@24916 b3059339-0415-0410-9bf9-f77b7e298cf2
2007-11-01 06:52:01 +00:00
uau c6824f577e Remove unused functions in af.c
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@24915 b3059339-0415-0410-9bf9-f77b7e298cf2
2007-11-01 06:51:57 +00:00
diego c8ae1836e6 cosmetics: misc typo fixes
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@24615 b3059339-0415-0410-9bf9-f77b7e298cf2
2007-09-25 16:34:23 +00:00
reimar 15649d0f00 Fix loads of typos
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@24581 b3059339-0415-0410-9bf9-f77b7e298cf2
2007-09-19 15:44:09 +00:00
reimar e9ea243fbd Fix typo in comment
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@24541 b3059339-0415-0410-9bf9-f77b7e298cf2
2007-09-16 09:00:45 +00:00
diego 84157efa5a Clean up the way get_path is handled: Compile get_path.c to an object to link
against instead of directly #including the C file and replace the many extern
declarations by a proper header file.


git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@24262 b3059339-0415-0410-9bf9-f77b7e298cf2
2007-08-28 11:20:24 +00:00
diego 505a5f013b Fix warning:
af_sinesuppress.c:34: warning: 'play_float' declared 'static' but never defined


git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@24191 b3059339-0415-0410-9bf9-f77b7e298cf2
2007-08-25 16:51:02 +00:00
diego 3e9e4acd8d Do not use leading underscores in multiple inclusion guards, they are reserved.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@23709 b3059339-0415-0410-9bf9-f77b7e298cf2
2007-07-02 22:34:45 +00:00
reimar 736affc4b2 ff_gcd is already in libavutil/common.h, no need for an extra prototype here
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@23643 b3059339-0415-0410-9bf9-f77b7e298cf2
2007-06-24 12:40:51 +00:00
zuxy 6e6d3acfa9 Add AF_CONTROL_PAN_BALANCE control
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@23571 b3059339-0415-0410-9bf9-f77b7e298cf2
2007-06-17 12:18:13 +00:00
zuxy 173c051b76 Remove incorrect comment: pan defaults to block all, instead of pass-thru.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@23553 b3059339-0415-0410-9bf9-f77b7e298cf2
2007-06-13 09:29:51 +00:00
zuxy c91cce5812 Avoid zero output for pan filter; zero output now means same # of channels
as input. Make pan work for af_add().


git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@23552 b3059339-0415-0410-9bf9-f77b7e298cf2
2007-06-13 09:28:49 +00:00
zuxy fd6d47944e Make pan reentrant. Multiple pans in chain work fine.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@23551 b3059339-0415-0410-9bf9-f77b7e298cf2
2007-06-13 09:20:36 +00:00
reimar 6a09e8e2ed Replace implicit use of fast_memcpy via macro by explicit use to allow
for future optimization.


git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@23475 b3059339-0415-0410-9bf9-f77b7e298cf2
2007-06-05 14:27:54 +00:00
diego 49b64742ed Add general variables for either static or shared FFmpeg libraries.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@23119 b3059339-0415-0410-9bf9-f77b7e298cf2
2007-04-26 11:22:22 +00:00
diego 5a8c8aadef cosmetics: Remove CONFIG_ prefix from FFmpeg library Makefile variables.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@23110 b3059339-0415-0410-9bf9-f77b7e298cf2
2007-04-25 08:35:35 +00:00
michael 3b3181fefd reasonable cutoff frequency default
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@22773 b3059339-0415-0410-9bf9-f77b7e298cf2
2007-03-22 01:50:04 +00:00