From a0ba714ad5ee26b3f1929aa572eb77cc71809e64 Mon Sep 17 00:00:00 2001 From: Brian Salomon Date: Mon, 20 Nov 2017 13:17:43 -0500 Subject: Require glyph positions in SkAtlasTextTarget::drawText Change-Id: Idf0977befc8ed4fd9eb3b733db5e945457b2164c Reviewed-on: https://skia-review.googlesource.com/73701 Reviewed-by: Ben Wagner Commit-Queue: Brian Salomon --- include/atlastext/SkAtlasTextTarget.h | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) (limited to 'include/atlastext') diff --git a/include/atlastext/SkAtlasTextTarget.h b/include/atlastext/SkAtlasTextTarget.h index a9d5dd5dca..ff879617d8 100644 --- a/include/atlastext/SkAtlasTextTarget.h +++ b/include/atlastext/SkAtlasTextTarget.h @@ -14,6 +14,7 @@ class SkAtlasTextContext; class SkAtlasTextFont; +struct SkPoint; /** Represents a client-created renderable surface and is used to draw text into the surface. */ class SK_API SkAtlasTextTarget { @@ -28,11 +29,12 @@ public: void* handle); /** - * Enqueues a text draw in the target. The meaning of 'color' here is interpreted by the - * client's SkAtlasTextRenderer when it actually renders the text. + * Enqueues a text draw in the target. The caller provides an array of glyphs and their + * positions. The meaning of 'color' here is interpreted by the client's SkAtlasTextRenderer + * when it actually renders the text. */ - virtual void drawText(const SkGlyphID*, int glyphCnt, SkScalar x, SkScalar y, uint32_t color, - const SkAtlasTextFont& font) = 0; + virtual void drawText(const SkGlyphID[], const SkPoint[], int glyphCnt, uint32_t color, + const SkAtlasTextFont&) = 0; /** Issues all queued text draws to SkAtlasTextRenderer. */ virtual void flush() = 0; -- cgit v1.2.3