1 // Copyright 2020 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4 
5 #ifndef SKIA_EXT_LEGACY_DISPLAY_GLOBALS_H_
6 #define SKIA_EXT_LEGACY_DISPLAY_GLOBALS_H_
7 
8 #include "third_party/skia/include/core/SkSurfaceProps.h"
9 
10 namespace skia {
11 
12 class SK_API LegacyDisplayGlobals {
13  public:
14   static void SetCachedPixelGeometry(SkPixelGeometry pixel_geometry);
15   static SkPixelGeometry GetCachedPixelGeometry();
16 
17   // Returns a SkSurfaceProps with the cached geometry settings.
18   static SkSurfaceProps GetSkSurfaceProps();
19   static SkSurfaceProps GetSkSurfaceProps(uint32_t flags);
20 
21   // Will turn off LCD text if |can_use_lcd_text| is false.
22   static SkSurfaceProps ComputeSurfaceProps(bool can_use_lcd_text);
23 };
24 
25 }  // namespace skia
26 
27 #endif  // SKIA_EXT_LEGACY_DISPLAY_GLOBALS_H_
28