4#ifndef AVFVIDEOBUFFER_H
5#define AVFVIDEOBUFFER_H
18#include <QtMultimedia/qvideoframe.h>
19#include <private/qabstractvideobuffer_p.h>
20#include <private/qcore_mac_p.h>
22#include <QtCore/qobject.h>
23#include <QtCore/qmutex.h>
26#include <CoreVideo/CVImageBuffer.h>
28#import "Metal/Metal.h"
29#import "MetalKit/MetalKit.h"
33struct AVFMetalTexture;
51 mutable CVMetalTextureRef cvMetalTexture[3] = {};
52 mutable QCFType<CVMetalTextureCacheRef> metalCache;
53#if defined(Q_OS_MACOS)
54 mutable CVOpenGLTextureRef cvOpenGLTexture =
nullptr;
55#elif defined(Q_OS_IOS)
56 mutable CVOpenGLESTextureRef cvOpenGLESTexture =
nullptr;
59 CVImageBufferRef m_buffer =
nullptr;
void unmap()
Releases the memory mapped by the map() function.
QVideoFrameFormat videoFormat() const
AVFVideoBuffer(AVFVideoSinkInterface *sink, CVImageBufferRef buffer)
virtual quint64 textureHandle(QRhi *, int plane) const
Returns a texture handle to the data buffer.
QVideoFrame::MapMode mapMode() const
The QAbstractVideoBuffer class is an abstraction for video data. \inmodule QtMultimedia.
\inmodule QtGuiPrivate \inheaderfile rhi/qrhi.h
MapMode
Enumerates how a video buffer's data is mapped to system memory.
QMap< QString, QString > map
[6]
Combined button and popup list for selecting options.
GLsizei GLenum GLboolean sink
unsigned long long quint64