Provides a way of specifying a render target. 更多...
头: | #include <QRenderTargetSelector> |
qmake: | QT += 3drender |
Since: | Qt 5.7 |
实例化: | RenderTargetSelector |
继承: | Qt3DRender::QFrameGraphNode |
该类在 Qt 5.7 引入。
QRenderTargetSelector (Qt3DCore::QNode * parent = nullptr) | |
QVector<QRenderTargetOutput::AttachmentPoint> | outputs () const |
void | setOutputs (const QVector<QRenderTargetOutput::AttachmentPoint> & buffers ) |
Qt3DRender::QRenderTarget * | target () const |
void | setTarget (Qt3DRender::QRenderTarget * target ) |
void | targetChanged (Qt3DRender::QRenderTarget * target ) |
A Qt3DRender::QRenderTargetSelector is used to select active Qt3DRender::QRenderTarget for the FrameGraph. When QRenderTargetSelector is present in the FrameGraph, the rendering is directed into QTexture objects or draw buffers instead of the surface specified in the Qt3DRender::QRenderSurfaceSelector . A render buffer is automatically generated for an attachment point if drawBuffers contain attachment point that any output in the QRenderTarget do not specify. If the drawBuffers is empty, the renderer will default to using all the outputs in QRenderTarget .
Holds the current render target
访问函数:
Qt3DRender::QRenderTarget * | target () const |
void | setTarget (Qt3DRender::QRenderTarget * target ) |
通知程序信号:
void | targetChanged (Qt3DRender::QRenderTarget * target ) |
Constructs QRenderTargetSelector with given parent .
Returns the list of draw buffers for the current Qt3DRender::QRenderTargetSelector 实例。
另请参阅 setOutputs ().
Sets the draw buffers to be used. The draw buffers should be matching the Qt3DRender::QRenderTargetOutput::AttachmentPoint defined in the attachments of the Qt3DRender::QRenderTarget associated to the Qt3DRender::QRenderTargetSelector 实例。
注意: At render time, if no draw buffer has been specified, the renderer will default to using all the attachments' draw buffers.
另请参阅 outputs ().