------------------------------------------------------------------------------
| 2269 | |
| 2270 | //------------------------------------------------------------------------------ |
| 2271 | FT_Outline* vtkFreeTypeTools::GetOutline(FT_UInt32 c, size_t prop_cache_id, int prop_font_size, |
| 2272 | FT_UInt& gindex, FT_OutlineGlyph& outline_glyph) |
| 2273 | { |
| 2274 | // Get the glyph index |
| 2275 | if (!this->GetGlyphIndex(prop_cache_id, c, &gindex)) |
| 2276 | { |
| 2277 | return nullptr; |
| 2278 | } |
| 2279 | FT_Glyph glyph; |
| 2280 | // Get the glyph as a outline |
| 2281 | if (!this->GetGlyph( |
| 2282 | prop_cache_id, prop_font_size, gindex, &glyph, vtkFreeTypeTools::GLYPH_REQUEST_OUTLINE) || |
| 2283 | glyph->format != ft_glyph_format_outline) |
| 2284 | { |
| 2285 | return nullptr; |
| 2286 | } |
| 2287 | |
| 2288 | outline_glyph = reinterpret_cast<FT_OutlineGlyph>(glyph); |
| 2289 | FT_Outline* outline = &outline_glyph->outline; |
| 2290 | |
| 2291 | return outline; |
| 2292 | } |
| 2293 | |
| 2294 | //------------------------------------------------------------------------------ |
| 2295 | FT_Outline* vtkFreeTypeTools::GetOutline( |