mirror of
https://github.com/ahwootech/BRUTAL.git
synced 2026-11-26 21:18:24 +01:00
293 lines
21 KiB
C#
293 lines
21 KiB
C#
// <auto-generated/>
|
|
// Generated by Brutal.Jolt.Generate; do not edit by hand.
|
|
#nullable enable
|
|
|
|
using Brutal.Interop;
|
|
using Brutal.Numerics;
|
|
namespace Brutal.JoltApi
|
|
{
|
|
public static partial class Jolt
|
|
{
|
|
public static unsafe partial class PInvoke
|
|
{
|
|
[LibraryImport("jolt", EntryPoint = "AxisConstraintPart_Create")]
|
|
public static partial AxisConstraintPart AxisConstraintPart_Create();
|
|
[LibraryImport("jolt", EntryPoint = "AxisConstraintPart_Destroy")]
|
|
public static partial void AxisConstraintPart_Destroy(AxisConstraintPart self);
|
|
/// <summary>
|
|
/// <para>
|
|
/// C++:
|
|
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Constraints/ConstraintPart/AxisConstraintPart.h#L249">Jolt/Physics/Constraints/ConstraintPart/AxisConstraintPart.h:249</see>
|
|
/// <br/>
|
|
/// <c>inline void CalculateConstraintProperties(const Body &inBody1, Vec3Arg inR1PlusU, const Body &inBody2, Vec3Arg inR2, Vec3Arg inWorldSpaceAxis, float inBias = 0.0f)</c>
|
|
/// </para>
|
|
/// </summary>
|
|
/// <remarks>
|
|
/// <code>
|
|
/// Calculate properties used during the functions below
|
|
/// @param inBody1 The first body that this constraint is attached to
|
|
/// @param inBody2 The second body that this constraint is attached to
|
|
/// @param inR1PlusU See equations above (r1 + u)
|
|
/// @param inR2 See equations above (r2)
|
|
/// @param inWorldSpaceAxis Axis along which the constraint acts (normalized, pointing from body 1 to 2)
|
|
/// @param inBias Bias term (b) for the constraint impulse: lambda = J v + b
|
|
/// </code>
|
|
/// </remarks>
|
|
[LibraryImport("jolt", EntryPoint = "AxisConstraintPart_CalculateConstraintProperties")]
|
|
public static partial void AxisConstraintPart_CalculateConstraintProperties(AxisConstraintPart self, Body body1, float3 r1PlusU, Body body2, float3 r2, float3 worldSpaceAxis, float bias);
|
|
/// <summary>
|
|
/// <para>
|
|
/// C++:
|
|
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Constraints/ConstraintPart/AxisConstraintPart.h#L273">Jolt/Physics/Constraints/ConstraintPart/AxisConstraintPart.h:273</see>
|
|
/// <br/>
|
|
/// <c>inline void CalculateConstraintPropertiesWithMassOverride(const Body &inBody1, float inInvMass1, float inInvInertiaScale1, Vec3Arg inR1PlusU, const Body &inBody2, float inInvMass2, float inInvInertiaScale2, Vec3Arg inR2, Vec3Arg inWorldSpaceAxis, float inBias = 0.0f)</c>
|
|
/// </para>
|
|
/// </summary>
|
|
/// <remarks>
|
|
/// <code>
|
|
/// Calculate properties used during the functions below, version that supports mass scaling
|
|
/// @param inBody1 The first body that this constraint is attached to
|
|
/// @param inBody2 The second body that this constraint is attached to
|
|
/// @param inInvMass1 The inverse mass of body 1 (only used when body 1 is dynamic)
|
|
/// @param inInvMass2 The inverse mass of body 2 (only used when body 2 is dynamic)
|
|
/// @param inInvInertiaScale1 Scale factor for the inverse inertia of body 1
|
|
/// @param inInvInertiaScale2 Scale factor for the inverse inertia of body 2
|
|
/// @param inR1PlusU See equations above (r1 + u)
|
|
/// @param inR2 See equations above (r2)
|
|
/// @param inWorldSpaceAxis Axis along which the constraint acts (normalized, pointing from body 1 to 2)
|
|
/// @param inBias Bias term (b) for the constraint impulse: lambda = J v + b
|
|
/// </code>
|
|
/// </remarks>
|
|
[LibraryImport("jolt", EntryPoint = "AxisConstraintPart_CalculateConstraintPropertiesWithMassOverride")]
|
|
public static partial void AxisConstraintPart_CalculateConstraintPropertiesWithMassOverride(AxisConstraintPart self, Body body1, float invMass1, float invInertiaScale1, float3 r1PlusU, Body body2, float invMass2, float invInertiaScale2, float3 r2, float3 worldSpaceAxis, float bias);
|
|
/// <summary>
|
|
/// <para>
|
|
/// C++:
|
|
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Constraints/ConstraintPart/AxisConstraintPart.h#L297">Jolt/Physics/Constraints/ConstraintPart/AxisConstraintPart.h:297</see>
|
|
/// <br/>
|
|
/// <c>inline void CalculateConstraintPropertiesWithFrequencyAndDamping(float inDeltaTime, const Body &inBody1, Vec3Arg inR1PlusU, const Body &inBody2, Vec3Arg inR2, Vec3Arg inWorldSpaceAxis, float inBias, float inC, float inFrequency, float inDamping)</c>
|
|
/// </para>
|
|
/// </summary>
|
|
/// <remarks>
|
|
/// <code>
|
|
/// Calculate properties used during the functions below
|
|
/// @param inDeltaTime Time step
|
|
/// @param inBody1 The first body that this constraint is attached to
|
|
/// @param inBody2 The second body that this constraint is attached to
|
|
/// @param inR1PlusU See equations above (r1 + u)
|
|
/// @param inR2 See equations above (r2)
|
|
/// @param inWorldSpaceAxis Axis along which the constraint acts (normalized, pointing from body 1 to 2)
|
|
/// @param inBias Bias term (b) for the constraint impulse: lambda = J v + b
|
|
/// @param inC Value of the constraint equation (C).
|
|
/// @param inFrequency Oscillation frequency (Hz).
|
|
/// @param inDamping Damping factor (0 = no damping, 1 = critical damping).
|
|
/// </code>
|
|
/// </remarks>
|
|
[LibraryImport("jolt", EntryPoint = "AxisConstraintPart_CalculateConstraintPropertiesWithFrequencyAndDamping")]
|
|
public static partial void AxisConstraintPart_CalculateConstraintPropertiesWithFrequencyAndDamping(AxisConstraintPart self, float deltaTime, Body body1, float3 r1PlusU, Body body2, float3 r2, float3 worldSpaceAxis, float bias, float c, float frequency, float damping);
|
|
/// <summary>
|
|
/// <para>
|
|
/// C++:
|
|
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Constraints/ConstraintPart/AxisConstraintPart.h#L318">Jolt/Physics/Constraints/ConstraintPart/AxisConstraintPart.h:318</see>
|
|
/// <br/>
|
|
/// <c>inline void CalculateConstraintPropertiesWithStiffnessAndDamping(float inDeltaTime, const Body &inBody1, Vec3Arg inR1PlusU, const Body &inBody2, Vec3Arg inR2, Vec3Arg inWorldSpaceAxis, float inBias, float inC, float inStiffness, float inDamping)</c>
|
|
/// </para>
|
|
/// </summary>
|
|
/// <remarks>
|
|
/// <code>
|
|
/// Calculate properties used during the functions below
|
|
/// @param inDeltaTime Time step
|
|
/// @param inBody1 The first body that this constraint is attached to
|
|
/// @param inBody2 The second body that this constraint is attached to
|
|
/// @param inR1PlusU See equations above (r1 + u)
|
|
/// @param inR2 See equations above (r2)
|
|
/// @param inWorldSpaceAxis Axis along which the constraint acts (normalized, pointing from body 1 to 2)
|
|
/// @param inBias Bias term (b) for the constraint impulse: lambda = J v + b
|
|
/// @param inC Value of the constraint equation (C).
|
|
/// @param inStiffness Spring stiffness k.
|
|
/// @param inDamping Spring damping coefficient c.
|
|
/// </code>
|
|
/// </remarks>
|
|
[LibraryImport("jolt", EntryPoint = "AxisConstraintPart_CalculateConstraintPropertiesWithStiffnessAndDamping")]
|
|
public static partial void AxisConstraintPart_CalculateConstraintPropertiesWithStiffnessAndDamping(AxisConstraintPart self, float deltaTime, Body body1, float3 r1PlusU, Body body2, float3 r2, float3 worldSpaceAxis, float bias, float c, float stiffness, float damping);
|
|
/// <summary>
|
|
/// <para>
|
|
/// C++:
|
|
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Constraints/ConstraintPart/AxisConstraintPart.h#L329">Jolt/Physics/Constraints/ConstraintPart/AxisConstraintPart.h:329</see>
|
|
/// <br/>
|
|
/// <c>inline void CalculateConstraintPropertiesWithSettings(float inDeltaTime, const Body &inBody1, Vec3Arg inR1PlusU, const Body &inBody2, Vec3Arg inR2, Vec3Arg inWorldSpaceAxis, float inBias, float inC, const SpringSettings &inSpringSettings)</c>
|
|
/// </para>
|
|
/// </summary>
|
|
/// <remarks>
|
|
/// <para>
|
|
/// Selects one of the above functions based on the spring settings
|
|
/// </para>
|
|
/// </remarks>
|
|
[LibraryImport("jolt", EntryPoint = "AxisConstraintPart_CalculateConstraintPropertiesWithSettings")]
|
|
public static partial void AxisConstraintPart_CalculateConstraintPropertiesWithSettings(AxisConstraintPart self, float deltaTime, Body body1, float3 r1PlusU, Body body2, float3 r2, float3 worldSpaceAxis, float bias, float c, SpringSettings springSettings);
|
|
/// <summary>
|
|
/// <para>
|
|
/// C++:
|
|
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Constraints/ConstraintPart/AxisConstraintPart.h#L342">Jolt/Physics/Constraints/ConstraintPart/AxisConstraintPart.h:342</see>
|
|
/// <br/>
|
|
/// <c>inline void Deactivate()</c>
|
|
/// </para>
|
|
/// </summary>
|
|
/// <remarks>
|
|
/// <para>
|
|
/// Deactivate this constraint
|
|
/// </para>
|
|
/// </remarks>
|
|
[LibraryImport("jolt", EntryPoint = "AxisConstraintPart_Deactivate")]
|
|
public static partial void AxisConstraintPart_Deactivate(AxisConstraintPart self);
|
|
/// <summary>
|
|
/// <para>
|
|
/// C++:
|
|
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Constraints/ConstraintPart/AxisConstraintPart.h#L349">Jolt/Physics/Constraints/ConstraintPart/AxisConstraintPart.h:349</see>
|
|
/// <br/>
|
|
/// <c>inline bool IsActive() const</c>
|
|
/// </para>
|
|
/// </summary>
|
|
/// <remarks>
|
|
/// <para>
|
|
/// Check if constraint is active
|
|
/// </para>
|
|
/// </remarks>
|
|
[LibraryImport("jolt", EntryPoint = "AxisConstraintPart_IsActive")]
|
|
public static partial Brutal.Bool8 AxisConstraintPart_IsActive(AxisConstraintPart self);
|
|
/// <summary>
|
|
/// <para>
|
|
/// C++:
|
|
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Constraints/ConstraintPart/AxisConstraintPart.h#L368">Jolt/Physics/Constraints/ConstraintPart/AxisConstraintPart.h:368</see>
|
|
/// <br/>
|
|
/// <c>inline void WarmStart(Body &ioBody1, Body &ioBody2, Vec3Arg inWorldSpaceAxis, float inWarmStartImpulseRatio)</c>
|
|
/// </para>
|
|
/// </summary>
|
|
/// <remarks>
|
|
/// <code>
|
|
/// Must be called from the WarmStartVelocityConstraint call to apply the previous frame's impulses
|
|
/// @param ioBody1 The first body that this constraint is attached to
|
|
/// @param ioBody2 The second body that this constraint is attached to
|
|
/// @param inWorldSpaceAxis Axis along which the constraint acts (normalized)
|
|
/// @param inWarmStartImpulseRatio Ratio of new step to old time step (dt_new / dt_old) for scaling the lagrange multiplier of the previous frame
|
|
/// </code>
|
|
/// </remarks>
|
|
[LibraryImport("jolt", EntryPoint = "AxisConstraintPart_WarmStart")]
|
|
public static partial void AxisConstraintPart_WarmStart(AxisConstraintPart self, Body body1, Body body2, float3 worldSpaceAxis, float warmStartImpulseRatio);
|
|
/// <summary>
|
|
/// <para>
|
|
/// C++:
|
|
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Constraints/ConstraintPart/AxisConstraintPart.h#L450">Jolt/Physics/Constraints/ConstraintPart/AxisConstraintPart.h:450</see>
|
|
/// <br/>
|
|
/// <c>inline bool SolveVelocityConstraint(Body &ioBody1, Body &ioBody2, Vec3Arg inWorldSpaceAxis, float inMinLambda, float inMaxLambda)</c>
|
|
/// </para>
|
|
/// </summary>
|
|
/// <remarks>
|
|
/// <code>
|
|
/// Iteratively update the velocity constraint. Makes sure d/dt C(...) = 0, where C is the constraint equation.
|
|
/// @param ioBody1 The first body that this constraint is attached to
|
|
/// @param ioBody2 The second body that this constraint is attached to
|
|
/// @param inWorldSpaceAxis Axis along which the constraint acts (normalized)
|
|
/// @param inMinLambda Minimum value of constraint impulse to apply (N s)
|
|
/// @param inMaxLambda Maximum value of constraint impulse to apply (N s)
|
|
/// </code>
|
|
/// </remarks>
|
|
[LibraryImport("jolt", EntryPoint = "AxisConstraintPart_SolveVelocityConstraint")]
|
|
public static partial Brutal.Bool8 AxisConstraintPart_SolveVelocityConstraint(AxisConstraintPart self, Body body1, Body body2, float3 worldSpaceAxis, float minLambda, float maxLambda);
|
|
/// <summary>
|
|
/// <para>
|
|
/// C++:
|
|
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Constraints/ConstraintPart/AxisConstraintPart.h#L503">Jolt/Physics/Constraints/ConstraintPart/AxisConstraintPart.h:503</see>
|
|
/// <br/>
|
|
/// <c>inline bool SolveVelocityConstraintWithMassOverride(Body &ioBody1, float inInvMass1, Body &ioBody2, float inInvMass2, Vec3Arg inWorldSpaceAxis, float inMinLambda, float inMaxLambda)</c>
|
|
/// </para>
|
|
/// </summary>
|
|
/// <remarks>
|
|
/// <code>
|
|
/// Iteratively update the velocity constraint. Makes sure d/dt C(...) = 0, where C is the constraint equation.
|
|
/// @param ioBody1 The first body that this constraint is attached to
|
|
/// @param ioBody2 The second body that this constraint is attached to
|
|
/// @param inInvMass1 The inverse mass of body 1 (only used when body 1 is dynamic)
|
|
/// @param inInvMass2 The inverse mass of body 2 (only used when body 2 is dynamic)
|
|
/// @param inWorldSpaceAxis Axis along which the constraint acts (normalized)
|
|
/// @param inMinLambda Minimum value of constraint impulse to apply (N s)
|
|
/// @param inMaxLambda Maximum value of constraint impulse to apply (N s)
|
|
/// </code>
|
|
/// </remarks>
|
|
[LibraryImport("jolt", EntryPoint = "AxisConstraintPart_SolveVelocityConstraintWithMassOverride")]
|
|
public static partial Brutal.Bool8 AxisConstraintPart_SolveVelocityConstraintWithMassOverride(AxisConstraintPart self, Body body1, float invMass1, Body body2, float invMass2, float3 worldSpaceAxis, float minLambda, float maxLambda);
|
|
/// <summary>
|
|
/// <para>
|
|
/// C++:
|
|
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Constraints/ConstraintPart/AxisConstraintPart.h#L554">Jolt/Physics/Constraints/ConstraintPart/AxisConstraintPart.h:554</see>
|
|
/// <br/>
|
|
/// <c>inline bool SolvePositionConstraint(Body &ioBody1, Body &ioBody2, Vec3Arg inWorldSpaceAxis, float inC, float inBaumgarte) const</c>
|
|
/// </para>
|
|
/// </summary>
|
|
/// <remarks>
|
|
/// <code>
|
|
/// Iteratively update the position constraint. Makes sure C(...) = 0.
|
|
/// @param ioBody1 The first body that this constraint is attached to
|
|
/// @param ioBody2 The second body that this constraint is attached to
|
|
/// @param inWorldSpaceAxis Axis along which the constraint acts (normalized)
|
|
/// @param inC Value of the constraint equation (C)
|
|
/// @param inBaumgarte Baumgarte constant (fraction of the error to correct)
|
|
/// </code>
|
|
/// </remarks>
|
|
[LibraryImport("jolt", EntryPoint = "AxisConstraintPart_SolvePositionConstraint")]
|
|
public static partial Brutal.Bool8 AxisConstraintPart_SolvePositionConstraint(AxisConstraintPart self, Body body1, Body body2, float3 worldSpaceAxis, float c, float baumgarte);
|
|
/// <summary>
|
|
/// <para>
|
|
/// C++:
|
|
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Constraints/ConstraintPart/AxisConstraintPart.h#L605">Jolt/Physics/Constraints/ConstraintPart/AxisConstraintPart.h:605</see>
|
|
/// <br/>
|
|
/// <c>inline bool SolvePositionConstraintWithMassOverride(Body &ioBody1, float inInvMass1, Body &ioBody2, float inInvMass2, Vec3Arg inWorldSpaceAxis, float inC, float inBaumgarte) const</c>
|
|
/// </para>
|
|
/// </summary>
|
|
/// <remarks>
|
|
/// <code>
|
|
/// Iteratively update the position constraint. Makes sure C(...) = 0.
|
|
/// @param ioBody1 The first body that this constraint is attached to
|
|
/// @param ioBody2 The second body that this constraint is attached to
|
|
/// @param inInvMass1 The inverse mass of body 1 (only used when body 1 is dynamic)
|
|
/// @param inInvMass2 The inverse mass of body 2 (only used when body 2 is dynamic)
|
|
/// @param inWorldSpaceAxis Axis along which the constraint acts (normalized)
|
|
/// @param inC Value of the constraint equation (C)
|
|
/// @param inBaumgarte Baumgarte constant (fraction of the error to correct)
|
|
/// </code>
|
|
/// </remarks>
|
|
[LibraryImport("jolt", EntryPoint = "AxisConstraintPart_SolvePositionConstraintWithMassOverride")]
|
|
public static partial Brutal.Bool8 AxisConstraintPart_SolvePositionConstraintWithMassOverride(AxisConstraintPart self, Body body1, float invMass1, Body body2, float invMass2, float3 worldSpaceAxis, float c, float baumgarte);
|
|
/// <summary>
|
|
/// <para>
|
|
/// C++:
|
|
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Constraints/ConstraintPart/AxisConstraintPart.h#L649">Jolt/Physics/Constraints/ConstraintPart/AxisConstraintPart.h:649</see>
|
|
/// <br/>
|
|
/// <c>inline void SetTotalLambda(float inLambda)</c>
|
|
/// </para>
|
|
/// </summary>
|
|
/// <remarks>
|
|
/// <para>
|
|
/// Override total lagrange multiplier, can be used to set the initial value for warm starting
|
|
/// </para>
|
|
/// </remarks>
|
|
[LibraryImport("jolt", EntryPoint = "AxisConstraintPart_SetTotalLambda")]
|
|
public static partial void AxisConstraintPart_SetTotalLambda(AxisConstraintPart self, float lambda);
|
|
/// <summary>
|
|
/// <para>
|
|
/// C++:
|
|
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Constraints/ConstraintPart/AxisConstraintPart.h#L655">Jolt/Physics/Constraints/ConstraintPart/AxisConstraintPart.h:655</see>
|
|
/// <br/>
|
|
/// <c>inline float GetTotalLambda() const</c>
|
|
/// </para>
|
|
/// </summary>
|
|
/// <remarks>
|
|
/// <para>
|
|
/// Return lagrange multiplier
|
|
/// </para>
|
|
/// </remarks>
|
|
[LibraryImport("jolt", EntryPoint = "AxisConstraintPart_GetTotalLambda")]
|
|
public static partial float AxisConstraintPart_GetTotalLambda(AxisConstraintPart self);
|
|
}
|
|
}
|
|
}
|