载入中...
搜索中...
未找到
eve::fluids::MeshSdfField类 参考final

Borrows a MeshSdf as the shared ISdfField3D capability surface. 更多...

#include <MeshSdfField.h>

类 eve::fluids::MeshSdfField 继承关系图:
eve::ISdfField3D

Public 成员函数

 MeshSdfField ()=default
 Constructs an unbound adapter.
 
void bind (const MeshSdf &field)
 Bind a live MeshSdf and bump the adapter revision.
 
void clear ()
 Clears the borrowed binding.
 
bool isBound () const
 True when a field is currently bound.
 
float sample (float x, float y, float z) const override
 Sample signed distance at a world-space position.
 
SdfField3DGradientStatus gradient (float x, float y, float z, float &outNx, float &outNy, float &outNz) const override
 Approximate outward unit gradient at a world-space position.
 
unsigned revision () const override
 Monotonic revision incremented after each successful field mutation.
 
void bounds (float &minX, float &minY, float &minZ, float &maxX, float &maxY, float &maxZ) const override
 Axis-aligned world bounds of the sampled lattice (inclusive corners).
 
- Public 成员函数 继承自 eve::ISdfField3D
virtual ~ISdfField3D ()=default
 I sdf field 3 d.
 

额外继承的成员函数

- 静态 Public 属性 继承自 eve::ISdfField3D
static constexpr const char * capabilityName = "ISdfField3D"
 

详细描述

Borrows a MeshSdf as the shared ISdfField3D capability surface.

@ownership Borrows the field; clear or destroy the adapter before destroying the field. @thread Simulation-thread affine; no callbacks.

MeshSdf has no built-in revision counter; bind increments a local revision so consumers can invalidate caches when the borrowed field is replaced.

在文件 MeshSdfField.h 第 19 行定义.

构造及析构函数说明

◆ MeshSdfField()

eve::fluids::MeshSdfField::MeshSdfField ( )
default

Constructs an unbound adapter.

成员函数说明

◆ bind()

void eve::fluids::MeshSdfField::bind ( const MeshSdf &  field)

Bind a live MeshSdf and bump the adapter revision.

参数
fieldBorrowed provider; must outlive this adapter while bound.

在文件 MeshSdfField.cpp 第 31 行定义.

引用了 eve::fluids::ocean_codec::field().

◆ bounds()

void eve::fluids::MeshSdfField::bounds ( float &  minX,
float &  minY,
float &  minZ,
float &  maxX,
float &  maxY,
float &  maxZ 
) const
overridevirtual

Axis-aligned world bounds of the sampled lattice (inclusive corners).

参数
[out]minXMinimum X of the sample lattice.
[out]minYMinimum Y of the sample lattice.
[out]minZMinimum Z of the sample lattice.
[out]maxXMaximum X of the sample lattice.
[out]maxYMaximum Y of the sample lattice.
[out]maxZMaximum Z of the sample lattice.

实现了 eve::ISdfField3D.

在文件 MeshSdfField.cpp 第 60 行定义.

引用了 eve::fluids::MeshSdf::cellSize, eve::fluids::MeshSdf::dims, eve::fluids::MeshSdf::origin , 以及 eve::fluids::ocean_script::vector().

◆ clear()

void eve::fluids::MeshSdfField::clear ( )

Clears the borrowed binding.

在文件 MeshSdfField.cpp 第 35 行定义.

◆ gradient()

SdfField3DGradientStatus eve::fluids::MeshSdfField::gradient ( float  x,
float  y,
float  z,
float &  outNx,
float &  outNy,
float &  outNz 
) const
overridevirtual

Approximate outward unit gradient at a world-space position.

参数
[out]outNxX component of the unit gradient when the status is Defined.
[out]outNyY component of the unit gradient when the status is Defined.
[out]outNzZ component of the unit gradient when the status is Defined.
返回
Defined when a finite gradient was written; Undefined at empty fields or singularities.

实现了 eve::ISdfField3D.

在文件 MeshSdfField.cpp 第 45 行定义.

引用了 eve::fluids::MeshSdf::cellSize, eve::Defined, g, eve::fluids::MeshSdf::gradient(), eve::Undefined, eve::fluids::ocean_script::vector(), x, y , 以及 z.

◆ isBound()

bool eve::fluids::MeshSdfField::isBound ( ) const
inline

True when a field is currently bound.

在文件 MeshSdfField.h 第 34 行定义.

◆ revision()

unsigned eve::fluids::MeshSdfField::revision ( ) const
overridevirtual

Monotonic revision incremented after each successful field mutation.

Consumers use this to detect stale GPU uploads or cached contacts.

实现了 eve::ISdfField3D.

在文件 MeshSdfField.cpp 第 58 行定义.

◆ sample()

float eve::fluids::MeshSdfField::sample ( float  x,
float  y,
float  z 
) const
overridevirtual

Sample signed distance at a world-space position.

返回
Finite signed distance in world units, or +inf when unsupported.

实现了 eve::ISdfField3D.

在文件 MeshSdfField.cpp 第 40 行定义.

引用了 eve::fluids::MeshSdf::sample(), x, y , 以及 z.


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