Use One-Time Initialization for glyph run caching to avoid duplicate glyph run genera...
[gdipp.git] / gdipp_server / ggo_renderer.h
blob48441866e1ae311f0148020fec172a0df233a975
1 #pragma once
3 #include "gdipp_server/renderer.h"
5 namespace gdipp
8 class ggo_renderer : public renderer
10 public:
11 explicit ggo_renderer(rpc_session *render_session);
13 bool render(bool is_glyph_index, LPCWSTR lpString, UINT c, glyph_run *new_glyph_run);
15 private:
16 static void outline_ggo_to_ft(DWORD ggo_outline_buf_len, const BYTE *ggo_outline_buf, std::vector<FT_Vector> &curve_points, std::vector<char> &curve_tags, std::vector<short> &contour_indices);
18 bool get_glyph_metrics(wchar_t ch, GLYPHMETRICS &glyph_metrics) const;
19 const FT_Glyph outline_to_bitmap(wchar_t ch, GLYPHMETRICS &glyph_metrics) const;
21 static FT_Glyph _empty_outline_glyph;
23 UINT _ggo_format;
24 MAT2 _matrix;