#include "src/core/SkPaintPriv.h"
#include "include/core/SkBlendMode.h"
#include "include/core/SkBlender.h"
#include "include/core/SkColorFilter.h"
#include "include/core/SkColorType.h"
#include "include/core/SkImageFilter.h"
#include "include/core/SkMaskFilter.h"
#include "include/core/SkPaint.h"
#include "include/core/SkPathEffect.h"
#include "include/core/SkRefCnt.h"
#include "include/core/SkShader.h"
#include "include/private/base/SkAssert.h"
#include "include/private/base/SkDebug.h"
#include "src/core/SkColorSpacePriv.h"
#include "src/core/SkPicturePriv.h"
#include "src/core/SkReadBuffer.h"
#include "src/core/SkSafeRange.h"
#include "src/core/SkWriteBuffer.h"
#include "src/effects/colorfilters/SkColorFilterBase.h"
#include "src/shaders/SkColorFilterShader.h"
#include "src/shaders/SkShaderBase.h"
#include <cstdint>
#include <optional>
class SkColorSpace;
static bool changes_alpha(const SkPaint& paint) { … }
enum SrcColorOpacity { … };
static bool blend_mode_is_opaque(SkBlendMode mode, SrcColorOpacity opacityType) { … }
bool SkPaintPriv::Overwrites(const SkPaint* paint, ShaderOverrideOpacity overrideOpacity) { … }
bool SkPaintPriv::ShouldDither(const SkPaint& p, SkColorType dstCT) { … }
static bool just_a_color(const SkPaint& paint, SkColor4f* color) { … }
SkColor SkPaintPriv::ComputeLuminanceColor(const SkPaint& paint) { … }
void SkPaintPriv::RemoveColorFilter(SkPaint* p, SkColorSpace* dstCS) { … }
#ifdef SK_DEBUG
static void ASSERT_FITS_IN(uint32_t value, int bitCount) { … }
#else
#define ASSERT_FITS_IN …
#endif
enum FlatFlags { … };
template <typename T> uint32_t shift_bits(T value, unsigned shift, unsigned bits) { … }
constexpr uint8_t CUSTOM_BLEND_MODE_SENTINEL = …;
static uint32_t pack_v68(const SkPaint& paint, unsigned flatFlags) { … }
static uint32_t unpack_v68(SkPaint* paint, uint32_t packed, SkSafeRange& safe) { … }
void SkPaintPriv::Flatten(const SkPaint& paint, SkWriteBuffer& buffer) { … }
SkPaint SkPaintPriv::Unflatten(SkReadBuffer& buffer) { … }