| OLD | NEW |
| 1 | 1 |
| 2 /* | 2 /* |
| 3 * Copyright 2011 Google Inc. | 3 * Copyright 2011 Google Inc. |
| 4 * | 4 * |
| 5 * Use of this source code is governed by a BSD-style license that can be | 5 * Use of this source code is governed by a BSD-style license that can be |
| 6 * found in the LICENSE file. | 6 * found in the LICENSE file. |
| 7 */ | 7 */ |
| 8 | 8 |
| 9 #ifndef SkWriteBuffer_DEFINED | 9 #ifndef SkWriteBuffer_DEFINED |
| 10 #define SkWriteBuffer_DEFINED | 10 #define SkWriteBuffer_DEFINED |
| (...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 42 virtual void writeIntArray(const int32_t* value, uint32_t count) = 0; | 42 virtual void writeIntArray(const int32_t* value, uint32_t count) = 0; |
| 43 virtual void writeUInt(uint32_t value) = 0; | 43 virtual void writeUInt(uint32_t value) = 0; |
| 44 void write32(int32_t value) { | 44 void write32(int32_t value) { |
| 45 this->writeInt(value); | 45 this->writeInt(value); |
| 46 } | 46 } |
| 47 virtual void writeString(const char* value) = 0; | 47 virtual void writeString(const char* value) = 0; |
| 48 | 48 |
| 49 virtual void writeFlattenable(const SkFlattenable* flattenable) = 0; | 49 virtual void writeFlattenable(const SkFlattenable* flattenable) = 0; |
| 50 virtual void writeColor(SkColor color) = 0; | 50 virtual void writeColor(SkColor color) = 0; |
| 51 virtual void writeColorArray(const SkColor* color, uint32_t count) = 0; | 51 virtual void writeColorArray(const SkColor* color, uint32_t count) = 0; |
| 52 virtual void writeColor4f(const SkColor4f& color) = 0; |
| 53 virtual void writeColor4fArray(const SkColor4f* color, uint32_t count) = 0; |
| 52 virtual void writePoint(const SkPoint& point) = 0; | 54 virtual void writePoint(const SkPoint& point) = 0; |
| 53 virtual void writePointArray(const SkPoint* point, uint32_t count) = 0; | 55 virtual void writePointArray(const SkPoint* point, uint32_t count) = 0; |
| 54 virtual void writeMatrix(const SkMatrix& matrix) = 0; | 56 virtual void writeMatrix(const SkMatrix& matrix) = 0; |
| 55 virtual void writeIRect(const SkIRect& rect) = 0; | 57 virtual void writeIRect(const SkIRect& rect) = 0; |
| 56 virtual void writeRect(const SkRect& rect) = 0; | 58 virtual void writeRect(const SkRect& rect) = 0; |
| 57 virtual void writeRegion(const SkRegion& region) = 0; | 59 virtual void writeRegion(const SkRegion& region) = 0; |
| 58 virtual void writePath(const SkPath& path) = 0; | 60 virtual void writePath(const SkPath& path) = 0; |
| 59 virtual size_t writeStream(SkStream* stream, size_t length) = 0; | 61 virtual size_t writeStream(SkStream* stream, size_t length) = 0; |
| 60 virtual void writeBitmap(const SkBitmap& bitmap) = 0; | 62 virtual void writeBitmap(const SkBitmap& bitmap) = 0; |
| 61 virtual void writeImage(const SkImage*) = 0; | 63 virtual void writeImage(const SkImage*) = 0; |
| (...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 100 void writeScalar(SkScalar value) override; | 102 void writeScalar(SkScalar value) override; |
| 101 void writeScalarArray(const SkScalar* value, uint32_t count) override; | 103 void writeScalarArray(const SkScalar* value, uint32_t count) override; |
| 102 void writeInt(int32_t value) override; | 104 void writeInt(int32_t value) override; |
| 103 void writeIntArray(const int32_t* value, uint32_t count) override; | 105 void writeIntArray(const int32_t* value, uint32_t count) override; |
| 104 void writeUInt(uint32_t value) override; | 106 void writeUInt(uint32_t value) override; |
| 105 void writeString(const char* value) override; | 107 void writeString(const char* value) override; |
| 106 | 108 |
| 107 void writeFlattenable(const SkFlattenable* flattenable) override; | 109 void writeFlattenable(const SkFlattenable* flattenable) override; |
| 108 void writeColor(SkColor color) override; | 110 void writeColor(SkColor color) override; |
| 109 void writeColorArray(const SkColor* color, uint32_t count) override; | 111 void writeColorArray(const SkColor* color, uint32_t count) override; |
| 112 void writeColor4f(const SkColor4f& color) override; |
| 113 void writeColor4fArray(const SkColor4f* color, uint32_t count) override; |
| 110 void writePoint(const SkPoint& point) override; | 114 void writePoint(const SkPoint& point) override; |
| 111 void writePointArray(const SkPoint* point, uint32_t count) override; | 115 void writePointArray(const SkPoint* point, uint32_t count) override; |
| 112 void writeMatrix(const SkMatrix& matrix) override; | 116 void writeMatrix(const SkMatrix& matrix) override; |
| 113 void writeIRect(const SkIRect& rect) override; | 117 void writeIRect(const SkIRect& rect) override; |
| 114 void writeRect(const SkRect& rect) override; | 118 void writeRect(const SkRect& rect) override; |
| 115 void writeRegion(const SkRegion& region) override; | 119 void writeRegion(const SkRegion& region) override; |
| 116 void writePath(const SkPath& path) override; | 120 void writePath(const SkPath& path) override; |
| 117 size_t writeStream(SkStream* stream, size_t length) override; | 121 size_t writeStream(SkStream* stream, size_t length) override; |
| 118 void writeBitmap(const SkBitmap& bitmap) override; | 122 void writeBitmap(const SkBitmap& bitmap) override; |
| 119 void writeImage(const SkImage*) override; | 123 void writeImage(const SkImage*) override; |
| (...skipping 24 matching lines...) Expand all Loading... |
| 144 | 148 |
| 145 SkRefCntSet* fTFSet; | 149 SkRefCntSet* fTFSet; |
| 146 | 150 |
| 147 SkAutoTUnref<SkPixelSerializer> fPixelSerializer; | 151 SkAutoTUnref<SkPixelSerializer> fPixelSerializer; |
| 148 | 152 |
| 149 // Only used if we do not have an fFactorySet | 153 // Only used if we do not have an fFactorySet |
| 150 SkTHashMap<SkString, uint32_t> fFlattenableDict; | 154 SkTHashMap<SkString, uint32_t> fFlattenableDict; |
| 151 }; | 155 }; |
| 152 | 156 |
| 153 #endif // SkWriteBuffer_DEFINED | 157 #endif // SkWriteBuffer_DEFINED |
| OLD | NEW |