载入中...
搜索中...
未找到
eve::graphics::Texture类 参考

GPU texture created via Graphics::newTexture. Owns GPU resources through an opaque backend handle. 更多...

#include <Texture.h>

类 eve::graphics::Texture 继承关系图:
eve::graphics::Drawable

Public 成员函数

 Texture ()
 Texture.
 
 ~Texture () override
 Texture.
 
void draw (Graphics *gfx, const glm::mat4 &matrix) const override
 Draws .
 
void drawOcclusion (Graphics *gfx, const glm::mat4 &matrix) const override
 Black silhouette using texture alpha (volumetric occlusion map).
 
int getWidth () const
 Returns the width.
 
int getHeight () const
 Returns the height.
 
int getPixelWidth () const
 Returns the pixel width.
 
int getPixelHeight () const
 Returns the pixel height.
 
int getMipmapCount () const
 Returns the mipmap count.
 
const TextureSampler & getSampler () const
 Returns the sampler.
 
void setAlphaConvention (const std::string &value)
 Declare whether RGB is straight or already multiplied by alpha.
 
std::string getAlphaConvention () const
 Returns the alpha convention.
 
bool hasPremultipliedAlpha () const
 True when premultiplied alpha.
 
void markDeferredFilePixels (Graphics *graphics)
 Mark deferred file pixels.
 
void clearDeferredFilePixels ()
 Clears deferred file pixels.
 
bool hasDeferredFilePixels () const
 True when deferred file pixels.
 
- Public 成员函数 继承自 eve::graphics::Drawable
virtual ~Drawable ()
 Releases Drawable resources.
 
bool getCastOcclusion () const
 When false, skipped by Graphics::drawOcclusion / volumetric occluder passes.
 
void setCastOcclusion (bool cast)
 Sets the cast occlusion.
 

Public 属性

void * gpuHandle = nullptr
 
int width = 0
 
int height = 0
 
int depth = 1
 
int layers = 1
 
int mipmapCount = 1
 
int pixelWidth = 0
 
int pixelHeight = 0
 
TextureSampler sampler {}
 

详细描述

GPU texture created via Graphics::newTexture. Owns GPU resources through an opaque backend handle.

在文件 Texture.h 第 18 行定义.

构造及析构函数说明

◆ Texture()

eve::graphics::Texture::Texture ( )
default

◆ ~Texture()

eve::graphics::Texture::~Texture ( )
override

Texture.

在文件 Texture.cpp 第 12 行定义.

引用了 gpuHandle.

成员函数说明

◆ clearDeferredFilePixels()

void eve::graphics::Texture::clearDeferredFilePixels ( )

Clears deferred file pixels.

在文件 Texture.cpp 第 22 行定义.

被这些函数引用 eve::graphics::Graphics::dropDeferredFileTexture().

◆ draw()

void eve::graphics::Texture::draw ( Graphics *  gfx,
const glm::mat4 &  matrix 
) const
overridevirtual

Draws .

实现了 eve::graphics::Drawable.

在文件 Texture.cpp 第 53 行定义.

◆ drawOcclusion()

void eve::graphics::Texture::drawOcclusion ( Graphics *  gfx,
const glm::mat4 &  matrix 
) const
overridevirtual

Black silhouette using texture alpha (volumetric occlusion map).

重载 eve::graphics::Drawable .

在文件 Texture.cpp 第 57 行定义.

引用了 eve::graphics::Graphics::drawOcclusionTexture(), eve::graphics::Drawable::getCastOcclusion(), h, w, x , 以及 y.

◆ getAlphaConvention()

std::string eve::graphics::Texture::getAlphaConvention ( ) const
inline

Returns the alpha convention.

在文件 Texture.h 第 47 行定义.

◆ getHeight()

◆ getMipmapCount()

int eve::graphics::Texture::getMipmapCount ( ) const

Returns the mipmap count.

在文件 Texture.cpp 第 48 行定义.

引用了 mipmapCount.

◆ getPixelHeight()

int eve::graphics::Texture::getPixelHeight ( ) const

Returns the pixel height.

在文件 Texture.cpp 第 43 行定义.

引用了 pixelHeight.

◆ getPixelWidth()

int eve::graphics::Texture::getPixelWidth ( ) const

Returns the pixel width.

在文件 Texture.cpp 第 38 行定义.

引用了 pixelWidth.

◆ getSampler()

const TextureSampler & eve::graphics::Texture::getSampler ( ) const
inline

Returns the sampler.

在文件 Texture.h 第 41 行定义.

引用了 sampler.

被这些函数引用 eve::graphics::Graphics::setTextureSampler().

◆ getWidth()

◆ hasDeferredFilePixels()

bool eve::graphics::Texture::hasDeferredFilePixels ( ) const
inline

True when deferred file pixels.

在文件 Texture.h 第 70 行定义.

被这些函数引用 eve::avatar::AvatarInstance::addLayer() , 以及 eve::avatar::AvatarInstance::setLayerTexture().

◆ hasPremultipliedAlpha()

bool eve::graphics::Texture::hasPremultipliedAlpha ( ) const
inline

True when premultiplied alpha.

在文件 Texture.h 第 51 行定义.

◆ markDeferredFilePixels()

void eve::graphics::Texture::markDeferredFilePixels ( Graphics *  graphics)

Mark deferred file pixels.

在文件 Texture.cpp 第 17 行定义.

◆ setAlphaConvention()

void eve::graphics::Texture::setAlphaConvention ( const std::string &  value)
inline

Declare whether RGB is straight or already multiplied by alpha.

在文件 Texture.h 第 43 行定义.

引用了 value.

类成员变量说明

◆ depth

int eve::graphics::Texture::depth = 1

◆ gpuHandle

◆ height

◆ layers

int eve::graphics::Texture::layers = 1

◆ mipmapCount

◆ pixelHeight

◆ pixelWidth

◆ sampler

◆ width


该类的文档由以下文件生成: