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

106 lines
4.9 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/StaticCompoundShape.h#L17">Jolt/Physics/Collision/Shape/StaticCompoundShape.h:17</see>
/// <br/>
/// <c>class StaticCompoundShapeSettings final : public CompoundShapeSettings</c>
/// </para>
/// </summary>
/// <remarks>
/// <para>
/// Class that constructs a StaticCompoundShape. Note that if you only want a compound of 1 shape, use a
/// RotatedTranslatedShape instead.
/// </para>
/// </remarks>
[InteropHandle]
public readonly partial struct StaticCompoundShapeSettings : IDisposable
{
public static StaticCompoundShapeSettings Create() => Jolt.PInvoke.StaticCompoundShapeSettings_Create();
/// <summary>
/// <para>
/// C++:
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Collision/Shape/StaticCompoundShape.h#L19">Jolt/Physics/Collision/Shape/StaticCompoundShape.h:19</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.StaticCompoundShapeSettings_GetRTTI(this);
/// <summary>
/// <para>
/// C++:
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Collision/Shape/StaticCompoundShape.h#L19">Jolt/Physics/Collision/Shape/StaticCompoundShape.h:19</see>
/// <br/>
/// <c></c>
/// </para>
/// </summary>
public unsafe Ptr CastTo(RTTI rTTI) => Jolt.PInvoke.StaticCompoundShapeSettings_CastTo(this, rTTI);
/// <summary>
/// <para>
/// C++:
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Collision/Shape/StaticCompoundShape.h#L23">Jolt/Physics/Collision/Shape/StaticCompoundShape.h:23</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.StaticCompoundShapeSettings_CreateShape(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/Collision/Shape/StaticCompoundShape.h#L26">Jolt/Physics/Collision/Shape/StaticCompoundShape.h:26</see>
/// <br/>
/// <c>ShapeResult Create(TempAllocator &amp;inTempAllocator) const</c>
/// </para>
/// </summary>
/// <remarks>
/// <para>
/// Specialization of Create() function that allows specifying a temp allocator to avoid temporary memory
/// allocations on the heap
/// </para>
/// <para>
/// Throws InvalidOperationException with Jolt's error message when the operation fails.
/// </para>
/// </remarks>
public Shape CreateShape(TempAllocator tempAllocator)
{
var _handle = Jolt.PInvoke.StaticCompoundShapeSettings_CreateShape_2(this, tempAllocator);
if (_handle.IsNull()) throw new InvalidOperationException(Jolt.GetLastError());
return _handle;
}
public void AddRef() => Jolt.PInvoke.StaticCompoundShapeSettings_AddRef(this);
public void Release() => Jolt.PInvoke.StaticCompoundShapeSettings_Release(this);
public uint GetRefCount() => Jolt.PInvoke.StaticCompoundShapeSettings_GetRefCount(this);
public static implicit operator CompoundShapeSettings(StaticCompoundShapeSettings value) => Jolt.PInvoke.StaticCompoundShapeSettings_AsCompoundShapeSettings(value);
public static implicit operator ShapeSettings(StaticCompoundShapeSettings value) => Jolt.PInvoke.StaticCompoundShapeSettings_AsShapeSettings(value);
public void Dispose()
{
if (IsNull()) return;
Release();
}
}
}