summaryrefslogtreecommitdiff
path: root/platform/default/local_glyph_rasterizer.cpp
diff options
context:
space:
mode:
authorChris Loer <chris.loer@gmail.com>2017-12-15 09:08:20 -0800
committerChris Loer <chris.loer@mapbox.com>2017-12-18 12:17:22 -0800
commita53818a10b821218b86478e048a3884db93f7c00 (patch)
tree9de0e83b67c163a4c8ed6f02736b2ad2ca2e8d15 /platform/default/local_glyph_rasterizer.cpp
parent2e3e88f0276bb6b6ade009549d8927f4af96bdd9 (diff)
downloadqtlocation-mapboxgl-a53818a10b821218b86478e048a3884db93f7c00.tar.gz
[core] Enable local glyph generation using TinySDF.
- Platform-specific LocalGlyphRasterizer is responsible for deciding which glyphs to rasterize locally and for implementing the rasterization. - Default platform implementation doesn't locally generate any glyphs -> no behavior change - Unit test uses StubLocalGlyphRasterizer, which returns a single fixed bitmap for all CJK glyphs - Rename glyph_loader.test to glyph_manager.test
Diffstat (limited to 'platform/default/local_glyph_rasterizer.cpp')
-rw-r--r--platform/default/local_glyph_rasterizer.cpp13
1 files changed, 13 insertions, 0 deletions
diff --git a/platform/default/local_glyph_rasterizer.cpp b/platform/default/local_glyph_rasterizer.cpp
new file mode 100644
index 0000000000..7ace6cbfb1
--- /dev/null
+++ b/platform/default/local_glyph_rasterizer.cpp
@@ -0,0 +1,13 @@
+#include <mbgl/text/local_glyph_rasterizer.hpp>
+
+namespace mbgl {
+
+bool LocalGlyphRasterizer::canRasterizeGlyph(const FontStack&, GlyphID) {
+ return false;
+}
+
+Glyph LocalGlyphRasterizer::rasterizeGlyph(const FontStack&, GlyphID) {
+ return Glyph();
+}
+
+} // namespace mbgl