载入中...
搜索中...
未找到

Uniform grid used for neighbor queries. 更多...

#include <FluidSimulation.h>

Public 成员函数

int cellCount () const
 Cell count.
 
int cellIndex (int x, int y, int z) const
 Cell index.
 
bool inBounds (int x, int y, int z) const
 In bounds.
 
glm::ivec3 cellOf (const glm::vec3 &p) const
 Cell of.
 

静态 Public 成员函数

static SimGrid make (const MeshSdf &sdf, float cellSize)
 Build a grid covering the SDF domain plus one cell of padding.
 

Public 属性

glm::vec3 origin {0.f}
 World position of cell (0,0,0).
 
glm::ivec3 dims {0}
 Cell counts per axis.
 
float cellSize = 1.f
 Cell size in world units (== SPH support radius).
 

详细描述

Uniform grid used for neighbor queries.

在文件 FluidSimulation.h 第 25 行定义.

成员函数说明

◆ cellCount()

int eve::fluids::SimGrid::cellCount ( ) const

Cell count.

返回
dims.x * dims.y * dims.z.

在文件 FluidSimulation.cpp 第 19 行定义.

引用了 dims.

被这些函数引用 eve::fluids::FluidSimulation::setSdf().

◆ cellIndex()

int eve::fluids::SimGrid::cellIndex ( int  x,
int  y,
int  z 
) const

Cell index.

返回
flat index of cell (x,y,z); caller guarantees bounds.

在文件 FluidSimulation.cpp 第 21 行定义.

引用了 dims, x, y , 以及 z.

◆ cellOf()

glm::ivec3 eve::fluids::SimGrid::cellOf ( const glm::vec3 &  p) const

Cell of.

返回
clamped cell coordinate of a world position.

在文件 FluidSimulation.cpp 第 27 行定义.

引用了 c, cellSize, dims, origin , 以及 p.

◆ inBounds()

bool eve::fluids::SimGrid::inBounds ( int  x,
int  y,
int  z 
) const

In bounds.

返回
true when the cell coordinate is inside the grid.

在文件 FluidSimulation.cpp 第 23 行定义.

引用了 dims, x, y , 以及 z.

◆ make()

SimGrid eve::fluids::SimGrid::make ( const MeshSdf &  sdf,
float  cellSize 
)
static

类成员变量说明

◆ cellSize

float eve::fluids::SimGrid::cellSize = 1.f

Cell size in world units (== SPH support radius).

在文件 FluidSimulation.h 第 31 行定义.

被这些函数引用 cellOf() , 以及 make().

◆ dims

glm::ivec3 eve::fluids::SimGrid::dims {0}

Cell counts per axis.

在文件 FluidSimulation.h 第 29 行定义.

被这些函数引用 cellCount(), cellIndex(), cellOf() , 以及 inBounds().

◆ origin

glm::vec3 eve::fluids::SimGrid::origin {0.f}

World position of cell (0,0,0).

在文件 FluidSimulation.h 第 27 行定义.

被这些函数引用 cellOf().


该结构体的文档由以下文件生成: