Navigation
API > API/Runtime > API/Runtime/Chaos
Base class for all the solver for a set of constraints of a specific type.
A SolverContainer is used to solve a set constraints in sequential order. There will be one solver container for each thread on which we solve constraints (see FPBDIslandConstraintGroupSolver). How constraints are assigned to groups depends on the constraint type and settings, but usually a group contains all constraints from one or more islands (unless we are coloring).
NOTE: there are two main use-case for FConstraintContainerSolver objects: the main physics scene and RBAN. The main scene uses the IslandManager to break the scene up into groups of constraints that can be solved in parallel (Islands). Those islands are then put into IslandGroups, and each IslandGroup is solved in a task, therefore we will have one FConstraintContainerSolver per type of constraint per IslandGroup. RBAN does not attempt to partition its scene into islands and just solves all constraints on its main thread, so it only has one FConstraintContainerSolver (per constraint type).
| Name | FConstraintContainerSolver |
| Type | class |
| Header File | /Engine/Source/Runtime/Experimental/Chaos/Public/Chaos/Evolution/SolverConstraintContainer.h |
| Include Path | #include "Chaos/Evolution/SolverConstraintContainer.h" |
Syntax
class FConstraintContainerSolver
Derived Classes
FConstraintContainerSolver derived class hierarchy
Constructors
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
FConstraintContainerSolver
(
const int32 InPriority |
Chaos/Evolution/SolverConstraintContainer.h |
Destructors
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
virtual ~FConstraintContainerSolver() |
Chaos/Evolution/SolverConstraintContainer.h |
Variables
Protected
| Name | Type | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|---|
| Priority | int32 | Chaos/Evolution/SolverConstraintContainer.h |
Functions
Public
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
void AddBodies
(
FSolverBodyContainer& SolverBodyContainer |
Add all the required bodies to the body container (required for the constraints added with AddConstraints) | Chaos/Evolution/SolverConstraintContainer.h | |
void AddConstraints
(
const TArrayView< Private::FPBDIslandConstraint* >& Constraints |
Island API. | Chaos/Evolution/SolverConstraintContainer.h | |
void AddConstraints () |
RBAN API. Add all (active) constraints to the solver. | Chaos/Evolution/SolverConstraintContainer.h | |
void ApplyPositionConstraints
(
const FReal Dt, |
Apply the position solve to all constraints in the container | Chaos/Evolution/SolverConstraintContainer.h | |
void ApplyProjectionConstraints
(
const FReal Dt, |
Apply the projection solve to all constraints in the container | Chaos/Evolution/SolverConstraintContainer.h | |
void ApplyVelocityConstraints
(
const FReal Dt, |
Apply the velocity solve to all constraints in the container | Chaos/Evolution/SolverConstraintContainer.h | |
void GatherInput
(
const FReal Dt, |
Chaos/Evolution/SolverConstraintContainer.h | ||
void GatherInput
(
const FReal Dt |
Chaos/Evolution/SolverConstraintContainer.h | ||
int32 GetNumConstraints() |
Chaos/Evolution/SolverConstraintContainer.h | ||
int32 GetPriority() |
Get the solver priority | Chaos/Evolution/SolverConstraintContainer.h | |
virtual void PreApplyPositionConstraints
(
const FReal Dt |
Chaos/Evolution/SolverConstraintContainer.h | ||
virtual void PreApplyProjectionConstraints
(
const FReal Dt |
Chaos/Evolution/SolverConstraintContainer.h | ||
virtual void PreApplyVelocityConstraints
(
const FReal Dt |
Chaos/Evolution/SolverConstraintContainer.h | ||
void Reset
(
const int32 MaxConstraints |
Set the maximum number of constraints the solver will have to handle. | Chaos/Evolution/SolverConstraintContainer.h | |
void ScatterOutput
(
const FReal Dt |
Chaos/Evolution/SolverConstraintContainer.h | ||
void ScatterOutput
(
const FReal Dt, |
Chaos/Evolution/SolverConstraintContainer.h | ||
void SetPriority
(
const int32 InPriority |
Set the solver priority. | Chaos/Evolution/SolverConstraintContainer.h |