QGroundControl
Ground Control Station for MAVLink Drones
Loading...
Searching...
No Matches
gstqsg6glnode.h
Go to the documentation of this file.
1
/*
2
* GStreamer
3
* Copyright (C) 2022 Matthew Waters <matthew@centricular.com>
4
*
5
* This library is free software; you can redistribute it and/or
6
* modify it under the terms of the GNU Library General Public
7
* License as published by the Free Software Foundation; either
8
* version 2 of the License, or (at your option) any later version.
9
*
10
* This library is distributed in the hope that it will be useful,
11
* but WITHOUT ANY WARRANTY; without even the implied warranty of
12
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13
* Library General Public License for more details.
14
*
15
* You should have received a copy of the GNU Library General Public
16
* License along with this library; if not, write to the
17
* Free Software Foundation, Inc., 51 Franklin St, Fifth Floor,
18
* Boston, MA 02110-1301, USA.
19
*/
20
21
#pragma once
22
23
#include <gst/gst.h>
24
#include <gst/gl/gl.h>
25
26
#include "
gstqt6gl.h
"
27
#include <QtQuick/QQuickItem>
28
#include <QtQuick/QSGTexture>
29
#include <QtQuick/QSGTextureProvider>
30
#include <QtQuick/QSGSimpleTextureNode>
31
#include <QtGui/QOpenGLFunctions>
32
33
class
GstQSG6OpenGLNode
:
public
QSGTextureProvider,
public
QSGSimpleTextureNode,
protected
QOpenGLFunctions
34
{
35
Q_OBJECT
36
37
public
:
38
GstQSG6OpenGLNode
(QQuickItem *item);
39
~GstQSG6OpenGLNode
();
40
41
QSGTexture *
texture
()
const override
;
42
43
void
setCaps
(GstCaps *caps);
44
void
setBuffer
(GstBuffer *buffer);
45
GstBuffer *
getBuffer
();
46
47
void
updateQSGTexture
();
48
49
private
:
50
QQuickWindow *window_;
51
GstBuffer * buffer_;
52
gboolean buffer_was_bound;
53
GstBuffer * sync_buffer_;
54
GstMemory * mem_;
55
QSGTexture *dummy_tex_;
56
GstVideoInfo v_info;
57
GstVideoFrame v_frame;
58
};
GstQSG6OpenGLNode
Definition
gstqsg6glnode.h:34
GstQSG6OpenGLNode::~GstQSG6OpenGLNode
~GstQSG6OpenGLNode()
Definition
gstqsg6glnode.cc:50
GstQSG6OpenGLNode::texture
QSGTexture * texture() const override
Definition
gstqsg6glnode.cc:60
GstQSG6OpenGLNode::setBuffer
void setBuffer(GstBuffer *buffer)
Definition
gstqsg6glnode.cc:91
GstQSG6OpenGLNode::getBuffer
GstBuffer * getBuffer()
Definition
gstqsg6glnode.cc:79
GstQSG6OpenGLNode::setCaps
void setCaps(GstCaps *caps)
Definition
gstqsg6glnode.cc:67
GstQSG6OpenGLNode::updateQSGTexture
void updateQSGTexture()
gstqt6gl.h
src
VideoManager
VideoReceiver
GStreamer
gstqml6gl
qt6
gstqsg6glnode.h
Generated by
1.9.8