Qt
Internal/Contributor docs for the Qt SDK. <b>Note:</b> These are NOT official API docs; those are found <a href='https://doc.qt.io/'>here</a>.
|
#include <qopenglprogrambinarycache_p.h>
Classes | |
struct | ProgramDesc |
struct | ShaderDesc |
Public Member Functions | |
QOpenGLProgramBinaryCache () | |
bool | load (const QByteArray &cacheKey, uint programId) |
void | save (const QByteArray &cacheKey, uint programId) |
Definition at line 33 of file qopenglprogrambinarycache_p.h.
QOpenGLProgramBinaryCache::QOpenGLProgramBinaryCache | ( | ) |
Definition at line 83 of file qopenglprogrambinarycache.cpp.
References QSysInfo::buildAbi(), QStandardPaths::CacheLocation, QStandardPaths::GenericCacheLocation, qCDebug, qPrintable, qt_ensureWritableDir(), subPath(), and QStandardPaths::writableLocation().
bool QOpenGLProgramBinaryCache::load | ( | const QByteArray & | cacheKey, |
uint | programId ) |
Definition at line 248 of file qopenglprogrambinarycache.cpp.
References BASE_HEADER_SIZE, cacheKey(), QByteArray::fromRawData(), FULL_HEADER_SIZE, header(), info, QCache< Key, T >::insert(), lock, QCache< Key, T >::object(), PADDING_SIZE, qCDebug, qt_safe_read(), QIODeviceBase::ReadOnly, readStr(), readUInt(), renderer, and QByteArray::size().
void QOpenGLProgramBinaryCache::save | ( | const QByteArray & | cacheKey, |
uint | programId ) |
Definition at line 353 of file qopenglprogrambinarycache.cpp.
References BINSHADER_MAGIC, BINSHADER_QTVERSION, BINSHADER_VERSION, cacheKey(), context, QOpenGLContext::currentContext(), QByteArray::data(), error, FULL_HEADER_SIZE, funcs, GL_CONTEXT_LOST, GL_PROGRAM_BINARY_LENGTH, GLenum(), GLint(), headerSize, i, info, lock, ok, PADDING_SIZE, qCDebug, qPrintable, qt_ensureWritableDir(), Qt::Uninitialized, writeFile(), writeStr(), and writeUInt().