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>.
Loading...
Searching...
No Matches
QSSGLoadedTexture Struct Reference

#include <qssgrenderloadedtexture_p.h>

+ Collaboration diagram for QSSGLoadedTexture:

Public Member Functions

 ~QSSGLoadedTexture ()
 
void setFormatFromComponents ()
 
bool scanForTransparency () const
 

Static Public Member Functions

static QSSGLoadedTextureload (const QString &inPath, const QSSGRenderTextureFormat &inFormat, bool inFlipY=true)
 
static QSSGLoadedTextureloadQImage (const QString &inPath, qint32 flipVertical)
 
static QSSGLoadedTextureloadCompressedImage (const QString &inPath)
 
static QSSGLoadedTextureloadHdrImage (const QSharedPointer< QIODevice > &source, const QSSGRenderTextureFormat &inFormat)
 
static QSSGLoadedTextureloadTextureData (QSSGRenderTextureData *textureData)
 

Public Attributes

qint32 width = 0
 
qint32 height = 0
 
qint32 depth = 0
 
qint32 components = 0
 
voiddata = nullptr
 
bool ownsData = true
 
QTextureFileData textureFileData
 
QImage image
 
quint32 dataSizeInBytes = 0
 
QSSGRenderTextureFormat format = QSSGRenderTextureFormat::RGBA8
 
bool isSRGB = false
 

Detailed Description

Definition at line 51 of file qssgrenderloadedtexture_p.h.

Constructor & Destructor Documentation

◆ ~QSSGLoadedTexture()

QSSGLoadedTexture::~QSSGLoadedTexture ( )

Definition at line 813 of file qssgrenderloadedtexture.cpp.

References ownsData.

Member Function Documentation

◆ load()

QSSGLoadedTexture * QSSGLoadedTexture::load ( const QString & inPath,
const QSSGRenderTextureFormat & inFormat,
bool inFlipY = true )
static

Definition at line 942 of file qssgrenderloadedtexture.cpp.

References fileName, fileType(), QSSGInputUtil::getStreamForTextureFile(), QSSGInputUtil::HdrFile, loadCompressedImage(), loadCubeMap(), loadHdrImage(), loadQImage(), QSSGInputUtil::TextureFile, and QSSGInputUtil::UnknownFile.

Referenced by QSSGBufferManager::loadLightmap(), and QSSGBufferManager::loadRenderImage().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ loadCompressedImage()

QSSGLoadedTexture * QSSGLoadedTexture::loadCompressedImage ( const QString & inPath)
static

Definition at line 311 of file qssgrenderloadedtexture.cpp.

References QImageReader::canRead(), fromGLtoTextureFormat(), qWarning, QImageReader::read(), QIODeviceBase::ReadOnly, textureFileData, and QImage::width().

Referenced by load().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ loadHdrImage()

QSSGLoadedTexture * QSSGLoadedTexture::loadHdrImage ( const QSharedPointer< QIODevice > & source,
const QSSGRenderTextureFormat & inFormat )
static

Definition at line 704 of file qssgrenderloadedtexture.cpp.

References imageData, QSSGRenderTextureFormat::RGBA16F, and QSSGRenderTextureFormat::Unknown.

Referenced by load(), and renderToKTXFileInternal().

+ Here is the caller graph for this function:

◆ loadQImage()

QSSGLoadedTexture * QSSGLoadedTexture::loadQImage ( const QString & inPath,
qint32 flipVertical )
static

Definition at line 292 of file qssgrenderloadedtexture.cpp.

References QImage::bits(), image, QColorSpace::Linear, loadImage(), and width.

Referenced by load().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ loadTextureData()

◆ scanForTransparency()

◆ setFormatFromComponents()

void QSSGLoadedTexture::setFormatFromComponents ( )
inline

Member Data Documentation

◆ components

qint32 QSSGLoadedTexture::components = 0

Definition at line 57 of file qssgrenderloadedtexture_p.h.

◆ data

void* QSSGLoadedTexture::data = nullptr

Definition at line 58 of file qssgrenderloadedtexture_p.h.

◆ dataSizeInBytes

quint32 QSSGLoadedTexture::dataSizeInBytes = 0

Definition at line 62 of file qssgrenderloadedtexture_p.h.

◆ depth

qint32 QSSGLoadedTexture::depth = 0

Definition at line 56 of file qssgrenderloadedtexture_p.h.

◆ format

Definition at line 63 of file qssgrenderloadedtexture_p.h.

◆ height

qint32 QSSGLoadedTexture::height = 0

Definition at line 55 of file qssgrenderloadedtexture_p.h.

◆ image

QImage QSSGLoadedTexture::image

Definition at line 61 of file qssgrenderloadedtexture_p.h.

Referenced by loadQImage().

◆ isSRGB

bool QSSGLoadedTexture::isSRGB = false

Definition at line 65 of file qssgrenderloadedtexture_p.h.

◆ ownsData

bool QSSGLoadedTexture::ownsData = true

Definition at line 59 of file qssgrenderloadedtexture_p.h.

Referenced by ~QSSGLoadedTexture().

◆ textureFileData

QTextureFileData QSSGLoadedTexture::textureFileData

Definition at line 60 of file qssgrenderloadedtexture_p.h.

Referenced by loadCompressedImage(), and loadCubeMap().

◆ width

qint32 QSSGLoadedTexture::width = 0

Definition at line 54 of file qssgrenderloadedtexture_p.h.

Referenced by loadQImage().


The documentation for this struct was generated from the following files: