11 #ifndef CUBBYFLOW_CUDA_PARTICLE_SYSTEM_SOLVER2_HPP 12 #define CUBBYFLOW_CUDA_PARTICLE_SYSTEM_SOLVER2_HPP 14 #ifdef CUBBYFLOW_USE_CUDA 33 class CUDAParticleSystemSolver2 :
public CUDAParticleSystemSolverBase2
39 CUDAParticleSystemSolver2();
42 CUDAParticleSystemSolver2(
float radius,
float mass);
45 CUDAParticleSystemSolver2(
const CUDAParticleSystemSolver2&) =
delete;
48 CUDAParticleSystemSolver2(CUDAParticleSystemSolver2&&) noexcept = delete;
51 ~CUDAParticleSystemSolver2() override = default;
54 CUDAParticleSystemSolver2& operator=(const CUDAParticleSystemSolver2&) =
58 CUDAParticleSystemSolver2& operator=(CUDAParticleSystemSolver2&&) noexcept =
65 void SetRadius(
float newRadius);
71 void SetMass(
float newMass);
74 static Builder GetBuilder();
78 void OnAdvanceTimeStep(
double timeStepInSeconds) override;
81 float m_radius = 1e-3f;
86 using CUDAParticleSystemSolver2Ptr = std::shared_ptr<CUDAParticleSystemSolver2>;
91 class CUDAParticleSystemSolver2::Builder final
92 : public CUDAParticleSystemSolverBuilderBase2<Builder>
96 Builder& WithRadius(
float radius);
99 Builder& WithMass(
float mass);
102 CUDAParticleSystemSolver2 Build()
const;
105 CUDAParticleSystemSolver2Ptr MakeShared()
const;
108 float m_radius = 1e-3f;
109 float m_mass = 1e-3f;
Definition: pybind11Utils.hpp:20