Flutter Engine
The Flutter Engine
|
Holds all of the data (both required and optional) for a DisplayList drawVertices call. More...
#include <dl_vertices.h>
Classes | |
class | Builder |
A utility class to build up a |DlVertices| object one set of data at a time. More... | |
Public Member Functions | |
size_t | size () const |
Returns the size of the object including all of the inlined data. More... | |
SkRect | bounds () const |
Returns the bounds of the vertices. More... | |
DlVertexMode | mode () const |
int | vertex_count () const |
const SkPoint * | vertices () const |
Returns a pointer to the vertex information. Should be non-null. More... | |
const SkPoint * | texture_coordinates () const |
const DlColor * | colors () const |
int | index_count () const |
const uint16_t * | indices () const |
bool | operator== (DlVertices const &other) const |
bool | operator!= (DlVertices const &other) const |
Static Public Member Functions | |
static std::shared_ptr< DlVertices > | Make (DlVertexMode mode, int vertex_count, const SkPoint vertices[], const SkPoint texture_coordinates[], const DlColor colors[], int index_count=0, const uint16_t indices[]=nullptr) |
Constructs a DlVector with compact inline storage for all of its required and optional lists of data. More... | |
Friends | |
class | DisplayListBuilder |
Holds all of the data (both required and optional) for a DisplayList drawVertices call.
There are 4 main pices of data:
Note that each vertex is mapped to exactly 1 texture_coordinate and color even if the DlVertexMode or indices specify that it contributes to more than one output triangle.
Definition at line 71 of file dl_vertices.h.
|
inline |
Returns the bounds of the vertices.
Definition at line 194 of file dl_vertices.h.
|
inline |
Returns a pointer to the vertex colors or null if none were provided.
Definition at line 217 of file dl_vertices.h.
|
inline |
Returns a pointer to the count of vertex indices or 0 if none were provided.
Definition at line 223 of file dl_vertices.h.
|
inline |
Returns a pointer to the vertex indices or null if none were provided.
Definition at line 227 of file dl_vertices.h.
|
static |
Constructs a DlVector with compact inline storage for all of its required and optional lists of data.
Vertices are always required. Optional texture coordinates and optional colors are stored if the arguments are non-null. Optional indices will be stored iff the array argument is non-null and the index_count is positive (>0).
Definition at line 39 of file dl_vertices.cc.
|
inline |
Returns the vertex mode that defines how the vertices (or the indices) are turned into triangles.
Definition at line 198 of file dl_vertices.h.
|
inline |
Definition at line 233 of file dl_vertices.h.
bool flutter::DlVertices::operator== | ( | DlVertices const & | other | ) | const |
Definition at line 179 of file dl_vertices.cc.
size_t flutter::DlVertices::size | ( | ) | const |
Returns the size of the object including all of the inlined data.
Definition at line 82 of file dl_vertices.cc.
|
inline |
Returns a pointer to the vertex texture coordinate or null if none were provided.
Definition at line 211 of file dl_vertices.h.
|
inline |
Returns the number of vertices, which also applies to the number of texture coordinate and colors if they are provided.
Definition at line 202 of file dl_vertices.h.
|
inline |
Returns a pointer to the vertex information. Should be non-null.
Definition at line 205 of file dl_vertices.h.
|
friend |
Definition at line 282 of file dl_vertices.h.