#include <SkPictureShader.h>
|
| SkPictureShader (sk_sp< SkPicture >, SkTileMode, SkTileMode, SkFilterMode, const SkRect *) |
|
ShaderType | type () const override |
|
sk_sp< SkPicture > | picture () const |
|
SkRect | tile () const |
|
SkTileMode | tileModeX () const |
|
SkTileMode | tileModeY () const |
|
SkFilterMode | filter () const |
|
| ~SkShaderBase () override |
|
sk_sp< SkShader > | makeInvertAlpha () const |
|
sk_sp< SkShader > | makeWithCTM (const SkMatrix &) const |
|
virtual bool | isConstant () const |
|
virtual GradientType | asGradient (GradientInfo *info=nullptr, SkMatrix *localMatrix=nullptr) const |
|
Context * | makeContext (const ContextRec &, SkArenaAlloc *) const |
|
bool | asLuminanceColor (SkColor4f *) const |
|
bool | appendRootStages (const SkStageRec &rec, const SkMatrix &ctm) const |
|
virtual SkImage * | onIsAImage (SkMatrix *, SkTileMode[2]) const |
|
virtual SkRuntimeEffect * | asRuntimeEffect () const |
|
Type | getFlattenableType () const override |
|
virtual sk_sp< SkShader > | makeAsALocalMatrixShader (SkMatrix *localMatrix) const |
|
virtual bool | isOpaque () const |
|
SkImage * | isAImage (SkMatrix *localMatrix, SkTileMode xy[2]) const |
|
bool | isAImage () const |
|
sk_sp< SkShader > | makeWithLocalMatrix (const SkMatrix &) const |
|
sk_sp< SkShader > | makeWithColorFilter (sk_sp< SkColorFilter >) const |
|
sk_sp< SkShader > | makeWithWorkingColorSpace (sk_sp< SkColorSpace >) const |
|
| SkFlattenable () |
|
virtual Factory | getFactory () const =0 |
|
virtual const char * | getTypeName () const =0 |
|
sk_sp< SkData > | serialize (const SkSerialProcs *=nullptr) const |
|
size_t | serialize (void *memory, size_t memory_size, const SkSerialProcs *=nullptr) const |
|
| SkRefCntBase () |
|
virtual | ~SkRefCntBase () |
|
bool | unique () const |
|
void | ref () const |
|
void | unref () const |
|
|
static sk_sp< SkShader > | Make (sk_sp< SkPicture >, SkTileMode, SkTileMode, SkFilterMode, const SkMatrix *, const SkRect *) |
|
static Type | GetFlattenableType () |
|
static sk_sp< SkShaderBase > | Deserialize (const void *data, size_t size, const SkDeserialProcs *procs=nullptr) |
|
static void | RegisterFlattenables () |
|
static SkMatrix | ConcatLocalMatrices (const SkMatrix &parentLM, const SkMatrix &childLM) |
|
static Factory | NameToFactory (const char name[]) |
|
static const char * | FactoryToName (Factory) |
|
static void | Register (const char name[], Factory) |
|
static sk_sp< SkFlattenable > | Deserialize (Type, const void *data, size_t length, const SkDeserialProcs *procs=nullptr) |
|
Definition at line 40 of file SkPictureShader.h.
◆ SkPictureShader() [1/2]
Definition at line 113 of file SkPictureShader.cpp.
119 , fTile(
tile ? *
tile : fPicture->cullRect())
SkFilterMode filter() const
sk_sp< SkPicture > picture() const
◆ SkPictureShader() [2/2]
◆ appendStages()
Adds stages to implement this shader. To ensure that the correct input coords are present in r,g MatrixRec::apply() must be called (unless the shader doesn't require it's input coords). The default impl creates shadercontext and calls that (not very efficient).
Implements SkShaderBase.
Definition at line 288 of file SkPictureShader.cpp.
288 {
289
291
292
293
294
295 bitmapShader = this->rasterShader(mRec.totalMatrix(),
296 rec.fDstColorType,
297 rec.fDstCS,
298 rec.fSurfaceProps);
299 if (!bitmapShader) {
300 return false;
301 }
303}
SkShaderBase * as_SB(SkShader *shader)
virtual bool appendStages(const SkStageRec &, const SkShaders::MatrixRec &) const =0
◆ filter()
◆ flatten()
Override this if your subclass needs to record data that it will need to recreate itself from its CreateProc (returned by getFactory()).
DEPRECATED public : will move to protected ... use serialize() instead
Reimplemented from SkFlattenable.
Definition at line 168 of file SkPictureShader.cpp.
168 {
169 buffer.write32((
unsigned)fTmx);
170 buffer.write32((
unsigned)fTmy);
172 buffer.write32((
unsigned)fFilter);
174}
static void Flatten(const sk_sp< const SkPicture >, SkWriteBuffer &buffer)
static const uint8_t buffer[]
◆ Make()
Definition at line 124 of file SkPictureShader.cpp.
125 {
127 return SkShaders::Empty();
128 }
129 return SkLocalMatrixShader::MakeWrapped<SkPictureShader>(lm,
134}
virtual SkRect cullRect() const =0
◆ picture()
◆ tile()
SkRect SkPictureShader::tile |
( |
| ) |
const |
|
inline |
◆ tileModeX()
◆ tileModeY()
◆ type()
The documentation for this class was generated from the following files: