mirror of
https://github.com/ahwootech/BRUTAL.git
synced 2026-11-26 13:08:24 +01:00
323 lines
16 KiB
C#
323 lines
16 KiB
C#
// <auto-generated/>
|
|
// Generated by Brutal.Jolt.Generate; do not edit by hand.
|
|
#nullable enable
|
|
|
|
using Brutal.Interop;
|
|
using Brutal.Numerics;
|
|
namespace Brutal.JoltApi
|
|
{
|
|
/// <summary>
|
|
/// <para>
|
|
/// C++:
|
|
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Constraints/PulleyConstraint.h#L18">Jolt/Physics/Constraints/PulleyConstraint.h:18</see>
|
|
/// <br/>
|
|
/// <c>class PulleyConstraintSettings final : public TwoBodyConstraintSettings</c>
|
|
/// </para>
|
|
/// </summary>
|
|
/// <remarks>
|
|
/// <code>
|
|
/// Pulley constraint settings, used to create a pulley constraint.
|
|
/// A pulley connects two bodies via two fixed world points to each other similar to a distance constraint.
|
|
/// We define Length1 = |BodyPoint1 - FixedPoint1| where Body1 is a point on body 1 in world space and FixedPoint1 a fixed point in world space
|
|
/// Length2 = |BodyPoint2 - FixedPoint2|
|
|
/// The constraint keeps the two line segments constrained so that
|
|
/// MinDistance &lt;= Length1 + Ratio * Length2 &lt;= MaxDistance
|
|
/// </code>
|
|
/// </remarks>
|
|
[InteropHandle]
|
|
public readonly partial struct PulleyConstraintSettings : IDisposable
|
|
{
|
|
public static PulleyConstraintSettings Create() => Jolt.PInvoke.PulleyConstraintSettings_Create();
|
|
/// <summary>
|
|
/// <para>
|
|
/// C++:
|
|
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Constraints/PulleyConstraint.h#L20">Jolt/Physics/Constraints/PulleyConstraint.h:20</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.PulleyConstraintSettings_GetRTTI(this);
|
|
/// <summary>
|
|
/// <para>
|
|
/// C++:
|
|
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Constraints/PulleyConstraint.h#L20">Jolt/Physics/Constraints/PulleyConstraint.h:20</see>
|
|
/// <br/>
|
|
/// <c></c>
|
|
/// </para>
|
|
/// </summary>
|
|
public unsafe Ptr CastTo(RTTI rTTI) => Jolt.PInvoke.PulleyConstraintSettings_CastTo(this, rTTI);
|
|
/// <summary>
|
|
/// <para>
|
|
/// C++:
|
|
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Constraints/PulleyConstraint.h#L24">Jolt/Physics/Constraints/PulleyConstraint.h:24</see>
|
|
/// <br/>
|
|
/// <c>virtual void SaveBinaryState(StreamOut &inStream) const override</c>
|
|
/// </para>
|
|
/// </summary>
|
|
/// <remarks>
|
|
/// <para>
|
|
/// See: ConstraintSettings::SaveBinaryState
|
|
/// </para>
|
|
/// </remarks>
|
|
public void SaveBinaryState(StreamOut stream) => Jolt.PInvoke.PulleyConstraintSettings_SaveBinaryState(this, stream);
|
|
/// <summary>
|
|
/// <para>
|
|
/// C++:
|
|
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Constraints/PulleyConstraint.h#L27">Jolt/Physics/Constraints/PulleyConstraint.h:27</see>
|
|
/// <br/>
|
|
/// <c>virtual TwoBodyConstraint * Create(Body &inBody1, Body &inBody2) const override</c>
|
|
/// </para>
|
|
/// </summary>
|
|
/// <remarks>
|
|
/// <para>
|
|
/// Create an instance of this constraint
|
|
/// </para>
|
|
/// </remarks>
|
|
public TwoBodyConstraint Create(Body body1, Body body2) => Jolt.PInvoke.PulleyConstraintSettings_Create_2(this, body1, body2);
|
|
/// <summary>
|
|
/// <para>
|
|
/// C++:
|
|
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Constraints/PulleyConstraint.h#L30">Jolt/Physics/Constraints/PulleyConstraint.h:30</see>
|
|
/// <br/>
|
|
/// <c>EConstraintSpace mSpace = EConstraintSpace::WorldSpace</c>
|
|
/// </para>
|
|
/// </summary>
|
|
/// <remarks>
|
|
/// <para>
|
|
/// This determines in which space the constraint is setup, specified properties below should be in the
|
|
/// specified space
|
|
/// </para>
|
|
/// </remarks>
|
|
public EConstraintSpace GetSpace() => Jolt.PInvoke.PulleyConstraintSettings_GetSpace(this);
|
|
/// <summary>
|
|
/// <para>
|
|
/// C++:
|
|
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Constraints/PulleyConstraint.h#L30">Jolt/Physics/Constraints/PulleyConstraint.h:30</see>
|
|
/// <br/>
|
|
/// <c>EConstraintSpace mSpace = EConstraintSpace::WorldSpace</c>
|
|
/// </para>
|
|
/// </summary>
|
|
/// <remarks>
|
|
/// <para>
|
|
/// This determines in which space the constraint is setup, specified properties below should be in the
|
|
/// specified space
|
|
/// </para>
|
|
/// </remarks>
|
|
public void SetSpace(EConstraintSpace value) => Jolt.PInvoke.PulleyConstraintSettings_SetSpace(this, value);
|
|
/// <summary>
|
|
/// <para>
|
|
/// C++:
|
|
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Constraints/PulleyConstraint.h#L33">Jolt/Physics/Constraints/PulleyConstraint.h:33</see>
|
|
/// <br/>
|
|
/// <c>RVec3 mBodyPoint1 = RVec3::sZero()</c>
|
|
/// </para>
|
|
/// </summary>
|
|
/// <remarks>
|
|
/// <para>
|
|
/// Body 1 constraint attachment point (space determined by mSpace).
|
|
/// </para>
|
|
/// </remarks>
|
|
public float3 GetBodyPoint1() => Jolt.PInvoke.PulleyConstraintSettings_GetBodyPoint1(this);
|
|
/// <summary>
|
|
/// <para>
|
|
/// C++:
|
|
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Constraints/PulleyConstraint.h#L33">Jolt/Physics/Constraints/PulleyConstraint.h:33</see>
|
|
/// <br/>
|
|
/// <c>RVec3 mBodyPoint1 = RVec3::sZero()</c>
|
|
/// </para>
|
|
/// </summary>
|
|
/// <remarks>
|
|
/// <para>
|
|
/// Body 1 constraint attachment point (space determined by mSpace).
|
|
/// </para>
|
|
/// </remarks>
|
|
public void SetBodyPoint1(float3 value) => Jolt.PInvoke.PulleyConstraintSettings_SetBodyPoint1(this, value);
|
|
/// <summary>
|
|
/// <para>
|
|
/// C++:
|
|
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Constraints/PulleyConstraint.h#L36">Jolt/Physics/Constraints/PulleyConstraint.h:36</see>
|
|
/// <br/>
|
|
/// <c>RVec3 mFixedPoint1 = RVec3::sZero()</c>
|
|
/// </para>
|
|
/// </summary>
|
|
/// <remarks>
|
|
/// <para>
|
|
/// Fixed world point to which body 1 is connected (always world space)
|
|
/// </para>
|
|
/// </remarks>
|
|
public float3 GetFixedPoint1() => Jolt.PInvoke.PulleyConstraintSettings_GetFixedPoint1(this);
|
|
/// <summary>
|
|
/// <para>
|
|
/// C++:
|
|
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Constraints/PulleyConstraint.h#L36">Jolt/Physics/Constraints/PulleyConstraint.h:36</see>
|
|
/// <br/>
|
|
/// <c>RVec3 mFixedPoint1 = RVec3::sZero()</c>
|
|
/// </para>
|
|
/// </summary>
|
|
/// <remarks>
|
|
/// <para>
|
|
/// Fixed world point to which body 1 is connected (always world space)
|
|
/// </para>
|
|
/// </remarks>
|
|
public void SetFixedPoint1(float3 value) => Jolt.PInvoke.PulleyConstraintSettings_SetFixedPoint1(this, value);
|
|
/// <summary>
|
|
/// <para>
|
|
/// C++:
|
|
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Constraints/PulleyConstraint.h#L39">Jolt/Physics/Constraints/PulleyConstraint.h:39</see>
|
|
/// <br/>
|
|
/// <c>RVec3 mBodyPoint2 = RVec3::sZero()</c>
|
|
/// </para>
|
|
/// </summary>
|
|
/// <remarks>
|
|
/// <para>
|
|
/// Body 2 constraint attachment point (space determined by mSpace)
|
|
/// </para>
|
|
/// </remarks>
|
|
public float3 GetBodyPoint2() => Jolt.PInvoke.PulleyConstraintSettings_GetBodyPoint2(this);
|
|
/// <summary>
|
|
/// <para>
|
|
/// C++:
|
|
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Constraints/PulleyConstraint.h#L39">Jolt/Physics/Constraints/PulleyConstraint.h:39</see>
|
|
/// <br/>
|
|
/// <c>RVec3 mBodyPoint2 = RVec3::sZero()</c>
|
|
/// </para>
|
|
/// </summary>
|
|
/// <remarks>
|
|
/// <para>
|
|
/// Body 2 constraint attachment point (space determined by mSpace)
|
|
/// </para>
|
|
/// </remarks>
|
|
public void SetBodyPoint2(float3 value) => Jolt.PInvoke.PulleyConstraintSettings_SetBodyPoint2(this, value);
|
|
/// <summary>
|
|
/// <para>
|
|
/// C++:
|
|
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Constraints/PulleyConstraint.h#L42">Jolt/Physics/Constraints/PulleyConstraint.h:42</see>
|
|
/// <br/>
|
|
/// <c>RVec3 mFixedPoint2 = RVec3::sZero()</c>
|
|
/// </para>
|
|
/// </summary>
|
|
/// <remarks>
|
|
/// <para>
|
|
/// Fixed world point to which body 2 is connected (always world space)
|
|
/// </para>
|
|
/// </remarks>
|
|
public float3 GetFixedPoint2() => Jolt.PInvoke.PulleyConstraintSettings_GetFixedPoint2(this);
|
|
/// <summary>
|
|
/// <para>
|
|
/// C++:
|
|
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Constraints/PulleyConstraint.h#L42">Jolt/Physics/Constraints/PulleyConstraint.h:42</see>
|
|
/// <br/>
|
|
/// <c>RVec3 mFixedPoint2 = RVec3::sZero()</c>
|
|
/// </para>
|
|
/// </summary>
|
|
/// <remarks>
|
|
/// <para>
|
|
/// Fixed world point to which body 2 is connected (always world space)
|
|
/// </para>
|
|
/// </remarks>
|
|
public void SetFixedPoint2(float3 value) => Jolt.PInvoke.PulleyConstraintSettings_SetFixedPoint2(this, value);
|
|
/// <summary>
|
|
/// <para>
|
|
/// C++:
|
|
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Constraints/PulleyConstraint.h#L45">Jolt/Physics/Constraints/PulleyConstraint.h:45</see>
|
|
/// <br/>
|
|
/// <c>float mRatio = 1.0f</c>
|
|
/// </para>
|
|
/// </summary>
|
|
/// <remarks>
|
|
/// <para>
|
|
/// Ratio between the two line segments (see formula above), can be used to create a block and tackle
|
|
/// </para>
|
|
/// </remarks>
|
|
public float GetRatio() => Jolt.PInvoke.PulleyConstraintSettings_GetRatio(this);
|
|
/// <summary>
|
|
/// <para>
|
|
/// C++:
|
|
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Constraints/PulleyConstraint.h#L45">Jolt/Physics/Constraints/PulleyConstraint.h:45</see>
|
|
/// <br/>
|
|
/// <c>float mRatio = 1.0f</c>
|
|
/// </para>
|
|
/// </summary>
|
|
/// <remarks>
|
|
/// <para>
|
|
/// Ratio between the two line segments (see formula above), can be used to create a block and tackle
|
|
/// </para>
|
|
/// </remarks>
|
|
public void SetRatio(float value) => Jolt.PInvoke.PulleyConstraintSettings_SetRatio(this, value);
|
|
/// <summary>
|
|
/// <para>
|
|
/// C++:
|
|
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Constraints/PulleyConstraint.h#L48">Jolt/Physics/Constraints/PulleyConstraint.h:48</see>
|
|
/// <br/>
|
|
/// <c>float mMinLength = 0.0f</c>
|
|
/// </para>
|
|
/// </summary>
|
|
/// <remarks>
|
|
/// <para>
|
|
/// The minimum length of the line segments (see formula above), use -1 to calculate the length based on the
|
|
/// positions of the objects when the constraint is created.
|
|
/// </para>
|
|
/// </remarks>
|
|
public float GetMinLength() => Jolt.PInvoke.PulleyConstraintSettings_GetMinLength(this);
|
|
/// <summary>
|
|
/// <para>
|
|
/// C++:
|
|
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Constraints/PulleyConstraint.h#L48">Jolt/Physics/Constraints/PulleyConstraint.h:48</see>
|
|
/// <br/>
|
|
/// <c>float mMinLength = 0.0f</c>
|
|
/// </para>
|
|
/// </summary>
|
|
/// <remarks>
|
|
/// <para>
|
|
/// The minimum length of the line segments (see formula above), use -1 to calculate the length based on the
|
|
/// positions of the objects when the constraint is created.
|
|
/// </para>
|
|
/// </remarks>
|
|
public void SetMinLength(float value) => Jolt.PInvoke.PulleyConstraintSettings_SetMinLength(this, value);
|
|
/// <summary>
|
|
/// <para>
|
|
/// C++:
|
|
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Constraints/PulleyConstraint.h#L51">Jolt/Physics/Constraints/PulleyConstraint.h:51</see>
|
|
/// <br/>
|
|
/// <c>float mMaxLength = -1.0f</c>
|
|
/// </para>
|
|
/// </summary>
|
|
/// <remarks>
|
|
/// <para>
|
|
/// The maximum length of the line segments (see formula above), use -1 to calculate the length based on the
|
|
/// positions of the objects when the constraint is created.
|
|
/// </para>
|
|
/// </remarks>
|
|
public float GetMaxLength() => Jolt.PInvoke.PulleyConstraintSettings_GetMaxLength(this);
|
|
/// <summary>
|
|
/// <para>
|
|
/// C++:
|
|
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Constraints/PulleyConstraint.h#L51">Jolt/Physics/Constraints/PulleyConstraint.h:51</see>
|
|
/// <br/>
|
|
/// <c>float mMaxLength = -1.0f</c>
|
|
/// </para>
|
|
/// </summary>
|
|
/// <remarks>
|
|
/// <para>
|
|
/// The maximum length of the line segments (see formula above), use -1 to calculate the length based on the
|
|
/// positions of the objects when the constraint is created.
|
|
/// </para>
|
|
/// </remarks>
|
|
public void SetMaxLength(float value) => Jolt.PInvoke.PulleyConstraintSettings_SetMaxLength(this, value);
|
|
public void AddRef() => Jolt.PInvoke.PulleyConstraintSettings_AddRef(this);
|
|
public void Release() => Jolt.PInvoke.PulleyConstraintSettings_Release(this);
|
|
public uint GetRefCount() => Jolt.PInvoke.PulleyConstraintSettings_GetRefCount(this);
|
|
public static implicit operator TwoBodyConstraintSettings(PulleyConstraintSettings value) => Jolt.PInvoke.PulleyConstraintSettings_AsTwoBodyConstraintSettings(value);
|
|
public static implicit operator ConstraintSettings(PulleyConstraintSettings value) => Jolt.PInvoke.PulleyConstraintSettings_AsConstraintSettings(value);
|
|
public void Dispose()
|
|
{
|
|
if (IsNull()) return;
|
|
Release();
|
|
}
|
|
}
|
|
}
|