Commit Graph

24902 Commits

Author SHA1 Message Date
diego ab990585e5 Add missing #include to fix GNU/kFreeBSD compilation, see Debian bug #448791.
patch by Petr Salinger, Petr.Salinger seznam cz


git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@24929 b3059339-0415-0410-9bf9-f77b7e298cf2
2007-11-01 23:33:51 +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 aa657df525 Make output samplerate independent of -speed
The samplerate requested from the audio out depended on the initial
value of playback speed on startup. Changing speed later at runtime
does not affect output samplerate; audio is always resampled instead.
Change the init code so that speed does not affect the samplerate
requested and behavior matches what you'd get by starting the file
with speed 1 and then changing it.

The previous behavior could be desirable when using a constant speed
value. However it means that if you start with a low speed and later
switch to normal speed then audio will be resampled to a low output
frequency. You can still use -srate to explicitly select the frequency.


git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@24923 b3059339-0415-0410-9bf9-f77b7e298cf2
2007-11-01 06:52:32 +00:00
uau 6338c068a2 Simplify init_audio_filters() arguments
Remove the following arguments as redundant: in_channels, in_format,
out_minsize, out_maxsize. The first two always equal fields of the
sh_audio_t struct given as the first argument to the function. The
last two are unused after the allocation of sh_audio->a_out_buffer
was changed to be done on demand.

After the out_minsize and out_maxsize arguments are removed the
function preinit_audio_filters() is identical to init_audio_filters(),
so remove it and use the latter instead.


git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@24922 b3059339-0415-0410-9bf9-f77b7e298cf2
2007-11-01 06:52:28 +00:00
uau 2d44426648 audio: simplify buffer allocation code
Remove the code allocating sh_audio->a_out_buffer from
init_audio_filters() and let the buffer be allocated by the new
dynamic allocation code.


git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@24921 b3059339-0415-0410-9bf9-f77b7e298cf2
2007-11-01 06:52:23 +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 a6d6f18216 Clean up some fields in stheader.h structs
sh_video_t: void *video_out: only assigned to, never read. Remove.
sh_video_t: void *vfilter: change type to struct vf_instance_s *
sh_audio_t: void *afilter: change type to struct af_stream_s *

The latter two never hold different types so there's no reason to use
void *. Maybe they were originally defined that way because the
option of using pointers to incomplete struct types was missed (the
typedefs vf_instance_t and af_stream_t would require extra headers)?


git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@24919 b3059339-0415-0410-9bf9-f77b7e298cf2
2007-11-01 06:52:14 +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
uau 3e8ab86642 Replace hopefully unreachable code with abort()
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@24914 b3059339-0415-0410-9bf9-f77b7e298cf2
2007-11-01 06:51:53 +00:00
uau 9e796deb33 dec_audio.c: Make some functions static
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@24913 b3059339-0415-0410-9bf9-f77b7e298cf2
2007-11-01 06:51:49 +00:00
uau 244bd237fb Simplify audio buffer allocation logic
Remove code that set sh_audio->a_out_buffer to equal
sh_audio->a_buffer between the calls to init_best_audio_codec and
init_audio_filters. Nothing uses the buffer between those calls.


git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@24912 b3059339-0415-0410-9bf9-f77b7e298cf2
2007-11-01 06:51:44 +00:00
uau 8338fa9ecf Reindent dec_audio.c
Also remove some commented out code


git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@24911 b3059339-0415-0410-9bf9-f77b7e298cf2
2007-11-01 06:51:38 +00:00
voroshil a5caea539b typo
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@24910 b3059339-0415-0410-9bf9-f77b7e298cf2
2007-11-01 03:11:59 +00:00
diego 8e7679b77e Escape some more '-' where appropriate.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@24909 b3059339-0415-0410-9bf9-f77b7e298cf2
2007-10-31 09:44:34 +00:00
ptt 60472f93ac corrected vqscale indentation
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@24908 b3059339-0415-0410-9bf9-f77b7e298cf2
2007-10-31 09:40:33 +00:00
zuxy 68dc8b557f Remove paragraph that no long applies: runtime SSE detection on Windows.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@24907 b3059339-0415-0410-9bf9-f77b7e298cf2
2007-10-31 02:16:58 +00:00
ulion bc81f68d3a Fix input.conf parse bug when comment follows key binding in the same line.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@24906 b3059339-0415-0410-9bf9-f77b7e298cf2
2007-10-31 01:23:33 +00:00
diego 3926a40d49 Remove outdated Hungarian translation of the playtree documentation.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@24905 b3059339-0415-0410-9bf9-f77b7e298cf2
2007-10-30 23:13:51 +00:00
cehoyos 0602bf1fdd Add a backslash.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@24904 b3059339-0415-0410-9bf9-f77b7e298cf2
2007-10-30 22:35:42 +00:00
nicodvb 3d1e0439ea removed unused variables and parameters
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@24903 b3059339-0415-0410-9bf9-f77b7e298cf2
2007-10-30 22:30:15 +00:00
compn 08e0319d59 spelling
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@24902 b3059339-0415-0410-9bf9-f77b7e298cf2
2007-10-30 21:18:39 +00:00
compn 2ff75864de remove thanks
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@24901 b3059339-0415-0410-9bf9-f77b7e298cf2
2007-10-30 21:18:07 +00:00
diego 4873936eb8 Explain the difference between '-' and '\-', correctly now.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@24900 b3059339-0415-0410-9bf9-f77b7e298cf2
2007-10-30 17:42:24 +00:00
diego 14c25c122f movie player for Linux --> movie player
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@24899 b3059339-0415-0410-9bf9-f77b7e298cf2
2007-10-30 17:39:55 +00:00
diego 345336399c Add some missing escapes for '-'.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@24898 b3059339-0415-0410-9bf9-f77b7e298cf2
2007-10-30 17:25:30 +00:00
diego d62943e7a2 Consistently use \- in option names.
In roff '-' is used for hyphens while '\-' is used for minus and en/em-dashes.


git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@24897 b3059339-0415-0410-9bf9-f77b7e298cf2
2007-10-30 17:09:46 +00:00
diego 523a3fdf11 Remove unused variable:
demux_lavf.c:441: warning: unused variable 'g'


git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@24896 b3059339-0415-0410-9bf9-f77b7e298cf2
2007-10-30 15:49:53 +00:00
diego 625098b0ac Comment out uninit function, its use is commented out. Fixes warning:
vf_yuvcsp.c:66: warning: 'uninit' defined but not used


git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@24895 b3059339-0415-0410-9bf9-f77b7e298cf2
2007-10-30 15:31:45 +00:00
diego f468804293 Remove commented-out and unused fmt_list array.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@24894 b3059339-0415-0410-9bf9-f77b7e298cf2
2007-10-30 15:27:13 +00:00
diego 80e1a70e8a Remove unused fmt_list array, fixes the warnings:
vf_ow.c:296: warning: 'fmt_list' defined but not used
vf_spp.c:544: warning: 'fmt_list' defined but not used
vf_uspp.c:334: warning: 'fmt_list' defined but not used


git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@24893 b3059339-0415-0410-9bf9-f77b7e298cf2
2007-10-30 15:24:09 +00:00
compn 82eef16f4d move errors and a warning to help_mp-en.h
so they can be translated.


git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@24892 b3059339-0415-0410-9bf9-f77b7e298cf2
2007-10-30 13:15:41 +00:00
diego 4e39ea3dfe Remove unused functions, fixes the warnings:
vf_2xsai.c:80: warning: 'GetResult1' defined but not used
vf_2xsai.c💯 warning: 'GetResult2' defined but not used


git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@24891 b3059339-0415-0410-9bf9-f77b7e298cf2
2007-10-30 09:10:01 +00:00
diego 8136f60409 Disable clear_screen function, the call to the function is commented out
due to buggyness. Fixes the warning:
vo_tdfx_vid.c:78: warning: 'clear_screen' defined but not used


git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@24890 b3059339-0415-0410-9bf9-f77b7e298cf2
2007-10-30 08:55:29 +00:00
diego 94e3b4a0f7 Comment out unused variable, fixes the warning:
dvb_tune.c:43: warning: 'dvb_secdev' defined but not used


git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@24889 b3059339-0415-0410-9bf9-f77b7e298cf2
2007-10-30 08:44:15 +00:00
diego 4de99aade1 Remove unused functions, fixes the warnings:
pnm.c:853: warning: 'pnm_peek_header' defined but not used
pnm.c:859: warning: 'pnm_close' defined but not used


git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@24888 b3059339-0415-0410-9bf9-f77b7e298cf2
2007-10-30 08:14:41 +00:00
diego 33772c1065 Disable function that is only used in disabled code, fixes warning:
yuv4mpeg.c:147: warning: 'y4m_snprint_xtags' defined but not used


git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@24887 b3059339-0415-0410-9bf9-f77b7e298cf2
2007-10-30 08:06:39 +00:00
diego 4f01d9c698 sync with FFmpeg r10874
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@24886 b3059339-0415-0410-9bf9-f77b7e298cf2
2007-10-30 07:54:56 +00:00
zuxy 4e927b4d21 Detect IPv6 support on Windows
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@24885 b3059339-0415-0410-9bf9-f77b7e298cf2
2007-10-30 02:44:17 +00:00
lu_zero 18acd7224d Fix fps guessing
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@24884 b3059339-0415-0410-9bf9-f77b7e298cf2
2007-10-29 19:24:55 +00:00
lu_zero dcf5dda469 Update to use newer libnemesi, should fix desync, fps guessing may fail now
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@24883 b3059339-0415-0410-9bf9-f77b7e298cf2
2007-10-29 18:31:47 +00:00
rtogni ec70a0fbbd Change the frame format passed to lavc realvideo decoders to adapt for
the changes in r10825.



git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@24882 b3059339-0415-0410-9bf9-f77b7e298cf2
2007-10-28 22:32:20 +00:00
gpoirier d08a99c12a sync w/r24875
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@24881 b3059339-0415-0410-9bf9-f77b7e298cf2
2007-10-28 21:29:00 +00:00
iive b69670151c Cleanup guess_buffer_cp() a bit, remove tmp variable, break the loop on success.
Requested by ulion.


git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@24880 b3059339-0415-0410-9bf9-f77b7e298cf2
2007-10-28 15:53:08 +00:00