Commit Graph

376 Commits

Author SHA1 Message Date
eugeni bebbe6557b Cosmetics: reindent.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@28977 b3059339-0415-0410-9bf9-f77b7e298cf2
2009-03-16 19:26:23 +00:00
eugeni bc1d60dcb7 Fix uninitialized memory access in ass_fontconfig.
This fixes hangups with plaintext subtitles happening when
the first subtitle is about to be displayed.

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@28976 b3059339-0415-0410-9bf9-f77b7e298cf2
2009-03-16 19:26:19 +00:00
greg a0735f5859 Use ScaledBorderAndShadow: yes by default.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@28935 b3059339-0415-0410-9bf9-f77b7e298cf2
2009-03-11 22:55:23 +00:00
eugeni 79b9156732 Cosmetics: reindent.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@28896 b3059339-0415-0410-9bf9-f77b7e298cf2
2009-03-08 16:13:26 +00:00
eugeni 686d57168f Treat -font/-subfont as Fontconfig pattern in libass.
Patch by Adrian Stutz (adrian sttz ch).

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@28895 b3059339-0415-0410-9bf9-f77b7e298cf2
2009-03-08 16:13:21 +00:00
greg 2a70f019e9 Remove extraneous braces.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@28892 b3059339-0415-0410-9bf9-f77b7e298cf2
2009-03-08 15:30:40 +00:00
greg af0797010e Don't assume width == stride for bitmap composition.
Fixes http://bugzilla.mplayerhq.hu/show_bug.cgi?id=1421

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@28891 b3059339-0415-0410-9bf9-f77b7e298cf2
2009-03-08 15:30:27 +00:00
greg 2c55cbabf9 Fix clipping for pan-and-scan.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@28876 b3059339-0415-0410-9bf9-f77b7e298cf2
2009-03-08 04:03:28 +00:00
greg eb3f82bfee Add a proper color check to the overlap compositing.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@28875 b3059339-0415-0410-9bf9-f77b7e298cf2
2009-03-08 04:03:24 +00:00
greg 668810ab04 Replace rotation functions with a simplified version adapted from
vsfilter.

This (mostly) fixes http://bugzilla.mplayerhq.hu/show_bug.cgi?id=1394#c7

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@28874 b3059339-0415-0410-9bf9-f77b7e298cf2
2009-03-08 02:53:14 +00:00
greg 463d61c7a6 Only use first \org in a line.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@28873 b3059339-0415-0410-9bf9-f77b7e298cf2
2009-03-07 23:56:03 +00:00
greg 27b512e1f5 Fix \be blur start position.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@28837 b3059339-0415-0410-9bf9-f77b7e298cf2
2009-03-06 09:20:14 +00:00
greg 25abe9651d Raise max. number of \be applications to 100, introduce #define for it.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@28836 b3059339-0415-0410-9bf9-f77b7e298cf2
2009-03-06 09:20:09 +00:00
greg d303d39798 Replace magic numbers (for subpixel accuracy masking) with a define.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@28835 b3059339-0415-0410-9bf9-f77b7e298cf2
2009-03-06 01:26:44 +00:00
greg d4423f7516 Use blur with kernel [[1,2,1], [2,4,2], [1,2,1]] for \be.
This is faster than gaussian blur and similar to vsfilter.

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@28834 b3059339-0415-0410-9bf9-f77b7e298cf2
2009-03-06 01:17:05 +00:00
greg 9bad4bdce4 Combine adjacent overlapping, translucent glyph borders and shadows to
avoid luminance build-up, which looks ugly.

The resulting, modified bitmaps are stored in separate bitmap cache.

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@28824 b3059339-0415-0410-9bf9-f77b7e298cf2
2009-03-05 20:47:33 +00:00
greg 8ad008e12a Fix positioned events' y-position when pan-and-scan is used.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@28823 b3059339-0415-0410-9bf9-f77b7e298cf2
2009-03-05 20:36:59 +00:00
greg f9aba2b83a Support for subpixel accuracy of 3 bits for \pos and \move.
Also, restrict advance subpixel accuracy to 3 bits to reduce cache
bloat.

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@28822 b3059339-0415-0410-9bf9-f77b7e298cf2
2009-03-05 20:36:56 +00:00
greg 40a38da7db Style override for ScaledBorderAndShadow.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@28821 b3059339-0415-0410-9bf9-f77b7e298cf2
2009-03-05 20:36:52 +00:00
greg 2432bbd43d Support ScaledBorderAndShadow property.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@28820 b3059339-0415-0410-9bf9-f77b7e298cf2
2009-03-05 20:36:48 +00:00
greg a2b82120c0 Scale shadow displacement and blur size like border size.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@28819 b3059339-0415-0410-9bf9-f77b7e298cf2
2009-03-05 20:36:44 +00:00
greg c23a1cdfb3 Round shadow displacement to nearest int.
Use double for shadow displacement parameter.

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@28818 b3059339-0415-0410-9bf9-f77b7e298cf2
2009-03-05 20:36:41 +00:00
greg a2020815ad Support a vsfilter special case:
If PlayResX or Y is 1280/1024 respectively and the other
PlayRes attribute isn't provided, use 1280/1024 for it.

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@28817 b3059339-0415-0410-9bf9-f77b7e298cf2
2009-03-05 20:36:39 +00:00
greg 153e7ada4c Hack: half-merge glyph border with outline to avoid ugly anti-aliasing
in certain situations.

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@28816 b3059339-0415-0410-9bf9-f77b7e298cf2
2009-03-05 20:36:35 +00:00
greg 16731f6349 Ignore PlayResX/Y aspect ratio for font aspect ratio.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@28814 b3059339-0415-0410-9bf9-f77b7e298cf2
2009-03-05 20:05:56 +00:00
eugeni 20a2db7dfd Fix a memory leak.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@28787 b3059339-0415-0410-9bf9-f77b7e298cf2
2009-03-01 19:31:29 +00:00
eugeni 9c8a334cc5 With pan-and-scan, keep positioned events in their original positions
relative to video.

Patch by Grigori Goronzy (greg chown ath cx).

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@28783 b3059339-0415-0410-9bf9-f77b7e298cf2
2009-03-01 16:01:24 +00:00
eugeni 15ed6e0199 Zero-fill glyph_info_t before use.
Patch by Grigori G (greg chown ath cx).

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@28754 b3059339-0415-0410-9bf9-f77b7e298cf2
2009-02-27 23:06:53 +00:00
eugeni 69ce550ee0 Remove unused function argument.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@28753 b3059339-0415-0410-9bf9-f77b7e298cf2
2009-02-27 23:06:50 +00:00
eugeni 00d6bb12b9 Support fractional arguments for some override tags.
Done by parsing all integers as doubles first and then converting them to the
nearest integer. Patch by Grigori G (greg chown ath cx).

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@28752 b3059339-0415-0410-9bf9-f77b7e298cf2
2009-02-27 23:06:47 +00:00
eugeni a1f50bf348 Fix two gcc warnings.
Patch by Grigori G (greg chown ath cx).

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@28751 b3059339-0415-0410-9bf9-f77b7e298cf2
2009-02-27 23:06:43 +00:00
eugeni bcad979a56 Fix memory leak produced by the \blur patch.
Patch by Grigori G (greg chown ath cx).

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@28750 b3059339-0415-0410-9bf9-f77b7e298cf2
2009-02-27 23:06:40 +00:00
eugeni b84c1b627f Stronger blur.
Patch by Grigori G (greg chown ath cx).

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@28749 b3059339-0415-0410-9bf9-f77b7e298cf2
2009-02-27 23:06:37 +00:00
eugeni 909f7b0c14 Allow shadow without border.
Patch by Grigori G (greg chown ath cx).

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@28748 b3059339-0415-0410-9bf9-f77b7e298cf2
2009-02-27 23:06:34 +00:00
eugeni 98c80613c6 In case of several \move or \pos in one line, prefer the first one.
Patch by Grigori G, greg at chown ath cx.

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@28473 b3059339-0415-0410-9bf9-f77b7e298cf2
2009-02-07 01:13:11 +00:00
eugeni 4fdc9591b4 Add stubs for a few unimplemented tags.
Patch by Grigori G, greg at chown ath cx.

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@28472 b3059339-0415-0410-9bf9-f77b7e298cf2
2009-02-07 01:13:07 +00:00
eugeni 94ea507ec2 Allow \be with arguments other than 0 or 1. Implement \blur.
Patch by Grigori G, greg at chown ath cx.

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@28471 b3059339-0415-0410-9bf9-f77b7e298cf2
2009-02-07 01:13:02 +00:00
compn c312c67753 increase max glyph and lines limit
patch by Scaevolus on irc
fixes http://samples.mplayerhq.hu/Matroska/subtitles/090128_gszs02.mkv


git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@28386 b3059339-0415-0410-9bf9-f77b7e298cf2
2009-01-29 02:23:06 +00:00
diego 0864f92e7a Get rid of pointless 'extern' keywords.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@28085 b3059339-0415-0410-9bf9-f77b7e298cf2
2008-12-03 23:01:03 +00:00
reimar c1c59ce8cd Consistently use NULL for pointers instead of 0.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@27876 b3059339-0415-0410-9bf9-f77b7e298cf2
2008-11-02 11:48:20 +00:00
reimar 1ae7149c08 Fallback to non-fontconfig behaviour when fontconfig initialization fails.
Also fixes a memleak in that case, bug #1313.


git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@27875 b3059339-0415-0410-9bf9-f77b7e298cf2
2008-11-02 09:57:22 +00:00
aurel 11d6f1fd2d libass: fix type mismatch between size parameter and the way it's used
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@27531 b3059339-0415-0410-9bf9-f77b7e298cf2
2008-09-05 22:59:01 +00:00
aurel 81058d5af2 libass: add a new ass_process_data() to process demuxed subtitle packets
conforming to the ASS spec


git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@27530 b3059339-0415-0410-9bf9-f77b7e298cf2
2008-09-05 15:07:06 +00:00
eugeni e1ce107366 Don't print drawing commands on screen.
Drawing mode is not implemented in libass.


git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@27442 b3059339-0415-0410-9bf9-f77b7e298cf2
2008-08-08 20:08:02 +00:00
eugeni 6c857af5c0 If (has outline) blur(outline) else blur(glyph).
If there is an outline, the glyph itself should not be blurred. Keeps
the border between glyph and outline clear (unblurred), which is
probably how it should be.

Patch by Diogo Franco (diogomfranco gmail com).


git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@27441 b3059339-0415-0410-9bf9-f77b7e298cf2
2008-08-07 22:20:58 +00:00
eugeni a925925543 \org turns off collision detection.
Patch by Diogo Franco (diogomfranco gmail com).


git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@27440 b3059339-0415-0410-9bf9-f77b7e298cf2
2008-08-07 22:20:56 +00:00
eugeni 6c92d9358b Treat \h as space character.
Patch by Robert Rudd (robrudd at users sourceforge net).


git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@27439 b3059339-0415-0410-9bf9-f77b7e298cf2
2008-08-07 22:20:54 +00:00
eugeni 054f28e2d1 Calculate subtitle origin in floating point.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@27438 b3059339-0415-0410-9bf9-f77b7e298cf2
2008-08-07 22:20:52 +00:00
eugeni 1670e33e21 Calculate subtitle position in floating point.
Improves subtitle position precision from a unit of script coordinates
to a screen pixel.


git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@27437 b3059339-0415-0410-9bf9-f77b7e298cf2
2008-08-07 22:20:50 +00:00
diego 091d352d06 Rename font-related preprocessor directives.
Switch them from a HAVE_ to a CONFIG_ prefix.


git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@27425 b3059339-0415-0410-9bf9-f77b7e298cf2
2008-08-07 10:36:07 +00:00