Flutter Impeller
typographer_context_stb.h
Go to the documentation of this file.
1 // Copyright 2013 The Flutter 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 #pragma once
6 
8 
9 #include <memory>
10 #include "flutter/fml/macros.h"
11 
12 namespace impeller {
13 
15  public:
16  static std::unique_ptr<TypographerContext> Make();
17 
19 
20  ~TypographerContextSTB() override;
21 
22  // |TypographerContext|
23  std::shared_ptr<GlyphAtlasContext> CreateGlyphAtlasContext() const override;
24 
25  // |TypographerContext|
26  std::shared_ptr<GlyphAtlas> CreateGlyphAtlas(
27  Context& context,
28  GlyphAtlas::Type type,
29  std::shared_ptr<GlyphAtlasContext> atlas_context,
30  const FontGlyphMap& font_glyph_map) const override;
31 
32  private:
33  FML_DISALLOW_COPY_AND_ASSIGN(TypographerContextSTB);
34 };
35 
36 } // namespace impeller
impeller::TypographerContext
The graphics context necessary to render text.
Definition: typographer_context.h:22
impeller::TypographerContextSTB::TypographerContextSTB
TypographerContextSTB()
Definition: typographer_context_stb.cc:33
impeller::FontGlyphMap
std::unordered_map< ScaledFont, std::unordered_set< Glyph > > FontGlyphMap
Definition: font_glyph_pair.h:28
typographer_context.h
impeller::TypographerContextSTB::~TypographerContextSTB
~TypographerContextSTB() override
impeller::GlyphAtlas::Type
Type
Describes how the glyphs are represented in the texture.
Definition: glyph_atlas.h:32
impeller::TypographerContextSTB::Make
static std::unique_ptr< TypographerContext > Make()
Definition: typographer_context_stb.cc:29
impeller::TypographerContextSTB
Definition: typographer_context_stb.h:14
impeller::TypographerContextSTB::CreateGlyphAtlasContext
std::shared_ptr< GlyphAtlasContext > CreateGlyphAtlasContext() const override
Definition: typographer_context_stb.cc:38
impeller::TypographerContextSTB::CreateGlyphAtlas
std::shared_ptr< GlyphAtlas > CreateGlyphAtlas(Context &context, GlyphAtlas::Type type, std::shared_ptr< GlyphAtlasContext > atlas_context, const FontGlyphMap &font_glyph_map) const override
Definition: typographer_context_stb.cc:376
impeller::Context
To do anything rendering related with Impeller, you need a context.
Definition: context.h:47
impeller
Definition: aiks_context.cc:10