Fix remove unnecessary function templating

This commit is contained in:
Francesco Abbate 2020-06-04 16:46:37 +02:00
parent a0e7d16167
commit c433017d75
1 changed files with 7 additions and 10 deletions

View File

@ -194,15 +194,12 @@ int FontRendererBakeFontBitmap(FontRenderer *font_renderer, int font_height,
return res;
}
// FIXME: remove the Blender template argument.
template <typename Blender>
void blend_solid_hspan(agg::rendering_buffer& rbuf, Blender& blender,
void blend_solid_hspan(agg::rendering_buffer& rbuf, blender_gamma_type& blender,
int x, int y, unsigned len,
const typename Blender::color_type& c, const agg::int8u* covers)
const agg::rgba8& c, const agg::int8u* covers)
{
typedef Blender blender_type;
typedef typename blender_type::color_type color_type;
typedef typename blender_type::order_type order_type;
typedef typename blender_gamma_type::color_type color_type;
typedef typename blender_gamma_type::order_type order_type;
typedef typename color_type::value_type value_type;
typedef typename color_type::calc_type calc_type;
@ -282,7 +279,7 @@ void FontRendererBlendGamma(FontRenderer *font_renderer, uint8_t *dst, int dst_s
const agg::rgba8 color_a(color.r, color.g, color.b);
for (int x = 0, y = 0; y < region_height; y++) {
agg::int8u *covers = src + y * src_stride;
blend_solid_hspan<blender_gamma_type>(dst_ren_buf, blender, x, y, region_width, color_a, covers);
blend_solid_hspan(dst_ren_buf, blender, x, y, region_width, color_a, covers);
}
}