3#include <QtQuick/QQuickWindow>
8 setFlag(ItemHasContents,
true);
14 QVideoFrameFormat::PixelFormat pixelFormat,
15 const QMatrix4x4& externalTextureMatrix)
17 _pendingTexture = texture;
18 _frameSize = frameSize;
19 _pixelFormat = pixelFormat;
20 _externalTextureMatrix = externalTextureMatrix;
32 node->
setFrame(_pendingTexture, _frameSize, _pixelFormat, _externalTextureMatrix);
35 node->markDirty(QSGNode::DirtyMaterial);
44 QVideoFrameFormat::PixelFormat pixelFormat,
45 const QMatrix4x4& externalTextureMatrix)
48 _frameSize = frameSize;
49 _pixelFormat = pixelFormat;
50 _externalTextureMatrix = externalTextureMatrix;
55 return {BlendState, ScissorState, ViewportState};
60 return {BoundedRectRendering, OpaqueRendering};
65 return QRectF(QPointF(0, 0), QSizeF(_frameSize));
QSGNode * updatePaintNode(QSGNode *oldNode, UpdatePaintNodeData *data) override
~QGCVideoNodeItem() override
QGCVideoNodeItem(QQuickItem *parent=nullptr)
void setCurrentTexture(QRhiTexture *texture, const QSize &frameSize, QVideoFrameFormat::PixelFormat pixelFormat, const QMatrix4x4 &externalTextureMatrix)
void setFrame(QRhiTexture *texture, const QSize &frameSize, QVideoFrameFormat::PixelFormat pixelFormat, const QMatrix4x4 &externalTextureMatrix)
~QGCVideoRenderNode() override
QRectF rect() const override
StateFlags changedStates() const override
RenderingFlags flags() const override
void releaseResources() override
void render(const RenderState *state) override