summaryrefslogtreecommitdiffstats
path: root/libass/ass_cache.c
Commit message (Collapse)AuthorAgeFilesLines
* Remove internal libass treeUoti Urpala2009-07-261-385/+0
| | | | | Remove the libass/ directory and use the newest standalone version of the library instead.
* Remove trailing whitespace from most filesUoti Urpala2009-07-071-4/+3
|
* Merge svn changes up to r28951Uoti Urpala2009-03-141-0/+2
|\
| * Treat -font/-subfont as Fontconfig pattern in libass.eugeni2009-03-081-0/+2
| | | | | | | | | | | | Patch by Adrian Stutz (adrian sttz ch). git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@28895 b3059339-0415-0410-9bf9-f77b7e298cf2
* | Merge svn changes up to r28862Uoti Urpala2009-03-071-0/+50
|\|
| * Combine adjacent overlapping, translucent glyph borders and shadows togreg2009-03-051-0/+50
| | | | | | | | | | | | | | | | 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
* | libass: Fix cache lookup problem causing memory bloatUoti Urpala2008-12-221-2/+10
|/ | | | | | | | | | | | | | | | | | | | | | The cache code did hash lookups by storing key values in struct fields and then hashing and comparing the struct as a single memory block. In at least one case such a struct contained uninitialized padding bytes which prevented the complete memory area of the struct from matching even though the fields did. As a result the code failed to find existing objects in the cache and stored new versions of them, causing gigabytes of memory use in some circumstances. Initializing the struct memory to zero before writing the fields avoided such memory use in tests but is not guaranteed to work if I interpret the C standard correctly (the compiler is allowed to write garbage over padding bytes when changing struct member values). Change the code to use struct-specific hashing and comparison functions that work field by field to guarantee correct behavior. Create these by replacing the struct definition with a template that lists the fields and can be used the generate each of struct definition, hash function and compare function with some preprocessor magic (otherwise every field would need to be listed separately in all three).
* cosmetics: Remove useless parentheses from return statements.diego2008-05-161-1/+1
| | | | git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@26791 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
* Fix stupid bug in r23229.eugeni2007-05-031-1/+1
| | | | git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@23232 b3059339-0415-0410-9bf9-f77b7e298cf2
* Make cache_*_add functions return the pointer to new (copied) value.eugeni2007-05-031-7/+8
| | | | git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@23229 b3059339-0415-0410-9bf9-f77b7e298cf2
* Store outline_glyph (glyph border) in glyph cache.eugeni2007-04-201-0/+1
| | | | git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@23043 b3059339-0415-0410-9bf9-f77b7e298cf2
* Oops, fix compilation broken in r23037.eugeni2007-04-201-1/+1
| | | | git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@23038 b3059339-0415-0410-9bf9-f77b7e298cf2
* Collect hit/miss statistic in hash map, and print in -v mode.eugeni2007-04-201-2/+11
| | | | git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@23037 b3059339-0415-0410-9bf9-f77b7e298cf2
* Add outline glyph cache (unused yet).eugeni2007-04-201-0/+46
| | | | git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@23036 b3059339-0415-0410-9bf9-f77b7e298cf2
* Rename glyph cache to bitmap cache.eugeni2007-04-201-18/+18
| | | | git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@23035 b3059339-0415-0410-9bf9-f77b7e298cf2
* Add generic hash map implementation.eugeni2007-04-201-120/+167
| | | | | | | Reimplement both font cache and glyph cache on top of it. git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@23034 b3059339-0415-0410-9bf9-f77b7e298cf2
* Add some missing includes.eugeni2007-02-221-0/+1
| | | | git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@22310 b3059339-0415-0410-9bf9-f77b7e298cf2
* Implement \frx and \fry (and reimplement \frz) as 3d rotations.eugeni2007-02-161-0/+3
| | | | git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@22233 b3059339-0415-0410-9bf9-f77b7e298cf2
* Keep embedded fonts in ass_library_t and perform actual disk writeeugeni2006-12-031-0/+1
| | | | | | | | in fontconfig initialization. This is required for some fontconfig-related improvements. git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@21474 b3059339-0415-0410-9bf9-f77b7e298cf2
* Use (ass_font_t, char code) instead of (FT_Face, glyph index) to identifyeugeni2006-11-281-3/+3
| | | | | | | glyphs in cache. git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@21364 b3059339-0415-0410-9bf9-f77b7e298cf2
* Fix compilation broken in previous commit.eugeni2006-11-271-1/+1
| | | | git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@21338 b3059339-0415-0410-9bf9-f77b7e298cf2
* Move ass_font_t allocation to ass_font.h.eugeni2006-11-271-20/+21
| | | | git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@21333 b3059339-0415-0410-9bf9-f77b7e298cf2
* Remove obsolete "no_more_font_messages" hack.eugeni2006-11-261-2/+0
| | | | git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@21295 b3059339-0415-0410-9bf9-f77b7e298cf2
* Move fonts-related code to a separate file.eugeni2006-11-261-41/+7
| | | | git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@21293 b3059339-0415-0410-9bf9-f77b7e298cf2
* Make ass_new_font return ass_font_t struct (instead of just FT_Face).eugeni2006-11-261-13/+12
| | | | | | | Use it to access the font face. git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@21283 b3059339-0415-0410-9bf9-f77b7e298cf2
* Move ass_font_t to header.eugeni2006-11-261-8/+0
| | | | git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@21282 b3059339-0415-0410-9bf9-f77b7e298cf2
* Rename:eugeni2006-11-261-24/+24
| | | | | | | | | face_desc_t -> ass_font_desc_t face_cache_item_t -> ass_font_t *face* -> *font* git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@21281 b3059339-0415-0410-9bf9-f77b7e298cf2
* MSGTRs for libasskraymer2006-11-191-2/+2
| | | | git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@21082 b3059339-0415-0410-9bf9-f77b7e298cf2
* Collect all includes of mplayer headers in libass in a single file (mputils.h).eugeni2006-11-191-1/+1
| | | | git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@21042 b3059339-0415-0410-9bf9-f77b7e298cf2
* Prefer microsoft-specific charmaps to all other.eugeni2006-11-031-0/+20
| | | | | | | | There are some fonts with both 'Unicode' and 'Microsoft/Unicode' charmaps, and the second always seems to be the right choice. git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@20653 b3059339-0415-0410-9bf9-f77b7e298cf2
* Introduce MSGT_ASS, use it for all libass messages.eugeni2006-11-031-2/+2
| | | | git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@20645 b3059339-0415-0410-9bf9-f77b7e298cf2
* Add copyright notice and vim/emacs comments to libass and vf_ass.c.eugeni2006-10-011-0/+20
| | | | git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@20014 b3059339-0415-0410-9bf9-f77b7e298cf2
* Shadow support in libass.eugeni2006-09-241-0/+1
| | | | git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@19971 b3059339-0415-0410-9bf9-f77b7e298cf2
* Add \be (blur edges) support to libass.eugeni2006-09-161-0/+1
| | | | git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@19854 b3059339-0415-0410-9bf9-f77b7e298cf2
* Store bitmap glyphs in a separate struct, instead of FreeType's internal buffer.eugeni2006-09-161-2/+4
| | | | | | | This is required for various bitmap modifications (like blur, outline and shadow). git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@19852 b3059339-0415-0410-9bf9-f77b7e298cf2
* Simplify ass_glyph_cache_reset().eugeni2006-08-261-4/+5
| | | | git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@19551 b3059339-0415-0410-9bf9-f77b7e298cf2
* Reset glyph cache on reconfigure.eugeni2006-08-261-2/+7
| | | | git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@19545 b3059339-0415-0410-9bf9-f77b7e298cf2
* Initial libass release (without mencoder support).eugeni2006-07-071-0/+209
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@18942 b3059339-0415-0410-9bf9-f77b7e298cf2