diff options
author | Mike Reed <reed@google.com> | 2017-07-17 21:12:19 +0000 |
---|---|---|
committer | Skia Commit-Bot <skia-commit-bot@chromium.org> | 2017-07-17 21:12:30 +0000 |
commit | 63b6f8b93209e593f60b235577f5b3d660396d5f (patch) | |
tree | 4864da686054d19002996f539b699e499018533a /src/pdf/SkPDFCanon.h | |
parent | 0983268dd52150fb968fb10bed2e8541095f12a1 (diff) |
Revert "SkPDF: Non-outline glyphs as images"
This reverts commit 3cf6b79e50f148cae7ed8c6ec0cd79f1ede71c95.
Reason for revert: breaking build
../../../../../work/skia/src/pdf/SkPDFDevice.cpp: In member function 'void SkPDFDevice::internalDrawText(const void*, size_t, const SkScalar*, SkTextBlob::GlyphPositioning, SkPoint, const SkPaint&, const uint32_t*, uint32_t, const char*)':
../../../../../work/skia/src/pdf/SkPDFDevice.cpp:1578:31: error: missing initializer for member 'SkPoint::fX' [-Werror=missing-field-initializers]
SkPoint xy = {};
^
Original change's description:
> SkPDF: Non-outline glyphs as images
>
> - Cache images in PDF Canon for de-duping
> - For now, rasterize at text scale. in the future, look at CTM and
> fRasterScale.
> - add a test that works on MacOS
>
> BUG=chromium:705480
> BUG=skia:3489
> Change-Id: I4fbc42f218e5b81ea15ea6cdccc61c91e532f6d0
> Reviewed-on: https://skia-review.googlesource.com/24080
> Commit-Queue: Hal Canary <halcanary@google.com>
> Reviewed-by: Ben Wagner <bungeman@google.com>
TBR=halcanary@google.com,bungeman@google.com
Change-Id: I3d8800fcb33817c6065da0860a534eb14350d132
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: chromium:705480, skia:3489
Reviewed-on: https://skia-review.googlesource.com/24160
Reviewed-by: Mike Reed <reed@google.com>
Commit-Queue: Mike Reed <reed@google.com>
Diffstat (limited to 'src/pdf/SkPDFCanon.h')
-rw-r--r-- | src/pdf/SkPDFCanon.h | 25 |
1 files changed, 2 insertions, 23 deletions
diff --git a/src/pdf/SkPDFCanon.h b/src/pdf/SkPDFCanon.h index 8edd06e391..03671bf921 100644 --- a/src/pdf/SkPDFCanon.h +++ b/src/pdf/SkPDFCanon.h @@ -7,14 +7,13 @@ #ifndef SkPDFCanon_DEFINED #define SkPDFCanon_DEFINED -#include "SkBitmapKey.h" -#include "SkPDFGradientShader.h" #include "SkPDFGraphicState.h" #include "SkPDFShader.h" +#include "SkPDFGradientShader.h" #include "SkPixelSerializer.h" #include "SkTDArray.h" #include "SkTHash.h" -#include "SkTypeface.h" +#include "SkBitmapKey.h" class SkPDFFont; struct SkAdvancedTypefaceMetrics; @@ -47,25 +46,5 @@ public: sk_sp<SkPDFStream> fInvertFunction; sk_sp<SkPDFDict> fNoSmaskGraphicState; sk_sp<SkPDFArray> fRangeObject; - - SK_BEGIN_REQUIRE_DENSE - struct BitmapGlyphKey { - SkFontID fFontID; // uint32_t - SkScalar fTextSize; // float32 - SkScalar fTextScaleX; // float32 - SkScalar fTextSkewX; // float32 - SkGlyphID fGlyphID; // uint16_t - uint16_t fPadding; - }; - SK_END_REQUIRE_DENSE - struct BitmapGlyph { - sk_sp<SkImage> fImage; - SkIPoint fOffset; - }; - SkTHashMap<BitmapGlyphKey, BitmapGlyph> fBitmapGlyphImages; }; - -inline bool operator==(const SkPDFCanon::BitmapGlyphKey& u, const SkPDFCanon::BitmapGlyphKey& v) { - return memcmp(&u, &u, sizeof(SkPDFCanon::BitmapGlyphKey)) == 0; -} #endif // SkPDFCanon_DEFINED |