1// Copyright (C) 2024 The Qt Company Ltd.
2// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only
3
4#ifndef QABSTRACTVIDEOBUFFER_H
5#define QABSTRACTVIDEOBUFFER_H
6
7#include <QtMultimedia/qtmultimediaexports.h>
8#include <QtMultimedia/qvideoframe.h>
9#include <QtMultimedia/qvideoframeformat.h>
10#include <QtMultimedia/qtvideo.h>
11
12QT_BEGIN_NAMESPACE
13
14class Q_MULTIMEDIA_EXPORT QAbstractVideoBuffer
15{
16public:
17 struct MapData
18 {
19 int planeCount = 0;
20 int bytesPerLine[4] = {};
21 uchar *data[4] = {};
22 int dataSize[4] = {};
23 };
24
25 virtual ~QAbstractVideoBuffer();
26 virtual MapData map(QVideoFrame::MapMode mode) = 0;
27 virtual void unmap();
28 virtual QVideoFrameFormat format() const = 0;
29};
30
31QT_END_NAMESPACE
32
33#endif
34

source code of qtmultimedia/src/multimedia/video/qabstractvideobuffer.h