QPlaneGeometry Class

(Qt3DExtras::QPlaneGeometry)

The QPlaneGeometry class allows creation of a plane in 3D space. 更多...

头文件: #include <Qt3DExtras/QPlaneGeometry>
qmake: QT += 3dextras
开始支持版本: Qt 5.7
Instantiated By: PlaneGeometry
基类: Qt3DRender::QGeometry

属性

公有函数

QPlaneGeometry(QNode *parent = nullptr)
float height() const
Qt3DRender::QAttribute *indexAttribute() const
bool mirrored() const
Qt3DRender::QAttribute *normalAttribute() const
Qt3DRender::QAttribute *positionAttribute() const
QSize resolution() const
Qt3DRender::QAttribute *tangentAttribute() const
Qt3DRender::QAttribute *texCoordAttribute() const
void updateIndices()
void updateVertices()
float width() const

公有槽函数

void setHeight(float height)
void setMirrored(bool mirrored)
void setResolution(const QSize &resolution)
void setWidth(float width)

信号

void heightChanged(float height)
void mirroredChanged(bool mirrored)
void resolutionChanged(const QSize &resolution)
void widthChanged(float width)

其他继承的成员

详细描述

The QPlaneGeometry class allows creation of a plane in 3D space.

The QPlaneGeometry class is most commonly used internally by the QPlaneMesh but can also be used in custom Qt3DRender::QGeometryRenderer subclasses.

属性

height : float

Holds the plane height.

访问函数:

float height() const
void setHeight(float height)

Notifier signal:

void heightChanged(float height)

indexAttribute : Qt3DRender::QAttribute * const

Holds the geometry index attribute.

访问函数:

Qt3DRender::QAttribute *indexAttribute() const

mirrored : bool

Controls if the UV coordinates of the plane should be flipped vertically.

This property was introduced in Qt 5.9.

访问函数:

bool mirrored() const
void setMirrored(bool mirrored)

Notifier signal:

void mirroredChanged(bool mirrored)

normalAttribute : Qt3DRender::QAttribute * const

Holds the geometry normal attribute.

访问函数:

Qt3DRender::QAttribute *normalAttribute() const

positionAttribute : Qt3DRender::QAttribute * const

Holds the geometry position attribute.

访问函数:

Qt3DRender::QAttribute *positionAttribute() const

resolution : QSize

Holds the plane resolution.

访问函数:

QSize resolution() const
void setResolution(const QSize &resolution)

Notifier signal:

void resolutionChanged(const QSize &resolution)

tangentAttribute : Qt3DRender::QAttribute * const

Holds the geometry tangent attribute.

访问函数:

Qt3DRender::QAttribute *tangentAttribute() const

texCoordAttribute : Qt3DRender::QAttribute * const

Holds the geometry texture coordinate attribute.

访问函数:

Qt3DRender::QAttribute *texCoordAttribute() const

width : float

Holds the plane width.

访问函数:

float width() const
void setWidth(float width)

Notifier signal:

void widthChanged(float width)

成员函数

QPlaneGeometry::QPlaneGeometry(QNode *parent = nullptr)

Constructs a new QPlaneGeometry with parent.

void QPlaneGeometry::updateIndices()

Updates indices based on mesh resolution.

void QPlaneGeometry::updateVertices()

Updates vertices based on mesh resolution, width, and height properties.