Qt
Internal/Contributor docs for the Qt SDK. Note: These are NOT official API docs; those are found at https://doc.qt.io/
Loading...
Searching...
No Matches
brcmbuffer.cpp
Go to the documentation of this file.
1
// Copyright (C) 2017 The Qt Company Ltd.
2
// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only
3
// Qt-Security score:critical reason:network-protocol
4
5
#
include
"brcmbuffer.h"
6
7
#
include
<
EGL
/
eglext
.
h
>
8
9
#
include
<
EGL
/
eglext_brcm
.
h
>
10
11
QT_BEGIN_NAMESPACE
12
13
BrcmBuffer::BrcmBuffer(
struct
::wl_client *client, uint32_t id,
const
QSize &size, EGLint *data, size_t count)
14
: QtWaylandServer::wl_buffer(client, id, 1)
15
, m_handle(count)
16
, m_size(size)
17
{
18
for
(size_t i = 0; i < count; ++i)
19
m_handle[i] = data[i];
20
}
21
22
BrcmBuffer::~BrcmBuffer()
23
{
24
static
PFNEGLDESTROYGLOBALIMAGEBRCMPROC eglDestroyGlobalImage =
25
(PFNEGLDESTROYGLOBALIMAGEBRCMPROC) eglGetProcAddress(
"eglDestroyGlobalImageBRCM"
);
26
eglDestroyGlobalImage(handle());
27
}
28
29
void
BrcmBuffer::buffer_destroy_resource(Resource *)
30
{
31
delete
this
;
32
}
33
34
void
BrcmBuffer::buffer_destroy(Resource *resource)
35
{
36
wl_resource_destroy(resource->handle);
37
}
38
39
QT_END_NAMESPACE
qtwayland
src
hardwareintegration
compositor
brcm-egl
brcmbuffer.cpp
Generated on
for Qt by
1.16.1