Struct HavokSimulation
Steps a physics world using Havok Physics plugin.
Inherited Members
Namespace: Havok.Physics
Syntax
public struct HavokSimulation : ISimulation, IDisposable
Constructors
HavokSimulation(HavokConfiguration)
Constructor.
Declaration
public HavokSimulation(HavokConfiguration config)
Parameters
Type | Name | Description |
---|---|---|
HavokConfiguration | config | The HavokConfiguration. |
Properties
CollisionEvents
Gets the collision events.
Declaration
public readonly HavokCollisionEvents CollisionEvents { get; }
Property Value
Type | Description |
---|---|
HavokCollisionEvents | The collision events. |
ContactsCount
Gets the Contact count.
Declaration
public readonly int ContactsCount { get; }
Property Value
Type | Description |
---|---|
Int32 | Number of contacts detected in the latest narrow phase. |
FinalJobHandle
Gets the handle of the final job.
Declaration
public readonly JobHandle FinalJobHandle { get; }
Property Value
Type | Description |
---|---|
JobHandle | The final job handle. |
FinalSimulationJobHandle
Gets the handle of the final simulation job (not including dispose jobs).
Declaration
public readonly JobHandle FinalSimulationJobHandle { get; }
Property Value
Type | Description |
---|---|
JobHandle | The final simulation job handle. |
ImpulseEvents
Gets the impulse events.
Declaration
public readonly HavokImpulseEvents ImpulseEvents { get; }
Property Value
Type | Description |
---|---|
HavokImpulseEvents | The impulse events. |
TriggerEvents
Gets the trigger events.
Declaration
public readonly HavokTriggerEvents TriggerEvents { get; }
Property Value
Type | Description |
---|---|
HavokTriggerEvents | The trigger events. |
Type
Gets the simulation type.
Declaration
public readonly SimulationType Type { get; }
Property Value
Type | Description |
---|---|
SimulationType | Unity.Physics.SimulationType.HavokPhysics. |
Implements
Methods
Dispose()
Disposes internal memory.
Declaration
public void Dispose()
Implements
ScheduleBroadphaseJobs(SimulationStepInput, JobHandle, Boolean)
Schedule broadphase jobs.
Declaration
public SimulationJobHandles ScheduleBroadphaseJobs(SimulationStepInput input, JobHandle inputDeps, bool multiThreaded = true)
Parameters
Type | Name | Description |
---|---|---|
SimulationStepInput | input | The input. |
JobHandle | inputDeps | The input deps. |
Boolean | multiThreaded | (Optional) True if multi threaded. |
Returns
Type | Description |
---|---|
SimulationJobHandles | The SimulationJobHandles. |
ScheduleCreateJacobiansJobs(SimulationStepInput, JobHandle, Boolean)
Schedule create jacobians jobs.
Declaration
public SimulationJobHandles ScheduleCreateJacobiansJobs(SimulationStepInput input, JobHandle inputDeps, bool multiThreaded = true)
Parameters
Type | Name | Description |
---|---|---|
SimulationStepInput | input | The input. |
JobHandle | inputDeps | The input deps. |
Boolean | multiThreaded | (Optional) True if multi threaded. |
Returns
Type | Description |
---|---|
SimulationJobHandles | The SimulationJobHandles. |
ScheduleNarrowphaseJobs(SimulationStepInput, JobHandle, Boolean)
Schedule narrowphase jobs.
Declaration
public SimulationJobHandles ScheduleNarrowphaseJobs(SimulationStepInput input, JobHandle inputDeps, bool multiThreaded = true)
Parameters
Type | Name | Description |
---|---|---|
SimulationStepInput | input | The input. |
JobHandle | inputDeps | The input deps. |
Boolean | multiThreaded | (Optional) True if multi threaded. |
Returns
Type | Description |
---|---|
SimulationJobHandles | The SimulationJobHandles. |
ScheduleSolveAndIntegrateJobs(SimulationStepInput, JobHandle, Boolean)
Schedule solve and integrate jobs.
Declaration
public SimulationJobHandles ScheduleSolveAndIntegrateJobs(SimulationStepInput input, JobHandle inputDeps, bool multiThreaded = true)
Parameters
Type | Name | Description |
---|---|---|
SimulationStepInput | input | The input. |
JobHandle | inputDeps | The input deps. |
Boolean | multiThreaded | (Optional) True if multi threaded. |
Returns
Type | Description |
---|---|
SimulationJobHandles | The SimulationJobHandles. |
ScheduleStepJobs(SimulationStepInput, JobHandle, Boolean)
Schedule step jobs.
Declaration
public SimulationJobHandles ScheduleStepJobs(SimulationStepInput input, JobHandle inputDeps, bool multiThreaded = true)
Parameters
Type | Name | Description |
---|---|---|
SimulationStepInput | input | The input. |
JobHandle | inputDeps | The input deps. |
Boolean | multiThreaded | (Optional) True if multi threaded. |
Returns
Type | Description |
---|---|
SimulationJobHandles | The SimulationJobHandles. |
Step(SimulationStepInput)
Steps the world immediately.
Declaration
public void Step(SimulationStepInput input)
Parameters
Type | Name | Description |
---|---|---|
SimulationStepInput | input | The input. |
Implements
StepImmediate(SimulationStepInput, ref SimulationContext)
Steps the simulation immediately on a single thread without spawning any jobs.
Declaration
public static void StepImmediate(SimulationStepInput input, ref SimulationContext simulationContext)
Parameters
Type | Name | Description |
---|---|---|
SimulationStepInput | input | The input. |
SimulationContext | simulationContext | [in,out] Context for the simulation. |