chromium/third_party/skia/src/core/SkWriteBuffer.cpp

/*
 * Copyright 2012 Google Inc.
 *
 * Use of this source code is governed by a BSD-style license that can be
 * found in the LICENSE file.
 */

#include "src/core/SkWriteBuffer.h"

#include "include/core/SkAlphaType.h"
#include "include/core/SkData.h"
#include "include/core/SkFlattenable.h"
#include "include/core/SkImage.h"
#include "include/core/SkPoint.h"
#include "include/core/SkPoint3.h"
#include "include/core/SkRect.h"
#include "include/core/SkTypeface.h"
#include "include/private/base/SkAssert.h"
#include "include/private/base/SkTFitsIn.h"
#include "include/private/base/SkTo.h"
#include "src/core/SkMatrixPriv.h"
#include "src/core/SkMipmap.h"
#include "src/core/SkPaintPriv.h"
#include "src/core/SkPtrRecorder.h"
#include "src/image/SkImage_Base.h"

#if !defined(SK_DISABLE_LEGACY_PNG_WRITEBUFFER)
#include "include/core/SkBitmap.h"
#include "include/core/SkStream.h"
#include "include/encode/SkPngEncoder.h"
#endif

#include <cstring>
#include <utility>

class SkMatrix;
class SkPaint;
class SkRegion;

///////////////////////////////////////////////////////////////////////////////////////////////////

SkBinaryWriteBuffer::SkBinaryWriteBuffer(const SkSerialProcs& p)
        :{}

SkBinaryWriteBuffer::SkBinaryWriteBuffer(void* storage, size_t storageSize, const SkSerialProcs& p)
        :{}

SkBinaryWriteBuffer::~SkBinaryWriteBuffer() {}

bool SkBinaryWriteBuffer::usingInitialStorage() const {}

void SkBinaryWriteBuffer::writeByteArray(const void* data, size_t size) {}

void SkBinaryWriteBuffer::writeBool(bool value) {}

void SkBinaryWriteBuffer::writeScalar(SkScalar value) {}

void SkBinaryWriteBuffer::writeScalarArray(const SkScalar* value, uint32_t count) {}

void SkBinaryWriteBuffer::writeInt(int32_t value) {}

void SkBinaryWriteBuffer::writeIntArray(const int32_t* value, uint32_t count) {}

void SkBinaryWriteBuffer::writeUInt(uint32_t value) {}

void SkBinaryWriteBuffer::writeString(std::string_view value) {}

void SkBinaryWriteBuffer::writeColor(SkColor color) {}

void SkBinaryWriteBuffer::writeColorArray(const SkColor* color, uint32_t count) {}

void SkBinaryWriteBuffer::writeColor4f(const SkColor4f& color) {}

void SkBinaryWriteBuffer::writeColor4fArray(const SkColor4f* color, uint32_t count) {}

void SkBinaryWriteBuffer::writePoint(const SkPoint& point) {}

void SkBinaryWriteBuffer::writePoint3(const SkPoint3& point) {}

void SkBinaryWriteBuffer::writePointArray(const SkPoint* point, uint32_t count) {}

void SkBinaryWriteBuffer::write(const SkM44& matrix) {}

void SkBinaryWriteBuffer::writeMatrix(const SkMatrix& matrix) {}

void SkBinaryWriteBuffer::writeIRect(const SkIRect& rect) {}

void SkBinaryWriteBuffer::writeRect(const SkRect& rect) {}

void SkBinaryWriteBuffer::writeRegion(const SkRegion& region) {}

void SkBinaryWriteBuffer::writeSampling(const SkSamplingOptions& sampling) {}

void SkBinaryWriteBuffer::writePath(const SkPath& path) {}

size_t SkBinaryWriteBuffer::writeStream(SkStream* stream, size_t length) {}

bool SkBinaryWriteBuffer::writeToStream(SkWStream* stream) const {}

static sk_sp<SkData> serialize_image(const SkImage* image, SkSerialProcs procs) {}

static sk_sp<SkData> serialize_mipmap(const SkMipmap* mipmap, SkSerialProcs procs) {}

/*  Format:
 *      flags: U32
 *      encoded : size_32 + data[]
 *      [subset: IRect]
 *      [mips]  : size_32 + data[]
 */
void SkBinaryWriteBuffer::writeImage(const SkImage* image) {}

void SkBinaryWriteBuffer::writeTypeface(SkTypeface* obj) {}

void SkBinaryWriteBuffer::writePaint(const SkPaint& paint) {}

void SkBinaryWriteBuffer::setFactoryRecorder(sk_sp<SkFactorySet> rec) {}

void SkBinaryWriteBuffer::setTypefaceRecorder(sk_sp<SkRefCntSet> rec) {}

void SkBinaryWriteBuffer::writeFlattenable(const SkFlattenable* flattenable) {}