CubbyFlow v0.71
Loading...
Searching...
No Matches
Core
CUDA
CUDAWCSPHSolver2.hpp
Go to the documentation of this file.
1
// This code is based on Jet framework.
2
// Copyright (c) 2018 Doyub Kim
3
// CubbyFlow is voxel-based fluid simulation engine for computer games.
4
// Copyright (c) 2020 CubbyFlow Team
5
// Core Part: Chris Ohk, Junwoo Hwang, Jihong Sin, Seungwoo Yoo
6
// AI Part: Dongheon Cho, Minseo Kim
7
// We are making my contributions/submissions to this project solely in our
8
// personal capacity and are not conveying any rights to any intellectual
9
// property of any third parties.
10
11
#ifndef CUBBYFLOW_CUDA_WC_SPH_SOLVER2_HPP
12
#define CUBBYFLOW_CUDA_WC_SPH_SOLVER2_HPP
13
14
#ifdef CUBBYFLOW_USE_CUDA
15
16
#include <
Core/CUDA/CUDASPHSolverBase2.hpp
>
17
18
namespace
CubbyFlow
19
{
36
class
CUDAWCSPHSolver2
:
public
CUDASPHSolverBase2
37
{
38
public
:
39
class
Builder;
40
42
CUDAWCSPHSolver2
();
43
46
CUDAWCSPHSolver2
(
float
targetDensity
,
float
targetSpacing
,
47
float
relativeKernelRadius
);
48
50
CUDAWCSPHSolver2
(
const
CUDAWCSPHSolver2
&) =
delete
;
51
53
CUDAWCSPHSolver2
(
CUDAWCSPHSolver2
&&)
noexcept
=
delete
;
54
56
~
CUDAWCSPHSolver2
()
override
=
default
;
57
59
CUDAWCSPHSolver2
&
operator
=(
const
CUDAWCSPHSolver2
&) =
delete
;
60
62
CUDAWCSPHSolver2
&
operator
=(
CUDAWCSPHSolver2
&&)
noexcept
=
delete
;
63
65
[[
nodiscard
]]
float
EOSExponent
()
const
;
66
74
void
SetEOSExponent
(
float
newEosExponent
);
75
77
static
Builder GetBuilder();
78
79
protected
:
81
void
OnAdvanceTimeStep(
double
timeStepInSeconds
)
override
;
82
83
private
:
84
float
m_eosExponent = 7.0
f
;
85
};
86
88
using
CUDAWCSPHSolver2Ptr
=
std
::
shared_ptr
<
CUDAWCSPHSolver2
>;
89
93
class
CUDAWCSPHSolver2
::Builder
final
94
:
public
CUDASPHSolverBuilderBase2
<
CUDAWCSPHSolver2
::Builder>
95
{
96
public
:
98
[[
nodiscard
]]
CUDAWCSPHSolver2
Build()
const
;
99
101
[[
nodiscard
]]
CUDAWCSPHSolver2Ptr
MakeShared()
const
;
102
};
103
}
// namespace CubbyFlow
104
105
#endif
106
107
#endif
CUDASPHSolverBase2.hpp
CubbyFlow
Definition
pybind11Utils.hpp:21
CubbyFlow::Vector
Matrix< T, Rows, 1 > Vector
Definition
Matrix.hpp:738
Generated on Mon Apr 6 2026 15:46:03 for CubbyFlow by
1.9.8