![]() |
Qt 6.x
The Qt SDK
|
#include "qssgiblbaker_p.h"
#include <QFile>
#include <QFileInfo>
#include <QScopeGuard>
#include <QtQuick3DRuntimeRender/private/qssgrhicontext_p.h>
#include <QtQuick3DRuntimeRender/private/qssgrenderloadedtexture_p.h>
#include <QtQuick3DRuntimeRender/private/qssgrendershadercache_p.h>
Go to the source code of this file.
Macros | |
#define | GL_FLOAT 0x1406 |
#define | GL_HALF_FLOAT 0x140B |
#define | GL_UNSIGNED_BYTE 0x1401 |
#define | GL_RGBA 0x1908 |
#define | GL_RGBA8 0x8058 |
#define | GL_RGBA16F 0x881A |
#define | GL_RGBA32F 0x8814 |
Functions | |
static constexpr QSSGRenderTextureFormat | FORMAT (QSSGRenderTextureFormat::RGBA16F) |
QString | renderToKTXFileInternal (const char *name, const QString &inPath, const QString &outPath, QRhi::Implementation impl, QRhiInitParams *initParams) |
void | adjustToPlatformQuirks (QRhi::Implementation &impl) |
QRhi::Implementation | getRhiImplementation () |
QString | renderToKTXFile (const QString &inPath, const QString &outPath) |
Variables | |
static const float | cube [] |
#define GL_FLOAT 0x1406 |
Definition at line 20 of file qssgiblbaker.cpp.
#define GL_HALF_FLOAT 0x140B |
Definition at line 21 of file qssgiblbaker.cpp.
#define GL_RGBA 0x1908 |
Definition at line 23 of file qssgiblbaker.cpp.
#define GL_RGBA16F 0x881A |
Definition at line 25 of file qssgiblbaker.cpp.
#define GL_RGBA32F 0x8814 |
Definition at line 26 of file qssgiblbaker.cpp.
#define GL_RGBA8 0x8058 |
Definition at line 24 of file qssgiblbaker.cpp.
#define GL_UNSIGNED_BYTE 0x1401 |
Definition at line 22 of file qssgiblbaker.cpp.
void adjustToPlatformQuirks | ( | QRhi::Implementation & | impl | ) |
Definition at line 584 of file qssgiblbaker.cpp.
References QRhi::create(), QRhi::Metal, QRhi::OpenGLES2, Q_UNUSED, and qDebug.
Referenced by getRhiImplementation().
|
staticconstexpr |
QRhi::Implementation getRhiImplementation | ( | ) |
Definition at line 605 of file qssgiblbaker.cpp.
References adjustToPlatformQuirks(), QByteArray::constData(), QRhi::D3D11, QRhi::D3D12, QByteArray::isEmpty(), QRhi::Metal, QRhi::Null, QRhi::OpenGLES2, QByteArrayLiteral, qgetenv(), qWarning, and QRhi::Vulkan.
Referenced by renderToKTXFile().
Definition at line 644 of file qssgiblbaker.cpp.
References QSurfaceFormat::CoreProfile, QRhi::D3D11, QRhi::D3D12, getRhiImplementation(), QOpenGLContext::LibGL, QRhi::Metal, QRhi::OpenGLES2, QOpenGLContext::openGLModuleType(), QStringLiteral, renderToKTXFileInternal(), and QRhi::Vulkan.
Referenced by QSSGIblBaker::import().
QString renderToKTXFileInternal | ( | const char * | name, |
const QString & | inPath, | ||
const QString & | outPath, | ||
QRhi::Implementation | impl, | ||
QRhiInitParams * | initParams | ||
) |
Definition at line 100 of file qssgiblbaker.cpp.
References QVarLengthArray< T, Prealloc >::append(), cb, QRhiTextureRenderTargetDescription::cbeginColorAttachments(), QRhiGraphicsPipeline::CCW, QRhiSampler::ClampToEdge, QFileDevice::close(), QRhiRenderBuffer::Color, QSSGRhiContext::commonPassFlags(), QMatrix4x4::constData(), QList< T >::constData(), QRhiBuffer::create(), QRhiTexture::create(), QRhiRenderBuffer::create(), QRhiShaderResourceBindings::create(), QRhiGraphicsPipeline::create(), QRhi::create(), cube, QRhiTexture::CubeMap, QList< T >::data(), QScopedPointer< T, Cleanup >::data(), QRhiResource::deleteLater(), desc, QRhiTextureRenderTarget::description(), QRhiBuffer::Dynamic, QRhiVertexInputAttribute::Float3, FORMAT(), QRhiShaderResourceBinding::FragmentStage, QRhiGraphicsPipeline::Front, QScopedPointer< T, Cleanup >::get(), QSSGRenderTextureFormat::getNumberOfComponent(), QSSGRenderTextureFormat::getSizeofFormat(), QSSGInputUtil::getStreamForFile(), GL_HALF_FLOAT, GL_RGBA, GL_RGBA16F, QSize::height(), QRhiBuffer::Immutable, QMap< Key, T >::insert(), KTX_IDENTIFIER_LENGTH, ktxIdentifier, QRhiGraphicsPipeline::LessOrEqual, QRhiSampler::Linear, QSSGLoadedTexture::loadHdrImage(), QMatrix4x4::lookAt(), QRhiTexture::MipMapped, QRhiRenderPassDescriptor::newCompatibleRenderPassDescriptor(), QRhiSampler::None, QFile::open(), QMatrix4x4::perspective(), platformEndianIdentifier, Q_ASSERT, qDebug, qMax(), qMin(), QStringLiteral, qWarning, QRhiResourceUpdateBatch::readBackTexture(), QRhiTexture::RenderTarget, QRhiSampler::Repeat, QList< T >::resize(), QRhiTexture::RGBA16F, QSSGRenderTextureFormat::RGBE8, QRhiShaderResourceBinding::sampledTexture(), QRhiVertexInputLayout::setAttributes(), QRhiShaderResourceBindings::setBindings(), QRhiVertexInputLayout::setBindings(), QRhiTextureRenderTargetDescription::setColorAttachments(), QRhiGraphicsPipeline::setCullMode(), QRhiGraphicsPipeline::setDepthOp(), QRhiGraphicsPipeline::setFrontFace(), QRhiColorAttachment::setLayer(), QRhiReadbackDescription::setLayer(), QRhiColorAttachment::setLevel(), QRhiReadbackDescription::setLevel(), QRhiGraphicsPipeline::setRenderPassDescriptor(), QRhiGraphicsPipeline::setShaderResourceBindings(), QRhiGraphicsPipeline::setShaderStages(), QRhiGraphicsPipeline::setVertexInputLayout(), QMap< Key, T >::size(), QList< T >::size(), QRhiColorAttachment::texture(), QRhiBuffer::UniformBuffer, QRhiShaderResourceBinding::uniformBufferWithDynamicOffset(), QRhiTexture::UsedWithGenerateMips, QRhiBuffer::VertexBuffer, QRhiShaderResourceBinding::VertexStage, QSize::width(), QIODevice::write(), and QIODeviceBase::WriteOnly.
Referenced by renderToKTXFile().
|
static |
Definition at line 62 of file qssgiblbaker.cpp.
Referenced by renderToKTXFileInternal().