Anurag Thakur pushed to branch gsoc-anurag-2023 at FreeType / FreeType
Commits:
-
ca850761
by Anurag Thakur at 2023-08-12T23:29:01+05:30
-
71f5924d
by Anurag Thakur at 2023-08-12T23:43:16+05:30
3 changed files:
Changes:
... | ... | @@ -430,8 +430,8 @@ FT_BEGIN_HEADER |
430 | 430 | * Do not `#undef` these macros here since the build system might define
|
431 | 431 | * them for certain configurations only.
|
432 | 432 | */
|
433 | -/* #define FT_DEBUG_LEVEL_ERROR */
|
|
434 | -/* #define FT_DEBUG_LEVEL_TRACE */
|
|
433 | +#define FT_DEBUG_LEVEL_ERROR
|
|
434 | +#define FT_DEBUG_LEVEL_TRACE
|
|
435 | 435 | |
436 | 436 | |
437 | 437 | /**************************************************************************
|
... | ... | @@ -647,7 +647,7 @@ FT_BEGIN_HEADER |
647 | 647 | * Do not `#undef` this macro here, since the build system might define it
|
648 | 648 | * for certain configurations only.
|
649 | 649 | */
|
650 | -#define TT_CONFIG_OPTION_BYTECODE_INTERPRETER
|
|
650 | +// #define TT_CONFIG_OPTION_BYTECODE_INTERPRETER
|
|
651 | 651 | |
652 | 652 | |
653 | 653 | /**************************************************************************
|
... | ... | @@ -681,7 +681,7 @@ FT_BEGIN_HEADER |
681 | 681 | * [1]
|
682 | 682 | * https://www.microsoft.com/typography/cleartype/truetypecleartype.aspx
|
683 | 683 | */
|
684 | -#define TT_CONFIG_OPTION_SUBPIXEL_HINTING
|
|
684 | +// #define TT_CONFIG_OPTION_SUBPIXEL_HINTING
|
|
685 | 685 | |
686 | 686 | |
687 | 687 | /**************************************************************************
|
... | ... | @@ -38,7 +38,7 @@ FONT_MODULES += truetype |
38 | 38 | # TrueType preload font driver.
|
39 | 39 | #
|
40 | 40 | # This driver needs the `sfnt' module.
|
41 | -FONT_MODULES += preload
|
|
41 | +#FONT_MODULES += preload
|
|
42 | 42 | |
43 | 43 | # PostScript Type 1 font driver.
|
44 | 44 | #
|
... | ... | @@ -2636,6 +2636,7 @@ |
2636 | 2636 | |
2637 | 2637 | driver = FT_DRIVER( cur[0] );
|
2638 | 2638 | |
2639 | + // TODO: Check the args for a "preload" flag and act accordingly
|
|
2639 | 2640 | if ( args->flags & FT_OPEN_PARAMS )
|
2640 | 2641 | {
|
2641 | 2642 | num_params = args->num_params;
|
... | ... | @@ -2726,6 +2727,7 @@ |
2726 | 2727 | /* face->driver instead. */
|
2727 | 2728 | FT_List_Add( &face->driver->faces_list, node );
|
2728 | 2729 | |
2730 | + // TODO: The preload logic should be performed here
|
|
2729 | 2731 | /* now allocate a glyph slot object for the face */
|
2730 | 2732 | FT_TRACE4(( "FT_Open_Face: Creating glyph slot\n" ));
|
2731 | 2733 | |
... | ... | @@ -4908,6 +4910,10 @@ |
4908 | 4910 | pixel_modes[slot->bitmap.pixel_mode],
|
4909 | 4911 | slot->bitmap.pixel_mode ));
|
4910 | 4912 | |
4913 | + if(pitch<0)
|
|
4914 | + {
|
|
4915 | + pitch = -pitch;
|
|
4916 | + }
|
|
4911 | 4917 | for ( i = 0; i < rows; i++ )
|
4912 | 4918 | for ( j = 0; j < pitch; j++ )
|
4913 | 4919 | coverage += bitmap.buffer[i * pitch + j];
|