#include "src/codec/SkWbmpCodec.h"
#include "include/codec/SkCodec.h"
#include "include/codec/SkEncodedImageFormat.h"
#include "include/codec/SkWbmpDecoder.h"
#include "include/core/SkColorType.h"
#include "include/core/SkData.h"
#include "include/core/SkImageInfo.h"
#include "include/core/SkRefCnt.h"
#include "include/core/SkSize.h"
#include "include/core/SkStream.h"
#include "include/private/SkEncodedInfo.h"
#include "include/private/base/SkAlign.h"
#include "include/private/base/SkTo.h"
#include "modules/skcms/skcms.h"
#include "src/codec/SkCodecPriv.h"
#include <utility>
usingnamespaceskia_private;
static inline size_t get_src_row_bytes(int width) { … }
static inline bool valid_color_type(const SkImageInfo& dstInfo) { … }
static bool read_byte(SkStream* stream, uint8_t* data)
{ … }
static bool read_mbf(SkStream* stream, uint64_t* value) { … }
static bool read_header(SkStream* stream, SkISize* size) { … }
bool SkWbmpCodec::onRewind() { … }
bool SkWbmpCodec::readRow(uint8_t* row) { … }
SkWbmpCodec::SkWbmpCodec(SkEncodedInfo&& info, std::unique_ptr<SkStream> stream)
: … { … }
SkEncodedImageFormat SkWbmpCodec::onGetEncodedFormat() const { … }
bool SkWbmpCodec::conversionSupported(const SkImageInfo& dst, bool srcIsOpaque,
bool ) { … }
SkCodec::Result SkWbmpCodec::onGetPixels(const SkImageInfo& info,
void* dst,
size_t rowBytes,
const Options& options,
int* rowsDecoded) { … }
bool SkWbmpCodec::IsWbmp(const void* buffer, size_t bytesRead) { … }
std::unique_ptr<SkCodec> SkWbmpCodec::MakeFromStream(std::unique_ptr<SkStream> stream,
Result* result) { … }
int SkWbmpCodec::onGetScanlines(void* dst, int count, size_t dstRowBytes) { … }
bool SkWbmpCodec::onSkipScanlines(int count) { … }
SkCodec::Result SkWbmpCodec::onStartScanlineDecode(const SkImageInfo& dstInfo,
const Options& options) { … }
namespace SkWbmpDecoder {
bool IsWbmp(const void* data, size_t len) { … }
std::unique_ptr<SkCodec> Decode(std::unique_ptr<SkStream> stream,
SkCodec::Result* outResult,
SkCodecs::DecodeContext) { … }
std::unique_ptr<SkCodec> Decode(sk_sp<SkData> data,
SkCodec::Result* outResult,
SkCodecs::DecodeContext) { … }
}