mirror of
https://github.com/ahwootech/BRUTAL.git
synced 2026-11-26 13:08:24 +01:00
242 lines
13 KiB
C#
242 lines
13 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/Collision/Shape/OffsetCenterOfMassShape.h#L35">Jolt/Physics/Collision/Shape/OffsetCenterOfMassShape.h:35</see>
|
|
/// <br/>
|
|
/// <c>class OffsetCenterOfMassShape final : public DecoratedShape</c>
|
|
/// </para>
|
|
/// </summary>
|
|
/// <remarks>
|
|
/// <para>
|
|
/// This shape will shift the center of mass of a child shape, it can e.g. be used to lower the center of mass
|
|
/// of an unstable object like a boat to make it stable
|
|
/// </para>
|
|
/// </remarks>
|
|
[InteropHandle]
|
|
public readonly partial struct OffsetCenterOfMassShape : IDisposable
|
|
{
|
|
/// <summary>
|
|
/// <para>
|
|
/// C++:
|
|
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Collision/Shape/OffsetCenterOfMassShape.h#L41">Jolt/Physics/Collision/Shape/OffsetCenterOfMassShape.h:41</see>
|
|
/// <br/>
|
|
/// <c>OffsetCenterOfMassShape()</c>
|
|
/// </para>
|
|
/// </summary>
|
|
/// <remarks>
|
|
/// <para>
|
|
/// Constructor
|
|
/// </para>
|
|
/// </remarks>
|
|
public static OffsetCenterOfMassShape Create() => Jolt.PInvoke.OffsetCenterOfMassShape_Create();
|
|
/// <summary>
|
|
/// <para>
|
|
/// C++:
|
|
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Collision/Shape/OffsetCenterOfMassShape.h#L43">Jolt/Physics/Collision/Shape/OffsetCenterOfMassShape.h:43</see>
|
|
/// <br/>
|
|
/// <c>OffsetCenterOfMassShape(const Shape *inShape, Vec3Arg inOffset)</c>
|
|
/// </para>
|
|
/// </summary>
|
|
public static OffsetCenterOfMassShape Create(Shape shape, float3 offset) => Jolt.PInvoke.OffsetCenterOfMassShape_Create_2(shape, offset);
|
|
/// <summary>
|
|
/// <para>
|
|
/// C++:
|
|
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Collision/Shape/OffsetCenterOfMassShape.h#L46">Jolt/Physics/Collision/Shape/OffsetCenterOfMassShape.h:46</see>
|
|
/// <br/>
|
|
/// <c>Vec3 GetOffset() const</c>
|
|
/// </para>
|
|
/// </summary>
|
|
/// <remarks>
|
|
/// <para>
|
|
/// Access the offset that is applied to the center of mass
|
|
/// </para>
|
|
/// </remarks>
|
|
public float3 GetOffset() => Jolt.PInvoke.OffsetCenterOfMassShape_GetOffset(this);
|
|
/// <summary>
|
|
/// <para>
|
|
/// C++:
|
|
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Collision/Shape/OffsetCenterOfMassShape.h#L49">Jolt/Physics/Collision/Shape/OffsetCenterOfMassShape.h:49</see>
|
|
/// <br/>
|
|
/// <c>virtual Vec3 GetCenterOfMass() const override</c>
|
|
/// </para>
|
|
/// </summary>
|
|
/// <remarks>
|
|
/// <para>
|
|
/// See Shape::GetCenterOfMass
|
|
/// </para>
|
|
/// </remarks>
|
|
public float3 GetCenterOfMass() => Jolt.PInvoke.OffsetCenterOfMassShape_GetCenterOfMass(this);
|
|
/// <summary>
|
|
/// <para>
|
|
/// C++:
|
|
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Collision/Shape/OffsetCenterOfMassShape.h#L59">Jolt/Physics/Collision/Shape/OffsetCenterOfMassShape.h:59</see>
|
|
/// <br/>
|
|
/// <c>virtual float GetInnerRadius() const override</c>
|
|
/// </para>
|
|
/// </summary>
|
|
/// <remarks>
|
|
/// <para>
|
|
/// See Shape::GetInnerRadius
|
|
/// </para>
|
|
/// </remarks>
|
|
public float GetInnerRadius() => Jolt.PInvoke.OffsetCenterOfMassShape_GetInnerRadius(this);
|
|
/// <summary>
|
|
/// <para>
|
|
/// C++:
|
|
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Collision/Shape/OffsetCenterOfMassShape.h#L73">Jolt/Physics/Collision/Shape/OffsetCenterOfMassShape.h:73</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.OffsetCenterOfMassShape_GetSurfaceNormal(this, subShapeID, localSurfacePosition);
|
|
/// <summary>
|
|
/// <para>
|
|
/// C++:
|
|
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Collision/Shape/OffsetCenterOfMassShape.h#L79">Jolt/Physics/Collision/Shape/OffsetCenterOfMassShape.h:79</see>
|
|
/// <br/>
|
|
/// <c>virtual void GetSubmergedVolume(Mat44Arg inCenterOfMassTransform, Vec3Arg inScale, const Plane &inSurface, float &outTotalVolume, float &outSubmergedVolume, Vec3 &outCenterOfBuoyancy JPH_IF_DEBUG_RENDERER(, RVec3Arg inBaseOffset)) const override</c>
|
|
/// </para>
|
|
/// </summary>
|
|
/// <remarks>
|
|
/// <para>
|
|
/// See Shape::GetSubmergedVolume
|
|
/// </para>
|
|
/// </remarks>
|
|
public void GetSubmergedVolume(float4x4 centerOfMassTransform, float3 scale, Plane surface, out float totalVolume, out float submergedVolume, out float3 centerOfBuoyancy, float3 baseOffset) => Jolt.PInvoke.OffsetCenterOfMassShape_GetSubmergedVolume(this, centerOfMassTransform, scale, surface, out totalVolume, out submergedVolume, out centerOfBuoyancy, baseOffset);
|
|
/// <summary>
|
|
/// <para>
|
|
/// C++:
|
|
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Collision/Shape/OffsetCenterOfMassShape.h#L83">Jolt/Physics/Collision/Shape/OffsetCenterOfMassShape.h:83</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.OffsetCenterOfMassShape_Draw(this, renderer, centerOfMassTransform, scale, color, useMaterialColors, drawWireframe);
|
|
/// <summary>
|
|
/// <para>
|
|
/// C++:
|
|
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Collision/Shape/OffsetCenterOfMassShape.h#L86">Jolt/Physics/Collision/Shape/OffsetCenterOfMassShape.h:86</see>
|
|
/// <br/>
|
|
/// <c>virtual void DrawGetSupportFunction(DebugRenderer *inRenderer, RMat44Arg inCenterOfMassTransform, Vec3Arg inScale, ColorArg inColor, bool inDrawSupportDirection) const override</c>
|
|
/// </para>
|
|
/// </summary>
|
|
/// <remarks>
|
|
/// <para>
|
|
/// See Shape::DrawGetSupportFunction
|
|
/// </para>
|
|
/// </remarks>
|
|
public void DrawGetSupportFunction(DebugRenderer renderer, float4x4 centerOfMassTransform, float3 scale, uint color, bool drawSupportDirection) => Jolt.PInvoke.OffsetCenterOfMassShape_DrawGetSupportFunction(this, renderer, centerOfMassTransform, scale, color, drawSupportDirection);
|
|
/// <summary>
|
|
/// <para>
|
|
/// C++:
|
|
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Collision/Shape/OffsetCenterOfMassShape.h#L89">Jolt/Physics/Collision/Shape/OffsetCenterOfMassShape.h:89</see>
|
|
/// <br/>
|
|
/// <c>virtual void DrawGetSupportingFace(DebugRenderer *inRenderer, RMat44Arg inCenterOfMassTransform, Vec3Arg inScale) const override</c>
|
|
/// </para>
|
|
/// </summary>
|
|
/// <remarks>
|
|
/// <para>
|
|
/// See Shape::DrawGetSupportingFace
|
|
/// </para>
|
|
/// </remarks>
|
|
public void DrawGetSupportingFace(DebugRenderer renderer, float4x4 centerOfMassTransform, float3 scale) => Jolt.PInvoke.OffsetCenterOfMassShape_DrawGetSupportingFace(this, renderer, centerOfMassTransform, scale);
|
|
/// <summary>
|
|
/// <para>
|
|
/// C++:
|
|
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Collision/Shape/OffsetCenterOfMassShape.h#L100">Jolt/Physics/Collision/Shape/OffsetCenterOfMassShape.h:100</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.OffsetCenterOfMassShape_CollideSoftBodyVertices(this, centerOfMassTransform, scale, vertices, numVertices, collidingShapeIndex);
|
|
/// <summary>
|
|
/// <para>
|
|
/// C++:
|
|
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Collision/Shape/OffsetCenterOfMassShape.h#L109">Jolt/Physics/Collision/Shape/OffsetCenterOfMassShape.h:109</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.OffsetCenterOfMassShape_GetTrianglesStart(this, ref context, box, positionCOM, rotation, scale);
|
|
/// <summary>
|
|
/// <para>
|
|
/// C++:
|
|
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Collision/Shape/OffsetCenterOfMassShape.h#L115">Jolt/Physics/Collision/Shape/OffsetCenterOfMassShape.h:115</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.OffsetCenterOfMassShape_SaveBinaryState(this, stream);
|
|
/// <summary>
|
|
/// <para>
|
|
/// C++:
|
|
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Collision/Shape/OffsetCenterOfMassShape.h#L121">Jolt/Physics/Collision/Shape/OffsetCenterOfMassShape.h:121</see>
|
|
/// <br/>
|
|
/// <c>virtual float GetVolume() const override</c>
|
|
/// </para>
|
|
/// </summary>
|
|
/// <remarks>
|
|
/// <para>
|
|
/// See Shape::GetVolume
|
|
/// </para>
|
|
/// </remarks>
|
|
public float GetVolume() => Jolt.PInvoke.OffsetCenterOfMassShape_GetVolume(this);
|
|
/// <summary>
|
|
/// <para>
|
|
/// C++:
|
|
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Collision/Shape/OffsetCenterOfMassShape.h#L124">Jolt/Physics/Collision/Shape/OffsetCenterOfMassShape.h:124</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.OffsetCenterOfMassShape_sRegister();
|
|
public void AddRef() => Jolt.PInvoke.OffsetCenterOfMassShape_AddRef(this);
|
|
public void Release() => Jolt.PInvoke.OffsetCenterOfMassShape_Release(this);
|
|
public uint GetRefCount() => Jolt.PInvoke.OffsetCenterOfMassShape_GetRefCount(this);
|
|
public static implicit operator DecoratedShape(OffsetCenterOfMassShape value) => Jolt.PInvoke.OffsetCenterOfMassShape_AsDecoratedShape(value);
|
|
public static implicit operator Shape(OffsetCenterOfMassShape value) => Jolt.PInvoke.OffsetCenterOfMassShape_AsShape(value);
|
|
public void Dispose()
|
|
{
|
|
if (IsNull()) return;
|
|
Release();
|
|
}
|
|
}
|
|
}
|