![]() |
Qt 6.x
The Qt SDK
|
The QSGGeometry::Attribute describes a single vertex attribute in a QSGGeometry. More...
#include <qsggeometry.h>
Static Public Member Functions | |
static Attribute | create (int pos, int tupleSize, int primitiveType, bool isPosition=false) |
Creates a new QSGGeometry::Attribute for attribute register pos with tupleSize. | |
static Attribute | createWithAttributeType (int pos, int tupleSize, int primitiveType, AttributeType attributeType) |
Creates a new QSGGeometry::Attribute for attribute register pos with tupleSize. | |
Public Attributes | |
int | position |
int | tupleSize |
int | type |
uint | isVertexCoordinate: 1 |
AttributeType | attributeType: 4 |
uint | reserved: 27 |
The QSGGeometry::Attribute describes a single vertex attribute in a QSGGeometry.
\inmodule QtQuick
The QSGGeometry::Attribute struct describes the attribute register position, the size of the attribute tuple and the attribute type.
It also contains a hint to the renderer if this attribute is the attribute describing the position. The scene graph renderer may use this information to perform optimizations.
It contains a number of bits which are reserved for future use.
Definition at line 57 of file qsggeometry.h.
|
static |
Creates a new QSGGeometry::Attribute for attribute register pos with tupleSize.
The primitiveType can be any of the supported types from QSGGeometry::Type, such as QSGGeometry::FloatType or QSGGeometry::UnsignedByteType.
If the attribute describes the position for the vertex, the isPosition hint should be set to true
. The scene graph renderer may use this information to perform optimizations.
Use the create function to construct the attribute, rather than an initialization list, to ensure that all fields are initialized.
Definition at line 14 of file qsggeometry.cpp.
References tupleSize, and QSGGeometry::UnknownAttribute.
|
static |
Creates a new QSGGeometry::Attribute for attribute register pos with tupleSize.
The primitiveType can be any of the supported types from QSGGeometry::Type, such as QSGGeometry::FloatType or QSGGeometry::UnsignedByteType.
attributeType describes the intended use of the attribute.
Use the create function to construct the attribute, rather than an initialization list, to ensure that all fields are initialized.
Definition at line 20 of file qsggeometry.cpp.
References pos, and QSGGeometry::PositionAttribute.
Referenced by QQuickShapeStrokeNode::attributes(), QSGGeometry::defaultAttributes_ColoredPoint2D(), QSGGeometry::defaultAttributes_Point2D(), QSGGeometry::defaultAttributes_TexturedPoint2D(), QT_BEGIN_NAMESPACE::smoothAttributeSet(), and QT_BEGIN_NAMESPACE::smoothImageAttributeSet().
AttributeType QSGGeometry::Attribute::attributeType |
Definition at line 65 of file qsggeometry.h.
uint QSGGeometry::Attribute::isVertexCoordinate |
Definition at line 63 of file qsggeometry.h.
Referenced by QSGBatchRenderer::qsg_positionAttribute().
int QSGGeometry::Attribute::position |
Definition at line 59 of file qsggeometry.h.
uint QSGGeometry::Attribute::reserved |
Definition at line 67 of file qsggeometry.h.
int QSGGeometry::Attribute::tupleSize |
Definition at line 60 of file qsggeometry.h.
Referenced by create(), and QSGBatchRenderer::qsg_positionAttribute().
int QSGGeometry::Attribute::type |
Definition at line 61 of file qsggeometry.h.
Referenced by QSGBatchRenderer::qsg_positionAttribute().