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

Drawable base (textures, meshes, canvases). 更多...

#include <Drawable.h>

类 eve::graphics::Drawable 继承关系图:
eve::graphics::Canvas eve::graphics::Mesh eve::graphics::Texture eve::graphics::Graphics eve::graphics::vulkan::OffscreenCanvas eve::graphics::webgpu::OffscreenCanvas eve::graphics::vulkan::Graphics eve::graphics::webgpu::Graphics

Public 成员函数

virtual ~Drawable ()
 Releases Drawable resources.
 
virtual void draw (Graphics *gfx, const glm::mat4 &matrix) const =0
 Draws the object with the specified transformation matrix.
 
bool getCastOcclusion () const
 When false, skipped by Graphics::drawOcclusion / volumetric occluder passes.
 
void setCastOcclusion (bool cast)
 Sets the cast occlusion.
 
virtual void drawOcclusion (Graphics *gfx, const glm::mat4 &matrix) const
 Draw as an opaque black silhouette for volumetric occlusion maps (screen-space god rays / light shafts). Default is a no-op; Texture / Mesh override with 2D black rects (alpha preserved for textures).
 

详细描述

Drawable base (textures, meshes, canvases).

Occlusion follows the same idea as mesh shadow casting: a drawable may contribute a black silhouette to a volumetric light occlusion map via drawOcclusion(). Defaults to casting occlusion (opt-out with setCastOcclusion).

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

构造及析构函数说明

◆ ~Drawable()

virtual eve::graphics::Drawable::~Drawable ( )
inlinevirtual

Releases Drawable resources.

在文件 Drawable.h 第 21 行定义.

成员函数说明

◆ draw()

virtual void eve::graphics::Drawable::draw ( Graphics *  gfx,
const glm::mat4 &  matrix 
) const
pure virtual

Draws the object with the specified transformation matrix.

参数
gfxBorrowed graphics backend for the draw.
matrixColumn-major model transform; borrowed for the call only.

在 eve::graphics::vulkan::OffscreenCanvas, eve::graphics::webgpu::OffscreenCanvas, eve::graphics::vulkan::Graphics, eve::graphics::webgpu::Graphics, eve::graphics::Mesh, eve::graphics::Texture , 以及 eve::graphics::Canvas 内被实现.

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

◆ drawOcclusion()

virtual void eve::graphics::Drawable::drawOcclusion ( Graphics *  gfx,
const glm::mat4 &  matrix 
) const
inlinevirtual

Draw as an opaque black silhouette for volumetric occlusion maps (screen-space god rays / light shafts). Default is a no-op; Texture / Mesh override with 2D black rects (alpha preserved for textures).

被 eve::graphics::Mesh , 以及 eve::graphics::Texture 重载.

在文件 Drawable.h 第 40 行定义.

引用了 matrix.

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

◆ getCastOcclusion()

bool eve::graphics::Drawable::getCastOcclusion ( ) const
inline

◆ setCastOcclusion()

void eve::graphics::Drawable::setCastOcclusion ( bool  cast)
inline

Sets the cast occlusion.

在文件 Drawable.h 第 33 行定义.

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


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