Flutter Engine
The Flutter Engine
Loading...
Searching...
No Matches
Public Types | Public Attributes | List of all members
SkCanvas::Lattice Struct Reference

#include <SkCanvas.h>

Public Types

enum  RectType : uint8_t { kDefault = 0 , kTransparent , kFixedColor }
 

Public Attributes

const intfXDivs
 x-axis values dividing bitmap
 
const intfYDivs
 y-axis values dividing bitmap
 
const RectTypefRectTypes
 array of fill types
 
int fXCount
 number of x-coordinates
 
int fYCount
 number of y-coordinates
 
const SkIRectfBounds
 source bounds to draw from
 
const SkColorfColors
 array of colors
 

Detailed Description

SkCanvas::Lattice divides SkBitmap or SkImage into a rectangular grid. Grid entries on even columns and even rows are fixed; these entries are always drawn at their original size if the destination is large enough. If the destination side is too small to hold the fixed entries, all fixed entries are proportionately scaled down to fit. The grid entries not on even columns and rows are scaled to fit the remaining space, if any.

Definition at line 1601 of file SkCanvas.h.

Member Enumeration Documentation

◆ RectType

Enumerator
kDefault 

draws SkBitmap into lattice rectangle

kTransparent 

skips lattice rectangle by making it transparent

kFixedColor 

draws one of fColors into lattice rectangle

Definition at line 1607 of file SkCanvas.h.

1607 : uint8_t {
1608 kDefault = 0, //!< draws SkBitmap into lattice rectangle
1609 kTransparent, //!< skips lattice rectangle by making it transparent
1610 kFixedColor, //!< draws one of fColors into lattice rectangle
1611 };
@ kFixedColor
draws one of fColors into lattice rectangle
Definition SkCanvas.h:1610
@ kDefault
draws SkBitmap into lattice rectangle
Definition SkCanvas.h:1608
@ kTransparent
skips lattice rectangle by making it transparent
Definition SkCanvas.h:1609

Member Data Documentation

◆ fBounds

const SkIRect* SkCanvas::Lattice::fBounds

source bounds to draw from

Definition at line 1618 of file SkCanvas.h.

◆ fColors

const SkColor* SkCanvas::Lattice::fColors

array of colors

Definition at line 1619 of file SkCanvas.h.

◆ fRectTypes

const RectType* SkCanvas::Lattice::fRectTypes

array of fill types

Definition at line 1615 of file SkCanvas.h.

◆ fXCount

int SkCanvas::Lattice::fXCount

number of x-coordinates

Definition at line 1616 of file SkCanvas.h.

◆ fXDivs

const int* SkCanvas::Lattice::fXDivs

x-axis values dividing bitmap

Definition at line 1613 of file SkCanvas.h.

◆ fYCount

int SkCanvas::Lattice::fYCount

number of y-coordinates

Definition at line 1617 of file SkCanvas.h.

◆ fYDivs

const int* SkCanvas::Lattice::fYDivs

y-axis values dividing bitmap

Definition at line 1614 of file SkCanvas.h.


The documentation for this struct was generated from the following file: