brutal/brutal.jolt/Brutal.Jolt/Generated/Classes/OffsetCenterOfMassShapeSettings.gen.cs
2026-10-15 14:12:02 +13:00

147 lines
7.1 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#L14">Jolt/Physics/Collision/Shape/OffsetCenterOfMassShape.h:14</see>
/// <br/>
/// <c>class OffsetCenterOfMassShapeSettings final : public DecoratedShapeSettings</c>
/// </para>
/// </summary>
/// <remarks>
/// <para>
/// Class that constructs an OffsetCenterOfMassShape
/// </para>
/// </remarks>
[InteropHandle]
public readonly partial struct OffsetCenterOfMassShapeSettings : IDisposable
{
/// <summary>
/// <para>
/// C++:
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Collision/Shape/OffsetCenterOfMassShape.h#L20">Jolt/Physics/Collision/Shape/OffsetCenterOfMassShape.h:20</see>
/// <br/>
/// <c>OffsetCenterOfMassShapeSettings() = default</c>
/// </para>
/// </summary>
/// <remarks>
/// <para>
/// Constructor
/// </para>
/// </remarks>
public static OffsetCenterOfMassShapeSettings Create() => Jolt.PInvoke.OffsetCenterOfMassShapeSettings_Create();
/// <summary>
/// <para>
/// C++:
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Collision/Shape/OffsetCenterOfMassShape.h#L23">Jolt/Physics/Collision/Shape/OffsetCenterOfMassShape.h:23</see>
/// <br/>
/// <c>OffsetCenterOfMassShapeSettings(Vec3Arg inOffset, const ShapeSettings *inShape)</c>
/// </para>
/// </summary>
/// <remarks>
/// <para>
/// Construct with shape settings, can be serialized.
/// </para>
/// </remarks>
public static OffsetCenterOfMassShapeSettings Create(float3 offset, ShapeSettings shape) => Jolt.PInvoke.OffsetCenterOfMassShapeSettings_Create_2(offset, shape);
/// <summary>
/// <para>
/// C++:
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Collision/Shape/OffsetCenterOfMassShape.h#L26">Jolt/Physics/Collision/Shape/OffsetCenterOfMassShape.h:26</see>
/// <br/>
/// <c>OffsetCenterOfMassShapeSettings(Vec3Arg inOffset, const Shape *inShape)</c>
/// </para>
/// </summary>
/// <remarks>
/// <para>
/// Variant that uses a concrete shape, which means this object cannot be serialized.
/// </para>
/// </remarks>
public static OffsetCenterOfMassShapeSettings Create(float3 offset, Shape shape) => Jolt.PInvoke.OffsetCenterOfMassShapeSettings_Create_3(offset, shape);
/// <summary>
/// <para>
/// C++:
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Collision/Shape/OffsetCenterOfMassShape.h#L16">Jolt/Physics/Collision/Shape/OffsetCenterOfMassShape.h:16</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.OffsetCenterOfMassShapeSettings_GetRTTI(this);
/// <summary>
/// <para>
/// C++:
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Collision/Shape/OffsetCenterOfMassShape.h#L16">Jolt/Physics/Collision/Shape/OffsetCenterOfMassShape.h:16</see>
/// <br/>
/// <c></c>
/// </para>
/// </summary>
public unsafe Ptr CastTo(RTTI rTTI) => Jolt.PInvoke.OffsetCenterOfMassShapeSettings_CastTo(this, rTTI);
/// <summary>
/// <para>
/// C++:
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Collision/Shape/OffsetCenterOfMassShape.h#L29">Jolt/Physics/Collision/Shape/OffsetCenterOfMassShape.h:29</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.OffsetCenterOfMassShapeSettings_CreateShape(this);
if (_handle.IsNull()) throw new InvalidOperationException(Jolt.GetLastError());
return _handle;
}
/// <summary>
/// <para>
/// Offset to be applied to the center of mass of the child shape
/// </para>
/// <para>
/// C++:
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Collision/Shape/OffsetCenterOfMassShape.h#L31">Jolt/Physics/Collision/Shape/OffsetCenterOfMassShape.h:31</see>
/// <br/>
/// <c>Vec3 mOffset</c>
/// </para>
/// </summary>
public float3 GetOffset() => Jolt.PInvoke.OffsetCenterOfMassShapeSettings_GetOffset(this);
/// <summary>
/// <para>
/// Offset to be applied to the center of mass of the child shape
/// </para>
/// <para>
/// C++:
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Collision/Shape/OffsetCenterOfMassShape.h#L31">Jolt/Physics/Collision/Shape/OffsetCenterOfMassShape.h:31</see>
/// <br/>
/// <c>Vec3 mOffset</c>
/// </para>
/// </summary>
public void SetOffset(float3 value) => Jolt.PInvoke.OffsetCenterOfMassShapeSettings_SetOffset(this, value);
public void AddRef() => Jolt.PInvoke.OffsetCenterOfMassShapeSettings_AddRef(this);
public void Release() => Jolt.PInvoke.OffsetCenterOfMassShapeSettings_Release(this);
public uint GetRefCount() => Jolt.PInvoke.OffsetCenterOfMassShapeSettings_GetRefCount(this);
public static implicit operator DecoratedShapeSettings(OffsetCenterOfMassShapeSettings value) => Jolt.PInvoke.OffsetCenterOfMassShapeSettings_AsDecoratedShapeSettings(value);
public static implicit operator ShapeSettings(OffsetCenterOfMassShapeSettings value) => Jolt.PInvoke.OffsetCenterOfMassShapeSettings_AsShapeSettings(value);
public void Dispose()
{
if (IsNull()) return;
Release();
}
}
}