#include <GrGeometryProcessor.h>
Describes a vertex or instance attribute.
Definition at line 66 of file GrGeometryProcessor.h.
◆ Attribute() [1/4]
constexpr GrGeometryProcessor::Attribute::Attribute |
( |
| ) |
|
|
constexprdefault |
◆ Attribute() [2/4]
Makes an attribute whose offset will be implicitly determined by the types and ordering of an array attributes.
Definition at line 75 of file GrGeometryProcessor.h.
80 }
constexpr GrVertexAttribType cpuType() const
constexpr const char * name() const
constexpr SkSLType gpuType() const
◆ Attribute() [3/4]
constexpr GrGeometryProcessor::Attribute::Attribute |
( |
const char * |
name, |
|
|
GrVertexAttribType |
cpuType, |
|
|
SkSLType |
gpuType, |
|
|
size_t |
offset |
|
) |
| |
|
inlineconstexpr |
Makes an attribute with an explicit offset.
Definition at line 84 of file GrGeometryProcessor.h.
91 }
constexpr uint32_t SkToU32(S x)
std::optional< size_t > offset() const
static constexpr size_t AlignOffset(size_t offset)
◆ Attribute() [4/4]
constexpr GrGeometryProcessor::Attribute::Attribute |
( |
const Attribute & |
| ) |
|
|
constexprdefault |
◆ AlignOffset()
static constexpr size_t GrGeometryProcessor::Attribute::AlignOffset |
( |
size_t |
offset | ) |
|
|
inlinestaticconstexpr |
◆ asShaderVar()
GrShaderVar GrGeometryProcessor::Attribute::asShaderVar |
( |
| ) |
const |
|
inline |
◆ cpuType()
◆ gpuType()
constexpr SkSLType GrGeometryProcessor::Attribute::gpuType |
( |
| ) |
const |
|
inlineconstexpr |
◆ isInitialized()
constexpr bool GrGeometryProcessor::Attribute::isInitialized |
( |
| ) |
const |
|
inlineconstexpr |
◆ name()
constexpr const char * GrGeometryProcessor::Attribute::name |
( |
| ) |
const |
|
inlineconstexpr |
◆ offset()
std::optional< size_t > GrGeometryProcessor::Attribute::offset |
( |
| ) |
const |
|
inline |
Returns the offset if attributes were specified with explicit offsets. Otherwise, offsets (and total vertex stride) are implicitly determined from attribute order and types.
Definition at line 106 of file GrGeometryProcessor.h.
106 {
107 if (fOffset != kImplicitOffset) {
109 return {fOffset};
110 }
111 return std::nullopt;
112 }
◆ operator=()
◆ size()
constexpr size_t GrGeometryProcessor::Attribute::size |
( |
| ) |
const |
|
inlineconstexpr |
Definition at line 566 of file GrGeometryProcessor.h.
566 {
568}
static constexpr size_t GrVertexAttribTypeSize(GrVertexAttribType type)
The documentation for this class was generated from the following file: