All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
SkBinaryWriteBuffer Class Reference

Concrete implementation that serializes to a flat binary blob. More...

#include <SkWriteBuffer.h>

Inheritance diagram for SkBinaryWriteBuffer:

Public Types

enum  Flags { kCrossProcess_Flag = 1 << 0 }

Public Member Functions

 SkBinaryWriteBuffer (uint32_t flags=0)
 SkBinaryWriteBuffer (void *initialStorage, size_t storageSize, uint32_t flags=0)
bool isCrossProcess () const override
void write (const void *buffer, size_t bytes)
void reset (void *storage=NULL, size_t storageSize=0)
size_t bytesWritten () const
void writeByteArray (const void *data, size_t size) override
void writeBool (bool value) override
void writeScalar (SkScalar value) override
void writeScalarArray (const SkScalar *value, uint32_t count) override
void writeInt (int32_t value) override
void writeIntArray (const int32_t *value, uint32_t count) override
void writeUInt (uint32_t value) override
void writeString (const char *value) override
void writeFlattenable (const SkFlattenable *flattenable) override
void writeColor (SkColor color) override
void writeColorArray (const SkColor *color, uint32_t count) override
void writeColor4f (const SkColor4f &color) override
void writeColor4fArray (const SkColor4f *color, uint32_t count) override
void writePoint (const SkPoint &point) override
void writePointArray (const SkPoint *point, uint32_t count) override
void writeMatrix (const SkMatrix &matrix) override
void writeIRect (const SkIRect &rect) override
void writeRect (const SkRect &rect) override
void writeRegion (const SkRegion &region) override
void writePath (const SkPath &path) override
size_t writeStream (SkStream *stream, size_t length) override
void writeBitmap (const SkBitmap &bitmap) override
void writeImage (const SkImage *) override
void writeTypeface (SkTypeface *typeface) override
void writePaint (const SkPaint &paint) override
bool writeToStream (SkWStream *)
void writeToMemory (void *dst)
SkFactorySet * setFactoryRecorder (SkFactorySet *)
SkRefCntSet * setTypefaceRecorder (SkRefCntSet *)
void setPixelSerializer (sk_sp< SkPixelSerializer >)
 Set an SkPixelSerializer to store an encoded representation of pixels, e.g. More...
SkPixelSerializergetPixelSerializer () const
- Public Member Functions inherited from SkWriteBuffer
void writeDataAsByteArray (SkData *data)
void write32 (int32_t value)
void setDeduper (SkDeduper *deduper)

Private Attributes

const uint32_t fFlags
SkFactorySet * fFactorySet
SkWriter32 fWriter
SkRefCntSet * fTFSet
sk_sp< SkPixelSerializerfPixelSerializer
SkTHashMap< SkString, uint32_t > fFlattenableDict

Additional Inherited Members

- Protected Attributes inherited from SkWriteBuffer
SkDeduper * fDeduper = nullptr

Detailed Description

Concrete implementation that serializes to a flat binary blob.

Member Function Documentation

void SkBinaryWriteBuffer::setPixelSerializer ( sk_sp< SkPixelSerializer )

Set an SkPixelSerializer to store an encoded representation of pixels, e.g.


TODO: Encode SkImage pixels as well.

The documentation for this class was generated from the following file: