| OLD | NEW |
| 1 // Copyright 2014 PDFium Authors. All rights reserved. | 1 // Copyright 2014 PDFium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 // Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com | 5 // Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com |
| 6 | 6 |
| 7 #include "../../../include/fxge/fx_ge.h" | 7 #include "core/include/fxge/fx_ge.h" |
| 8 |
| 8 #include "text_int.h" | 9 #include "text_int.h" |
| 10 |
| 9 static CFX_GEModule* g_pGEModule = NULL; | 11 static CFX_GEModule* g_pGEModule = NULL; |
| 10 CFX_GEModule::CFX_GEModule(const char** pUserFontPaths) { | 12 CFX_GEModule::CFX_GEModule(const char** pUserFontPaths) { |
| 11 m_pFontCache = NULL; | 13 m_pFontCache = NULL; |
| 12 m_pFontMgr = NULL; | 14 m_pFontMgr = NULL; |
| 13 m_FTLibrary = NULL; | 15 m_FTLibrary = NULL; |
| 14 m_pCodecModule = NULL; | 16 m_pCodecModule = NULL; |
| 15 m_pPlatformData = NULL; | 17 m_pPlatformData = NULL; |
| 16 m_pUserFontPaths = pUserFontPaths; | 18 m_pUserFontPaths = pUserFontPaths; |
| 17 } | 19 } |
| 18 CFX_GEModule::~CFX_GEModule() { | 20 CFX_GEModule::~CFX_GEModule() { |
| (...skipping 30 matching lines...) Expand all Loading... |
| 49 int i = 0; | 51 int i = 0; |
| 50 while (i < 256) { | 52 while (i < 256) { |
| 51 m_GammaValue[i] = | 53 m_GammaValue[i] = |
| 52 (uint8_t)(FXSYS_pow((FX_FLOAT)i / 255, gammaValue) * 255.0f + 0.5f); | 54 (uint8_t)(FXSYS_pow((FX_FLOAT)i / 255, gammaValue) * 255.0f + 0.5f); |
| 53 i++; | 55 i++; |
| 54 } | 56 } |
| 55 } | 57 } |
| 56 const uint8_t* CFX_GEModule::GetTextGammaTable() { | 58 const uint8_t* CFX_GEModule::GetTextGammaTable() { |
| 57 return m_GammaValue; | 59 return m_GammaValue; |
| 58 } | 60 } |
| OLD | NEW |