QRhiSampler Class

Sampler resource. More...

Header: #include <QRhiSampler>
qmake: QT += rhi
Inherits: QRhiResource

Public Types

enum AddressMode { Repeat, ClampToEdge, Border, Mirror, MirrorOnce }
enum CompareOp { Never, Less, Equal, LessOrEqual, ..., Always }
enum Filter { None, Nearest, Linear }

Public Functions

QRhiSampler::AddressMode addressU() const
QRhiSampler::AddressMode addressV() const
QRhiSampler::AddressMode addressW() const
virtual bool build() = 0
QRhiSampler::Filter magFilter() const
QRhiSampler::Filter minFilter() const
QRhiSampler::Filter mipmapMode() const
void setAddressU(QRhiSampler::AddressMode mode)
void setAddressV(QRhiSampler::AddressMode mode)
void setAddressW(QRhiSampler::AddressMode mode)
void setMagFilter(QRhiSampler::Filter f)
void setMinFilter(QRhiSampler::Filter f)
void setMipmapMode(QRhiSampler::Filter f)
void setTextureCompareOp(QRhiSampler::CompareOp op)
QRhiSampler::CompareOp textureCompareOp() const

Reimplemented Public Functions

virtual QRhiResource::Type resourceType() const override

Protected Variables

QRhiSampler::AddressMode m_addressU
QRhiSampler::AddressMode m_addressV
QRhiSampler::AddressMode m_addressW
QRhiSampler::CompareOp m_compareOp
QRhiSampler::Filter m_magFilter
QRhiSampler::Filter m_minFilter
QRhiSampler::Filter m_mipmapMode

Additional Inherited Members

Detailed Description

Sampler resource.

Member Type Documentation

enum QRhiSampler::AddressMode

Specifies the addressing mode

ConstantValue
QRhiSampler::Repeat0
QRhiSampler::ClampToEdge1
QRhiSampler::Border2
QRhiSampler::Mirror3
QRhiSampler::MirrorOnce4

enum QRhiSampler::CompareOp

Specifies the texture comparison function.

ConstantValueDescription
QRhiSampler::Never0(default)
QRhiSampler::Less1 
QRhiSampler::Equal2 
QRhiSampler::LessOrEqual3 
QRhiSampler::Greater4 
QRhiSampler::NotEqual5 
QRhiSampler::GreaterOrEqual6 
QRhiSampler::Always7 

enum QRhiSampler::Filter

Specifies the minification, magnification, or mipmap filtering

ConstantValueDescription
QRhiSampler::None0Applicable only for mipmapMode(), indicates no mipmaps to be used
QRhiSampler::Nearest1 
QRhiSampler::Linear2 

Property Documentation

Member Function Documentation

QRhiSampler::AddressMode QRhiSampler::addressU() const

See also setAddressU().

QRhiSampler::AddressMode QRhiSampler::addressV() const

See also setAddressV().

QRhiSampler::AddressMode QRhiSampler::addressW() const

See also setAddressW().

[pure virtual] bool QRhiSampler::build()

QRhiSampler::Filter QRhiSampler::magFilter() const

See also setMagFilter().

QRhiSampler::Filter QRhiSampler::minFilter() const

See also setMinFilter().

QRhiSampler::Filter QRhiSampler::mipmapMode() const

See also setMipmapMode().

[override virtual] QRhiResource::Type QRhiSampler::resourceType() const

Reimplemented from QRhiResource::resourceType().

Returns the resource type.

void QRhiSampler::setAddressU(QRhiSampler::AddressMode mode)

See also addressU().

void QRhiSampler::setAddressV(QRhiSampler::AddressMode mode)

See also addressV().

void QRhiSampler::setAddressW(QRhiSampler::AddressMode mode)

See also addressW().

void QRhiSampler::setMagFilter(QRhiSampler::Filter f)

See also magFilter().

void QRhiSampler::setMinFilter(QRhiSampler::Filter f)

See also minFilter().

void QRhiSampler::setMipmapMode(QRhiSampler::Filter f)

See also mipmapMode().

void QRhiSampler::setTextureCompareOp(QRhiSampler::CompareOp op)

See also textureCompareOp().

QRhiSampler::CompareOp QRhiSampler::textureCompareOp() const

See also setTextureCompareOp().

Member Variable Documentation

Related Non-Members

Macro Documentation