11#ifndef PBAT_GPU_XPBD_INTEGRATOR_H
12#define PBAT_GPU_XPBD_INTEGRATOR_H
14#include "PhysicsBasedAnimationToolkitExport.h"
16#include "pbat/sim/xpbd/Data.h"
17#include "pbat/sim/xpbd/Enums.h"
22namespace pbat::gpu::impl::xpbd {
Definition Integrator.cuh:21
PBAT_API Integrator(Data const &data)
Construct a new Integrator object from the input XPBD data.
Definition Integrator.cu:14
PBAT_API GpuMatrixX GetLameCoefficients() const
Fetch the Lame coefficients from the GPU.
Definition Integrator.cu:100
PBAT_API GpuMatrixX GetExternalAcceleration() const
Fetch the external acceleration from the GPU.
Definition Integrator.cu:90
PBAT_API void SetLameCoefficients(Eigen::Ref< GpuMatrixX const > const &l)
Set the GPU Lame coefficients from the input CPU Lame coefficients.
Definition Integrator.cu:63
PBAT_API void SetMassInverse(Eigen::Ref< GpuMatrixX const > const &minv)
Set the GPU mass inverse from the input CPU mass inverse.
Definition Integrator.cu:58
PBAT_API GpuMatrixX GetShapeMatrixInverse() const
Fetch the shape matrix inverses from the GPU.
Definition Integrator.cu:106
PBAT_API void SetSceneBoundingBox(Eigen::Vector< GpuScalar, 3 > const &min, Eigen::Vector< GpuScalar, 3 > const &max)
Set the world bounding box for the current time step.
Definition Integrator.cu:78
PBAT_API GpuVectorX GetMassInverse() const
Fetch the mass inverse from the GPU.
Definition Integrator.cu:95
PBAT_API void SetFrictionCoefficients(GpuScalar muS, GpuScalar muK)
Set the friction coefficients to use for contact handling.
Definition Integrator.cu:73
PBAT_API GpuMatrixX GetVelocity() const
Fetch the vertex velocities from the GPU.
Definition Integrator.cu:85
PBAT_API void SetPositions(Eigen::Ref< GpuMatrixX const > const &X)
Set the GPU vertex positions from the input CPU vertex positions.
Definition Integrator.cu:43
PBAT_API GpuMatrixX Positions() const
Fetch the current positions from the GPU.
Definition Integrator.cu:38
PBAT_API GpuMatrixX GetLagrangeMultiplier(EConstraint eConstraint) const
Fetch the Lagrange multipliers from the GPU.
Definition Integrator.cu:118
PBAT_API void SetCompliance(Eigen::Ref< GpuMatrixX const > const &alpha, EConstraint eConstraint)
Set the GPU constraint compliances from the input CPU constraint compliances.
Definition Integrator.cu:68
pbat::sim::xpbd::EConstraint EConstraint
Constraint type enumeration short name.
Definition Integrator.h:37
PBAT_API GpuMatrixX GetRestStableGamma() const
Fetch the Stable Neo-Hookean rest-stable gamma from the GPU smith2018snh.
Definition Integrator.cu:112
PBAT_API void SetVelocities(Eigen::Ref< GpuMatrixX const > const &v)
Set the GPU vertex velocities from the input CPU vertex velocities.
Definition Integrator.cu:48
pbat::sim::xpbd::Data Data
Input XPBD data constructor parameter object short name.
Definition Integrator.h:36
PBAT_API void SetExternalAcceleration(Eigen::Ref< GpuMatrixX const > const &aext)
Set the GPU external acceleration from the input CPU external acceleration.
Definition Integrator.cu:53
PBAT_API void Step(GpuScalar dt, GpuIndex iterations, GpuIndex substeps)
Step once in time.
Definition Integrator.cu:33
PBAT_API GpuMatrixX GetCompliance(EConstraint eConstraint) const
Fetch the compliance from the GPU.
Definition Integrator.cu:129
Type aliases for GPU code.
GPU algorithm implementations.
Definition VertexTriangleMixedCcdDcd.h:21
(eXtended) Position-Based Dynamics (XPBD) bender2015position public GPU API
Definition Integrator.cu:12
GPU related public functionality.
Definition Buffer.cu:16
The main namespace of the library.
Definition Aliases.h:15
float GpuScalar
Scalar type for GPU code.
Definition Aliases.h:19
Eigen::Vector< Scalar, N > Vector
Fixed-size vector type.
Definition Aliases.h:24
Eigen::Vector< GpuScalar, Eigen::Dynamic > GpuVectorX
Vector type for GPU code.
Definition Aliases.h:27
Eigen::Matrix< GpuScalar, Eigen::Dynamic, Eigen::Dynamic > GpuMatrixX
Matrix type for GPU code.
Definition Aliases.h:22
std::int32_t GpuIndex
Index type for GPU code.
Definition Aliases.h:20