Drawable base (textures, meshes, canvases). 更多...
#include <Drawable.h>
Public 成员函数 | |
| virtual | ~Drawable () |
| 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) |
| 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 第 17 行定义.
构造及析构函数说明
◆ ~Drawable()
|
inlinevirtual |
在文件 Drawable.h 第 19 行定义.
成员函数说明
◆ draw()
|
pure virtual |
Draws the object with the specified transformation matrix.
在 eve::graphics::vulkan::OffscreenCanvas, eve::graphics::webgpu::OffscreenCanvas, eve::graphics::vulkan::Graphics, eve::graphics::webgpu::Graphics, eve::graphics::Mesh , 以及 eve::graphics::Texture 内被实现.
被这些函数引用 eve::graphics::Graphics::draw().
◆ drawOcclusion()
|
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 第 35 行定义.
◆ getCastOcclusion()
|
inline |
When false, skipped by Graphics::drawOcclusion / volumetric occluder passes.
在文件 Drawable.h 第 27 行定义.
被这些函数引用 eve::graphics::Graphics::drawOcclusion(), eve::graphics::Mesh::drawOcclusion() , 以及 eve::graphics::Texture::drawOcclusion().
◆ setCastOcclusion()
|
inline |
在文件 Drawable.h 第 28 行定义.
该类的文档由以下文件生成:
- src/modules/graphics/Drawable.h