freetype-commit
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Git][freetype/freetype][master] * src/raster/ftraster.c (Render_Single_


From: Alexei Podtelezhnikov (@apodtele)
Subject: [Git][freetype/freetype][master] * src/raster/ftraster.c (Render_Single_Pass): Simplify `band_stack'.
Date: Wed, 30 Jun 2021 14:55:35 +0000

Alexei Podtelezhnikov pushed to branch master at FreeType / FreeType

Commits:

2 changed files:

Changes:

  • ChangeLog
    1
    +2021-06-30  Alexei Podtelezhnikov  <apodtele@gmail.com>
    
    2
    +
    
    3
    +	* src/raster/ftraster.c (Render_Single_Pass): Simplify `band_stack'.
    
    4
    +
    
    1 5
     2021-06-29  Alexei Podtelezhnikov  <apodtele@gmail.com>
    
    2 6
     
    
    3 7
     	[raster] Do not skip the second pass without dropout control.
    

  • src/raster/ftraster.c
    ... ... @@ -366,16 +366,6 @@
    366 366
       typedef PProfile*  PProfileList;
    
    367 367
     
    
    368 368
     
    
    369
    -  /* Simple record used to implement a stack of bands, required */
    
    370
    -  /* by the sub-banding mechanism                               */
    
    371
    -  typedef struct  black_TBand_
    
    372
    -  {
    
    373
    -    Int  y_min;   /* band's minimum */
    
    374
    -    Int  y_max;   /* band's maximum */
    
    375
    -
    
    376
    -  } black_TBand;
    
    377
    -
    
    378
    -
    
    379 369
     #define AlignProfileSize \
    
    380 370
       ( ( sizeof ( TProfile ) + sizeof ( Alignment ) - 1 ) / sizeof ( Long ) )
    
    381 371
     
    
    ... ... @@ -3027,9 +3017,7 @@
    3027 3017
       {
    
    3028 3018
         Int  y_mid;
    
    3029 3019
         Int  band_top = 0;
    
    3030
    -
    
    3031
    -    black_TBand  band_stack[16];    /* band stack used for sub-banding     */
    
    3032
    -                                    /* enough for signed short bands       */
    
    3020
    +    Int  band_stack[32];  /* enough to bisect 32-bit int bands */
    
    3033 3021
     
    
    3034 3022
     
    
    3035 3023
         while ( 1 )
    
    ... ... @@ -3053,12 +3041,8 @@
    3053 3041
     
    
    3054 3042
             y_mid = ( y_min + y_max ) >> 1;
    
    3055 3043
     
    
    3056
    -        band_stack[band_top].y_min = y_min;
    
    3057
    -        band_stack[band_top].y_max = y_mid;
    
    3058
    -
    
    3059
    -        band_top++;
    
    3060
    -
    
    3061
    -        y_min = y_mid + 1;
    
    3044
    +        band_stack[band_top++] = y_min;
    
    3045
    +        y_min                  = y_mid + 1;
    
    3062 3046
           }
    
    3063 3047
           else
    
    3064 3048
           {
    
    ... ... @@ -3069,8 +3053,8 @@
    3069 3053
             if ( --band_top < 0 )
    
    3070 3054
               break;
    
    3071 3055
     
    
    3072
    -        y_min = band_stack[band_top].y_min;
    
    3073
    -        y_max = band_stack[band_top].y_max;
    
    3056
    +        y_max = y_min - 1;
    
    3057
    +        y_min = band_stack[band_top];
    
    3074 3058
           }
    
    3075 3059
         }
    
    3076 3060
     
    


  • reply via email to

    [Prev in Thread] Current Thread [Next in Thread]