Index: src/pdf/SkPDFUtils.h |
diff --git a/src/pdf/SkPDFUtils.h b/src/pdf/SkPDFUtils.h |
index 124e19961481a6d48da583f8a00c923fe1ef0b03..3ddd3d0933c00aed8f31df03867c2915c2a5a4f7 100644 |
--- a/src/pdf/SkPDFUtils.h |
+++ b/src/pdf/SkPDFUtils.h |
@@ -76,6 +76,13 @@ inline void WriteUInt16BE(SkDynamicMemoryWStream* wStream, uint16_t value) { |
result[3] = gHex[0xF & (value )]; |
wStream->write(result, 4); |
} |
+inline void WriteUInt8(SkDynamicMemoryWStream* wStream, uint8_t value) { |
+ static const char gHex[] = "0123456789ABCDEF"; |
+ char result[2]; |
+ result[0] = gHex[value >> 4 ]; |
+ result[1] = gHex[0xF & value]; |
+ wStream->write(result, 2); |
+} |
} // namespace SkPDFUtils |