MCPcopy Create free account
hub / github.com/Kitware/VTK / InitializeCacheManager

Method InitializeCacheManager

Rendering/FreeType/vtkFreeTypeTools.cxx:396–429  ·  view source on GitHub ↗

------------------------------------------------------------------------------

Source from the content-addressed store, hash-verified

394
395//------------------------------------------------------------------------------
396void vtkFreeTypeTools::InitializeCacheManager()
397{
398 this->ReleaseCacheManager();
399
400 FT_Error error;
401
402 // Create the cache manager itself
403 this->CacheManager = new FTC_Manager;
404
405 error = this->CreateFTCManager();
406
407 if (error)
408 {
409 vtkErrorMacro(<< "Failed allocating a new FreeType Cache Manager");
410 }
411
412 // The image cache
413 this->ImageCache = new FTC_ImageCache;
414 error = FTC_ImageCache_New(*this->CacheManager, this->ImageCache);
415
416 if (error)
417 {
418 vtkErrorMacro(<< "Failed allocating a new FreeType Image Cache");
419 }
420
421 // The charmap cache
422 this->CMapCache = new FTC_CMapCache;
423 error = FTC_CMapCache_New(*this->CacheManager, this->CMapCache);
424
425 if (error)
426 {
427 vtkErrorMacro(<< "Failed allocating a new FreeType CMap Cache");
428 }
429}
430
431//------------------------------------------------------------------------------
432void vtkFreeTypeTools::ReleaseCacheManager()

Callers 3

GetCacheManagerMethod · 0.95
GetImageCacheMethod · 0.95
GetCMapCacheMethod · 0.95

Calls 4

ReleaseCacheManagerMethod · 0.95
CreateFTCManagerMethod · 0.95
FTC_ImageCache_NewFunction · 0.85
FTC_CMapCache_NewFunction · 0.85

Tested by

no test coverage detected