One-draw particle shadow caster matching Fluid3D ShadowmapExposer behavior. @ownership Borrows Graphics for its lifetime and owns one Graphics-managed dynamic mesh. @thread Construction, update and destruction are render-thread affine. @reentrancy Invokes no script callbacks; destruction must occur outside shadow traversal. 更多...
#include <VolumeFluidShadowCaster.h>
Public 成员函数 | |
| VolumeFluidShadowCaster (graphics::Graphics &graphics) | |
| Constructs a VolumeFluidShadowCaster. | |
| ~VolumeFluidShadowCaster () | |
| Releases VolumeFluidShadowCaster resources. | |
| VolumeFluidShadowCaster (const VolumeFluidShadowCaster &)=delete | |
| VolumeFluidShadowCaster & | operator= (const VolumeFluidShadowCaster &)=delete |
| Result< void > | update (const VolumeFluid &fluid, unsigned actorGroup, float radiusScale, float alpha=1.f, unsigned maxParticles=4096) |
| Rebuild one actor's bounded octahedral shadow batch. | |
| unsigned | particleCount () const noexcept |
| Number of particles in the currently published shadow batch. | |
详细描述
One-draw particle shadow caster matching Fluid3D ShadowmapExposer behavior. @ownership Borrows Graphics for its lifetime and owns one Graphics-managed dynamic mesh. @thread Construction, update and destruction are render-thread affine. @reentrancy Invokes no script callbacks; destruction must occur outside shadow traversal.
在文件 VolumeFluidShadowCaster.h 第 21 行定义.
构造及析构函数说明
◆ VolumeFluidShadowCaster() [1/2]
|
explicit |
Constructs a VolumeFluidShadowCaster.
- 参数
-
graphics Initialized backend that must outlive this caster.
在文件 VolumeFluidShadowCaster.cpp 第 17 行定义.
◆ ~VolumeFluidShadowCaster()
| eve::fluids::VolumeFluidShadowCaster::~VolumeFluidShadowCaster | ( | ) |
Releases VolumeFluidShadowCaster resources.
在文件 VolumeFluidShadowCaster.cpp 第 19 行定义.
引用了 eve::graphics::Graphics::releaseMesh() , 以及 eve::graphics::RenderSystem3D::removeShadowExtraDrawer().
◆ VolumeFluidShadowCaster() [2/2]
|
delete |
成员函数说明
◆ operator=()
|
delete |
◆ particleCount()
|
inlinenoexcept |
Number of particles in the currently published shadow batch.
在文件 VolumeFluidShadowCaster.h 第 44 行定义.
◆ update()
| Result< void > eve::fluids::VolumeFluidShadowCaster::update | ( | const VolumeFluid & | fluid, |
| unsigned | actorGroup, | ||
| float | radiusScale, | ||
| float | alpha = 1.f, |
||
| unsigned | maxParticles = 4096 |
||
| ) |
Rebuild one actor's bounded octahedral shadow batch.
- 参数
-
fluid Borrowed solver, not mutated or retained. actorGroup Stable emitter actor identity. radiusScale Positive particle radius multiplier. alpha Fixed-step interpolation fraction in [0,1]. maxParticles Complete-output budget in [1,65536].
- 返回
- Success, or failure preserving the prior visible batch.
Reuses CPU arrays and one dynamic GPU mesh after capacity warm-up. The registered CSM callback issues at most one indexed draw per cascade.
在文件 VolumeFluidShadowCaster.cpp 第 24 行定义.
引用了 eve::graphics::RenderSystem3D::addShadowExtraDrawer(), c, eve::fluids::VolumeFluid::copyParticleImpostors(), count, directions, eve::graphics::Graphics::drawMeshShadow(), eve::Result< T >::failure(), lightVP, local, eve::graphics::Graphics::newMeshFromArrays(), normal, point, q, eve::Result< T >::success(), eve::graphics::Graphics::updateMeshVertices() , 以及 v.
该类的文档由以下文件生成:
- src/modules/fluids/VolumeFluidShadowCaster.h
- src/modules/fluids/VolumeFluidShadowCaster.cpp