8#ifndef SkReadBuffer_DEFINED
9#define SkReadBuffer_DEFINED
66 return fVersion > 0 && fVersion < targetVersion;
77 size_t size()
const {
return fStop - fBase; }
78 size_t offset()
const {
return fCurr - fBase; }
79 bool eof() {
return fCurr >= fStop; }
84 template <
typename T>
const T*
skipT() {
85 return static_cast<const T*
>(this->
skip(
sizeof(
T)));
88 return static_cast<const T*
>(this->
skip(count,
sizeof(
T)));
101 if (!this->
validate(value <=
static_cast<uint32_t
>(
max))) {
104 return static_cast<T>(
value);
177 fFactoryArray = array;
178 fFactoryCount =
count;
203 template <
typename T>
220 return static_cast<T>(this->
checkInt(
static_cast<int32_t
>(
min),
221 static_cast<int32_t
>(
max)));
232 bool readArray(
void*
value,
size_t size,
size_t elementSize);
236 const char* fCurr =
nullptr;
237 const char* fStop =
nullptr;
238 const char* fBase =
nullptr;
249 int fFactoryCount = 0;
253 static bool IsPtrAlign4(
const void* ptr) {
257 bool fAllowSkSL =
true;
static const int points[]
static constexpr bool SkIsAlign4(T x)
sk_sp< SkFlattenable >(* Factory)(SkReadBuffer &)
static SkPaint Unflatten(SkReadBuffer &buffer)
const T * skipT(size_t count)
bool readColor4fArray(SkColor4f *colors, size_t size)
uint32_t getVersion() const
void readColor4f(SkColor4f *color)
SkLegacyFQ checkFilterQuality()
SkFlattenable * readRawFlattenable()
const void * skipByteArray(size_t *size)
void readMatrix(SkMatrix *matrix)
void setMemory(const void *, size_t)
bool readByteArray(void *value, size_t size)
bool validate(bool isValid)
bool readIntArray(int32_t *values, size_t size)
const void * skip(size_t size)
sk_sp< SkData > readByteArrayAsData()
void readIRect(SkIRect *rect)
void setAllowSkSL(bool allow)
bool validateIndex(int index, int count)
void setDeserialProcs(const SkDeserialProcs &procs)
const SkDeserialProcs & getDeserialProcs() const
void setTypefaceArray(sk_sp< SkTypeface > array[], int count)
SkSamplingOptions readSampling()
sk_sp< SkPathEffect > readPathEffect()
T checkRange(T min, T max)
void setFactoryPlayback(SkFlattenable::Factory array[], int count)
bool readPointArray(SkPoint *points, size_t size)
sk_sp< SkColorFilter > readColorFilter()
sk_sp< SkBlender > readBlender()
sk_sp< SkTypeface > readTypeface()
void readString(SkString *string)
void setVersion(int version)
SkReadBuffer(const void *data, size_t size)
bool readColorArray(SkColor *colors, size_t size)
bool readPad32(void *buffer, size_t bytes)
sk_sp< SkMaskFilter > readMaskFilter()
sk_sp< SkShader > readShader()
int32_t checkInt(int min, int max)
sk_sp< T > readFlattenable()
bool readScalarArray(SkScalar *values, size_t size)
void readPoint3(SkPoint3 *point)
sk_sp< SkImage > readImage()
void readRRect(SkRRect *rrect)
bool validateCanReadN(size_t n)
void readRegion(SkRegion *region)
void readPath(SkPath *path)
sk_sp< SkImageFilter > readImageFilter()
bool isVersionLT(SkPicturePriv::Version targetVersion) const
static float max(float r, float g, float b)
static float min(float r, float g, float b)
unsigned useCenter Optional< SkMatrix > matrix
ClipOpAndAA opAA SkRegion region
sk_sp< SkBlender > blender SkRect rect
PODArray< SkColor > colors
DEF_SWITCHES_START aot vmservice shared library Name of the *so containing AOT compiled Dart assets for launching the service isolate vm snapshot The VM snapshot data that will be memory mapped as read only SnapshotAssetPath must be present isolate snapshot The isolate snapshot data that will be memory mapped as read only SnapshotAssetPath must be present cache dir path
DEF_SWITCHES_START aot vmservice shared library Name of the *so containing AOT compiled Dart assets for launching the service isolate vm snapshot The VM snapshot data that will be memory mapped as read only SnapshotAssetPath must be present isolate snapshot The isolate snapshot data that will be memory mapped as read only SnapshotAssetPath must be present cache dir Path to the cache directory This is different from the persistent_cache_path in embedder which is used for Skia shader cache icu native lib Path to the library file that exports the ICU data vm service The hostname IP address on which the Dart VM Service should be served If not defaults to or::depending on whether ipv6 is specified vm service A custom Dart VM Service port The default is to pick a randomly available open port disable vm Disable the Dart VM Service The Dart VM Service is never available in release mode disable vm service Disable mDNS Dart VM Service publication Bind to the IPv6 localhost address for the Dart VM Service Ignored if vm service host is set endless trace buffer
std::shared_ptr< const fml::Mapping > data