src/cache/ftcsbits.c


Log

Author Commit Date CI Message
Werner Lemberg a0dd16fb 2018-08-15T18:13:17 Don't use `trace_' prefix for FT_COMPONENT arguments. * include/freetype/internal/ftdebug.h (FT_TRACE_COMP, FT_TRACE_COMP_): New auxiliary macros to add `trace_' prefix. (FT_TRACE): Use `FT_TRACE_COMP'. */* (FT_COMPONENT): Updated.
Werner Lemberg 9ac9060d 2018-06-03T09:01:17 [GSoC] src/*.*: Convert block comments to `light' style. This monster commit was created by applying Nikhil's scripts `docconverter.py' and `markify.py' to all C header and source files, followed up by minor manual clean-up. No change in functionality, of course. I used commit f7419907bc6044b9b7057f9789866426c804ba82 from https://github.com/nikramakrishnan/freetype-docs.git.
Werner Lemberg 0a0c2256 2018-01-02T09:33:57 Update copyright year.
Werner Lemberg 563ae780 2017-01-04T20:16:34 Update copyright year.
Werner Lemberg 4441f7b2 2016-12-26T17:08:17 Replace `foo == NULL' and `foo != NULL' with `!foo' and `foo', resp. Other minor formatting.
Werner Lemberg 0d053bac 2016-02-07T19:25:56 Fix runtime errors found by clang's sanitizer (#47082). * src/base/ftobjs.c (FT_Render_Glyph_Internal), src/base/ftoutln.c (FT_Outline_Copy), src/cache/ftcsbits.c (ftc_sbit_copy_bitmap): Properly handle empty input buffer.
Werner Lemberg 9adeab64 2016-01-13T11:54:10 Update copyright year.
Werner Lemberg 2e9d2660 2016-01-12T21:40:53 Don't use macro names that contain `__' [2/2]. Such macro names are reserved for both C and C++. * src/cache/*: s/__/_/.
Werner Lemberg 24e4e96a 2015-02-25T06:57:16 [cache] Signedness fixes. * src/cache/ftcbasic.c, src/cache/ftccmap.c, src/cache/ftcimage.c, src/cache/ftcmanag.c, src/cache/ftcsbits.c: Apply.
Werner Lemberg f57fc59e 2015-01-17T20:41:43 Run `src/tools/update-copyright'.
Werner Lemberg b3500af7 2014-11-19T21:28:21 Change some fields in `FT_Bitmap' to unsigned type. This doesn't break ABI. * include/ftimage.h (FT_Bitmap): Make `rows', `width', `num_grays', `pixel_mode', and `palette_mode' unsigned types. * src/base/ftbitmap.c: Updated. (FT_Bitmap_Copy): Fix casts. * src/cache/ftcsbits.c, src/raster/ftraster.c, src/sfnt/pngshim.c: Updated.
Werner Lemberg 89f50647 2013-03-14T17:50:49 */*: Use FT_ERR_EQ, FT_ERR_NEQ, and FT_ERR where appropriate. FT_Err_XXX and friends are no longer directly used in the source code.
Werner Lemberg e3c93015 2013-03-14T11:21:17 */*: Use FT_Err_Ok only. This is a purely mechanical conversion.
Werner Lemberg 059bc335 2013-03-14T10:27:35 */*: Use `FT_THROW'. This is essentially a mechanical conversion, adding inclusion of `FT_INTERNAL_DEBUG_H' where necessary, and providing the macros for stand-alone compiling modes of the rasterizer modules. To convert the remaining occurrences of FT_Err_XXX and friends it is necessary to rewrite the code. Note, however, that it doesn't harm if some cases are not handled since FT_THROW is a no-op.
Werner Lemberg 3757b1e1 2011-01-13T10:33:04 Cleanup/formatting.
suzuki toshiya 38b272ff 2011-01-09T22:49:07 [cache] Notice if a cache query induced the node list change. Some node comparators (comparing the cache node content and the properties specified by the query) can flush the cache node to prevent the cache inflation. The change may invalidate the pointers to the node obtained before the node comparison, so the change should be noticed to the caller. The problem caused by the cache node changing is reported by Harsha, see Savannah bug #31923. * src/cache/ftccache.h (FTC_Node_CompareFunc): Add new argument `FT_Bool* list_changed' to indicate the change of the cached nodes to the caller. (FTC_CACHE_LOOKUP_CMP): Watch the change of the cached nodes by `_list_changed'. (FTC_CACHE_TRYLOOP_END): Take new macro argument `_list_changed' and update it when FTC_Manager_FlushN() flushes any nodes. * src/cache/ftccback.h (ftc_snode_compare): Updated to fit with new FTC_Node_CompareFunc type. (ftc_gnode_compare): Ditto. * src/cache/ftcbasic.c: Include FT_INTERNAL_OBJECTS_H to use TRUE/FALSE macros. (ftc_basic_gnode_compare_faceid): New argument `FT_Bool* list_changed' to indicate the change of the cache nodes, anyway, it is always FALSE. * src/cache/ftccmap.c: Include FT_INTERNAL_OBJECTS_H to use TRUE/FALSE macros. (ftc_cmap_node_compare): New argument `FT_Bool* list_changed' to indicate the change of the cache nodes, anyway, it is always FALSE. (ftc_cmap_node_remove_faceid): Ditto. * src/cache/ftccache.c (FTC_Cache_NewNode): Pass a NULL pointer to FTC_CACHE_TRYLOOP_END(), because the result is not needed. (FTC_Cache_Lookup): Watch the change of the cache nodes by `list_changed'. (FTC_Cache_RemoveFaceID): Ditto. * src/cache/ftcglyph.c: Include FT_INTERNAL_OBJECTS_H to use TRUE/FALSE macros. (ftc_gnode_compare): New argument `FT_Bool* list_changed' to indicate the change of the cache nodes, anyway, it is always FALSE. (FTC_GNode_Compare): New argument `FT_Bool* list_changed' to be passed to ftc_gnode_compare(). * src/cache/ftcglyph.h (FTC_GNode_Compare): Ditto. * src/cache/ftcsbits.c (ftc_snode_compare): New argument `FT_Bool* list_changed' to indicate the change of the cache nodes, anyway. It is updated by FTC_CACHE_TRYLOOP(). (FTC_SNode_Compare): New argument `FT_Bool* list_changed' to be passed to ftc_snode_compare(). * src/cache/ftcsbits.h (FTC_SNode_Compare): Ditto.
suzuki toshiya 52a1e47a 2011-01-09T20:47:37 [cache] inline-specific functions are conditionalized. * src/cache/ftcglyph.c (FTC_GNode_Compare): Conditionalized for inlined config. This function is a thin wrapper of ftc_gnode_compare() for inlined FTC_CACHE_LOOKUP_CMP() (see `nodecmp' argument). Under non-inlined config, ftc_gnode_compare() is invoked by FTC_Cache_Lookup(), via FTC_Cache->clazz.node_compare(). * src/cache/ftcglyph.h (FTC_GNode_Compare): Ditto. * src/cache/ftcsbits.c (FTC_SNode_Compare): Ditto, for ftc_snode_compare(). * src/cache/ftcsbits.h (FTC_SNode_Compare): Ditto.
Harsha 7774ac67 2010-12-25T16:34:56 Apply Savannah patch #7422. If we encouter a space in a string then the sbit buffer is NULL, height and width are 0s. So the check in ftc_snode_compare will always pass for spaces (comparision with 255). Here the comments above the condition are proper but the implementation is not. When we create an snode I think it is the proper way to initialize the width to 255 and then put a check for being equal to 255 in snode compare function. * src/cache/ftcsbits.c (FTC_SNode_New): Initialize sbit widths with value 255. (ftc_snode_compare): Fix condition.
Werner Lemberg 6abb9232 2010-09-14T09:02:10 Improve tracing messages. * src/truetype/ttinterp.c (TT_RunIns): Improve wording of tracing message. * src/truetype/ttobjs.c (tt_size_run_fpgm, tt_size_run_prep): Add tracing message. * src/truetype/ttgload.c (tt_loader_init): Add tracing message. * src/cache/ftcsbits.c (ftc_snode_load): Emit tracing message if glyph doesn't fit into a small bitmap container.
Werner Lemberg f765e440 2010-06-24T10:34:29 */*: Use module specific error names where appropriate.
Werner Lemberg ca87cd0b 2009-10-06T11:09:29 Fix `make multi'. * src/cache/ftccache.c, src/cache/ftcsbits.c (FT_COMPONENT): Define. * src/sfnt/sfdriver.c: Include FT_INTERNAL_DEBUG_H.
suzuki toshiya ed1d3590 2009-08-01T00:32:10 cache: Fix some data types mismatching with their sources.
suzuki toshiya ebf8e294 2009-08-01T00:30:19 cache: Fix some data types mismatching with their sources.
Werner Lemberg 858abbed 2009-06-26T06:15:41 For warning messages, replace FT_ERROR with FT_TRACE0. FT_ERROR is now used only if a function produces a non-zero `error' value. Formatting, improving and harmonizing debug strings.
Werner Lemberg 6c5b617c 2006-03-22T15:30:41 * src/cache/ftccache.c, (ftc_node_mru_up, FTC_Cache_Lookup) [!FTC_INLINE]: Compile conditionally. * src/cache/ftccache.h: Updated. * src/cache/ftcglyph.c (FTC_GNode_Init, FTC_GNode_UnselectFamily, FTC_GNode_Done, FTC_GNode_Compare, FTC_Family_Init, FTC_GCache_New): s/FT_EXPORT/FT_LOCAL/. (FTC_GCache_Init, FTC_GCache_Done): Commented out. (FTC_GCache_Lookup) [!FTC_INLINE]: Compile conditionally. s/FT_EXPORT/FT_LOCAL/. * src/cache/ftcglyph.h: Updated. * src/cache/ftcimage.c (FTC_INode_Free, FTC_INode_New): s/FT_EXPORT/FT_LOCAL/. (FTC_INode_Weight): Commented out. * src/cache/ftcimage.h: Updated. * src/cache/ftmanag.c (FTC_Manager_Compress, FTC_Manager_RegisterCache, FTC_Manager_FlushN): s/FT_EXPORT/FT_LOCAL/. * src/cache/ftmanag.h: Updated. * src/cache/ftcsbits.c (FTC_SNode_Free, FTC_SNode_New, FTC_SNode_Compare): s/FT_EXPORT/FT_LOCAL/. (FTC_SNode_Weight): Commented out. * src/cache/ftcsbits.h: Updated.
Werner Lemberg 5a73d8d2 2006-03-20T16:55:32 * builds/freetype.mk (CACHE_DIR, CACHE_H): Remove. (FREETYPE_H): Updated. * src/cache/rules.mk (CACHE_H_DIR): Remove. (CACHE_DRV_H): Updated. Formatting, copyright years.
David Turner 256de4b1 2006-03-20T12:10:24 * include/freetype/cache/ftccache.h, include/freetype/cache/ftccmap.h, include/freetype/cache/ftcglyph.h include/freetype/cache/ftcimage.h include/freetype/cache/ftcmanag.h include/freetype/cache/ftcmru.h include/freetype/cache/ftcsbits.h: removing these header files from the public include directory. * include/freetype/config/ftheader.h: changing the definition of FT_CACHE_INTERNAL_XXX_H macros to redirect to FT_CACHE_H instead * src/cache/ftcbasic.c, src/cache/ftccache.c, src/cache/ftccache.h, src/cache/ftccback.h, src/cache/ftccmap.c, src/cache/ftcglyph.c, src/cache/ftcglyph.h, src/cache/ftcimage.c, src/cache/ftcimage.h, src/cache/ftcmanag.c, src/cache/ftcmanag.h, src/cache/ftcmru.c, src/cache/ftcmru.h, src/cache/ftcsbits.c, src/cache/ftcsbits.h: modifications to prevent using the FT_CACHE_INTERNAL_XXX_H macros, and grab the headers in 'src/cache' instead (see below).
Werner Lemberg 92aa527a 2005-05-23T21:33:02 * builds/amiga/makefile.os4 (WARNINGS), builds/compiler/gcc-dev.mk (CFLAGS), builds/compiler/gcc.mk (CFLAGS): Remove -fno-strict-aliasing. Say you have `(Foo*)x' and want to assign, pass, or return it as `(Bar*)'. If you simply say `x' or `(Bar*)x', then the C compiler would warn you that type casting incompatible pointer types breaks strict-aliasing. The solution is to cast to `(void*)' instead which is the generic pointer type, so the compiler knows that it should make no strict-aliasing assumption on `x'. But the problem with `(void*)x' is that seems like in C++, unlike C, `void*' is not a generic pointer type and assigning `void*' to `Bar*' without a cast causes an error. The solution is to cast to `Bar*' too, with `(Bar*)(void*)x' as the result -- this is what the patch does. * include/freetype/cache/ftccache.h (FTC_CACHE_LOOKUP_CMP), include/freetype/cache/ftcmru.h (FTC_MRULIST_LOOKUP_CMP): Remove cast on lvalue, use a temporary pointer instead. Cast temporarily to (void*) to not break strict aliasing. * include/freetype/internal/ftmemory.h (FT_MEM_ALLOC, FT_MEM_REALLOC, FT_MEM_QALLOC, FT_MEM_QREALLOC, FT_MEM_FREE), src/base/ftglyph.c (FT_Glyph_To_Bitmap): Cast temporarily to (void*) to not break strict aliasing. * src/base/ftinit.c (FT_USE_MODULE): Fix wrong type information. * builds/unix/configure.ac (XX_CFLAGS): Remove -fno-strict-aliasing. * src/sfnt/rules.mk (SFNT_DRV_SRC): Don't include ttsbit0.c -- it is currently loaded from ttsbit.c. Other formatting.
David Turner f9e05597 2005-05-23T13:04:53 * include/freetype/cache/ftcache.h, src/cache/ftccache.c, src/cache/ftcsbits.c: fixing bug #12213 (incorrect behaviour of the cache sub-system in low-memory conditions).
David Turner 6a6e6f27 2004-07-12T22:54:09 * src/cache/ftcsbits.c: fixing advance computation for transformed glyphs
Werner Lemberg fefd8742 2004-06-12T13:21:20 * docs/CHANGES: Updated. Minor clean-ups.
David Turner b83239b7 2004-06-09T21:07:49 * include/freetype/cache/ftcmru.h, src/cache/ftcbasic.c, src/cache/ftccache.c, src/cache/ftcglyph.c, src/cache/ftcmanag.c, src/cache/ftcsbits.c: fixing some annoying bugs and inefficiencies in the cache sub-system.
Werner Lemberg e260d253 2004-05-17T09:25:04 * src/cache/ftcbasic.c (ftc_basic_family_compare, ftc_basic_family_init, ftc_basic_family_get_count, ftc_basic_family_load_bitmap, ftc_basic_family_load_glyph, ftc_basic_gnode_compare_faceid): Adjust parameters and return types to prototypes given in header files from include/freetype/cache. Use casts to proper types locally. (ftc_basic_image_family_class, ftc_basic_image_cache_class, ftc_basic_sbit_family_class, ftc_basic_sbit_cache_class): Remove casts. * src/cache/ftccback.h: Adjust parameters and return types to prototypes given in header files from include/freetype/cache. * src/cache/ftcimage.c (ftc_inode_free, ftc_inode_new, ftc_inode_weight): Adjust parameters and return types to prototypes given in header files from include/freetype/cache. Use casts to proper types locally. * src/cache/ftcsbits.c (ftc_snode_free, ftc_snode_new, ftc_snode_weight, ftc_snode_compare): Adjust parameters and return types to prototypes given in header files from include/freetype/cache. Use casts to proper types locally. * src/cache/ftccmap.c (ftc_cmap_node_free, ftc_cmap_node_new, ftc_cmap_node_weight, ftc_cmap_node_compare, ftc_cmap_node_remove_faceid): Adjust parameters and return types to prototypes given in header files from include/freetype/cache. Use casts to proper types locally. (ftc_cmap_cache_class): Remove casts. * src/cache/ftcglyph.c (ftc_gnode_compare, ftc_gcache_init, ftc_gcache_done): Adjust parameters and return types to prototypes given in header files from include/freetype/cache. Use casts to proper types locally. * src/cache/ftcmanag.c (ftc_size_node_done, ftc_size_node_compare, ftc_size_node_init, ftc_size_node_reset, ftc_size_node_compare_faceid, ftc_face_node_init, ftc_face_node_done, ftc_face_node_compare: Adjust parameters and return types to prototypes given in header files from include/freetype/cache. Use casts to proper types locally. (ftc_size_list_class, ftc_face_list_class): Remove casts. * src/autohint/ahmodule.c (ft_autohinter_init, ft_autohinter_done): Use FT_Module as parameter and do a cast to FT_AutoHinter locally. (autohint_module_class): Remove casts. * src/base/ftglyph.c (ft_bitmap_glyph_init, ft_bitmap_glyph_copy, ft_bitmap_glyph_done, ft_bitmap_glyph_bbox, ft_outline_glyph_init, ft_outline_glyph_done, ft_outline_glyph_copy, ft_outline_glyph_transform, ft_outline_glyph_bbox, ft_outline_glyph_prepare): Use FT_Glyph as parameter and do a cast to FT_XXXGlyph locally. Use FT_CALLBACK_DEF throughout. (ft_bitmap_glyph_class, ft_outline_glyph_class): Remove casts. * src/bdf/bdfdrivr.c (bdf_cmap_init, bdf_cmap_done, bdf_cmap_char_index, bdf_cmap_char_next): Use FT_CMap as parameter and do a cast to BDF_CMap locally. (bdf_cmap_class): Remove casts.
Werner Lemberg 336bc908 2004-04-15T16:09:31 * src/cache/ftcsbits.c (ftc_snode_load): Initialize `*asize' in case of error.
Werner Lemberg dfa46199 2004-03-05T09:26:24 * Jamfile, vms_make.com, builds/win32/visualc/freetype.dsp, builds/win32/visualc/freetype/vcproj, include/freetype/ftmoderr.h: Add LZW module. * Jamfile.in: Removed. * docs/CHANGES: Updated. * include/freetype/internal/ftobjs.h: s/MIN/FT_MIN/, s/MAX/FT_MAX/, s/ABS/FT_ABS/. Updated all callers. * src/type1/t1load.c (parse_dict), src/pcf/pcfdrivr.c (PCF_Face_Init): Use FT_ERROR_BASE. Add support for PCF fonts compressed with LZW (extension .pcf.Z, created with `compress'). * include/freetype/config/ftoption.h, devel/ftoption.h (FT_CONFIG_OPTION_USE_LZW): New macro. * include/freetype/ftlzw.h: New file. * include/freetype/config/ftheader.h (FT_LZW_H): New macro for ftlzw.h. * src/lzw/*: New files. * src/pcf/pcfdrivr.c: Include FT_LZW_H. (PCF_Face_Init): Try LZW also. * src/gzip/ftgzip.c: s/0/Gzip_Err_Ok/ where appropriate. Beautify.
Werner Lemberg 09370c8c 2004-02-17T18:41:58 Fix callback functions in cache module. * src/cache/ftccback.h: New file for callback declarations. * src/cache/ftcbasic.c (ftc_basic_family_compare, ftc_basic_family_init, ftc_basic_family_get_count, ftc_basic_family_load_bitmap, ftc_basic_family_load_glyph, ftc_basic_gnode_compare_faceid): Use FT_CALLBACK_DEF. (ftc_basic_image_family_class, ftc_basic_image_cache_class, ftc_basic_sbit_family_class, ftc_basic_sbit_cache_class): Use FT_CALLBACK_TABLE_DEF and local wrapper functions. * src/cache/ftccache.c: Include ftccback.h. (ftc_cache_init, ftc_cache_done): New wrapper functions which use FT_LOCAL_DEF. * src/cache/ftccmap.c: Include ftccback.h. (ftc_cmap_cache_class): Use local wrapper functions. * src/cache/ftcglyph.c: Include ftccback.h. (ftc_gnode_compare, ftc_gcache_init, ftc_gcache_done): New wrapper functions which use FT_LOCAL_DEF. * src/cache/ftcimage.c: Include ftccback.h. (ftc_inode_free, ftc_inode_new, ftc_inode_weight): New wrapper functions which use FT_LOCAL_DEF. * src/cache/ftcmanag.c (ftc_size_list_class, ftc_face_list_class): Use FT_CALLBACK_TABLE_DEF. * src/cache;/ftcsbits.c: Include ftccback.h. (ftc_snode_free, ftc_snode_new, ftc_snode_weight, ftc_snode_compare): New wrapper functions which use FT_LOCAL_DEF. * src/cache/rules.mk (CACHE_DRV_H): Add ftccback.h.
Werner Lemberg d233482e 2004-02-13T23:48:39 * src/base/ftobjs.c (FT_Set_Char_Size): Return immediately if ppem values don't change. Suggested by Graham Asher.
Werner Lemberg 80cfbd70 2003-12-26T07:26:08 * src/base/fttrigon.c, src/base/ftgloadr.c: Inlude FT_INTERNAL_OBJECTS_H. * src/base/ftstroke.c (FT_Outline_GetInsideBorder, FT_Outline_GetOutsideBorder): s/or/o/ to make it compile with C++ compilers. * src/cache/ftcmru.c, include/freetype/cache/ftcmru.h: s/select/selection/ to avoid compiler warning. * src/cff/cffload.h: s/select/ftselect/ to avoid potential compiler warning. Formatting.
Werner Lemberg a40b1b64 2003-12-25T20:15:51 * src/cache/ftcsbits.c (FTC_SNode_Weight): s/FTC_SBIT_ITEM_PER_NODE/FTC_SBIT_ITEMS_PER_NODE/.
David Turner cf2c49c8 2003-12-24T18:42:04 * fixed compilation problems in the cache sub-system * partial updates to src/autofit
David Turner 581ec91c 2003-12-22T21:53:37 * include/freetype/ftcache.h, include/freetype/cache/ftcmanag.h, include/freetype/cache/ftccache.h, include/freetype/cache/ftcmanag.h, include/freetype/cache/ftcmru.h (added), include/freetype/cache/ftlru.h (removed), include/freetype/cache/ftcsbits.h, include/freetype/cache/ftcimage.h, include/freetype/cache/ftcglyph.h, src/cache/ftcmru.c, src/cache/ftcmanag.c, src/cache/ftccache.c, src/cache/ftcglyph.c, src/cache/ftcimage.c, src/cache/ftcsbits.c, src/cache/ftccmap.c, src/cache/ftcbasic.c (added), src/cache/ftclru.c (removed): *Complete* rewrite of the cache sub-system to "solve" the following points: - all public APIs have been moved to FT_CACHE_H, everything under "include/freetype/cache" is only needed by client applications that want to implement their own caches - a new function named FTC_Manager_RemoveFaceID to deal with the uninstallation of FaceIDs - the image and sbit cache are now abstract classes, that can be extended much more easily by client applications - better performance in certain areas. Further optimizations to come shortly anyway... - the FTC_CMapCache_Lookup function has changed its signature, charmaps can now only be retrieved by index - FTC_Manager_Lookup_Face => FTC_Manager_LookupFace FTC_Manager_Lookup_Size => FTC_Manager_LookupSize (still in private header for the moment)
David Turner 89f331b7 2003-12-21T01:41:32 important bug fixes for new cache code
David Turner 57ecae22 2003-12-19T21:23:58 new version of the cache sub-system - still under debugging
Werner Lemberg 4ee9b7ba 2003-07-02T15:03:36 * src/cache/ftcsbits.c (ftc_sbit_node_compare): Only add `size' if there is no error. Reported by Knut St. Osmundsen <bird-freetype@anduin.net>.
Werner Lemberg 779afe4b 2003-06-22T15:33:53 * src/winfonts/winfnt.c (FNT_Load_Glyph): Use first_char in computation of glyph_index. (FNT_Size_Set_Pixels): To find a strike, first check pixel_height only, then try to find a better hit by comparing pixel_width also. Without this fix it isn't possible to access all strikes. Also compute metrics.max_advance to be in sync with other bitmap drivers. * src/base/ftobjs.c (FT_Set_Char_Size): Remove redundant code. (FT_Set_Pixel_Size): Assign value to `metrics' after validation of arguments. Synchronize computation of height and width for bitmap strikes. The `width' field in the FT_Bitmap_Size structure is now only useful to enumerate different strikes. The `max_advance' field of the FT_Size_Metrics structure should be used to get the (maximum) width of a strike. * src/bdf/bdfdrivr.c (BDF_Face_Init): Don't use AVERAGE_WIDTH for computing `available_sizes->width' but make it always equal to `available_sizes->height'. * src/pcf/pcfread.c (pcf_load_font): Don't use RESOLUTION_X for computing `available_sizes->width' but make it always equal to `available_sizes->height'. * src/truetype/ttdriver.c (Set_Pixel_Sizes): Pass only single argument to function. * src/psnames/psmodule.c (ps_unicode_value): Handle `.' after `uniXXXX' and `uXXXX[X[X]]'. * src/bdf/bdfdrivr.c: s/FT_Err_/BDF_Err/. * src/cache/ftccache.c, src/cache/ftcsbits.c, src/cache/ftlru.c: s/FT_Err_/FTC_Err_/. * src/cff/cffcmap.c: s/FT_Err_/CFF_Err_/. * src/pcf/pcfdrivr.c: s/FT_Err_/PCF_Err_/. * src/psaux/t1cmap.c: Include psauxerr.h. s/FT_Err_/PSaux_Err_/. * src/pshinter/pshnterr.h: New file. * src/pshinter/rules.mk: Updated. * src/pshinter/pshalgo.c, src/pshinter/pshrec.c: Include pshnterr.h. s/FT_Err_/PSH_Err_/. * src/pfr/pfrdrivr.c, src/pfr/pfrobjs.c, src/pfr/pfrsbit.c: s/FT_Err_/PFR_Err_/. * src/sfnt/sfdriver.c, src/sfnt/sfobjs.c, src/sfnt/ttcmap0.c, src/sfnt/ttload.c: s/FT_Err_/SFNT_Err_/. * src/truetype/ttgload.c: s/FT_Err_/TT_Err_/. * src/gzip/ftgzip.c: Load FT_MODULE_ERRORS_H and define FT_ERR_PREFIX and FT_ERR_BASE. s/FT_Err_/Gzip_Err_/.
Werner Lemberg 7a024104 2003-06-18T06:59:57 * include/freetype/freetype.h (FT_Open_Flags): Replaced with #defines for the constants. (FT_Open_Args): Change type of `flags' to FT_UInt. (FT_GlyphSlot): Move `flags' to FT_Slot_Internal. * include/freetype/ftimage.h (FT_Outline_Flags, FT_Raster_Flag): Replaced with #defines for the constants. * include/freetype/internal/ftobjs.h (FT_Slot_Internal): New field `flags' (from FT_GlyphSlot). Updated all affected source files. (FT_GLYPH_OWN_BITMAP): New macro (from ftgloadr.h). * include/freetype/internal/ftgloadr.h (FT_GLYPH_OWN_BITMAP): Moved to ftobjs.h. * src/base/ftglyph.c (FT_Glyph_To_Bitmap): Use dummy FT_GlyphSlot_Internal object.
Werner Lemberg 2acb963b 2003-04-23T06:47:12 Cleanups.
David Turner b280537b 2003-03-13T21:07:51 * src/base/ftdbgmem.c, docs/DEBUG.TXT: added new environment variables to control memory debugging with FreeType. See the description of "FT2_DEBUG_MEMORY", "FT2_ALLOC_TOTAL_MAX" and "FT2_ALLOC_COUNT_MAX" in DEBUG.TXT * src/cache/ftccache.c, src/cache/ftccmap.c, src/cache/ftcsbits.c, ftlru.c: fixed the cache sub-system to correctly deal with out-of-memory conditions. * src/pfr/pfrobjs.c, src/pfr/pfrsbits.c: fixing compiler warnings and a small memory leak * src/psaux/psobjs.c (t1_reallocate_table): fixed a bug (memory leak) that only happened when trying to resize an array would end in an OOM. * src/smooth/ftgrays.c: removed compiler warnings / volatile bug * src/truetype/ttobjs.c: removed segmentation fault that happened in tight memory environments.
David Turner 5237993a 2002-11-07T09:46:43 fixed a small bug in the sbit cache that caused problems with embedded bitmaps
Werner Lemberg 7a99b507 2002-09-17T07:31:17 * src/type1/t1parse.h (T1_ParserRec): Change type of `base_len' and `private_len' to FT_Long. * src/cache/ftcsbits.c (ftc_sbit_node_load): Remove unused label. * src/pshinter/pshalgo3.c (psh3_hint_align): Remove unused variable.
David Turner 00d9f40c 2002-09-08T21:29:11 * src/smooth/ftsmooth.c, src/base/ftobjs.c, include/freetype/config/ftmodule.h: updated to correctly support sub-pixel rendering * include/freetype/cache/ftcimage.h, include/freetype/cache/ftcsbits.h, src/cache/ftcimage.c, src/cache/ftcsbit.c: updated to support sub-pixel rendering correctly. Definition of FTC_ImageTypeRec that replaces the obsolete FTC_ImageDesc, and has slightly different fields. The image type is now determined directly by "load_flags" values. * src/autohint/ahtypes.h, src/autohint/ahhint.c, src/pshinter/pshalgo3.c, src/pshinter/pshalgo3.h: various enhancements to the automatic and Postscript hinters !! and sub-pixel hinting now works correctly (see demo programs)
Werner Lemberg 8c90c22d 2002-06-08T06:47:18 * src/cache/ftccache.c (ftc_node_hash_unlink, ftc_node_hash_link) [FTC_CACHE_USE_LINEAR_HASHING]: Fix returned error code. Fix debugging messages. * src/type42/t42error.h: New file. * src/type42/t42drivr.c, src/type42/t42objs.c, src/type42/t42parse.c: Use t42 error codes. * src/type42/rules.mk: Updated. * src/base/ftnames.c: Include FT_INTERNAL_STREAM_H. Formatting, adding copyright messages.
David Turner 08b7ad44 2002-06-07T20:07:44 * include/freetype/cache/ftccache.h, src/cache/ftccache.c, src/cache/ftccache.i, src/cache/ftcsbits.c: adding various experimental optimisations to the cache manager * src/type42/t42parse.c: removing duplicate function
Werner Lemberg 7cf4d377 2002-05-21T14:13:01 * src/type42/t42drivr.c: s/T42_ENCODING_TYPE_/T1_ENCODING_TYPE_/. (parse_font_matrix): Remove unnecessary code. (parse_sfnts): Initialize some variables. (t42_driver_class) [TT_CONFIG_OPTION_BYTECODE_INTERPRETER]: Use ft_module_driver_has_hinter conditionally. Moved some type 42 specific structure definitions to... * include/freetype/internal/t42types.h: New file. * include/freetype/internal/internal.h (FT_INTERNAL_T42_TYPES_H): New macro. * include/freetype/cache/ftcsbits.h (FTC_SBit): Added a new field `num_grays' for specifying the number of used gray levels. * src/cache/ftcsbits.c (ftc_sbit_node_load): Initialize it. Adding a driver for BDF fonts written by Francesco Zappa Nardelli <Francesco.Zappa.Nardelli@ens.fr>. Heavily modified by me to better adapt it to FreeType, removing unneeded stuff. Additionally, it now supports Mark Leisher's BDF extension for anti-aliased bitmap glyphs with 2 and 4 bpp. * src/bdf/*: New driver. * include/freetype/internal/bdftypes.h: New file. * include/freetype/internal/fttrace.h: Added BDF driver components. * include/freetype/fterrdef.h: Added error codes for BDF driver. * include/freetype/config/ftmodule.h, src/Jamfile: Updated. * include/freetype/internal/internal.h (FT_INTERNAL_BDF_TYPES_H): New macro. * include/freetype/config/ftstdlib.h (ft_sprintf): New alias for sprintf. * include/freetype/internal/fttrace.h: Added Type 42 driver component. * src/type42/t42drivr.c: Use it. * include/freetype/internal/internal.h (FT_INTERNAL_PCF_TYPES_H): New macro.
Werner Lemberg 7b3dc7bb 2002-04-28T02:48:20 * src/cache/ftccache.c (ftc_cache_lookup), src/cache/ftccmap.c (ftc_cmap_family_init), src/cache/ftcmanag.c (ftc_family_table_alloc), src/cache/ftcsbits.c (FTC_SBit_Cache_Lookup): Use FTC_Err_*. src/cache/ftcimage.c (FTC_Image_Cache_Lookup): Use FTC_Err_*. (FTC_ImageCache_Lookup): Fix handling of invalid arguments.
David Turner d15bc0d1 2002-04-12T09:31:48 * README.UNX: updated the Unix-specific quick-compilation guide to warn about the GNU Make requirement at compile time.. * include/freetype/config/ftstdlib.h, include/freetype/config/ftconfig.h, include/freetype/config/ftheader.h, include/freetype/internal/ftmemory.h, include/freetype/internal/ftobjs.h, src/autohint/ahoptim.c, src/base/ftdbgmem.c, src/base/ftdebug.c, src/base/ftmac.c, src/base/ftobjs.c, src/base/ftsystem.c, src/cache/ftcimage.c, src/cache/ftcsbits.c, src/cff/cffdriver.c, src/cff/cffload.c, src/cff/cffobjs.c, src/cid/cidload.c, src/cid/cidparse.c, src/cid/cidriver.c, src/pcf/pcfdriver.c, src/pcf/pcfread.c, src/psaux/t1cmap.c, src/psaux/t1decode.c, src/pshinter/pshalgo1.c, src/pshinter/pshalgo2.c, src/pshinter/pshrec.c, src/psnames/psmodule.c, src/raster/ftraster.c, src/sfnt/sfdriver.c, src/sfnt/ttload.c, src/sfnt/ttpost.c, src/smooth/ftgrays.c, src/type1/t1afm.c, src/type1/t1driver.c, src/type1/t1gload.c, src/type1/t1load.c, src/type1/t1objs.c, src/type1/t1parse.c: added the new configuration file "ftstdlib.h" used to define aliases for all ISO C library functions used by the engine (e.g. strlen, qsort, setjmp, etc...) this eases the porting of FreeType 2 to exotic environments like XFree86 modules/extensions.. also removed many #include <string.h>, #include <stdlib.h>, etc... from the engine's sources where they're not needed..
Werner Lemberg 48c984b5 2002-03-30T16:41:09 * src/cff/cffdrivr.c (cff_get_glyph_name): Fix debug message. * src/cff/cffobjs.c (CFF_Driver_Init, CFF_Driver_Done) [TT_CONFIG_OPTION_EXTEND_ENGINE]: Removed. * src/cff/sfobjs.c (SFNT_Load_Face) [TT_CONFIG_OPTION_EXTEND_ENGINE]: Ditto. * src/truetype/ttobjs.c (TT_Init_Driver, TT_Done_Driver) [TT_CONFIG_OPTION_EXTEND_ENGINE]: Ditto. * src/truetype/ttdriver.c, src/truetype/ttobjs.c, src/truetype/ttobjs.h: Renaming driver functions to the FT_<Subject>_<Action> scheme: TT_Init_Driver => TT_Driver_Init TT_Done_Driver => TT_Driver_Done TT_Init_Face => TT_Face_Init TT_Done_Face => TT_Face_Done TT_Init_Size => TT_Size_Init TT_Done_Size => TT_Size_Done TT_Reset_Size => TT_Size_Reset
David Turner e459d742 2002-03-22T13:52:37 * include/freetype/internal/ftmemory.h, and a lot of other files !!: changed the names of memory macros. Examples: MEM_Set => FT_MEM_SET MEM_Copy => FT_MEM_COPY MEM_Move => FT_MEM_MOVE ALLOC => FT_ALLOC FREE => FT_FREE REALLOC = >FT_REALLOC FT_NEW was introduced to allocate a new object from a _typed_ pointer.. note that ALLOC_ARRAY and REALLOC_ARRAY have been replaced by FT_NEW_ARRAY and FT_RENEW_ARRAY which take _typed_ pointer arguments. This results in _lots_ of sources being changed, but makes the code more generic and less error-prone..
David Turner 4a233510 2002-02-24T02:39:08 renaming "ft_glyph_own_bitmap" into "FT_GLYPH_OWN_BITMAP"
Werner Lemberg 21e046e0 2001-12-20T17:49:10 Formatting. * src/cache/ftccache.c (ftc_node_destroy, ftc_cache_lookup): Fix tracing strings. * src/cache/ftccmap.c (ftc_cmap_family_init): Ditto. * src/cache/ftcmanag.c (ftc_family_table_alloc, ftc_family_table_free, FTC_Manager_Check): Ditto. * src/cache/ftcsbits.c (ftc_sbit_node_load): Ditto.
Werner Lemberg 5da9dd77 2001-12-16T08:17:33 * src/base/ftglyph (FT_Glyph_To_Bitmap): Remove compiler warning. * include/freetype/ftcache.h (FTC_Node_Unref): Removed. It is already in ftcmanag.h. * src/cache/ftcsbits.c (ftc_sbit_node_load): Remove unused variable `gfam'. * src/cache/ftcmanag.c (ftc_family_table_alloc, * ftc_family_table_free): Use FT_EXPORT_DEF. * include/freetype/cache/ftcmanag.h: Updated. * src/cache/ftccache.c (ftc_node_destroy): Use FT_EXPORT_DEF. * src/cache/ftccmap.c (ftc_cmap_node_init): Remove unused variable `cfam'. Remove compiler warning. (FTC_CMapCache_Lookup): Remove compiler warnings. (ftc_cmap_family_init): Ditto. (FTC_CMapCache_Lookup): Ditto. * builds/unix/configure.ac: Increase `version_info' to 8:0:2. * builds/unix/configure: Regenerated. * builds/mac/README: Updated.
David Turner 145f94cb 2001-12-07T14:43:45 added new charmap cache. see include/freetype/cache/ftccmap.h
David Turner 14183ea0 2001-12-05T15:59:33 First of all, a big thanks to Werner and Antoine for their latest work !! * src/pshinter/pshalgo2.c (psh2_hint_table_init), src/pshinter/pshalgo1.c (psh1_hint_table_init): removed compiler warnings * include/freetype/cache/*, src/cache/*: yet another massive rewrite of the caching sub-system, in order to both increase performance and allow simpler cache sub-classing. As an example, the code for the image and sbit caches is now much simpler I still need to update the documentation in www/freetype2/docs/cache.html to reflect the new design though..
Werner Lemberg c3b21608 2001-12-05T01:22:05 Formatting. Cleaning up of ChangeLog. * docs/license.txt: s/X Windows/X Window System/. * src/raster/ftraster.c: Fix definition condition of MEM_Set(). * src/smooth/ftgrays.c (M_Y): Change value to 192. * src/base/ftdbgmem.c (ft_mem_table_destroy): Fix printf() parameter. Remove unused variable. * src/cache/ftcimage.c (ftc_image_node_init, ftc_image_node_compare): Remove unused variables. * src/cache/ftcsbits.c (ftc_sbit_node_weight): Remove unused variable. * src/raster/ftraster.c (MEM_Set): Move definition down to avoid compiler warning. * src/autohint/ahhint.c (ah_hinter_hint_edges): Use UNUSED() to avoid compiler warnings. * src/pcf/pcfread.c (tableNames): Use `const'. (pcf_read_TOC): Change counter name to avoid compiler warning. Use `const'. * src/pshinter/pshrec.c (ps_hints_close): Remove redundant declaration. * src/pshinter/pshalgo1.c (psh1_hint_table_init): Rename variables to avoid shadowing. * src/pshinter/pshalgo2.c (psh2_hint_table_activate_mask): Ditto. * src/type1/t1objs.h: Remove double declarations of `T1_Size_Init()' and `T1_Size_Done()'.
David Turner 75133bff 2001-10-27T17:36:04 fixed a small performance bug in the new cache sub-system implementation
David Turner cd605b63 2001-10-26T16:58:27 _major_ re-design of the caching sub-system. Still using the same API though :-)
Werner Lemberg 415235df 2001-06-28T17:49:10 finishing function header formatting updating copyrights
Werner Lemberg f814d0fa 2001-06-27T16:18:10 First round in converting type foo ( ... ) to type foo ( ... ) Other minor formatting issues.
David Turner dee78134 2001-06-27T09:26:46 * include/freetype/ftconfig.h, src/*/*.c: changed the definition and uses of the FT_CALLBACK_DEF macro in order to support 16-bit compilers
Werner Lemberg 8eb0353f 2001-06-19T23:03:41 Formatting.
David Turner 8edbcabc 2001-06-19T08:28:24 - updated doc for FT_New_Memory_Face - removed lots of compiler warnings in lint-style warning modes (/W4 with Visual C++)
Werner Lemberg 1f7f0e87 2001-06-06T17:30:41 Complete redesign of error codes. Please check ftmoderr.h for more details. * include/freetype/internal/cfferrs.h, include/freetype/internal/tterrors.h, include/freetype/internal/t1errors.h: Removed. Replaced with files local to the module. All extra error codes have been moved to `fterrors.h'. * src/sfnt/ttpost.h: Move error codes to `fterrors.h'. * src/autohint/aherrors.h, src/cache/ftcerror.h, src/cff/cfferrs.h, src/cid/ciderrs.h, src/pcf/pcferror.h, src/psaux/psauxerr.h, src/psnames/psnamerr.h, src/raster/rasterrs.h, src/sfnt/sferrors.h, src/smooth/ftsmerrs.h, src/truetype/tterrors.h, src/type1/t1errors.h, src/winfonts/fnterrs.h: New files defining the error names for the module it belongs to. * include/freetype/ftmoderr.h: New file, defining the module error offsets. Its structure is similar to `fterrors.h'. * include/freetype/fterrors.h (FT_NOERRORDEF): New macro. (FT_ERRORDEF): Redefined to use module error offsets. All internal error codes are now public; unused error codes have been removed, some are new. * include/freetype/config/ftheader.h (FT_MODULE_ERRORS_H): New macro. * include/freetype/config/ftoption.h (FT_CONFIG_OPTION_USE_MODULE_ERRORS): New macro. All other source files have been updated to use the new error codes; some already existing (internal) error codes local to a module have been renamed to give them the same name as in the base module. All make files have been updated to include the local error files. * src/cid/cidtokens.h: Replaced with... * src/cid/cidtoken.h: This file for 8+3 consistency. * src/raster/ftraster.c: Use macros for header file names.
Werner Lemberg 63408a12 2000-12-13T23:44:37 include/freetype/internal/internal.h: Fixed header inclusion macros to use direct definitions. This is the only way to do these things in a portable way :-( The rest of the code should follow shortly though everything compiles now. * builds/compiler/intelc.mk, builds/compiler/watcom.mk: New files. * builds/win32/detect.mk: Added support for the Intel C/C++ compiler, as well as _preliminary_ (read: doesn't work!) support for Watcom. Also added a new setup target. Type "make setup list" for a list of supported command-line compilers on Win32. * src/base/ftdebug.c: Added dummy symbol to avoid empty file if conditionals are off.
Werner Lemberg cc069beb 2000-12-08T16:17:16 cleanups
David Turner 19ed8afe 2000-12-08T02:42:29 - updated all source files to adhere to the new inclusion scheme - the CFF loader now loads the encodings and charset tables though doesn't use them for now
Werner Lemberg ada9503d 2000-11-29T17:48:57 * src/base/ftcalc.c (FT_SqrtFixed), src/base/ftobjs.c (FT_Set_Renderer): Use FT_EXPORT_DEF. * src/cache/ftcimage.c (FTC_Image_Cache_Lookup), src/cache/ftcmanag.c (FTC_Manager_Done, FTC_Manager_Reset, FTC_Manager_Lookup_Face, FTC_Manager_Lookup_Size, FTC_Manager_Register_Cache), src/cache/ftcsbits.c (FTC_SBit_Cache_Lookup): Ditto. * src/include/freetype/cache/ftcglyph.h (FTC_GlyphNode_Init), src/include/freetype/ftmac.h (FT_New_Face_From_FOND): Use FT_EXPORT.
Werner Lemberg a82cd844 2000-11-10T22:43:37 Small fixes and formatting.
Werner Lemberg 4b68007b 2000-11-07T06:30:29 Complementing David's changes with formatting, adding documentation, etc. More `*'-convention formatting, adding the `a' resp. `an' prefix to variables.
David Turner 25dee217 2000-11-06T19:29:06 some updates to the cache sub-system. some methods were moved from the concrete "FTC_Image_Cache" and "FTC_SBit_Cache" to the abstract "FTC_Glyph_Cache" and "FTC_Chunk_Cache", respectively.. note: this is not the end of changes to the cache sub-system
David Turner 76a5f623 2000-11-04T01:55:49 major reformatting of the sources: FT_EXPORT_DEF => FT_EXPORT FT_EXPORT_FUNC => FT_EXPORT_DEF BASE_DEF => FT_BASE BASE_FUNC => FT_BASE_DEF LOCAL_DEF => FT_LOCAL LOCAL_FUNC => FT_LOCAL_DEF LOCAL_FUNC_X => FT_CALLBACK_DEF LOCAL_DEF_X => FT_CALLBACK_TABLE FT_CPLUSPLUS => FT_CALLBACK_TABLE_DEF
Werner Lemberg ab855232 2000-10-31T22:13:54 Fixing include header for a `make multi' build. Finishing formatting of cache stuff. Fixed getDriverClass stuff -- added it to winfnt.c also. Note that this still has to be documented.
Werner Lemberg e4b32a5d 2000-10-31T20:42:18 Removing trailing whitespace.
David Turner 29094757 2000-10-31T10:58:23 at last, the infamous cache bug is fixed !!
David Turner ece63798 2000-10-28T23:34:45 completed the sbit cache, though it's still buggy :-( major reformatting of the cache subsystem (again) added substantial documentation too in header files
David Turner 4e4a4363 2000-10-28T13:17:11 - completed the abstract chunk cache class - started implementin a "small-bitmaps" cache derived from it - (soon a "metrics" cache will be written too)