Flutter Engine
The Flutter Engine
|
#include <SkLatticeIter.h>
Public Member Functions | |
SkLatticeIter (const SkCanvas::Lattice &lattice, const SkRect &dst) | |
SkLatticeIter (int imageWidth, int imageHeight, const SkIRect ¢er, const SkRect &dst) | |
bool | next (SkIRect *src, SkRect *dst, bool *isFixedColor=nullptr, SkColor *fixedColor=nullptr) |
bool | next (SkRect *src, SkRect *dst, bool *isFixedColor=nullptr, SkColor *fixedColor=nullptr) |
void | mapDstScaleTranslate (const SkMatrix &matrix) |
int | numRectsToDraw () const |
Static Public Member Functions | |
static bool | Valid (int imageWidth, int imageHeight, const SkCanvas::Lattice &lattice) |
static bool | Valid (int imageWidth, int imageHeight, const SkIRect ¢er) |
Disect a lattice request into an sequence of src-rect / dst-rect pairs
Definition at line 23 of file SkLatticeIter.h.
SkLatticeIter::SkLatticeIter | ( | const SkCanvas::Lattice & | lattice, |
const SkRect & | dst | ||
) |
Definition at line 120 of file SkLatticeIter.cpp.
SkLatticeIter::SkLatticeIter | ( | int | imageWidth, |
int | imageHeight, | ||
const SkIRect & | center, | ||
const SkRect & | dst | ||
) |
Definition at line 219 of file SkLatticeIter.cpp.
void SkLatticeIter::mapDstScaleTranslate | ( | const SkMatrix & | matrix | ) |
Apply a matrix to the dst points.
Definition at line 294 of file SkLatticeIter.cpp.
bool SkLatticeIter::next | ( | SkIRect * | src, |
SkRect * | dst, | ||
bool * | isFixedColor = nullptr , |
||
SkColor * | fixedColor = nullptr |
||
) |
While it returns true, use src/dst to draw the image/bitmap. Optional parameters isFixedColor and fixedColor specify if the rectangle is filled with a fixed color. If (*isFixedColor) is true, then (*fixedColor) contains the rectangle color.
Definition at line 262 of file SkLatticeIter.cpp.
|
inline |
Version of above that converts the integer src rect to a scalar rect.
Definition at line 43 of file SkLatticeIter.h.
|
inline |
Returns the number of rects that will actually be drawn.
Definition at line 61 of file SkLatticeIter.h.
|
static |
Definition at line 32 of file SkLatticeIter.cpp.
Definition at line 215 of file SkLatticeIter.cpp.