mirror of
https://github.com/ahwootech/BRUTAL.git
synced 2026-11-26 04:58:24 +01:00
SOURCE DUMP v1
This commit is contained in:
parent
bd62d51ec9
commit
fb20299e9d
598 changed files with 768360 additions and 0 deletions
|
|
@ -0,0 +1,41 @@
|
|||
// <auto-generated/>
|
||||
// Generated by Brutal.Jolt.Generate; do not edit by hand.
|
||||
#nullable enable
|
||||
|
||||
using Brutal.Interop;
|
||||
using Brutal.Numerics;
|
||||
namespace Brutal.JoltApi
|
||||
{
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/AABBTree/AABBTreeBuilder.h#L35">Jolt/AABBTree/AABBTreeBuilder.h:35</see>
|
||||
/// <br/>
|
||||
/// <c>class AABBTreeBuilder</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <para>
|
||||
/// Helper class to build an AABB tree
|
||||
/// </para>
|
||||
/// </remarks>
|
||||
[InteropHandle]
|
||||
public readonly partial struct AABBTreeBuilder : IDisposable
|
||||
{
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/AABBTree/AABBTreeBuilder.h#L101">Jolt/AABBTree/AABBTreeBuilder.h:101</see>
|
||||
/// <br/>
|
||||
/// <c>explicit AABBTreeBuilder(TriangleSplitter &inSplitter, uint inMaxTrianglesPerLeaf = 16)</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <para>
|
||||
/// Constructor
|
||||
/// </para>
|
||||
/// </remarks>
|
||||
public static AABBTreeBuilder Create(TriangleSplitter splitter, uint maxTrianglesPerLeaf) => Jolt.PInvoke.AABBTreeBuilder_Create(splitter, maxTrianglesPerLeaf);
|
||||
public void Dispose() => Jolt.PInvoke.AABBTreeBuilder_Destroy(this);
|
||||
}
|
||||
}
|
||||
385
brutal.jolt/Brutal.Jolt/Generated/Classes/AABox.gen.cs
Normal file
385
brutal.jolt/Brutal.Jolt/Generated/Classes/AABox.gen.cs
Normal file
|
|
@ -0,0 +1,385 @@
|
|||
// <auto-generated/>
|
||||
// Generated by Brutal.Jolt.Generate; do not edit by hand.
|
||||
#nullable enable
|
||||
|
||||
using Brutal.Interop;
|
||||
using Brutal.Numerics;
|
||||
namespace Brutal.JoltApi
|
||||
{
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Geometry/AABox.h#L15">Jolt/Geometry/AABox.h:15</see>
|
||||
/// <br/>
|
||||
/// <c>class AABox</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <para>
|
||||
/// Axis aligned box
|
||||
/// </para>
|
||||
/// </remarks>
|
||||
[InteropHandle]
|
||||
public readonly partial struct AABox : IDisposable
|
||||
{
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Geometry/AABox.h#L21">Jolt/Geometry/AABox.h:21</see>
|
||||
/// <br/>
|
||||
/// <c>AABox()</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <para>
|
||||
/// Constructor
|
||||
/// </para>
|
||||
/// </remarks>
|
||||
public static AABox Create() => Jolt.PInvoke.AABox_Create();
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Geometry/AABox.h#L22">Jolt/Geometry/AABox.h:22</see>
|
||||
/// <br/>
|
||||
/// <c>AABox(Vec3Arg inMin, Vec3Arg inMax)</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
public static AABox Create(float3 min, float3 max) => Jolt.PInvoke.AABox_Create_2(min, max);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Geometry/AABox.h#L24">Jolt/Geometry/AABox.h:24</see>
|
||||
/// <br/>
|
||||
/// <c>AABox(Vec3Arg inCenter, float inRadius)</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
public static AABox Create(float3 center, float radius) => Jolt.PInvoke.AABox_Create_3(center, radius);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Geometry/AABox.h#L49">Jolt/Geometry/AABox.h:49</see>
|
||||
/// <br/>
|
||||
/// <c>void SetEmpty()</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <para>
|
||||
/// Reset the bounding box to an empty bounding box
|
||||
/// </para>
|
||||
/// </remarks>
|
||||
public void SetEmpty() => Jolt.PInvoke.AABox_SetEmpty(this);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Geometry/AABox.h#L56">Jolt/Geometry/AABox.h:56</see>
|
||||
/// <br/>
|
||||
/// <c>bool IsValid() const</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <para>
|
||||
/// Check if the bounding box is valid (max >= min)
|
||||
/// </para>
|
||||
/// </remarks>
|
||||
public bool IsValid() => Jolt.PInvoke.AABox_IsValid(this);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Geometry/AABox.h#L62">Jolt/Geometry/AABox.h:62</see>
|
||||
/// <br/>
|
||||
/// <c>void Encapsulate(Vec3Arg inPos)</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <para>
|
||||
/// Encapsulate point in bounding box
|
||||
/// </para>
|
||||
/// </remarks>
|
||||
public void Encapsulate(float3 pos) => Jolt.PInvoke.AABox_Encapsulate(this, pos);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Geometry/AABox.h#L69">Jolt/Geometry/AABox.h:69</see>
|
||||
/// <br/>
|
||||
/// <c>void Encapsulate(const AABox &inRHS)</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <para>
|
||||
/// Encapsulate bounding box in bounding box
|
||||
/// </para>
|
||||
/// </remarks>
|
||||
public void Encapsulate(AABox rHS) => Jolt.PInvoke.AABox_Encapsulate_2(this, rHS);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Geometry/AABox.h#L76">Jolt/Geometry/AABox.h:76</see>
|
||||
/// <br/>
|
||||
/// <c>void Encapsulate(const Triangle &inRHS)</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <para>
|
||||
/// Encapsulate triangle in bounding box
|
||||
/// </para>
|
||||
/// </remarks>
|
||||
public void Encapsulate(Triangle rHS) => Jolt.PInvoke.AABox_Encapsulate_3(this, rHS);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Geometry/AABox.h#L100">Jolt/Geometry/AABox.h:100</see>
|
||||
/// <br/>
|
||||
/// <c>void EnsureMinimalEdgeLength(float inMinEdgeLength)</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <para>
|
||||
/// Make sure that each edge of the bounding box has a minimal length
|
||||
/// </para>
|
||||
/// </remarks>
|
||||
public void EnsureMinimalEdgeLength(float minEdgeLength) => Jolt.PInvoke.AABox_EnsureMinimalEdgeLength(this, minEdgeLength);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Geometry/AABox.h#L107">Jolt/Geometry/AABox.h:107</see>
|
||||
/// <br/>
|
||||
/// <c>void ExpandBy(Vec3Arg inVector)</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <para>
|
||||
/// Widen the box on both sides by inVector
|
||||
/// </para>
|
||||
/// </remarks>
|
||||
public void ExpandBy(float3 vector) => Jolt.PInvoke.AABox_ExpandBy(this, vector);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Geometry/AABox.h#L114">Jolt/Geometry/AABox.h:114</see>
|
||||
/// <br/>
|
||||
/// <c>Vec3 GetCenter() const</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <para>
|
||||
/// Get center of bounding box
|
||||
/// </para>
|
||||
/// </remarks>
|
||||
public float3 GetCenter() => Jolt.PInvoke.AABox_GetCenter(this);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Geometry/AABox.h#L120">Jolt/Geometry/AABox.h:120</see>
|
||||
/// <br/>
|
||||
/// <c>Vec3 GetExtent() const</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <para>
|
||||
/// Get extent of bounding box (half of the size)
|
||||
/// </para>
|
||||
/// </remarks>
|
||||
public float3 GetExtent() => Jolt.PInvoke.AABox_GetExtent(this);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Geometry/AABox.h#L126">Jolt/Geometry/AABox.h:126</see>
|
||||
/// <br/>
|
||||
/// <c>Vec3 GetSize() const</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <para>
|
||||
/// Get size of bounding box
|
||||
/// </para>
|
||||
/// </remarks>
|
||||
public float3 GetSize() => Jolt.PInvoke.AABox_GetSize(this);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Geometry/AABox.h#L132">Jolt/Geometry/AABox.h:132</see>
|
||||
/// <br/>
|
||||
/// <c>float GetSurfaceArea() const</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <para>
|
||||
/// Get surface area of bounding box
|
||||
/// </para>
|
||||
/// </remarks>
|
||||
public float GetSurfaceArea() => Jolt.PInvoke.AABox_GetSurfaceArea(this);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Geometry/AABox.h#L139">Jolt/Geometry/AABox.h:139</see>
|
||||
/// <br/>
|
||||
/// <c>float GetVolume() const</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <para>
|
||||
/// Get volume of bounding box
|
||||
/// </para>
|
||||
/// </remarks>
|
||||
public float GetVolume() => Jolt.PInvoke.AABox_GetVolume(this);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Geometry/AABox.h#L146">Jolt/Geometry/AABox.h:146</see>
|
||||
/// <br/>
|
||||
/// <c>bool Contains(const AABox &inOther) const</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <para>
|
||||
/// Check if this box contains another box
|
||||
/// </para>
|
||||
/// </remarks>
|
||||
public bool Contains(AABox other) => Jolt.PInvoke.AABox_Contains(this, other);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Geometry/AABox.h#L152">Jolt/Geometry/AABox.h:152</see>
|
||||
/// <br/>
|
||||
/// <c>bool Contains(Vec3Arg inOther) const</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <para>
|
||||
/// Check if this box contains a point
|
||||
/// </para>
|
||||
/// </remarks>
|
||||
public bool Contains(float3 other) => Jolt.PInvoke.AABox_Contains_2(this, other);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Geometry/AABox.h#L164">Jolt/Geometry/AABox.h:164</see>
|
||||
/// <br/>
|
||||
/// <c>bool Overlaps(const AABox &inOther) const</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <para>
|
||||
/// Check if this box overlaps with another box
|
||||
/// </para>
|
||||
/// </remarks>
|
||||
public bool Overlaps(AABox other) => Jolt.PInvoke.AABox_Overlaps(this, other);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Geometry/AABox.h#L170">Jolt/Geometry/AABox.h:170</see>
|
||||
/// <br/>
|
||||
/// <c>bool Overlaps(const Plane &inPlane) const</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <para>
|
||||
/// Check if this box overlaps with a plane
|
||||
/// </para>
|
||||
/// </remarks>
|
||||
public bool Overlaps(Plane plane) => Jolt.PInvoke.AABox_Overlaps_2(this, plane);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Geometry/AABox.h#L179">Jolt/Geometry/AABox.h:179</see>
|
||||
/// <br/>
|
||||
/// <c>void Translate(Vec3Arg inTranslation)</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <para>
|
||||
/// Translate bounding box
|
||||
/// </para>
|
||||
/// </remarks>
|
||||
public void Translate(float3 translation) => Jolt.PInvoke.AABox_Translate(this, translation);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Geometry/AABox.h#L230">Jolt/Geometry/AABox.h:230</see>
|
||||
/// <br/>
|
||||
/// <c>Vec3 GetSupport(Vec3Arg inDirection) const</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <para>
|
||||
/// Calculate the support vector for this convex shape.
|
||||
/// </para>
|
||||
/// </remarks>
|
||||
public float3 GetSupport(float3 direction) => Jolt.PInvoke.AABox_GetSupport(this, direction);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Geometry/AABox.h#L297">Jolt/Geometry/AABox.h:297</see>
|
||||
/// <br/>
|
||||
/// <c>Vec3 GetClosestPoint(Vec3Arg inPoint) const</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <para>
|
||||
/// Get the closest point on or in this box to inPoint
|
||||
/// </para>
|
||||
/// </remarks>
|
||||
public float3 GetClosestPoint(float3 point) => Jolt.PInvoke.AABox_GetClosestPoint(this, point);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Geometry/AABox.h#L303">Jolt/Geometry/AABox.h:303</see>
|
||||
/// <br/>
|
||||
/// <c>inline float GetSqDistanceTo(Vec3Arg inPoint) const</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <para>
|
||||
/// Get the squared distance between inPoint and this box (will be 0 if in Point is inside the box)
|
||||
/// </para>
|
||||
/// </remarks>
|
||||
public float GetSqDistanceTo(float3 point) => Jolt.PInvoke.AABox_GetSqDistanceTo(this, point);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Geometry/AABox.h#L309">Jolt/Geometry/AABox.h:309</see>
|
||||
/// <br/>
|
||||
/// <c>Vec3 mMin</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <para>
|
||||
/// Bounding box min and max
|
||||
/// </para>
|
||||
/// </remarks>
|
||||
public float3 GetMin() => Jolt.PInvoke.AABox_GetMin(this);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Geometry/AABox.h#L309">Jolt/Geometry/AABox.h:309</see>
|
||||
/// <br/>
|
||||
/// <c>Vec3 mMin</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <para>
|
||||
/// Bounding box min and max
|
||||
/// </para>
|
||||
/// </remarks>
|
||||
public void SetMin(float3 value) => Jolt.PInvoke.AABox_SetMin(this, value);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Geometry/AABox.h#L310">Jolt/Geometry/AABox.h:310</see>
|
||||
/// <br/>
|
||||
/// <c>Vec3 mMax</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
public float3 GetMax() => Jolt.PInvoke.AABox_GetMax(this);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Geometry/AABox.h#L310">Jolt/Geometry/AABox.h:310</see>
|
||||
/// <br/>
|
||||
/// <c>Vec3 mMax</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
public void SetMax(float3 value) => Jolt.PInvoke.AABox_SetMax(this, value);
|
||||
public void Dispose() => Jolt.PInvoke.AABox_Destroy(this);
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,224 @@
|
|||
// <auto-generated/>
|
||||
// Generated by Brutal.Jolt.Generate; do not edit by hand.
|
||||
#nullable enable
|
||||
|
||||
using Brutal.Interop;
|
||||
using Brutal.Numerics;
|
||||
namespace Brutal.JoltApi
|
||||
{
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Constraints/ConstraintPart/AngleConstraintPart.h#L36">Jolt/Physics/Constraints/ConstraintPart/AngleConstraintPart.h:36</see>
|
||||
/// <br/>
|
||||
/// <c>class AngleConstraintPart</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <code>
|
||||
/// Constraint that constrains rotation along 1 axis
|
||||
///
|
||||
/// Based on: "Constraints Derivation for Rigid Body Simulation in 3D" - Daniel Chappuis, see section 2.4.5
|
||||
///
|
||||
/// Constraint equation (eq 108):
|
||||
///
|
||||
/// \f[C = \theta(t) - \theta_{min}\f]
|
||||
///
|
||||
/// Jacobian (eq 109):
|
||||
///
|
||||
/// \f[J = \begin{bmatrix}0 &amp; -a^T &amp; 0 &amp; a^T\end{bmatrix}\f]
|
||||
///
|
||||
/// Used terms (here and below, everything in world space):\n
|
||||
/// a = axis around which rotation is constrained (normalized).\n
|
||||
/// x1, x2 = center of mass for the bodies.\n
|
||||
/// v = [v1, w1, v2, w2].\n
|
||||
/// v1, v2 = linear velocity of body 1 and 2.\n
|
||||
/// w1, w2 = angular velocity of body 1 and 2.\n
|
||||
/// M = mass matrix, a diagonal matrix of the mass and inertia with diagonal [m1, I1, m2, I2].\n
|
||||
/// \f$K^{-1} = \left( J M^{-1} J^T \right)^{-1}\f$ = effective mass.\n
|
||||
/// b = velocity bias.\n
|
||||
/// \f$\beta\f$ = baumgarte constant.
|
||||
/// </code>
|
||||
/// </remarks>
|
||||
[InteropHandle]
|
||||
public readonly partial struct AngleConstraintPart : IDisposable
|
||||
{
|
||||
public static AngleConstraintPart Create() => Jolt.PInvoke.AngleConstraintPart_Create();
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Constraints/ConstraintPart/AngleConstraintPart.h#L81">Jolt/Physics/Constraints/ConstraintPart/AngleConstraintPart.h:81</see>
|
||||
/// <br/>
|
||||
/// <c>inline void CalculateConstraintProperties(const Body &inBody1, const Body &inBody2, 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 inWorldSpaceAxis The axis of rotation along which the constraint acts (normalized)
|
||||
/// Set the following terms to zero if you don't want to drive the constraint to zero with a spring:
|
||||
/// @param inBias Bias term (b) for the constraint impulse: lambda = J v + b
|
||||
/// </code>
|
||||
/// </remarks>
|
||||
public void CalculateConstraintProperties(Body body1, Body body2, float3 worldSpaceAxis, float bias) => Jolt.PInvoke.AngleConstraintPart_CalculateConstraintProperties(this, body1, body2, worldSpaceAxis, bias);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Constraints/ConstraintPart/AngleConstraintPart.h#L104">Jolt/Physics/Constraints/ConstraintPart/AngleConstraintPart.h:104</see>
|
||||
/// <br/>
|
||||
/// <c>inline void CalculateConstraintPropertiesWithFrequencyAndDamping(float inDeltaTime, const Body &inBody1, const Body &inBody2, 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 inWorldSpaceAxis The axis of rotation along which the constraint acts (normalized)
|
||||
/// Set the following terms to zero if you don't want to drive the constraint to zero with a spring:
|
||||
/// @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>
|
||||
public void CalculateConstraintPropertiesWithFrequencyAndDamping(float deltaTime, Body body1, Body body2, float3 worldSpaceAxis, float bias, float c, float frequency, float damping) => Jolt.PInvoke.AngleConstraintPart_CalculateConstraintPropertiesWithFrequencyAndDamping(this, deltaTime, body1, body2, worldSpaceAxis, bias, c, frequency, damping);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Constraints/ConstraintPart/AngleConstraintPart.h#L124">Jolt/Physics/Constraints/ConstraintPart/AngleConstraintPart.h:124</see>
|
||||
/// <br/>
|
||||
/// <c>inline void CalculateConstraintPropertiesWithStiffnessAndDamping(float inDeltaTime, const Body &inBody1, const Body &inBody2, 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 inWorldSpaceAxis The axis of rotation along which the constraint acts (normalized)
|
||||
/// Set the following terms to zero if you don't want to drive the constraint to zero with a spring:
|
||||
/// @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>
|
||||
public void CalculateConstraintPropertiesWithStiffnessAndDamping(float deltaTime, Body body1, Body body2, float3 worldSpaceAxis, float bias, float c, float stiffness, float damping) => Jolt.PInvoke.AngleConstraintPart_CalculateConstraintPropertiesWithStiffnessAndDamping(this, deltaTime, body1, body2, worldSpaceAxis, bias, c, stiffness, damping);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Constraints/ConstraintPart/AngleConstraintPart.h#L135">Jolt/Physics/Constraints/ConstraintPart/AngleConstraintPart.h:135</see>
|
||||
/// <br/>
|
||||
/// <c>inline void CalculateConstraintPropertiesWithSettings(float inDeltaTime, const Body &inBody1, const Body &inBody2, 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>
|
||||
public void CalculateConstraintPropertiesWithSettings(float deltaTime, Body body1, Body body2, float3 worldSpaceAxis, float bias, float c, SpringSettings springSettings) => Jolt.PInvoke.AngleConstraintPart_CalculateConstraintPropertiesWithSettings(this, deltaTime, body1, body2, worldSpaceAxis, bias, c, springSettings);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Constraints/ConstraintPart/AngleConstraintPart.h#L148">Jolt/Physics/Constraints/ConstraintPart/AngleConstraintPart.h:148</see>
|
||||
/// <br/>
|
||||
/// <c>inline void Deactivate()</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <para>
|
||||
/// Deactivate this constraint
|
||||
/// </para>
|
||||
/// </remarks>
|
||||
public void Deactivate() => Jolt.PInvoke.AngleConstraintPart_Deactivate(this);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Constraints/ConstraintPart/AngleConstraintPart.h#L155">Jolt/Physics/Constraints/ConstraintPart/AngleConstraintPart.h:155</see>
|
||||
/// <br/>
|
||||
/// <c>inline bool IsActive() const</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <para>
|
||||
/// Check if constraint is active
|
||||
/// </para>
|
||||
/// </remarks>
|
||||
public bool IsActive() => Jolt.PInvoke.AngleConstraintPart_IsActive(this);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Constraints/ConstraintPart/AngleConstraintPart.h#L164">Jolt/Physics/Constraints/ConstraintPart/AngleConstraintPart.h:164</see>
|
||||
/// <br/>
|
||||
/// <c>inline void WarmStart(Body &ioBody1, Body &ioBody2, 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 inWarmStartImpulseRatio Ratio of new step to old time step (dt_new / dt_old) for scaling the lagrange multiplier of the previous frame
|
||||
/// </code>
|
||||
/// </remarks>
|
||||
public void WarmStart(Body body1, Body body2, float warmStartImpulseRatio) => Jolt.PInvoke.AngleConstraintPart_WarmStart(this, body1, body2, warmStartImpulseRatio);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Constraints/ConstraintPart/AngleConstraintPart.h#L176">Jolt/Physics/Constraints/ConstraintPart/AngleConstraintPart.h:176</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 The axis of rotation along which the constraint acts (normalized)
|
||||
/// @param inMinLambda Minimum angular impulse to apply (N m s)
|
||||
/// @param inMaxLambda Maximum angular impulse to apply (N m s)
|
||||
/// </code>
|
||||
/// </remarks>
|
||||
public bool SolveVelocityConstraint(Body body1, Body body2, float3 worldSpaceAxis, float minLambda, float maxLambda) => Jolt.PInvoke.AngleConstraintPart_SolveVelocityConstraint(this, body1, body2, worldSpaceAxis, minLambda, maxLambda);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Constraints/ConstraintPart/AngleConstraintPart.h#L190">Jolt/Physics/Constraints/ConstraintPart/AngleConstraintPart.h:190</see>
|
||||
/// <br/>
|
||||
/// <c>float GetTotalLambda() const</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <para>
|
||||
/// Return lagrange multiplier
|
||||
/// </para>
|
||||
/// </remarks>
|
||||
public float GetTotalLambda() => Jolt.PInvoke.AngleConstraintPart_GetTotalLambda(this);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Constraints/ConstraintPart/AngleConstraintPart.h#L200">Jolt/Physics/Constraints/ConstraintPart/AngleConstraintPart.h:200</see>
|
||||
/// <br/>
|
||||
/// <c>inline bool SolvePositionConstraint(Body &ioBody1, Body &ioBody2, 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 inC Value of the constraint equation (C)
|
||||
/// @param inBaumgarte Baumgarte constant (fraction of the error to correct)
|
||||
/// </code>
|
||||
/// </remarks>
|
||||
public bool SolvePositionConstraint(Body body1, Body body2, float c, float baumgarte) => Jolt.PInvoke.AngleConstraintPart_SolvePositionConstraint(this, body1, body2, c, baumgarte);
|
||||
public void Dispose() => Jolt.PInvoke.AngleConstraintPart_Destroy(this);
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,314 @@
|
|||
// <auto-generated/>
|
||||
// Generated by Brutal.Jolt.Generate; do not edit by hand.
|
||||
#nullable enable
|
||||
|
||||
using Brutal.Interop;
|
||||
using Brutal.Numerics;
|
||||
namespace Brutal.JoltApi
|
||||
{
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Constraints/ConstraintPart/AxisConstraintPart.h#L42">Jolt/Physics/Constraints/ConstraintPart/AxisConstraintPart.h:42</see>
|
||||
/// <br/>
|
||||
/// <c>class AxisConstraintPart</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <code>
|
||||
/// Constraint that constrains motion along 1 axis
|
||||
///
|
||||
/// @see "Constraints Derivation for Rigid Body Simulation in 3D" - Daniel Chappuis, section 2.1.1
|
||||
/// (we're not using the approximation of eq 27 but instead add the U term as in eq 55)
|
||||
///
|
||||
/// Constraint equation (eq 25):
|
||||
///
|
||||
/// \f[C = (p_2 - p_1) \cdot n\f]
|
||||
///
|
||||
/// Jacobian (eq 28):
|
||||
///
|
||||
/// \f[J = \begin{bmatrix} -n^T &amp; (-(r_1 + u) \times n)^T &amp; n^T &amp; (r_2 \times n)^T \end{bmatrix}\f]
|
||||
///
|
||||
/// Used terms (here and below, everything in world space):\n
|
||||
/// n = constraint axis (normalized).\n
|
||||
/// p1, p2 = constraint points.\n
|
||||
/// r1 = p1 - x1.\n
|
||||
/// r2 = p2 - x2.\n
|
||||
/// u = x2 + r2 - x1 - r1 = p2 - p1.\n
|
||||
/// x1, x2 = center of mass for the bodies.\n
|
||||
/// v = [v1, w1, v2, w2].\n
|
||||
/// v1, v2 = linear velocity of body 1 and 2.\n
|
||||
/// w1, w2 = angular velocity of body 1 and 2.\n
|
||||
/// M = mass matrix, a diagonal matrix of the mass and inertia with diagonal [m1, I1, m2, I2].\n
|
||||
/// \f$K^{-1} = \left( J M^{-1} J^T \right)^{-1}\f$ = effective mass.\n
|
||||
/// b = velocity bias.\n
|
||||
/// \f$\beta\f$ = baumgarte constant.
|
||||
/// </code>
|
||||
/// </remarks>
|
||||
[InteropHandle]
|
||||
public readonly partial struct AxisConstraintPart : IDisposable
|
||||
{
|
||||
public static AxisConstraintPart Create() => Jolt.PInvoke.AxisConstraintPart_Create();
|
||||
/// <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>
|
||||
public void CalculateConstraintProperties(Body body1, float3 r1PlusU, Body body2, float3 r2, float3 worldSpaceAxis, float bias) => Jolt.PInvoke.AxisConstraintPart_CalculateConstraintProperties(this, body1, r1PlusU, body2, r2, worldSpaceAxis, 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>
|
||||
public void CalculateConstraintPropertiesWithMassOverride(Body body1, float invMass1, float invInertiaScale1, float3 r1PlusU, Body body2, float invMass2, float invInertiaScale2, float3 r2, float3 worldSpaceAxis, float bias) => Jolt.PInvoke.AxisConstraintPart_CalculateConstraintPropertiesWithMassOverride(this, body1, invMass1, invInertiaScale1, r1PlusU, body2, invMass2, invInertiaScale2, r2, worldSpaceAxis, 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>
|
||||
public void CalculateConstraintPropertiesWithFrequencyAndDamping(float deltaTime, Body body1, float3 r1PlusU, Body body2, float3 r2, float3 worldSpaceAxis, float bias, float c, float frequency, float damping) => Jolt.PInvoke.AxisConstraintPart_CalculateConstraintPropertiesWithFrequencyAndDamping(this, deltaTime, body1, r1PlusU, body2, r2, worldSpaceAxis, bias, c, frequency, 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>
|
||||
public void CalculateConstraintPropertiesWithStiffnessAndDamping(float deltaTime, Body body1, float3 r1PlusU, Body body2, float3 r2, float3 worldSpaceAxis, float bias, float c, float stiffness, float damping) => Jolt.PInvoke.AxisConstraintPart_CalculateConstraintPropertiesWithStiffnessAndDamping(this, deltaTime, body1, r1PlusU, body2, r2, worldSpaceAxis, bias, c, stiffness, 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>
|
||||
public void CalculateConstraintPropertiesWithSettings(float deltaTime, Body body1, float3 r1PlusU, Body body2, float3 r2, float3 worldSpaceAxis, float bias, float c, SpringSettings springSettings) => Jolt.PInvoke.AxisConstraintPart_CalculateConstraintPropertiesWithSettings(this, deltaTime, body1, r1PlusU, body2, r2, worldSpaceAxis, bias, c, 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>
|
||||
public void Deactivate() => Jolt.PInvoke.AxisConstraintPart_Deactivate(this);
|
||||
/// <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>
|
||||
public bool IsActive() => Jolt.PInvoke.AxisConstraintPart_IsActive(this);
|
||||
/// <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>
|
||||
public void WarmStart(Body body1, Body body2, float3 worldSpaceAxis, float warmStartImpulseRatio) => Jolt.PInvoke.AxisConstraintPart_WarmStart(this, body1, body2, worldSpaceAxis, 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>
|
||||
public bool SolveVelocityConstraint(Body body1, Body body2, float3 worldSpaceAxis, float minLambda, float maxLambda) => Jolt.PInvoke.AxisConstraintPart_SolveVelocityConstraint(this, body1, body2, worldSpaceAxis, minLambda, 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>
|
||||
public bool SolveVelocityConstraintWithMassOverride(Body body1, float invMass1, Body body2, float invMass2, float3 worldSpaceAxis, float minLambda, float maxLambda) => Jolt.PInvoke.AxisConstraintPart_SolveVelocityConstraintWithMassOverride(this, body1, invMass1, body2, invMass2, worldSpaceAxis, minLambda, 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>
|
||||
public bool SolvePositionConstraint(Body body1, Body body2, float3 worldSpaceAxis, float c, float baumgarte) => Jolt.PInvoke.AxisConstraintPart_SolvePositionConstraint(this, body1, body2, worldSpaceAxis, c, 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>
|
||||
public bool SolvePositionConstraintWithMassOverride(Body body1, float invMass1, Body body2, float invMass2, float3 worldSpaceAxis, float c, float baumgarte) => Jolt.PInvoke.AxisConstraintPart_SolvePositionConstraintWithMassOverride(this, body1, invMass1, body2, invMass2, worldSpaceAxis, c, 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>
|
||||
public void SetTotalLambda(float lambda) => Jolt.PInvoke.AxisConstraintPart_SetTotalLambda(this, 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>
|
||||
public float GetTotalLambda() => Jolt.PInvoke.AxisConstraintPart_GetTotalLambda(this);
|
||||
public void Dispose() => Jolt.PInvoke.AxisConstraintPart_Destroy(this);
|
||||
}
|
||||
}
|
||||
1397
brutal.jolt/Brutal.Jolt/Generated/Classes/Body.gen.cs
Normal file
1397
brutal.jolt/Brutal.Jolt/Generated/Classes/Body.gen.cs
Normal file
File diff suppressed because it is too large
Load diff
|
|
@ -0,0 +1,57 @@
|
|||
// <auto-generated/>
|
||||
// Generated by Brutal.Jolt.Generate; do not edit by hand.
|
||||
#nullable enable
|
||||
|
||||
using Brutal.Interop;
|
||||
using Brutal.Numerics;
|
||||
namespace Brutal.JoltApi
|
||||
{
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyActivationListener.h#L13">Jolt/Physics/Body/BodyActivationListener.h:13</see>
|
||||
/// <br/>
|
||||
/// <c>class BodyActivationListener</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <code>
|
||||
/// A listener class that receives events when a body activates or deactivates.
|
||||
/// It can be registered with the BodyManager (or PhysicsSystem).
|
||||
/// </code>
|
||||
/// </remarks>
|
||||
[InteropHandle]
|
||||
public readonly partial struct BodyActivationListener
|
||||
{
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyActivationListener.h#L21">Jolt/Physics/Body/BodyActivationListener.h:21</see>
|
||||
/// <br/>
|
||||
/// <c>virtual void OnBodyActivated(const BodyID &inBodyID, uint64 inBodyUserData) = 0</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <code>
|
||||
/// Called whenever a body activates, note this can be called from any thread so make sure your code is thread safe.
|
||||
/// At the time of the callback the body inBodyID will be locked and no bodies can be written/activated/deactivated from the callback.
|
||||
/// </code>
|
||||
/// </remarks>
|
||||
public void OnBodyActivated(uint bodyID, ulong bodyUserData) => Jolt.PInvoke.BodyActivationListener_OnBodyActivated(this, bodyID, bodyUserData);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyActivationListener.h#L25">Jolt/Physics/Body/BodyActivationListener.h:25</see>
|
||||
/// <br/>
|
||||
/// <c>virtual void OnBodyDeactivated(const BodyID &inBodyID, uint64 inBodyUserData) = 0</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <code>
|
||||
/// Called whenever a body deactivates, note this can be called from any thread so make sure your code is thread safe.
|
||||
/// At the time of the callback the body inBodyID will be locked and no bodies can be written/activated/deactivated from the callback.
|
||||
/// </code>
|
||||
/// </remarks>
|
||||
public void OnBodyDeactivated(uint bodyID, ulong bodyUserData) => Jolt.PInvoke.BodyActivationListener_OnBodyDeactivated(this, bodyID, bodyUserData);
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,884 @@
|
|||
// <auto-generated/>
|
||||
// Generated by Brutal.Jolt.Generate; do not edit by hand.
|
||||
#nullable enable
|
||||
|
||||
using Brutal.Interop;
|
||||
using Brutal.Numerics;
|
||||
namespace Brutal.JoltApi
|
||||
{
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyCreationSettings.h#L30">Jolt/Physics/Body/BodyCreationSettings.h:30</see>
|
||||
/// <br/>
|
||||
/// <c>class BodyCreationSettings</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <para>
|
||||
/// Settings for constructing a rigid body
|
||||
/// </para>
|
||||
/// </remarks>
|
||||
[InteropHandle]
|
||||
public readonly partial struct BodyCreationSettings : IDisposable
|
||||
{
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyCreationSettings.h#L36">Jolt/Physics/Body/BodyCreationSettings.h:36</see>
|
||||
/// <br/>
|
||||
/// <c>BodyCreationSettings() = default</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <para>
|
||||
/// Constructor
|
||||
/// </para>
|
||||
/// </remarks>
|
||||
public static BodyCreationSettings Create() => Jolt.PInvoke.BodyCreationSettings_Create();
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyCreationSettings.h#L37">Jolt/Physics/Body/BodyCreationSettings.h:37</see>
|
||||
/// <br/>
|
||||
/// <c>BodyCreationSettings(const ShapeSettings *inShape, RVec3Arg inPosition, QuatArg inRotation, EMotionType inMotionType, ObjectLayer inObjectLayer)</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
public static BodyCreationSettings Create(ShapeSettings shape, float3 position, floatQuat rotation, EMotionType motionType, ushort objectLayer) => Jolt.PInvoke.BodyCreationSettings_Create_2(shape, position, rotation, motionType, objectLayer);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyCreationSettings.h#L38">Jolt/Physics/Body/BodyCreationSettings.h:38</see>
|
||||
/// <br/>
|
||||
/// <c>BodyCreationSettings(const Shape *inShape, RVec3Arg inPosition, QuatArg inRotation, EMotionType inMotionType, ObjectLayer inObjectLayer)</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
public static BodyCreationSettings Create(Shape shape, float3 position, floatQuat rotation, EMotionType motionType, ushort objectLayer) => Jolt.PInvoke.BodyCreationSettings_Create_3(shape, position, rotation, motionType, objectLayer);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyCreationSettings.h#L41">Jolt/Physics/Body/BodyCreationSettings.h:41</see>
|
||||
/// <br/>
|
||||
/// <c>const ShapeSettings * GetShapeSettings() const</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <para>
|
||||
/// Access to the shape settings object. This contains serializable (non-runtime optimized) information
|
||||
/// about the Shape.
|
||||
/// </para>
|
||||
/// </remarks>
|
||||
public ShapeSettings GetShapeSettings() => Jolt.PInvoke.BodyCreationSettings_GetShapeSettings(this);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyCreationSettings.h#L42">Jolt/Physics/Body/BodyCreationSettings.h:42</see>
|
||||
/// <br/>
|
||||
/// <c>void SetShapeSettings(const ShapeSettings *inShape)</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
public void SetShapeSettings(ShapeSettings shape) => Jolt.PInvoke.BodyCreationSettings_SetShapeSettings(this, shape);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyCreationSettings.h#L45">Jolt/Physics/Body/BodyCreationSettings.h:45</see>
|
||||
/// <br/>
|
||||
/// <c>Shape::ShapeResult ConvertShapeSettings()</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <para>
|
||||
/// Convert ShapeSettings object into a Shape object. This will free the ShapeSettings object and make the
|
||||
/// object ready for runtime. Serialization is no longer possible after this.
|
||||
/// </para>
|
||||
/// <para>
|
||||
/// Throws InvalidOperationException with Jolt's error message when the operation fails.
|
||||
/// </para>
|
||||
/// </remarks>
|
||||
public Shape ConvertShapeSettings()
|
||||
{
|
||||
var _handle = Jolt.PInvoke.BodyCreationSettings_ConvertShapeSettings(this);
|
||||
if (_handle.IsNull()) throw new InvalidOperationException(Jolt.GetLastError());
|
||||
return _handle;
|
||||
}
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyCreationSettings.h#L48">Jolt/Physics/Body/BodyCreationSettings.h:48</see>
|
||||
/// <br/>
|
||||
/// <c>const Shape * GetShape() const</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <para>
|
||||
/// Access to the run-time shape object. Will convert from ShapeSettings object if needed.
|
||||
/// </para>
|
||||
/// </remarks>
|
||||
public Shape GetShape() => Jolt.PInvoke.BodyCreationSettings_GetShape(this);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyCreationSettings.h#L49">Jolt/Physics/Body/BodyCreationSettings.h:49</see>
|
||||
/// <br/>
|
||||
/// <c>void SetShape(const Shape *inShape)</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
public void SetShape(Shape shape) => Jolt.PInvoke.BodyCreationSettings_SetShape(this, shape);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyCreationSettings.h#L52">Jolt/Physics/Body/BodyCreationSettings.h:52</see>
|
||||
/// <br/>
|
||||
/// <c>bool HasMassProperties() const</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <para>
|
||||
/// Check if the mass properties of this body will be calculated (only relevant for kinematic or dynamic
|
||||
/// objects that need a MotionProperties object)
|
||||
/// </para>
|
||||
/// </remarks>
|
||||
public bool HasMassProperties() => Jolt.PInvoke.BodyCreationSettings_HasMassProperties(this);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyCreationSettings.h#L58">Jolt/Physics/Body/BodyCreationSettings.h:58</see>
|
||||
/// <br/>
|
||||
/// <c>void SaveBinaryState(StreamOut &inStream) const</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <para>
|
||||
/// Saves the state of this object in binary form to inStream. Doesn't store the shape nor the group filter.
|
||||
/// </para>
|
||||
/// </remarks>
|
||||
public void SaveBinaryState(StreamOut stream) => Jolt.PInvoke.BodyCreationSettings_SaveBinaryState(this, stream);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyCreationSettings.h#L61">Jolt/Physics/Body/BodyCreationSettings.h:61</see>
|
||||
/// <br/>
|
||||
/// <c>void RestoreBinaryState(StreamIn &inStream)</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <para>
|
||||
/// Restore the state of this object from inStream. Doesn't restore the shape nor the group filter.
|
||||
/// </para>
|
||||
/// </remarks>
|
||||
public void RestoreBinaryState(StreamIn stream) => Jolt.PInvoke.BodyCreationSettings_RestoreBinaryState(this, stream);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// Position of the body (not of the center of mass)
|
||||
/// </para>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyCreationSettings.h#L80">Jolt/Physics/Body/BodyCreationSettings.h:80</see>
|
||||
/// <br/>
|
||||
/// <c>RVec3 mPosition = RVec3::sZero()</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
public float3 GetPosition() => Jolt.PInvoke.BodyCreationSettings_GetPosition(this);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// Position of the body (not of the center of mass)
|
||||
/// </para>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyCreationSettings.h#L80">Jolt/Physics/Body/BodyCreationSettings.h:80</see>
|
||||
/// <br/>
|
||||
/// <c>RVec3 mPosition = RVec3::sZero()</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
public void SetPosition(float3 value) => Jolt.PInvoke.BodyCreationSettings_SetPosition(this, value);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// Rotation of the body
|
||||
/// </para>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyCreationSettings.h#L81">Jolt/Physics/Body/BodyCreationSettings.h:81</see>
|
||||
/// <br/>
|
||||
/// <c>Quat mRotation = Quat::sIdentity()</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
public floatQuat GetRotation() => Jolt.PInvoke.BodyCreationSettings_GetRotation(this);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// Rotation of the body
|
||||
/// </para>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyCreationSettings.h#L81">Jolt/Physics/Body/BodyCreationSettings.h:81</see>
|
||||
/// <br/>
|
||||
/// <c>Quat mRotation = Quat::sIdentity()</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
public void SetRotation(floatQuat value) => Jolt.PInvoke.BodyCreationSettings_SetRotation(this, value);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// World space linear velocity of the center of mass (m/s)
|
||||
/// </para>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyCreationSettings.h#L82">Jolt/Physics/Body/BodyCreationSettings.h:82</see>
|
||||
/// <br/>
|
||||
/// <c>Vec3 mLinearVelocity = Vec3::sZero()</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
public float3 GetLinearVelocity() => Jolt.PInvoke.BodyCreationSettings_GetLinearVelocity(this);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// World space linear velocity of the center of mass (m/s)
|
||||
/// </para>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyCreationSettings.h#L82">Jolt/Physics/Body/BodyCreationSettings.h:82</see>
|
||||
/// <br/>
|
||||
/// <c>Vec3 mLinearVelocity = Vec3::sZero()</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
public void SetLinearVelocity(float3 value) => Jolt.PInvoke.BodyCreationSettings_SetLinearVelocity(this, value);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// World space angular velocity (rad/s)
|
||||
/// </para>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyCreationSettings.h#L83">Jolt/Physics/Body/BodyCreationSettings.h:83</see>
|
||||
/// <br/>
|
||||
/// <c>Vec3 mAngularVelocity = Vec3::sZero()</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
public float3 GetAngularVelocity() => Jolt.PInvoke.BodyCreationSettings_GetAngularVelocity(this);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// World space angular velocity (rad/s)
|
||||
/// </para>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyCreationSettings.h#L83">Jolt/Physics/Body/BodyCreationSettings.h:83</see>
|
||||
/// <br/>
|
||||
/// <c>Vec3 mAngularVelocity = Vec3::sZero()</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
public void SetAngularVelocity(float3 value) => Jolt.PInvoke.BodyCreationSettings_SetAngularVelocity(this, value);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyCreationSettings.h#L86">Jolt/Physics/Body/BodyCreationSettings.h:86</see>
|
||||
/// <br/>
|
||||
/// <c>uint64 mUserData = 0</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <para>
|
||||
/// User data value (can be used by application)
|
||||
/// </para>
|
||||
/// </remarks>
|
||||
public ulong GetUserData() => Jolt.PInvoke.BodyCreationSettings_GetUserData(this);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyCreationSettings.h#L86">Jolt/Physics/Body/BodyCreationSettings.h:86</see>
|
||||
/// <br/>
|
||||
/// <c>uint64 mUserData = 0</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <para>
|
||||
/// User data value (can be used by application)
|
||||
/// </para>
|
||||
/// </remarks>
|
||||
public void SetUserData(ulong value) => Jolt.PInvoke.BodyCreationSettings_SetUserData(this, value);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// The collision layer this body belongs to (determines if two objects can collide)
|
||||
/// </para>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyCreationSettings.h#L89">Jolt/Physics/Body/BodyCreationSettings.h:89</see>
|
||||
/// <br/>
|
||||
/// <c>ObjectLayer mObjectLayer = 0</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <para>
|
||||
/// @name Collision settings
|
||||
/// </para>
|
||||
/// </remarks>
|
||||
public ushort GetObjectLayer() => Jolt.PInvoke.BodyCreationSettings_GetObjectLayer(this);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// The collision layer this body belongs to (determines if two objects can collide)
|
||||
/// </para>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyCreationSettings.h#L89">Jolt/Physics/Body/BodyCreationSettings.h:89</see>
|
||||
/// <br/>
|
||||
/// <c>ObjectLayer mObjectLayer = 0</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <para>
|
||||
/// @name Collision settings
|
||||
/// </para>
|
||||
/// </remarks>
|
||||
public void SetObjectLayer(ushort value) => Jolt.PInvoke.BodyCreationSettings_SetObjectLayer(this, value);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// Motion type, determines if the object is static, dynamic or kinematic
|
||||
/// </para>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyCreationSettings.h#L93">Jolt/Physics/Body/BodyCreationSettings.h:93</see>
|
||||
/// <br/>
|
||||
/// <c>EMotionType mMotionType = EMotionType::Dynamic</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <para>
|
||||
/// @name Simulation properties
|
||||
/// </para>
|
||||
/// </remarks>
|
||||
public EMotionType GetMotionType() => Jolt.PInvoke.BodyCreationSettings_GetMotionType(this);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// Motion type, determines if the object is static, dynamic or kinematic
|
||||
/// </para>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyCreationSettings.h#L93">Jolt/Physics/Body/BodyCreationSettings.h:93</see>
|
||||
/// <br/>
|
||||
/// <c>EMotionType mMotionType = EMotionType::Dynamic</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <para>
|
||||
/// @name Simulation properties
|
||||
/// </para>
|
||||
/// </remarks>
|
||||
public void SetMotionType(EMotionType value) => Jolt.PInvoke.BodyCreationSettings_SetMotionType(this, value);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// Which degrees of freedom this body has (can be used to limit simulation to 2D)
|
||||
/// </para>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyCreationSettings.h#L94">Jolt/Physics/Body/BodyCreationSettings.h:94</see>
|
||||
/// <br/>
|
||||
/// <c>EAllowedDOFs mAllowedDOFs = EAllowedDOFs::All</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
public EAllowedDOFs GetAllowedDOFs() => Jolt.PInvoke.BodyCreationSettings_GetAllowedDOFs(this);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// Which degrees of freedom this body has (can be used to limit simulation to 2D)
|
||||
/// </para>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyCreationSettings.h#L94">Jolt/Physics/Body/BodyCreationSettings.h:94</see>
|
||||
/// <br/>
|
||||
/// <c>EAllowedDOFs mAllowedDOFs = EAllowedDOFs::All</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
public void SetAllowedDOFs(EAllowedDOFs value) => Jolt.PInvoke.BodyCreationSettings_SetAllowedDOFs(this, value);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// When this body is created as static, this setting tells the system to create a MotionProperties object
|
||||
/// so that the object can be switched to kinematic or dynamic
|
||||
/// </para>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyCreationSettings.h#L95">Jolt/Physics/Body/BodyCreationSettings.h:95</see>
|
||||
/// <br/>
|
||||
/// <c>bool mAllowDynamicOrKinematic = false</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
public bool GetAllowDynamicOrKinematic() => Jolt.PInvoke.BodyCreationSettings_GetAllowDynamicOrKinematic(this);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// When this body is created as static, this setting tells the system to create a MotionProperties object
|
||||
/// so that the object can be switched to kinematic or dynamic
|
||||
/// </para>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyCreationSettings.h#L95">Jolt/Physics/Body/BodyCreationSettings.h:95</see>
|
||||
/// <br/>
|
||||
/// <c>bool mAllowDynamicOrKinematic = false</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
public void SetAllowDynamicOrKinematic(bool value) => Jolt.PInvoke.BodyCreationSettings_SetAllowDynamicOrKinematic(this, value);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// If this body is a sensor. A sensor will receive collision callbacks, but will not cause any collision
|
||||
/// responses and can be used as a trigger volume. See description at Body::SetIsSensor.
|
||||
/// </para>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyCreationSettings.h#L96">Jolt/Physics/Body/BodyCreationSettings.h:96</see>
|
||||
/// <br/>
|
||||
/// <c>bool mIsSensor = false</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
public bool GetIsSensor() => Jolt.PInvoke.BodyCreationSettings_GetIsSensor(this);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// If this body is a sensor. A sensor will receive collision callbacks, but will not cause any collision
|
||||
/// responses and can be used as a trigger volume. See description at Body::SetIsSensor.
|
||||
/// </para>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyCreationSettings.h#L96">Jolt/Physics/Body/BodyCreationSettings.h:96</see>
|
||||
/// <br/>
|
||||
/// <c>bool mIsSensor = false</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
public void SetIsSensor(bool value) => Jolt.PInvoke.BodyCreationSettings_SetIsSensor(this, value);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// If kinematic objects can generate contact points against other kinematic or static objects. See
|
||||
/// description at Body::SetCollideKinematicVsNonDynamic.
|
||||
/// </para>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyCreationSettings.h#L97">Jolt/Physics/Body/BodyCreationSettings.h:97</see>
|
||||
/// <br/>
|
||||
/// <c>bool mCollideKinematicVsNonDynamic = false</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
public bool GetCollideKinematicVsNonDynamic() => Jolt.PInvoke.BodyCreationSettings_GetCollideKinematicVsNonDynamic(this);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// If kinematic objects can generate contact points against other kinematic or static objects. See
|
||||
/// description at Body::SetCollideKinematicVsNonDynamic.
|
||||
/// </para>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyCreationSettings.h#L97">Jolt/Physics/Body/BodyCreationSettings.h:97</see>
|
||||
/// <br/>
|
||||
/// <c>bool mCollideKinematicVsNonDynamic = false</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
public void SetCollideKinematicVsNonDynamic(bool value) => Jolt.PInvoke.BodyCreationSettings_SetCollideKinematicVsNonDynamic(this, value);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// If this body should use manifold reduction (see description at Body::SetUseManifoldReduction)
|
||||
/// </para>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyCreationSettings.h#L98">Jolt/Physics/Body/BodyCreationSettings.h:98</see>
|
||||
/// <br/>
|
||||
/// <c>bool mUseManifoldReduction = true</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
public bool GetUseManifoldReduction() => Jolt.PInvoke.BodyCreationSettings_GetUseManifoldReduction(this);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// If this body should use manifold reduction (see description at Body::SetUseManifoldReduction)
|
||||
/// </para>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyCreationSettings.h#L98">Jolt/Physics/Body/BodyCreationSettings.h:98</see>
|
||||
/// <br/>
|
||||
/// <c>bool mUseManifoldReduction = true</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
public void SetUseManifoldReduction(bool value) => Jolt.PInvoke.BodyCreationSettings_SetUseManifoldReduction(this, value);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// Set to indicate that the gyroscopic force should be applied to this body (aka Dzhanibekov effect, see
|
||||
/// https://en.wikipedia.org/wiki/Tennis_racket_theorem)
|
||||
/// </para>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyCreationSettings.h#L99">Jolt/Physics/Body/BodyCreationSettings.h:99</see>
|
||||
/// <br/>
|
||||
/// <c>bool mApplyGyroscopicForce = false</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
public bool GetApplyGyroscopicForce() => Jolt.PInvoke.BodyCreationSettings_GetApplyGyroscopicForce(this);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// Set to indicate that the gyroscopic force should be applied to this body (aka Dzhanibekov effect, see
|
||||
/// https://en.wikipedia.org/wiki/Tennis_racket_theorem)
|
||||
/// </para>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyCreationSettings.h#L99">Jolt/Physics/Body/BodyCreationSettings.h:99</see>
|
||||
/// <br/>
|
||||
/// <c>bool mApplyGyroscopicForce = false</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
public void SetApplyGyroscopicForce(bool value) => Jolt.PInvoke.BodyCreationSettings_SetApplyGyroscopicForce(this, value);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// Motion quality, or how well it detects collisions when it has a high velocity
|
||||
/// </para>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyCreationSettings.h#L100">Jolt/Physics/Body/BodyCreationSettings.h:100</see>
|
||||
/// <br/>
|
||||
/// <c>EMotionQuality mMotionQuality = EMotionQuality::Discrete</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
public EMotionQuality GetMotionQuality() => Jolt.PInvoke.BodyCreationSettings_GetMotionQuality(this);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// Motion quality, or how well it detects collisions when it has a high velocity
|
||||
/// </para>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyCreationSettings.h#L100">Jolt/Physics/Body/BodyCreationSettings.h:100</see>
|
||||
/// <br/>
|
||||
/// <c>EMotionQuality mMotionQuality = EMotionQuality::Discrete</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
public void SetMotionQuality(EMotionQuality value) => Jolt.PInvoke.BodyCreationSettings_SetMotionQuality(this, value);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// Set to indicate that extra effort should be made to try to remove ghost contacts (collisions with
|
||||
/// internal edges of a mesh). This is more expensive but makes bodies move smoother over a mesh with convex
|
||||
/// edges.
|
||||
/// </para>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyCreationSettings.h#L101">Jolt/Physics/Body/BodyCreationSettings.h:101</see>
|
||||
/// <br/>
|
||||
/// <c>bool mEnhancedInternalEdgeRemoval = false</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
public bool GetEnhancedInternalEdgeRemoval() => Jolt.PInvoke.BodyCreationSettings_GetEnhancedInternalEdgeRemoval(this);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// Set to indicate that extra effort should be made to try to remove ghost contacts (collisions with
|
||||
/// internal edges of a mesh). This is more expensive but makes bodies move smoother over a mesh with convex
|
||||
/// edges.
|
||||
/// </para>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyCreationSettings.h#L101">Jolt/Physics/Body/BodyCreationSettings.h:101</see>
|
||||
/// <br/>
|
||||
/// <c>bool mEnhancedInternalEdgeRemoval = false</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
public void SetEnhancedInternalEdgeRemoval(bool value) => Jolt.PInvoke.BodyCreationSettings_SetEnhancedInternalEdgeRemoval(this, value);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// If this body can go to sleep or not
|
||||
/// </para>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyCreationSettings.h#L102">Jolt/Physics/Body/BodyCreationSettings.h:102</see>
|
||||
/// <br/>
|
||||
/// <c>bool mAllowSleeping = true</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
public bool GetAllowSleeping() => Jolt.PInvoke.BodyCreationSettings_GetAllowSleeping(this);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// If this body can go to sleep or not
|
||||
/// </para>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyCreationSettings.h#L102">Jolt/Physics/Body/BodyCreationSettings.h:102</see>
|
||||
/// <br/>
|
||||
/// <c>bool mAllowSleeping = true</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
public void SetAllowSleeping(bool value) => Jolt.PInvoke.BodyCreationSettings_SetAllowSleeping(this, value);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// Friction of the body (dimensionless number, usually between 0 and 1, 0 = no friction, 1 = friction force
|
||||
/// equals force that presses the two bodies together). Note that bodies can have negative friction but the
|
||||
/// combined friction (see PhysicsSystem::SetCombineFriction) should never go below zero.
|
||||
/// </para>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyCreationSettings.h#L103">Jolt/Physics/Body/BodyCreationSettings.h:103</see>
|
||||
/// <br/>
|
||||
/// <c>float mFriction = 0.2f</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
public float GetFriction() => Jolt.PInvoke.BodyCreationSettings_GetFriction(this);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// Friction of the body (dimensionless number, usually between 0 and 1, 0 = no friction, 1 = friction force
|
||||
/// equals force that presses the two bodies together). Note that bodies can have negative friction but the
|
||||
/// combined friction (see PhysicsSystem::SetCombineFriction) should never go below zero.
|
||||
/// </para>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyCreationSettings.h#L103">Jolt/Physics/Body/BodyCreationSettings.h:103</see>
|
||||
/// <br/>
|
||||
/// <c>float mFriction = 0.2f</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
public void SetFriction(float value) => Jolt.PInvoke.BodyCreationSettings_SetFriction(this, value);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// Restitution of body (dimensionless number, usually between 0 and 1, 0 = completely inelastic collision
|
||||
/// response, 1 = completely elastic collision response). Note that bodies can have negative restitution but
|
||||
/// the combined restitution (see PhysicsSystem::SetCombineRestitution) should never go below zero.
|
||||
/// </para>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyCreationSettings.h#L104">Jolt/Physics/Body/BodyCreationSettings.h:104</see>
|
||||
/// <br/>
|
||||
/// <c>float mRestitution = 0.0f</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
public float GetRestitution() => Jolt.PInvoke.BodyCreationSettings_GetRestitution(this);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// Restitution of body (dimensionless number, usually between 0 and 1, 0 = completely inelastic collision
|
||||
/// response, 1 = completely elastic collision response). Note that bodies can have negative restitution but
|
||||
/// the combined restitution (see PhysicsSystem::SetCombineRestitution) should never go below zero.
|
||||
/// </para>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyCreationSettings.h#L104">Jolt/Physics/Body/BodyCreationSettings.h:104</see>
|
||||
/// <br/>
|
||||
/// <c>float mRestitution = 0.0f</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
public void SetRestitution(float value) => Jolt.PInvoke.BodyCreationSettings_SetRestitution(this, value);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// Linear damping: dv/dt = -c * v. c. Value should be zero or positive and is usually close to 0.
|
||||
/// </para>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyCreationSettings.h#L105">Jolt/Physics/Body/BodyCreationSettings.h:105</see>
|
||||
/// <br/>
|
||||
/// <c>float mLinearDamping = 0.05f</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
public float GetLinearDamping() => Jolt.PInvoke.BodyCreationSettings_GetLinearDamping(this);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// Linear damping: dv/dt = -c * v. c. Value should be zero or positive and is usually close to 0.
|
||||
/// </para>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyCreationSettings.h#L105">Jolt/Physics/Body/BodyCreationSettings.h:105</see>
|
||||
/// <br/>
|
||||
/// <c>float mLinearDamping = 0.05f</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
public void SetLinearDamping(float value) => Jolt.PInvoke.BodyCreationSettings_SetLinearDamping(this, value);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// Angular damping: dw/dt = -c * w. c. Value should be zero or positive and is usually close to 0.
|
||||
/// </para>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyCreationSettings.h#L106">Jolt/Physics/Body/BodyCreationSettings.h:106</see>
|
||||
/// <br/>
|
||||
/// <c>float mAngularDamping = 0.05f</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
public float GetAngularDamping() => Jolt.PInvoke.BodyCreationSettings_GetAngularDamping(this);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// Angular damping: dw/dt = -c * w. c. Value should be zero or positive and is usually close to 0.
|
||||
/// </para>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyCreationSettings.h#L106">Jolt/Physics/Body/BodyCreationSettings.h:106</see>
|
||||
/// <br/>
|
||||
/// <c>float mAngularDamping = 0.05f</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
public void SetAngularDamping(float value) => Jolt.PInvoke.BodyCreationSettings_SetAngularDamping(this, value);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// Maximum linear velocity that this body can reach (m/s)
|
||||
/// </para>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyCreationSettings.h#L107">Jolt/Physics/Body/BodyCreationSettings.h:107</see>
|
||||
/// <br/>
|
||||
/// <c>float mMaxLinearVelocity = 500.0f</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
public float GetMaxLinearVelocity() => Jolt.PInvoke.BodyCreationSettings_GetMaxLinearVelocity(this);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// Maximum linear velocity that this body can reach (m/s)
|
||||
/// </para>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyCreationSettings.h#L107">Jolt/Physics/Body/BodyCreationSettings.h:107</see>
|
||||
/// <br/>
|
||||
/// <c>float mMaxLinearVelocity = 500.0f</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
public void SetMaxLinearVelocity(float value) => Jolt.PInvoke.BodyCreationSettings_SetMaxLinearVelocity(this, value);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// Maximum angular velocity that this body can reach (rad/s)
|
||||
/// </para>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyCreationSettings.h#L108">Jolt/Physics/Body/BodyCreationSettings.h:108</see>
|
||||
/// <br/>
|
||||
/// <c>float mMaxAngularVelocity = 0.25f * JPH_PI * 60.0f</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
public float GetMaxAngularVelocity() => Jolt.PInvoke.BodyCreationSettings_GetMaxAngularVelocity(this);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// Maximum angular velocity that this body can reach (rad/s)
|
||||
/// </para>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyCreationSettings.h#L108">Jolt/Physics/Body/BodyCreationSettings.h:108</see>
|
||||
/// <br/>
|
||||
/// <c>float mMaxAngularVelocity = 0.25f * JPH_PI * 60.0f</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
public void SetMaxAngularVelocity(float value) => Jolt.PInvoke.BodyCreationSettings_SetMaxAngularVelocity(this, value);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// Value to multiply gravity with for this body
|
||||
/// </para>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyCreationSettings.h#L109">Jolt/Physics/Body/BodyCreationSettings.h:109</see>
|
||||
/// <br/>
|
||||
/// <c>float mGravityFactor = 1.0f</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
public float GetGravityFactor() => Jolt.PInvoke.BodyCreationSettings_GetGravityFactor(this);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// Value to multiply gravity with for this body
|
||||
/// </para>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyCreationSettings.h#L109">Jolt/Physics/Body/BodyCreationSettings.h:109</see>
|
||||
/// <br/>
|
||||
/// <c>float mGravityFactor = 1.0f</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
public void SetGravityFactor(float value) => Jolt.PInvoke.BodyCreationSettings_SetGravityFactor(this, value);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// Used only when this body is dynamic and colliding. Override for the number of solver velocity iterations
|
||||
/// to run, 0 means use the default in PhysicsSettings::mNumVelocitySteps. The number of iterations to use
|
||||
/// is the max of all contacts and constraints in the island.
|
||||
/// </para>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyCreationSettings.h#L110">Jolt/Physics/Body/BodyCreationSettings.h:110</see>
|
||||
/// <br/>
|
||||
/// <c>uint mNumVelocityStepsOverride = 0</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
public uint GetNumVelocityStepsOverride() => Jolt.PInvoke.BodyCreationSettings_GetNumVelocityStepsOverride(this);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// Used only when this body is dynamic and colliding. Override for the number of solver velocity iterations
|
||||
/// to run, 0 means use the default in PhysicsSettings::mNumVelocitySteps. The number of iterations to use
|
||||
/// is the max of all contacts and constraints in the island.
|
||||
/// </para>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyCreationSettings.h#L110">Jolt/Physics/Body/BodyCreationSettings.h:110</see>
|
||||
/// <br/>
|
||||
/// <c>uint mNumVelocityStepsOverride = 0</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
public void SetNumVelocityStepsOverride(uint value) => Jolt.PInvoke.BodyCreationSettings_SetNumVelocityStepsOverride(this, value);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// Used only when this body is dynamic and colliding. Override for the number of solver position iterations
|
||||
/// to run, 0 means use the default in PhysicsSettings::mNumPositionSteps. The number of iterations to use
|
||||
/// is the max of all contacts and constraints in the island.
|
||||
/// </para>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyCreationSettings.h#L111">Jolt/Physics/Body/BodyCreationSettings.h:111</see>
|
||||
/// <br/>
|
||||
/// <c>uint mNumPositionStepsOverride = 0</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
public uint GetNumPositionStepsOverride() => Jolt.PInvoke.BodyCreationSettings_GetNumPositionStepsOverride(this);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// Used only when this body is dynamic and colliding. Override for the number of solver position iterations
|
||||
/// to run, 0 means use the default in PhysicsSettings::mNumPositionSteps. The number of iterations to use
|
||||
/// is the max of all contacts and constraints in the island.
|
||||
/// </para>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyCreationSettings.h#L111">Jolt/Physics/Body/BodyCreationSettings.h:111</see>
|
||||
/// <br/>
|
||||
/// <c>uint mNumPositionStepsOverride = 0</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
public void SetNumPositionStepsOverride(uint value) => Jolt.PInvoke.BodyCreationSettings_SetNumPositionStepsOverride(this, value);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// Determines how mMassPropertiesOverride will be used
|
||||
/// </para>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyCreationSettings.h#L114">Jolt/Physics/Body/BodyCreationSettings.h:114</see>
|
||||
/// <br/>
|
||||
/// <c>EOverrideMassProperties mOverrideMassProperties = EOverrideMassProperties::CalculateMassAndInertia</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <para>
|
||||
/// @name Mass properties of the body (by default calculated by the shape)
|
||||
/// </para>
|
||||
/// </remarks>
|
||||
public EOverrideMassProperties GetOverrideMassProperties() => Jolt.PInvoke.BodyCreationSettings_GetOverrideMassProperties(this);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// Determines how mMassPropertiesOverride will be used
|
||||
/// </para>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyCreationSettings.h#L114">Jolt/Physics/Body/BodyCreationSettings.h:114</see>
|
||||
/// <br/>
|
||||
/// <c>EOverrideMassProperties mOverrideMassProperties = EOverrideMassProperties::CalculateMassAndInertia</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <para>
|
||||
/// @name Mass properties of the body (by default calculated by the shape)
|
||||
/// </para>
|
||||
/// </remarks>
|
||||
public void SetOverrideMassProperties(EOverrideMassProperties value) => Jolt.PInvoke.BodyCreationSettings_SetOverrideMassProperties(this, value);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// When calculating the inertia (not when it is provided) the calculated inertia will be multiplied by this
|
||||
/// value
|
||||
/// </para>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyCreationSettings.h#L115">Jolt/Physics/Body/BodyCreationSettings.h:115</see>
|
||||
/// <br/>
|
||||
/// <c>float mInertiaMultiplier = 1.0f</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
public float GetInertiaMultiplier() => Jolt.PInvoke.BodyCreationSettings_GetInertiaMultiplier(this);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// When calculating the inertia (not when it is provided) the calculated inertia will be multiplied by this
|
||||
/// value
|
||||
/// </para>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyCreationSettings.h#L115">Jolt/Physics/Body/BodyCreationSettings.h:115</see>
|
||||
/// <br/>
|
||||
/// <c>float mInertiaMultiplier = 1.0f</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
public void SetInertiaMultiplier(float value) => Jolt.PInvoke.BodyCreationSettings_SetInertiaMultiplier(this, value);
|
||||
public void Dispose() => Jolt.PInvoke.BodyCreationSettings_Destroy(this);
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,42 @@
|
|||
// <auto-generated/>
|
||||
// Generated by Brutal.Jolt.Generate; do not edit by hand.
|
||||
#nullable enable
|
||||
|
||||
using Brutal.Interop;
|
||||
using Brutal.Numerics;
|
||||
namespace Brutal.JoltApi
|
||||
{
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyFilter.h#L116">Jolt/Physics/Body/BodyFilter.h:116</see>
|
||||
/// <br/>
|
||||
/// <c>class BodyDrawFilter : public NonCopyable</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <para>
|
||||
/// Class function to filter out bodies for debug rendering, returns true if body should be rendered
|
||||
/// </para>
|
||||
/// </remarks>
|
||||
[InteropHandle]
|
||||
public readonly partial struct BodyDrawFilter : IDisposable
|
||||
{
|
||||
public static BodyDrawFilter Create() => Jolt.PInvoke.BodyDrawFilter_Create();
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyFilter.h#L123">Jolt/Physics/Body/BodyFilter.h:123</see>
|
||||
/// <br/>
|
||||
/// <c>virtual bool ShouldDraw(const Body& inBody) const</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <para>
|
||||
/// Filter function. Returns true if inBody should be rendered
|
||||
/// </para>
|
||||
/// </remarks>
|
||||
public bool ShouldDraw(Body body) => Jolt.PInvoke.BodyDrawFilter_ShouldDraw(this, body);
|
||||
public void Dispose() => Jolt.PInvoke.BodyDrawFilter_Destroy(this);
|
||||
}
|
||||
}
|
||||
57
brutal.jolt/Brutal.Jolt/Generated/Classes/BodyFilter.gen.cs
Normal file
57
brutal.jolt/Brutal.Jolt/Generated/Classes/BodyFilter.gen.cs
Normal file
|
|
@ -0,0 +1,57 @@
|
|||
// <auto-generated/>
|
||||
// Generated by Brutal.Jolt.Generate; do not edit by hand.
|
||||
#nullable enable
|
||||
|
||||
using Brutal.Interop;
|
||||
using Brutal.Numerics;
|
||||
namespace Brutal.JoltApi
|
||||
{
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyFilter.h#L15">Jolt/Physics/Body/BodyFilter.h:15</see>
|
||||
/// <br/>
|
||||
/// <c>class BodyFilter : public NonCopyable</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <para>
|
||||
/// Class function to filter out bodies, returns true if test should collide with body
|
||||
/// </para>
|
||||
/// </remarks>
|
||||
[InteropHandle]
|
||||
public readonly partial struct BodyFilter : IDisposable
|
||||
{
|
||||
public static BodyFilter Create() => Jolt.PInvoke.BodyFilter_Create();
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyFilter.h#L22">Jolt/Physics/Body/BodyFilter.h:22</see>
|
||||
/// <br/>
|
||||
/// <c>virtual bool ShouldCollide(const BodyID &inBodyID) const</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <para>
|
||||
/// Filter function. Returns true if we should collide with inBodyID
|
||||
/// </para>
|
||||
/// </remarks>
|
||||
public bool ShouldCollide(uint bodyID) => Jolt.PInvoke.BodyFilter_ShouldCollide(this, bodyID);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyFilter.h#L28">Jolt/Physics/Body/BodyFilter.h:28</see>
|
||||
/// <br/>
|
||||
/// <c>virtual bool ShouldCollideLocked(const Body &inBody) const</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <para>
|
||||
/// Filter function. Returns true if we should collide with inBody (this is called after the body is locked
|
||||
/// and makes it possible to filter based on body members)
|
||||
/// </para>
|
||||
/// </remarks>
|
||||
public bool ShouldCollideLocked(Body body) => Jolt.PInvoke.BodyFilter_ShouldCollideLocked(this, body);
|
||||
public void Dispose() => Jolt.PInvoke.BodyFilter_Destroy(this);
|
||||
}
|
||||
}
|
||||
1265
brutal.jolt/Brutal.Jolt/Generated/Classes/BodyInterface.gen.cs
Normal file
1265
brutal.jolt/Brutal.Jolt/Generated/Classes/BodyInterface.gen.cs
Normal file
File diff suppressed because it is too large
Load diff
|
|
@ -0,0 +1,44 @@
|
|||
// <auto-generated/>
|
||||
// Generated by Brutal.Jolt.Generate; do not edit by hand.
|
||||
#nullable enable
|
||||
|
||||
using Brutal.Interop;
|
||||
using Brutal.Numerics;
|
||||
namespace Brutal.JoltApi
|
||||
{
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyLockInterface.h#L16">Jolt/Physics/Body/BodyLockInterface.h:16</see>
|
||||
/// <br/>
|
||||
/// <c>class BodyLockInterface : public NonCopyable</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <para>
|
||||
/// Base class interface for locking a body. Usually you will use BodyLockRead / BodyLockWrite /
|
||||
/// BodyLockMultiRead / BodyLockMultiWrite instead.
|
||||
/// </para>
|
||||
/// </remarks>
|
||||
[InteropHandle]
|
||||
public readonly partial struct BodyLockInterface
|
||||
{
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyLockInterface.h#L50">Jolt/Physics/Body/BodyLockInterface.h:50</see>
|
||||
/// <br/>
|
||||
/// <c>inline Body * TryGetBody(const BodyID &inBodyID) const</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <para>
|
||||
/// Convert body ID to body
|
||||
/// </para>
|
||||
/// <para>
|
||||
/// The returned handle is borrowed from its owner; don't Dispose it.
|
||||
/// </para>
|
||||
/// </remarks>
|
||||
public Body TryGetBody(uint bodyID) => Jolt.PInvoke.BodyLockInterface_TryGetBody(this, bodyID);
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,27 @@
|
|||
// <auto-generated/>
|
||||
// Generated by Brutal.Jolt.Generate; do not edit by hand.
|
||||
#nullable enable
|
||||
|
||||
using Brutal.Interop;
|
||||
using Brutal.Numerics;
|
||||
namespace Brutal.JoltApi
|
||||
{
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyLockInterface.h#L77">Jolt/Physics/Body/BodyLockInterface.h:77</see>
|
||||
/// <br/>
|
||||
/// <c>class BodyLockInterfaceLocking final : public BodyLockInterface</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <para>
|
||||
/// Implementation that uses the body manager to lock the correct mutex for a body
|
||||
/// </para>
|
||||
/// </remarks>
|
||||
[InteropHandle]
|
||||
public readonly partial struct BodyLockInterfaceLocking
|
||||
{
|
||||
public static implicit operator BodyLockInterface(BodyLockInterfaceLocking value) => Jolt.PInvoke.BodyLockInterfaceLocking_AsBodyLockInterface(value);
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,27 @@
|
|||
// <auto-generated/>
|
||||
// Generated by Brutal.Jolt.Generate; do not edit by hand.
|
||||
#nullable enable
|
||||
|
||||
using Brutal.Interop;
|
||||
using Brutal.Numerics;
|
||||
namespace Brutal.JoltApi
|
||||
{
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyLockInterface.h#L57">Jolt/Physics/Body/BodyLockInterface.h:57</see>
|
||||
/// <br/>
|
||||
/// <c>class BodyLockInterfaceNoLock final : public BodyLockInterface</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <para>
|
||||
/// Implementation that performs no locking (assumes the lock has already been taken)
|
||||
/// </para>
|
||||
/// </remarks>
|
||||
[InteropHandle]
|
||||
public readonly partial struct BodyLockInterfaceNoLock
|
||||
{
|
||||
public static implicit operator BodyLockInterface(BodyLockInterfaceNoLock value) => Jolt.PInvoke.BodyLockInterfaceNoLock_AsBodyLockInterface(value);
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,48 @@
|
|||
// <auto-generated/>
|
||||
// Generated by Brutal.Jolt.Generate; do not edit by hand.
|
||||
#nullable enable
|
||||
|
||||
using Brutal.Interop;
|
||||
using Brutal.Numerics;
|
||||
namespace Brutal.JoltApi
|
||||
{
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyLockMulti.h#L109">Jolt/Physics/Body/BodyLockMulti.h:109</see>
|
||||
/// <br/>
|
||||
/// <c>class BodyLockMultiRead : public BodyLockMultiBase<false, const Body></c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <code>
|
||||
/// A multi body lock takes a number of body IDs and locks the underlying bodies so that other threads cannot access its members
|
||||
///
|
||||
/// The common usage pattern is:
|
||||
///
|
||||
/// BodyLockInterface lock_interface = physics_system.GetBodyLockInterface(); // Or non-locking interface if the lock is already taken
|
||||
/// const BodyID *body_id = ...; // Obtain IDs to bodies
|
||||
/// int num_body_ids = ...;
|
||||
///
|
||||
/// // Scoped lock
|
||||
/// {
|
||||
/// BodyLockMultiRead lock(lock_interface, body_ids, num_body_ids);
|
||||
/// for (int i = 0; i &lt; num_body_ids; ++i)
|
||||
/// {
|
||||
/// const Body *body = lock.GetBody(i);
|
||||
/// if (body != nullptr)
|
||||
/// {
|
||||
/// const Body &amp;body = lock.Body();
|
||||
///
|
||||
/// // Do something with body
|
||||
/// ...
|
||||
/// }
|
||||
/// }
|
||||
/// }
|
||||
/// </code>
|
||||
/// </remarks>
|
||||
[InteropHandle]
|
||||
public readonly partial struct BodyLockMultiRead
|
||||
{
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,26 @@
|
|||
// <auto-generated/>
|
||||
// Generated by Brutal.Jolt.Generate; do not edit by hand.
|
||||
#nullable enable
|
||||
|
||||
using Brutal.Interop;
|
||||
using Brutal.Numerics;
|
||||
namespace Brutal.JoltApi
|
||||
{
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyLockMulti.h#L115">Jolt/Physics/Body/BodyLockMulti.h:115</see>
|
||||
/// <br/>
|
||||
/// <c>class BodyLockMultiWrite : public BodyLockMultiBase<true, Body></c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <para>
|
||||
/// Specialization that locks multiple bodies for writing to. @see BodyLockMultiRead for usage patterns.
|
||||
/// </para>
|
||||
/// </remarks>
|
||||
[InteropHandle]
|
||||
public readonly partial struct BodyLockMultiWrite
|
||||
{
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,43 @@
|
|||
// <auto-generated/>
|
||||
// Generated by Brutal.Jolt.Generate; do not edit by hand.
|
||||
#nullable enable
|
||||
|
||||
using Brutal.Interop;
|
||||
using Brutal.Numerics;
|
||||
namespace Brutal.JoltApi
|
||||
{
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyLock.h#L100">Jolt/Physics/Body/BodyLock.h:100</see>
|
||||
/// <br/>
|
||||
/// <c>class BodyLockRead : public BodyLockBase<false, const Body></c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <code>
|
||||
/// A body lock takes a body ID and locks the underlying body so that other threads cannot access its members
|
||||
///
|
||||
/// The common usage pattern is:
|
||||
///
|
||||
/// BodyLockInterface lock_interface = physics_system.GetBodyLockInterface(); // Or non-locking interface if the lock is already taken
|
||||
/// BodyID body_id = ...; // Obtain ID to body
|
||||
///
|
||||
/// // Scoped lock
|
||||
/// {
|
||||
/// BodyLockRead lock(lock_interface, body_id);
|
||||
/// if (lock.Succeeded()) // body_id may no longer be valid
|
||||
/// {
|
||||
/// const Body &amp;body = lock.GetBody();
|
||||
///
|
||||
/// // Do something with body
|
||||
/// ...
|
||||
/// }
|
||||
/// }
|
||||
/// </code>
|
||||
/// </remarks>
|
||||
[InteropHandle]
|
||||
public readonly partial struct BodyLockRead
|
||||
{
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,26 @@
|
|||
// <auto-generated/>
|
||||
// Generated by Brutal.Jolt.Generate; do not edit by hand.
|
||||
#nullable enable
|
||||
|
||||
using Brutal.Interop;
|
||||
using Brutal.Numerics;
|
||||
namespace Brutal.JoltApi
|
||||
{
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyLock.h#L106">Jolt/Physics/Body/BodyLock.h:106</see>
|
||||
/// <br/>
|
||||
/// <c>class BodyLockWrite : public BodyLockBase<true, Body></c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <para>
|
||||
/// Specialization that locks a body for writing to. @see BodyLockRead for usage patterns.
|
||||
/// </para>
|
||||
/// </remarks>
|
||||
[InteropHandle]
|
||||
public readonly partial struct BodyLockWrite
|
||||
{
|
||||
}
|
||||
}
|
||||
982
brutal.jolt/Brutal.Jolt/Generated/Classes/BodyManager.gen.cs
Normal file
982
brutal.jolt/Brutal.Jolt/Generated/Classes/BodyManager.gen.cs
Normal file
|
|
@ -0,0 +1,982 @@
|
|||
// <auto-generated/>
|
||||
// Generated by Brutal.Jolt.Generate; do not edit by hand.
|
||||
#nullable enable
|
||||
|
||||
using Brutal.Interop;
|
||||
using Brutal.Numerics;
|
||||
namespace Brutal.JoltApi
|
||||
{
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyManager.h#L46">Jolt/Physics/Body/BodyManager.h:46</see>
|
||||
/// <br/>
|
||||
/// <c>class BodyManager : public NonCopyable</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <code>
|
||||
/// Class that contains all bodies
|
||||
///
|
||||
/// WARNING: This class is an internal part of PhysicsSystem, it has no functions that can be called by users of the library.
|
||||
/// Its functionality is exposed through PhysicsSystem, BodyInterface, BodyLockRead and BodyLockWrite.
|
||||
/// </code>
|
||||
/// </remarks>
|
||||
[InteropHandle]
|
||||
public readonly partial struct BodyManager
|
||||
{
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyManager.h#L222">Jolt/Physics/Body/BodyManager.h:222</see>
|
||||
/// <br/>
|
||||
/// <c>enum class EShapeColor</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
public enum EShapeColor : int
|
||||
{
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// Random color per instance
|
||||
/// </para>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyManager.h#L224">Jolt/Physics/Body/BodyManager.h:224</see>
|
||||
/// <br/>
|
||||
/// <c>InstanceColor</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
InstanceColor,
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// Convex = green, scaled = yellow, compound = orange, mesh = red
|
||||
/// </para>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyManager.h#L225">Jolt/Physics/Body/BodyManager.h:225</see>
|
||||
/// <br/>
|
||||
/// <c>ShapeTypeColor</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
ShapeTypeColor,
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// Static = grey, keyframed = green, dynamic = random color per instance
|
||||
/// </para>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyManager.h#L226">Jolt/Physics/Body/BodyManager.h:226</see>
|
||||
/// <br/>
|
||||
/// <c>MotionTypeColor</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
MotionTypeColor,
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// Static = grey, keyframed = green, dynamic = yellow, sleeping = red
|
||||
/// </para>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyManager.h#L227">Jolt/Physics/Body/BodyManager.h:227</see>
|
||||
/// <br/>
|
||||
/// <c>SleepColor</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
SleepColor,
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// Static = grey, active = random color per island, sleeping = light grey
|
||||
/// </para>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyManager.h#L228">Jolt/Physics/Body/BodyManager.h:228</see>
|
||||
/// <br/>
|
||||
/// <c>IslandColor</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
IslandColor,
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// Color as defined by the PhysicsMaterial of the shape
|
||||
/// </para>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyManager.h#L229">Jolt/Physics/Body/BodyManager.h:229</see>
|
||||
/// <br/>
|
||||
/// <c>MaterialColor</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
MaterialColor,
|
||||
}
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyManager.h#L64">Jolt/Physics/Body/BodyManager.h:64</see>
|
||||
/// <br/>
|
||||
/// <c>struct BodyStats</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <para>
|
||||
/// Helper struct that counts the number of bodies of each type
|
||||
/// </para>
|
||||
/// </remarks>
|
||||
[StructLayout(LayoutKind.Explicit, Size = 36)]
|
||||
public struct BodyStats
|
||||
{
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// Total number of bodies in the body manager
|
||||
/// </para>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyManager.h#L66">Jolt/Physics/Body/BodyManager.h:66</see>
|
||||
/// <br/>
|
||||
/// <c>uint mNumBodies = 0</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
[FieldOffset(0)]
|
||||
public uint mNumBodies;
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// Max allowed number of bodies in the body manager (as configured in Init(...))
|
||||
/// </para>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyManager.h#L67">Jolt/Physics/Body/BodyManager.h:67</see>
|
||||
/// <br/>
|
||||
/// <c>uint mMaxBodies = 0</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
[FieldOffset(4)]
|
||||
public uint mMaxBodies;
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// Number of static bodies
|
||||
/// </para>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyManager.h#L69">Jolt/Physics/Body/BodyManager.h:69</see>
|
||||
/// <br/>
|
||||
/// <c>uint mNumBodiesStatic = 0</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
[FieldOffset(8)]
|
||||
public uint mNumBodiesStatic;
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// Number of dynamic bodies
|
||||
/// </para>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyManager.h#L71">Jolt/Physics/Body/BodyManager.h:71</see>
|
||||
/// <br/>
|
||||
/// <c>uint mNumBodiesDynamic = 0</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
[FieldOffset(12)]
|
||||
public uint mNumBodiesDynamic;
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// Number of dynamic bodies that are currently active
|
||||
/// </para>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyManager.h#L72">Jolt/Physics/Body/BodyManager.h:72</see>
|
||||
/// <br/>
|
||||
/// <c>uint mNumActiveBodiesDynamic = 0</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
[FieldOffset(16)]
|
||||
public uint mNumActiveBodiesDynamic;
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// Number of kinematic bodies
|
||||
/// </para>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyManager.h#L74">Jolt/Physics/Body/BodyManager.h:74</see>
|
||||
/// <br/>
|
||||
/// <c>uint mNumBodiesKinematic = 0</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
[FieldOffset(20)]
|
||||
public uint mNumBodiesKinematic;
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// Number of kinematic bodies that are currently active
|
||||
/// </para>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyManager.h#L75">Jolt/Physics/Body/BodyManager.h:75</see>
|
||||
/// <br/>
|
||||
/// <c>uint mNumActiveBodiesKinematic = 0</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
[FieldOffset(24)]
|
||||
public uint mNumActiveBodiesKinematic;
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// Number of soft bodies
|
||||
/// </para>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyManager.h#L77">Jolt/Physics/Body/BodyManager.h:77</see>
|
||||
/// <br/>
|
||||
/// <c>uint mNumSoftBodies = 0</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
[FieldOffset(28)]
|
||||
public uint mNumSoftBodies;
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// Number of soft bodies that are currently active
|
||||
/// </para>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyManager.h#L78">Jolt/Physics/Body/BodyManager.h:78</see>
|
||||
/// <br/>
|
||||
/// <c>uint mNumActiveSoftBodies = 0</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
[FieldOffset(32)]
|
||||
public uint mNumActiveSoftBodies;
|
||||
}
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyManager.h#L243">Jolt/Physics/Body/BodyManager.h:243</see>
|
||||
/// <br/>
|
||||
/// <c>struct DrawSettings</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <code>
|
||||
/// Draw settings
|
||||
///
|
||||
/// Note that there are several debug drawing features that are not exposed through this interface since they use information
|
||||
/// that is only available deep inside the simulation update and are mostly there to facilitate debugging Jolt. These options
|
||||
/// use DebugRenderer::sInstance to draw.
|
||||
///
|
||||
/// E.g.:
|
||||
/// * To draw contact information, use ContactConstraintManager::sDrawContactManifolds.
|
||||
/// * To draw when continuous collision detection is used, use PhysicsSystem::sDrawMotionQualityLinearCast.
|
||||
/// * To draw what's going on in a CharacterVirtual update, use CharacterVirtual::sDrawConstraints, CharacterVirtual::sDrawWalkStairs and CharacterVirtual::sDrawStickToFloor.
|
||||
/// * To draw the volume of water that interacts with a shape, use Shape::sDrawSubmergedVolumes.
|
||||
/// </code>
|
||||
/// </remarks>
|
||||
[StructLayout(LayoutKind.Explicit, Size = 36)]
|
||||
public struct DrawSettings
|
||||
{
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// Draw the GetSupport() function, used for convex collision detection
|
||||
/// </para>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyManager.h#L245">Jolt/Physics/Body/BodyManager.h:245</see>
|
||||
/// <br/>
|
||||
/// <c>bool mDrawGetSupportFunction = false</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
[FieldOffset(0)]
|
||||
public Brutal.Bool8 mDrawGetSupportFunction;
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// When drawing the support function, also draw which direction mapped to a specific support point
|
||||
/// </para>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyManager.h#L246">Jolt/Physics/Body/BodyManager.h:246</see>
|
||||
/// <br/>
|
||||
/// <c>bool mDrawSupportDirection = false</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
[FieldOffset(1)]
|
||||
public Brutal.Bool8 mDrawSupportDirection;
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// Draw the faces that were found colliding during collision detection
|
||||
/// </para>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyManager.h#L247">Jolt/Physics/Body/BodyManager.h:247</see>
|
||||
/// <br/>
|
||||
/// <c>bool mDrawGetSupportingFace = false</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
[FieldOffset(2)]
|
||||
public Brutal.Bool8 mDrawGetSupportingFace;
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// Draw the shapes of all bodies
|
||||
/// </para>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyManager.h#L248">Jolt/Physics/Body/BodyManager.h:248</see>
|
||||
/// <br/>
|
||||
/// <c>bool mDrawShape = true</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
[FieldOffset(3)]
|
||||
public Brutal.Bool8 mDrawShape;
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// When mDrawShape is true and this is true, the shapes will be drawn in wireframe instead of solid.
|
||||
/// </para>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyManager.h#L249">Jolt/Physics/Body/BodyManager.h:249</see>
|
||||
/// <br/>
|
||||
/// <c>bool mDrawShapeWireframe = false</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
[FieldOffset(4)]
|
||||
public Brutal.Bool8 mDrawShapeWireframe;
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// Coloring scheme to use for shapes
|
||||
/// </para>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyManager.h#L250">Jolt/Physics/Body/BodyManager.h:250</see>
|
||||
/// <br/>
|
||||
/// <c>EShapeColor mDrawShapeColor = EShapeColor::MotionTypeColor</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
[FieldOffset(8)]
|
||||
public BodyManager.EShapeColor mDrawShapeColor;
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// Draw a bounding box per body
|
||||
/// </para>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyManager.h#L251">Jolt/Physics/Body/BodyManager.h:251</see>
|
||||
/// <br/>
|
||||
/// <c>bool mDrawBoundingBox = false</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
[FieldOffset(12)]
|
||||
public Brutal.Bool8 mDrawBoundingBox;
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// Draw the center of mass for each body
|
||||
/// </para>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyManager.h#L252">Jolt/Physics/Body/BodyManager.h:252</see>
|
||||
/// <br/>
|
||||
/// <c>bool mDrawCenterOfMassTransform = false</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
[FieldOffset(13)]
|
||||
public Brutal.Bool8 mDrawCenterOfMassTransform;
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// Draw the world transform (which can be different than the center of mass) for each body
|
||||
/// </para>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyManager.h#L253">Jolt/Physics/Body/BodyManager.h:253</see>
|
||||
/// <br/>
|
||||
/// <c>bool mDrawWorldTransform = false</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
[FieldOffset(14)]
|
||||
public Brutal.Bool8 mDrawWorldTransform;
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// Draw the velocity vector for each body
|
||||
/// </para>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyManager.h#L254">Jolt/Physics/Body/BodyManager.h:254</see>
|
||||
/// <br/>
|
||||
/// <c>bool mDrawVelocity = false</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
[FieldOffset(15)]
|
||||
public Brutal.Bool8 mDrawVelocity;
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// Draw the mass and inertia (as the box equivalent) for each body
|
||||
/// </para>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyManager.h#L255">Jolt/Physics/Body/BodyManager.h:255</see>
|
||||
/// <br/>
|
||||
/// <c>bool mDrawMassAndInertia = false</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
[FieldOffset(16)]
|
||||
public Brutal.Bool8 mDrawMassAndInertia;
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// Draw stats regarding the sleeping algorithm of each body
|
||||
/// </para>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyManager.h#L256">Jolt/Physics/Body/BodyManager.h:256</see>
|
||||
/// <br/>
|
||||
/// <c>bool mDrawSleepStats = false</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
[FieldOffset(17)]
|
||||
public Brutal.Bool8 mDrawSleepStats;
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// Draw the vertices of soft bodies
|
||||
/// </para>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyManager.h#L257">Jolt/Physics/Body/BodyManager.h:257</see>
|
||||
/// <br/>
|
||||
/// <c>bool mDrawSoftBodyVertices = false</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
[FieldOffset(18)]
|
||||
public Brutal.Bool8 mDrawSoftBodyVertices;
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// Draw the velocities of the vertices of soft bodies
|
||||
/// </para>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyManager.h#L258">Jolt/Physics/Body/BodyManager.h:258</see>
|
||||
/// <br/>
|
||||
/// <c>bool mDrawSoftBodyVertexVelocities = false</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
[FieldOffset(19)]
|
||||
public Brutal.Bool8 mDrawSoftBodyVertexVelocities;
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// Draw the edge constraints of soft bodies
|
||||
/// </para>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyManager.h#L259">Jolt/Physics/Body/BodyManager.h:259</see>
|
||||
/// <br/>
|
||||
/// <c>bool mDrawSoftBodyEdgeConstraints = false</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
[FieldOffset(20)]
|
||||
public Brutal.Bool8 mDrawSoftBodyEdgeConstraints;
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// Draw the bend constraints of soft bodies
|
||||
/// </para>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyManager.h#L260">Jolt/Physics/Body/BodyManager.h:260</see>
|
||||
/// <br/>
|
||||
/// <c>bool mDrawSoftBodyBendConstraints = false</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
[FieldOffset(21)]
|
||||
public Brutal.Bool8 mDrawSoftBodyBendConstraints;
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// Draw the volume constraints of soft bodies
|
||||
/// </para>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyManager.h#L261">Jolt/Physics/Body/BodyManager.h:261</see>
|
||||
/// <br/>
|
||||
/// <c>bool mDrawSoftBodyVolumeConstraints = false</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
[FieldOffset(22)]
|
||||
public Brutal.Bool8 mDrawSoftBodyVolumeConstraints;
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// Draw the skin constraints of soft bodies
|
||||
/// </para>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyManager.h#L262">Jolt/Physics/Body/BodyManager.h:262</see>
|
||||
/// <br/>
|
||||
/// <c>bool mDrawSoftBodySkinConstraints = false</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
[FieldOffset(23)]
|
||||
public Brutal.Bool8 mDrawSoftBodySkinConstraints;
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// Draw the LRA constraints of soft bodies
|
||||
/// </para>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyManager.h#L263">Jolt/Physics/Body/BodyManager.h:263</see>
|
||||
/// <br/>
|
||||
/// <c>bool mDrawSoftBodyLRAConstraints = false</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
[FieldOffset(24)]
|
||||
public Brutal.Bool8 mDrawSoftBodyLRAConstraints;
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// Draw the rods of soft bodies
|
||||
/// </para>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyManager.h#L264">Jolt/Physics/Body/BodyManager.h:264</see>
|
||||
/// <br/>
|
||||
/// <c>bool mDrawSoftBodyRods = false</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
[FieldOffset(25)]
|
||||
public Brutal.Bool8 mDrawSoftBodyRods;
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// Draw the rod states (orientation and angular velocity) of soft bodies
|
||||
/// </para>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyManager.h#L265">Jolt/Physics/Body/BodyManager.h:265</see>
|
||||
/// <br/>
|
||||
/// <c>bool mDrawSoftBodyRodStates = false</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
[FieldOffset(26)]
|
||||
public Brutal.Bool8 mDrawSoftBodyRodStates;
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// Draw the rod bend twist constraints of soft bodies
|
||||
/// </para>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyManager.h#L266">Jolt/Physics/Body/BodyManager.h:266</see>
|
||||
/// <br/>
|
||||
/// <c>bool mDrawSoftBodyRodBendTwistConstraints = false</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
[FieldOffset(27)]
|
||||
public Brutal.Bool8 mDrawSoftBodyRodBendTwistConstraints;
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// Draw the predicted bounds of soft bodies
|
||||
/// </para>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyManager.h#L267">Jolt/Physics/Body/BodyManager.h:267</see>
|
||||
/// <br/>
|
||||
/// <c>bool mDrawSoftBodyPredictedBounds = false</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
[FieldOffset(28)]
|
||||
public Brutal.Bool8 mDrawSoftBodyPredictedBounds;
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// Coloring scheme to use for soft body constraints
|
||||
/// </para>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyManager.h#L268">Jolt/Physics/Body/BodyManager.h:268</see>
|
||||
/// <br/>
|
||||
/// <c>ESoftBodyConstraintColor mDrawSoftBodyConstraintColor = ESoftBodyConstraintColor::ConstraintType</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
[FieldOffset(32)]
|
||||
public ESoftBodyConstraintColor mDrawSoftBodyConstraintColor;
|
||||
}
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyManager.h#L55">Jolt/Physics/Body/BodyManager.h:55</see>
|
||||
/// <br/>
|
||||
/// <c>void Init(uint inMaxBodies, uint inNumBodyMutexes, const BroadPhaseLayerInterface &inLayerInterface)</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <para>
|
||||
/// Initialize the manager
|
||||
/// </para>
|
||||
/// </remarks>
|
||||
public void Init(uint maxBodies, uint numBodyMutexes, BroadPhaseLayerInterface layerInterface) => Jolt.PInvoke.BodyManager_Init(this, maxBodies, numBodyMutexes, layerInterface);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyManager.h#L58">Jolt/Physics/Body/BodyManager.h:58</see>
|
||||
/// <br/>
|
||||
/// <c>uint GetNumBodies() const</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <para>
|
||||
/// Gets the current amount of bodies that are in the body manager
|
||||
/// </para>
|
||||
/// </remarks>
|
||||
public uint GetNumBodies() => Jolt.PInvoke.BodyManager_GetNumBodies(this);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyManager.h#L61">Jolt/Physics/Body/BodyManager.h:61</see>
|
||||
/// <br/>
|
||||
/// <c>uint GetMaxBodies() const</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <para>
|
||||
/// Gets the max bodies that we can support
|
||||
/// </para>
|
||||
/// </remarks>
|
||||
public uint GetMaxBodies() => Jolt.PInvoke.BodyManager_GetMaxBodies(this);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyManager.h#L85">Jolt/Physics/Body/BodyManager.h:85</see>
|
||||
/// <br/>
|
||||
/// <c>Body * AllocateBody(const BodyCreationSettings &inBodyCreationSettings) const</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <para>
|
||||
/// Create a body using creation settings. The returned body will not be part of the body manager yet.
|
||||
/// </para>
|
||||
/// <para>
|
||||
/// The returned handle is borrowed from its owner; don't Dispose it.
|
||||
/// </para>
|
||||
/// </remarks>
|
||||
public Body AllocateBody(BodyCreationSettings bodyCreationSettings) => Jolt.PInvoke.BodyManager_AllocateBody(this, bodyCreationSettings);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyManager.h#L88">Jolt/Physics/Body/BodyManager.h:88</see>
|
||||
/// <br/>
|
||||
/// <c>Body * AllocateSoftBody(const SoftBodyCreationSettings &inSoftBodyCreationSettings) const</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <para>
|
||||
/// Create a soft body using creation settings. The returned body will not be part of the body manager yet.
|
||||
/// </para>
|
||||
/// <para>
|
||||
/// The returned handle is borrowed from its owner; don't Dispose it.
|
||||
/// </para>
|
||||
/// </remarks>
|
||||
public Body AllocateSoftBody(SoftBodyCreationSettings softBodyCreationSettings) => Jolt.PInvoke.BodyManager_AllocateSoftBody(this, softBodyCreationSettings);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyManager.h#L91">Jolt/Physics/Body/BodyManager.h:91</see>
|
||||
/// <br/>
|
||||
/// <c>void FreeBody(Body *inBody) const</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <para>
|
||||
/// Free a body that has not been added to the body manager yet (if it has, use DestroyBodies).
|
||||
/// </para>
|
||||
/// </remarks>
|
||||
public void FreeBody(Body body) => Jolt.PInvoke.BodyManager_FreeBody(this, body);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyManager.h#L94">Jolt/Physics/Body/BodyManager.h:94</see>
|
||||
/// <br/>
|
||||
/// <c>bool AddBody(Body *ioBody)</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <para>
|
||||
/// Add a body to the body manager, assigning it the next available ID. Returns false if no more IDs are
|
||||
/// available.
|
||||
/// </para>
|
||||
/// </remarks>
|
||||
public bool AddBody(Body body) => Jolt.PInvoke.BodyManager_AddBody(this, body);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyManager.h#L97">Jolt/Physics/Body/BodyManager.h:97</see>
|
||||
/// <br/>
|
||||
/// <c>bool AddBodyWithCustomID(Body *ioBody, const BodyID &inBodyID)</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <para>
|
||||
/// Add a body to the body manager, assigning it a custom ID. Returns false if the ID is not valid.
|
||||
/// </para>
|
||||
/// </remarks>
|
||||
public bool AddBodyWithCustomID(Body body, uint bodyID) => Jolt.PInvoke.BodyManager_AddBodyWithCustomID(this, body, bodyID);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyManager.h#L103">Jolt/Physics/Body/BodyManager.h:103</see>
|
||||
/// <br/>
|
||||
/// <c>void DestroyBodies(const BodyID *inBodyIDs, int inNumber)</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <para>
|
||||
/// Remove a set of bodies from the body manager and frees them.
|
||||
/// </para>
|
||||
/// </remarks>
|
||||
public unsafe void DestroyBodies(Ptr<uint> bodyIDs, int number) => Jolt.PInvoke.BodyManager_DestroyBodies(this, bodyIDs, number);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyManager.h#L107">Jolt/Physics/Body/BodyManager.h:107</see>
|
||||
/// <br/>
|
||||
/// <c>void ActivateBodies(const BodyID *inBodyIDs, int inNumber)</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <code>
|
||||
/// Activate a list of bodies.
|
||||
/// This function should only be called when an exclusive lock for the bodies are held.
|
||||
/// </code>
|
||||
/// </remarks>
|
||||
public unsafe void ActivateBodies(Ptr<uint> bodyIDs, int number) => Jolt.PInvoke.BodyManager_ActivateBodies(this, bodyIDs, number);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyManager.h#L111">Jolt/Physics/Body/BodyManager.h:111</see>
|
||||
/// <br/>
|
||||
/// <c>void DeactivateBodies(const BodyID *inBodyIDs, int inNumber)</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <code>
|
||||
/// Deactivate a list of bodies.
|
||||
/// This function should only be called when an exclusive lock for the bodies are held.
|
||||
/// </code>
|
||||
/// </remarks>
|
||||
public unsafe void DeactivateBodies(Ptr<uint> bodyIDs, int number) => Jolt.PInvoke.BodyManager_DeactivateBodies(this, bodyIDs, number);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyManager.h#L114">Jolt/Physics/Body/BodyManager.h:114</see>
|
||||
/// <br/>
|
||||
/// <c>void SetMotionQuality(Body &ioBody, EMotionQuality inMotionQuality)</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <para>
|
||||
/// Update the motion quality for a body
|
||||
/// </para>
|
||||
/// </remarks>
|
||||
public void SetMotionQuality(Body body, EMotionQuality motionQuality) => Jolt.PInvoke.BodyManager_SetMotionQuality(this, body, motionQuality);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyManager.h#L123">Jolt/Physics/Body/BodyManager.h:123</see>
|
||||
/// <br/>
|
||||
/// <c>uint32 GetNumActiveBodies(EBodyType inType) const</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <para>
|
||||
/// Get the number of active bodies.
|
||||
/// </para>
|
||||
/// </remarks>
|
||||
public uint GetNumActiveBodies(EBodyType type) => Jolt.PInvoke.BodyManager_GetNumActiveBodies(this, type);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyManager.h#L126">Jolt/Physics/Body/BodyManager.h:126</see>
|
||||
/// <br/>
|
||||
/// <c>uint32 GetNumActiveCCDBodies() const</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <para>
|
||||
/// Get the number of active bodies that are using continuous collision detection
|
||||
/// </para>
|
||||
/// </remarks>
|
||||
public uint GetNumActiveCCDBodies() => Jolt.PInvoke.BodyManager_GetNumActiveCCDBodies(this);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyManager.h#L129">Jolt/Physics/Body/BodyManager.h:129</see>
|
||||
/// <br/>
|
||||
/// <c>void SetBodyActivationListener(BodyActivationListener *inListener)</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <para>
|
||||
/// Listener that is notified whenever a body is activated/deactivated
|
||||
/// </para>
|
||||
/// </remarks>
|
||||
public void SetBodyActivationListener(BodyActivationListener listener) => Jolt.PInvoke.BodyManager_SetBodyActivationListener(this, listener);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyManager.h#L130">Jolt/Physics/Body/BodyManager.h:130</see>
|
||||
/// <br/>
|
||||
/// <c>BodyActivationListener * GetBodyActivationListener() const</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <para>
|
||||
/// The returned handle is borrowed from its owner; don't Dispose it.
|
||||
/// </para>
|
||||
/// </remarks>
|
||||
public BodyActivationListener GetBodyActivationListener() => Jolt.PInvoke.BodyManager_GetBodyActivationListener(this);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyManager.h#L133">Jolt/Physics/Body/BodyManager.h:133</see>
|
||||
/// <br/>
|
||||
/// <c>static inline bool sIsValidBodyPointer(const Body *inBody)</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <para>
|
||||
/// Check if this is a valid body pointer. When a body is freed the memory that the pointer occupies is
|
||||
/// reused to store a freelist.
|
||||
/// </para>
|
||||
/// </remarks>
|
||||
public static bool sIsValidBodyPointer(Body body) => Jolt.PInvoke.BodyManager_sIsValidBodyPointer(body);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyManager.h#L145">Jolt/Physics/Body/BodyManager.h:145</see>
|
||||
/// <br/>
|
||||
/// <c>const Body & GetBody(const BodyID &inID) const</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <para>
|
||||
/// Access a body (not protected by lock)
|
||||
/// </para>
|
||||
/// <para>
|
||||
/// The returned handle is borrowed from its owner; don't Dispose it.
|
||||
/// </para>
|
||||
/// </remarks>
|
||||
public Body GetBody(uint iD) => Jolt.PInvoke.BodyManager_GetBody(this, iD);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyManager.h#L151">Jolt/Physics/Body/BodyManager.h:151</see>
|
||||
/// <br/>
|
||||
/// <c>const Body * TryGetBody(const BodyID &inID) const</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <para>
|
||||
/// Access a body, will return a nullptr if the body ID is no longer valid (not protected by lock)
|
||||
/// </para>
|
||||
/// <para>
|
||||
/// The returned handle is borrowed from its owner; don't Dispose it.
|
||||
/// </para>
|
||||
/// </remarks>
|
||||
public Body TryGetBody(uint iD) => Jolt.PInvoke.BodyManager_TryGetBody(this, iD);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyManager.h#L195">Jolt/Physics/Body/BodyManager.h:195</see>
|
||||
/// <br/>
|
||||
/// <c>void LockAllBodies() const</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <para>
|
||||
/// Lock all bodies. This should only be done during PhysicsSystem::Update().
|
||||
/// </para>
|
||||
/// </remarks>
|
||||
public void LockAllBodies() => Jolt.PInvoke.BodyManager_LockAllBodies(this);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyManager.h#L198">Jolt/Physics/Body/BodyManager.h:198</see>
|
||||
/// <br/>
|
||||
/// <c>void UnlockAllBodies() const</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <para>
|
||||
/// Unlock all bodies. This should only be done during PhysicsSystem::Update().
|
||||
/// </para>
|
||||
/// </remarks>
|
||||
public void UnlockAllBodies() => Jolt.PInvoke.BodyManager_UnlockAllBodies(this);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyManager.h#L201">Jolt/Physics/Body/BodyManager.h:201</see>
|
||||
/// <br/>
|
||||
/// <c>inline void SetBodyObjectLayerInternal(Body &ioBody, ObjectLayer inLayer) const</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <para>
|
||||
/// Function to update body's layer (should only be called by the BodyInterface since it also requires
|
||||
/// updating the broadphase)
|
||||
/// </para>
|
||||
/// </remarks>
|
||||
public void SetBodyObjectLayerInternal(Body body, ushort layer) => Jolt.PInvoke.BodyManager_SetBodyObjectLayerInternal(this, body, layer);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyManager.h#L204">Jolt/Physics/Body/BodyManager.h:204</see>
|
||||
/// <br/>
|
||||
/// <c>void InvalidateContactCacheForBody(Body &ioBody)</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <para>
|
||||
/// Set the Body::EFlags::InvalidateContactCache flag for the specified body. This means that the collision
|
||||
/// cache is invalid for any body pair involving that body until the next physics step.
|
||||
/// </para>
|
||||
/// </remarks>
|
||||
public void InvalidateContactCacheForBody(Body body) => Jolt.PInvoke.BodyManager_InvalidateContactCacheForBody(this, body);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyManager.h#L207">Jolt/Physics/Body/BodyManager.h:207</see>
|
||||
/// <br/>
|
||||
/// <c>void ValidateContactCacheForAllBodies()</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <para>
|
||||
/// Reset the Body::EFlags::InvalidateContactCache flag for all bodies. All contact pairs in the contact
|
||||
/// cache will now by valid again.
|
||||
/// </para>
|
||||
/// </remarks>
|
||||
public void ValidateContactCacheForAllBodies() => Jolt.PInvoke.BodyManager_ValidateContactCacheForAllBodies(this);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyManager.h#L216">Jolt/Physics/Body/BodyManager.h:216</see>
|
||||
/// <br/>
|
||||
/// <c>void SaveBodyState(const Body &inBody, StateRecorder &inStream) const</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <para>
|
||||
/// Save the state of a single body for replay
|
||||
/// </para>
|
||||
/// </remarks>
|
||||
public void SaveBodyState(Body body, StateRecorder stream) => Jolt.PInvoke.BodyManager_SaveBodyState(this, body, stream);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyManager.h#L219">Jolt/Physics/Body/BodyManager.h:219</see>
|
||||
/// <br/>
|
||||
/// <c>void RestoreBodyState(Body &inBody, StateRecorder &inStream)</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <para>
|
||||
/// Save the state of a single body for replay
|
||||
/// </para>
|
||||
/// </remarks>
|
||||
public void RestoreBodyState(Body body, StateRecorder stream) => Jolt.PInvoke.BodyManager_RestoreBodyState(this, body, stream);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Body/BodyManager.h#L272">Jolt/Physics/Body/BodyManager.h:272</see>
|
||||
/// <br/>
|
||||
/// <c>void Draw(const DrawSettings &inSettings, const PhysicsSettings &inPhysicsSettings, DebugRenderer *inRenderer, const BodyDrawFilter *inBodyFilter = nullptr)</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <para>
|
||||
/// Draw the state of the bodies (debugging purposes)
|
||||
/// </para>
|
||||
/// </remarks>
|
||||
public void Draw(ref BodyManager.DrawSettings settings, ref PhysicsSettings physicsSettings, DebugRenderer renderer, BodyDrawFilter bodyFilter) => Jolt.PInvoke.BodyManager_Draw(this, ref settings, ref physicsSettings, renderer, bodyFilter);
|
||||
}
|
||||
}
|
||||
205
brutal.jolt/Brutal.Jolt/Generated/Classes/BoxShape.gen.cs
Normal file
205
brutal.jolt/Brutal.Jolt/Generated/Classes/BoxShape.gen.cs
Normal file
|
|
@ -0,0 +1,205 @@
|
|||
// <auto-generated/>
|
||||
// Generated by Brutal.Jolt.Generate; do not edit by hand.
|
||||
#nullable enable
|
||||
|
||||
using Brutal.Interop;
|
||||
using Brutal.Numerics;
|
||||
namespace Brutal.JoltApi
|
||||
{
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Collision/Shape/BoxShape.h#L33">Jolt/Physics/Collision/Shape/BoxShape.h:33</see>
|
||||
/// <br/>
|
||||
/// <c>class BoxShape final : public ConvexShape</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <para>
|
||||
/// A box, centered around the origin
|
||||
/// </para>
|
||||
/// </remarks>
|
||||
[InteropHandle]
|
||||
public readonly partial struct BoxShape : IDisposable
|
||||
{
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Collision/Shape/BoxShape.h#L39">Jolt/Physics/Collision/Shape/BoxShape.h:39</see>
|
||||
/// <br/>
|
||||
/// <c>BoxShape()</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <para>
|
||||
/// Constructor
|
||||
/// </para>
|
||||
/// </remarks>
|
||||
public static BoxShape Create() => Jolt.PInvoke.BoxShape_Create();
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Collision/Shape/BoxShape.h#L44">Jolt/Physics/Collision/Shape/BoxShape.h:44</see>
|
||||
/// <br/>
|
||||
/// <c>explicit BoxShape(Vec3Arg inHalfExtent, float inConvexRadius = cDefaultConvexRadius, const PhysicsMaterial *inMaterial = nullptr)</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <code>
|
||||
/// Create a box with half edge length inHalfExtent and convex radius inConvexRadius.
|
||||
/// (internally the convex radius will be subtracted from the half extent so the total box will not grow with the convex radius).
|
||||
/// </code>
|
||||
/// </remarks>
|
||||
public static BoxShape Create(float3 halfExtent, float convexRadius, PhysicsMaterial material) => Jolt.PInvoke.BoxShape_Create_2(halfExtent, convexRadius, material);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Collision/Shape/BoxShape.h#L47">Jolt/Physics/Collision/Shape/BoxShape.h:47</see>
|
||||
/// <br/>
|
||||
/// <c>Vec3 GetHalfExtent() const</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <para>
|
||||
/// Get half extent of box
|
||||
/// </para>
|
||||
/// </remarks>
|
||||
public float3 GetHalfExtent() => Jolt.PInvoke.BoxShape_GetHalfExtent(this);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Collision/Shape/BoxShape.h#L53">Jolt/Physics/Collision/Shape/BoxShape.h:53</see>
|
||||
/// <br/>
|
||||
/// <c>virtual float GetInnerRadius() const override</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <para>
|
||||
/// See Shape::GetInnerRadius
|
||||
/// </para>
|
||||
/// </remarks>
|
||||
public float GetInnerRadius() => Jolt.PInvoke.BoxShape_GetInnerRadius(this);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Collision/Shape/BoxShape.h#L59">Jolt/Physics/Collision/Shape/BoxShape.h:59</see>
|
||||
/// <br/>
|
||||
/// <c>virtual Vec3 GetSurfaceNormal(const SubShapeID &inSubShapeID, Vec3Arg inLocalSurfacePosition) const override</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <para>
|
||||
/// See Shape::GetSurfaceNormal
|
||||
/// </para>
|
||||
/// </remarks>
|
||||
public float3 GetSurfaceNormal(uint subShapeID, float3 localSurfacePosition) => Jolt.PInvoke.BoxShape_GetSurfaceNormal(this, subShapeID, localSurfacePosition);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Collision/Shape/BoxShape.h#L69">Jolt/Physics/Collision/Shape/BoxShape.h:69</see>
|
||||
/// <br/>
|
||||
/// <c>virtual void Draw(DebugRenderer *inRenderer, RMat44Arg inCenterOfMassTransform, Vec3Arg inScale, ColorArg inColor, bool inUseMaterialColors, bool inDrawWireframe) const override</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <para>
|
||||
/// See Shape::Draw
|
||||
/// </para>
|
||||
/// </remarks>
|
||||
public void Draw(DebugRenderer renderer, float4x4 centerOfMassTransform, float3 scale, uint color, bool useMaterialColors, bool drawWireframe) => Jolt.PInvoke.BoxShape_Draw(this, renderer, centerOfMassTransform, scale, color, useMaterialColors, drawWireframe);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Collision/Shape/BoxShape.h#L80">Jolt/Physics/Collision/Shape/BoxShape.h:80</see>
|
||||
/// <br/>
|
||||
/// <c>virtual void CollideSoftBodyVertices(Mat44Arg inCenterOfMassTransform, Vec3Arg inScale, const CollideSoftBodyVertexIterator &inVertices, uint inNumVertices, int inCollidingShapeIndex) const override</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <para>
|
||||
/// See: Shape::CollideSoftBodyVertices
|
||||
/// </para>
|
||||
/// </remarks>
|
||||
public void CollideSoftBodyVertices(float4x4 centerOfMassTransform, float3 scale, CollideSoftBodyVertexIterator vertices, uint numVertices, int collidingShapeIndex) => Jolt.PInvoke.BoxShape_CollideSoftBodyVertices(this, centerOfMassTransform, scale, vertices, numVertices, collidingShapeIndex);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Collision/Shape/BoxShape.h#L83">Jolt/Physics/Collision/Shape/BoxShape.h:83</see>
|
||||
/// <br/>
|
||||
/// <c>virtual void GetTrianglesStart(GetTrianglesContext &ioContext, const AABox &inBox, Vec3Arg inPositionCOM, QuatArg inRotation, Vec3Arg inScale) const override</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <para>
|
||||
/// See Shape::GetTrianglesStart
|
||||
/// </para>
|
||||
/// </remarks>
|
||||
public void GetTrianglesStart(ref Shape.GetTrianglesContext context, AABox box, float3 positionCOM, floatQuat rotation, float3 scale) => Jolt.PInvoke.BoxShape_GetTrianglesStart(this, ref context, box, positionCOM, rotation, scale);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Collision/Shape/BoxShape.h#L89">Jolt/Physics/Collision/Shape/BoxShape.h:89</see>
|
||||
/// <br/>
|
||||
/// <c>virtual void SaveBinaryState(StreamOut &inStream) const override</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <para>
|
||||
/// See Shape
|
||||
/// </para>
|
||||
/// </remarks>
|
||||
public void SaveBinaryState(StreamOut stream) => Jolt.PInvoke.BoxShape_SaveBinaryState(this, stream);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Collision/Shape/BoxShape.h#L95">Jolt/Physics/Collision/Shape/BoxShape.h:95</see>
|
||||
/// <br/>
|
||||
/// <c>virtual float GetVolume() const override</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <para>
|
||||
/// See Shape::GetVolume
|
||||
/// </para>
|
||||
/// </remarks>
|
||||
public float GetVolume() => Jolt.PInvoke.BoxShape_GetVolume(this);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Collision/Shape/BoxShape.h#L98">Jolt/Physics/Collision/Shape/BoxShape.h:98</see>
|
||||
/// <br/>
|
||||
/// <c>float GetConvexRadius() const</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <para>
|
||||
/// Get the convex radius of this box
|
||||
/// </para>
|
||||
/// </remarks>
|
||||
public float GetConvexRadius() => Jolt.PInvoke.BoxShape_GetConvexRadius(this);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Collision/Shape/BoxShape.h#L101">Jolt/Physics/Collision/Shape/BoxShape.h:101</see>
|
||||
/// <br/>
|
||||
/// <c>static void sRegister()</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <para>
|
||||
/// Register shape functions with the registry
|
||||
/// </para>
|
||||
/// </remarks>
|
||||
public static void sRegister() => Jolt.PInvoke.BoxShape_sRegister();
|
||||
public void AddRef() => Jolt.PInvoke.BoxShape_AddRef(this);
|
||||
public void Release() => Jolt.PInvoke.BoxShape_Release(this);
|
||||
public uint GetRefCount() => Jolt.PInvoke.BoxShape_GetRefCount(this);
|
||||
public static implicit operator ConvexShape(BoxShape value) => Jolt.PInvoke.BoxShape_AsConvexShape(value);
|
||||
public static implicit operator Shape(BoxShape value) => Jolt.PInvoke.BoxShape_AsShape(value);
|
||||
public void Dispose()
|
||||
{
|
||||
if (IsNull()) return;
|
||||
Release();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,152 @@
|
|||
// <auto-generated/>
|
||||
// Generated by Brutal.Jolt.Generate; do not edit by hand.
|
||||
#nullable enable
|
||||
|
||||
using Brutal.Interop;
|
||||
using Brutal.Numerics;
|
||||
namespace Brutal.JoltApi
|
||||
{
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Collision/Shape/BoxShape.h#L13">Jolt/Physics/Collision/Shape/BoxShape.h:13</see>
|
||||
/// <br/>
|
||||
/// <c>class BoxShapeSettings final : public ConvexShapeSettings</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <para>
|
||||
/// Class that constructs a BoxShape
|
||||
/// </para>
|
||||
/// </remarks>
|
||||
[InteropHandle]
|
||||
public readonly partial struct BoxShapeSettings : IDisposable
|
||||
{
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Collision/Shape/BoxShape.h#L19">Jolt/Physics/Collision/Shape/BoxShape.h:19</see>
|
||||
/// <br/>
|
||||
/// <c>BoxShapeSettings() = default</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <para>
|
||||
/// Default constructor for deserialization
|
||||
/// </para>
|
||||
/// </remarks>
|
||||
public static BoxShapeSettings Create() => Jolt.PInvoke.BoxShapeSettings_Create();
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Collision/Shape/BoxShape.h#L23">Jolt/Physics/Collision/Shape/BoxShape.h:23</see>
|
||||
/// <br/>
|
||||
/// <c>explicit BoxShapeSettings(Vec3Arg inHalfExtent, float inConvexRadius = cDefaultConvexRadius, const PhysicsMaterial *inMaterial = nullptr)</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <code>
|
||||
/// Create a box with half edge length inHalfExtent and convex radius inConvexRadius.
|
||||
/// (internally the convex radius will be subtracted from the half extent so the total box will not grow with the convex radius).
|
||||
/// </code>
|
||||
/// </remarks>
|
||||
public static BoxShapeSettings Create(float3 halfExtent, float convexRadius, PhysicsMaterial material) => Jolt.PInvoke.BoxShapeSettings_Create_2(halfExtent, convexRadius, material);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Collision/Shape/BoxShape.h#L15">Jolt/Physics/Collision/Shape/BoxShape.h:15</see>
|
||||
/// <br/>
|
||||
/// <c></c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <para>
|
||||
/// The returned handle is borrowed from its owner; don't Dispose it.
|
||||
/// </para>
|
||||
/// </remarks>
|
||||
public RTTI GetRTTI() => Jolt.PInvoke.BoxShapeSettings_GetRTTI(this);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Collision/Shape/BoxShape.h#L15">Jolt/Physics/Collision/Shape/BoxShape.h:15</see>
|
||||
/// <br/>
|
||||
/// <c></c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
public unsafe Ptr CastTo(RTTI rTTI) => Jolt.PInvoke.BoxShapeSettings_CastTo(this, rTTI);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Collision/Shape/BoxShape.h#L26">Jolt/Physics/Collision/Shape/BoxShape.h:26</see>
|
||||
/// <br/>
|
||||
/// <c>virtual ShapeResult Create() const override</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <para>
|
||||
/// See: ShapeSettings
|
||||
/// </para>
|
||||
/// <para>
|
||||
/// Throws InvalidOperationException with Jolt's error message when the operation fails.
|
||||
/// </para>
|
||||
/// </remarks>
|
||||
public Shape CreateShape()
|
||||
{
|
||||
var _handle = Jolt.PInvoke.BoxShapeSettings_CreateShape(this);
|
||||
if (_handle.IsNull()) throw new InvalidOperationException(Jolt.GetLastError());
|
||||
return _handle;
|
||||
}
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// Half the size of the box (including convex radius)
|
||||
/// </para>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Collision/Shape/BoxShape.h#L28">Jolt/Physics/Collision/Shape/BoxShape.h:28</see>
|
||||
/// <br/>
|
||||
/// <c>Vec3 mHalfExtent = Vec3::sZero()</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
public float3 GetHalfExtent() => Jolt.PInvoke.BoxShapeSettings_GetHalfExtent(this);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// Half the size of the box (including convex radius)
|
||||
/// </para>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Collision/Shape/BoxShape.h#L28">Jolt/Physics/Collision/Shape/BoxShape.h:28</see>
|
||||
/// <br/>
|
||||
/// <c>Vec3 mHalfExtent = Vec3::sZero()</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
public void SetHalfExtent(float3 value) => Jolt.PInvoke.BoxShapeSettings_SetHalfExtent(this, value);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Collision/Shape/BoxShape.h#L29">Jolt/Physics/Collision/Shape/BoxShape.h:29</see>
|
||||
/// <br/>
|
||||
/// <c>float mConvexRadius = 0.0f</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
public float GetConvexRadius() => Jolt.PInvoke.BoxShapeSettings_GetConvexRadius(this);
|
||||
/// <summary>
|
||||
/// <para>
|
||||
/// C++:
|
||||
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Collision/Shape/BoxShape.h#L29">Jolt/Physics/Collision/Shape/BoxShape.h:29</see>
|
||||
/// <br/>
|
||||
/// <c>float mConvexRadius = 0.0f</c>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
public void SetConvexRadius(float value) => Jolt.PInvoke.BoxShapeSettings_SetConvexRadius(this, value);
|
||||
public void AddRef() => Jolt.PInvoke.BoxShapeSettings_AddRef(this);
|
||||
public void Release() => Jolt.PInvoke.BoxShapeSettings_Release(this);
|
||||
public uint GetRefCount() => Jolt.PInvoke.BoxShapeSettings_GetRefCount(this);
|
||||
public static implicit operator ConvexShapeSettings(BoxShapeSettings value) => Jolt.PInvoke.BoxShapeSettings_AsConvexShapeSettings(value);
|
||||
public static implicit operator ShapeSettings(BoxShapeSettings value) => Jolt.PInvoke.BoxShapeSettings_AsShapeSettings(value);
|
||||
public void Dispose()
|
||||
{
|
||||
if (IsNull()) return;
|
||||
Release();
|
||||
}
|
||||
}
|
||||
}
|
||||
Some files were not shown because too many files have changed in this diff Show more
Loading…
Reference in a new issue