SkPDFCanon
authorhalcanary <halcanary@google.com>
Wed, 21 Jan 2015 17:59:14 +0000 (09:59 -0800)
committerCommit bot <commit-bot@chromium.org>
Wed, 21 Jan 2015 17:59:14 +0000 (09:59 -0800)
commitfb62b3d423fa34c672df42f47017dbef087d19e9
tree014428ea2ca480f62b55d3d63db5115df577bff6
parent1c60dfe7ca0db010fa3118a1a2c7ff4c09136ab0
SkPDFCanon

SkPDFCanon's fields and methods will eventually become part of
SkPDFDocument/SkDocument_PDF.  For now, it exists as a singleton to
preflight that transition.  This replaces three global arrays in
SkPDFFont, SkPDFShader, and SkPDFGraphicsContext.  This code is still
thread-unsafe (http://skbug.com/2683), but moving this functionality
into SkPDFDocument will fix that.

This CL does not change pdf output from either GMs or SKPs.

This change also simplifies some code around the SkPDFCanon methods.

BUG=skia:2683

Review URL: https://codereview.chromium.org/842253003
gyp/pdf.gypi
src/pdf/SkPDFCanon.cpp [new file with mode: 0644]
src/pdf/SkPDFCanon.h [new file with mode: 0644]
src/pdf/SkPDFFont.cpp
src/pdf/SkPDFFont.h
src/pdf/SkPDFGraphicState.cpp
src/pdf/SkPDFGraphicState.h
src/pdf/SkPDFShader.cpp
src/pdf/SkPDFShader.h