summaryrefslogtreecommitdiffstats
path: root/libass/ass_render.c
Commit message (Collapse)AuthorAgeFilesLines
* Update internal libass copy to commit 8db4a5greg2010-01-081-2301/+2360
| | | | git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@30242 b3059339-0415-0410-9bf9-f77b7e298cf2
* Fix stupid, off-by-one, mistakes in assert() expressions.eugeni2009-07-271-2/+2
| | | | git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@29448 b3059339-0415-0410-9bf9-f77b7e298cf2
* Make sure clip coordinates are inside the screen area.eugeni2009-07-181-0/+11
| | | | git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@29425 b3059339-0415-0410-9bf9-f77b7e298cf2
* Cosmetics: make some variables constant to signify their intended use and,eugeni2009-07-181-6/+5
| | | | | | | therefore, improve code readability. git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@29424 b3059339-0415-0410-9bf9-f77b7e298cf2
* Fix read after the end of allocated buffer.eugeni2009-07-181-6/+17
| | | | git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@29423 b3059339-0415-0410-9bf9-f77b7e298cf2
* whitespace cosmetics: Remove all trailing whitespace.diego2009-05-131-54/+54
| | | | git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@29305 b3059339-0415-0410-9bf9-f77b7e298cf2
* Don't automatically wrap lines when WrapStyle==2.eugeni2009-04-211-1/+1
| | | | | | \n and \N still work. git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@29219 b3059339-0415-0410-9bf9-f77b7e298cf2
* Document the ass_render_event event_images parameter.reimar2009-03-281-0/+1
| | | | git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@29087 b3059339-0415-0410-9bf9-f77b7e298cf2
* Initialize all structs to 0 before using them.reimar2009-03-281-0/+3
| | | | | | | | | | This is consistent with the remaining code (which uses e.g. calloc) and makes it easier to extend the structs in the future. As a side effect it fixes several valgrind errors in hashmap_hash/hashmap_key_compare caused by padding in the structures, but it is not a correct fix for that issue. git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@29086 b3059339-0415-0410-9bf9-f77b7e298cf2
* Treat -font/-subfont as Fontconfig pattern in libass.eugeni2009-03-081-0/+3
| | | | | | Patch by Adrian Stutz (adrian sttz ch). git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@28895 b3059339-0415-0410-9bf9-f77b7e298cf2
* Remove extraneous braces.greg2009-03-081-4/+4
| | | | git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@28892 b3059339-0415-0410-9bf9-f77b7e298cf2
* Don't assume width == stride for bitmap composition.greg2009-03-081-6/+8
| | | | | | 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
* Fix clipping for pan-and-scan.greg2009-03-081-4/+6
| | | | git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@28876 b3059339-0415-0410-9bf9-f77b7e298cf2
* Add a proper color check to the overlap compositing.greg2009-03-081-0/+3
| | | | git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@28875 b3059339-0415-0410-9bf9-f77b7e298cf2
* Replace rotation functions with a simplified version adapted fromgreg2009-03-081-79/+40
| | | | | | | | 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
* Only use first \org in a line.greg2009-03-071-4/+6
| | | | git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@28873 b3059339-0415-0410-9bf9-f77b7e298cf2
* Raise max. number of \be applications to 100, introduce #define for it.greg2009-03-061-2/+3
| | | | git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@28836 b3059339-0415-0410-9bf9-f77b7e298cf2
* Replace magic numbers (for subpixel accuracy masking) with a define.greg2009-03-061-4/+5
| | | | git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@28835 b3059339-0415-0410-9bf9-f77b7e298cf2
* Use blur with kernel [[1,2,1], [2,4,2], [1,2,1]] for \be.greg2009-03-061-5/+1
| | | | | | 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
* Combine adjacent overlapping, translucent glyph borders and shadows togreg2009-03-051-1/+106
| | | | | | | | 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
* Fix positioned events' y-position when pan-and-scan is used.greg2009-03-051-2/+7
| | | | git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@28823 b3059339-0415-0410-9bf9-f77b7e298cf2
* Support for subpixel accuracy of 3 bits for \pos and \move.greg2009-03-051-15/+20
| | | | | | | 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
* Support ScaledBorderAndShadow property.greg2009-03-051-1/+4
| | | | git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@28820 b3059339-0415-0410-9bf9-f77b7e298cf2
* Scale shadow displacement and blur size like border size.greg2009-03-051-3/+3
| | | | git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@28819 b3059339-0415-0410-9bf9-f77b7e298cf2
* Round shadow displacement to nearest int.greg2009-03-051-4/+5
| | | | | | Use double for shadow displacement parameter. git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@28818 b3059339-0415-0410-9bf9-f77b7e298cf2
* Support a vsfilter special case:greg2009-03-051-1/+7
| | | | | | | 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
* Ignore PlayResX/Y aspect ratio for font aspect ratio.greg2009-03-051-4/+1
| | | | git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@28814 b3059339-0415-0410-9bf9-f77b7e298cf2
* With pan-and-scan, keep positioned events in their original positionseugeni2009-03-011-1/+5
| | | | | | | | 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
* Zero-fill glyph_info_t before use.eugeni2009-02-271-1/+1
| | | | | | Patch by Grigori G (greg chown ath cx). git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@28754 b3059339-0415-0410-9bf9-f77b7e298cf2
* Remove unused function argument.eugeni2009-02-271-40/+40
| | | | git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@28753 b3059339-0415-0410-9bf9-f77b7e298cf2
* Support fractional arguments for some override tags.eugeni2009-02-271-21/+25
| | | | | | | 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
* Fix two gcc warnings.eugeni2009-02-271-2/+2
| | | | | | Patch by Grigori G (greg chown ath cx). git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@28751 b3059339-0415-0410-9bf9-f77b7e298cf2
* Allow shadow without border.eugeni2009-02-271-6/+3
| | | | | | Patch by Grigori G (greg chown ath cx). git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@28748 b3059339-0415-0410-9bf9-f77b7e298cf2
* In case of several \move or \pos in one line, prefer the first one.eugeni2009-02-071-8/+12
| | | | | | Patch by Grigori G, greg at chown ath cx. git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@28473 b3059339-0415-0410-9bf9-f77b7e298cf2
* Add stubs for a few unimplemented tags.eugeni2009-02-071-1/+39
| | | | | | Patch by Grigori G, greg at chown ath cx. git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@28472 b3059339-0415-0410-9bf9-f77b7e298cf2
* Allow \be with arguments other than 0 or 1. Implement \blur.eugeni2009-02-071-6/+28
| | | | | | Patch by Grigori G, greg at chown ath cx. git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@28471 b3059339-0415-0410-9bf9-f77b7e298cf2
* increase max glyph and lines limitcompn2009-01-291-2/+2
| | | | | | | | 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
* Don't print drawing commands on screen.eugeni2008-08-081-1/+12
| | | | | | | Drawing mode is not implemented in libass. git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@27442 b3059339-0415-0410-9bf9-f77b7e298cf2
* \org turns off collision detection.eugeni2008-08-071-0/+1
| | | | | | | Patch by Diogo Franco (diogomfranco gmail com). git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@27440 b3059339-0415-0410-9bf9-f77b7e298cf2
* Treat \h as space character.eugeni2008-08-071-1/+1
| | | | | | | Patch by Robert Rudd (robrudd at users sourceforge net). git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@27439 b3059339-0415-0410-9bf9-f77b7e298cf2
* Calculate subtitle origin in floating point.eugeni2008-08-071-1/+1
| | | | git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@27438 b3059339-0415-0410-9bf9-f77b7e298cf2
* Calculate subtitle position in floating point.eugeni2008-08-071-7/+7
| | | | | | | | 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
* Fix \fn without an argument consuming the next '\'.eugeni2008-07-091-6/+7
| | | | git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@27242 b3059339-0415-0410-9bf9-f77b7e298cf2
* Speak of libass instead of MPlayer in the libass license headers.diego2008-05-141-4/+4
| | | | | | | | We already use LIBASS_ prefixes for the multiple inclusion guards. Thus libass can be considered separate enough to warrant this. git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@26770 b3059339-0415-0410-9bf9-f77b7e298cf2
* Use standard license header.diego2008-05-131-16/+18
| | | | git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@26755 b3059339-0415-0410-9bf9-f77b7e298cf2
* Remove libass dependency on global font_fontconfig variable.eugeni2008-04-301-2/+12
| | | | | | | | | A new function (ass_set_fonts_nofc) is introduced instead of an extra argument to existing ass_set_fonts to keep binary compatibility with older versions of the library. git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@26614 b3059339-0415-0410-9bf9-f77b7e298cf2
* Better handling of behind-the-camera objects.eugeni2008-02-221-2/+3
| | | | | | | | | Every point that is behind the camera is moved to the clipping plane by orthographic projection. It is obviously incorrect, but this is a very rare case, and proper clipping of Bezier curves is not that easy. git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@26065 b3059339-0415-0410-9bf9-f77b7e298cf2
* Print FreeType version in libass init. Makes error logs slightly more helpful.eugeni2008-02-221-0/+7
| | | | git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@26064 b3059339-0415-0410-9bf9-f77b7e298cf2
* Return from ass_start_frame immediately if the track is empty.eugeni2007-12-301-0/+3
| | | | git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@25541 b3059339-0415-0410-9bf9-f77b7e298cf2
* Avoid text deformation and subtitles moving outside the screen in pan-and-scaneugeni2007-10-191-7/+20
| | | | | | | | | | | | mode. For this, crop amounts are passed from vo_gl as negative margins sizes. They are used to calculate aspect ratio. They are ignored when calculating subtitle positions, so subtitles will stay on screen most of the time. Based on a patch by Jindrich Makovicka [makovick gmail com]. git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@24815 b3059339-0415-0410-9bf9-f77b7e298cf2
* More precise line spacing.eugeni2007-09-181-1/+1
| | | | git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@24577 b3059339-0415-0410-9bf9-f77b7e298cf2
* Fix text height calculation. It depends on line spacing.eugeni2007-09-181-0/+1
| | | | git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@24576 b3059339-0415-0410-9bf9-f77b7e298cf2
* Fix an obviously incorrect comment.eugeni2007-09-181-1/+0
| | | | git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@24575 b3059339-0415-0410-9bf9-f77b7e298cf2
* Enable ass_line_spacing option.eugeni2007-09-181-0/+5
| | | | | | | Patch by Thomas Reitmayr (treitmayr devbase at). git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@24574 b3059339-0415-0410-9bf9-f77b7e298cf2
* Correct font size in libass.eugeni2007-05-191-3/+1
| | | | | | | | | Values from TrueType OS/2 table are used to reproduce VSFilter behaviour. Magic 0.8 multiplier and scaling for the fractional part of font size are not needed anymore. git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@23346 b3059339-0415-0410-9bf9-f77b7e298cf2
* Revert y-axis rotation. Change order of rotations.eugeni2007-05-181-4/+5
| | | | | | | | | Now rotations are performed in the following order: X, Y, Z. Before this, it was the other way around. Also, in FreeType Y axis is directed upwards, so the corresponding rotation must be reverted. git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@23340 b3059339-0415-0410-9bf9-f77b7e298cf2
* Support fractional font sizes.eugeni2007-05-141-4/+4
| | | | git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@23318 b3059339-0415-0410-9bf9-f77b7e298cf2
* Limit ass_font_set_transform to nonrotating transformations.eugeni2007-05-141-9/+4
| | | | | | | | Rotations are not needed here (they are performed in transform3d) and they disable autohinter. git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@23317 b3059339-0415-0410-9bf9-f77b7e298cf2
* Deallocate string.eugeni2007-05-031-0/+1
| | | | git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@23231 b3059339-0415-0410-9bf9-f77b7e298cf2
* Always deallocate glyphs. Fixes memory leak.eugeni2007-05-021-5/+5
| | | | git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@23208 b3059339-0415-0410-9bf9-f77b7e298cf2
* Update comments.eugeni2007-05-011-11/+25
| | | | git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@23197 b3059339-0415-0410-9bf9-f77b7e298cf2
* Cosmetics.eugeni2007-05-011-4/+4
| | | | git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@23196 b3059339-0415-0410-9bf9-f77b7e298cf2
* Move glyph_to_bitmap() call and outline glyph deallocation toeugeni2007-05-011-30/+22
| | | | | | | get_bitmap_glyph(). git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@23195 b3059339-0415-0410-9bf9-f77b7e298cf2
* Minor code simplification.eugeni2007-05-011-14/+16
| | | | git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@23193 b3059339-0415-0410-9bf9-f77b7e298cf2
* Move get_bitmap_glyph() call to a separate loop.eugeni2007-05-011-1/+3
| | | | git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@23192 b3059339-0415-0410-9bf9-f77b7e298cf2
* Move transform_3d() call to get_bitmap_glyph().eugeni2007-05-011-10/+9
| | | | git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@23191 b3059339-0415-0410-9bf9-f77b7e298cf2
* Make a function static.eugeni2007-05-011-1/+1
| | | | git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@23190 b3059339-0415-0410-9bf9-f77b7e298cf2
* Don't recalculate rotation radius. eugeni2007-05-011-2/+2
| | | | git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@23189 b3059339-0415-0410-9bf9-f77b7e298cf2
* Bugfix: glyph cache depends on border width, because it contains outline_glypheugeni2007-05-011-0/+1
| | | | | | | (glyph border obtained with FT_Glyph_StrokeBorder) since r23043. git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@23188 b3059339-0415-0410-9bf9-f77b7e298cf2
* Add -ass-hinting option for setting font hinting method.eugeni2007-04-271-1/+10
| | | | | | | | | It is possible to separately configure hinting for scaled and unscaled osd. The default is native hinter for unscaled osd (only vo_gl at this point), no hinting for vf_ass. git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@23152 b3059339-0415-0410-9bf9-f77b7e298cf2
* Fix division by zero in "\t" parsing.eugeni2007-04-271-3/+6
| | | | git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@23151 b3059339-0415-0410-9bf9-f77b7e298cf2
* Do not use FT_Glyph_Copy with NULL glyphs.eugeni2007-04-241-2/+5
| | | | | | | Contrary to the docs, it leaves garbage in *target. git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@23104 b3059339-0415-0410-9bf9-f77b7e298cf2
* Deallocate glyphs in a separate loop.eugeni2007-04-211-0/+3
| | | | git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@23054 b3059339-0415-0410-9bf9-f77b7e298cf2
* Always deallocate glyphs. Fixes a memory leak.eugeni2007-04-211-3/+4
| | | | git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@23053 b3059339-0415-0410-9bf9-f77b7e298cf2
*