//
// Generated by Brutal.Jolt.Generate; do not edit by hand.
#nullable enable
using System.Runtime.CompilerServices;
using Brutal.Interop;
using Brutal.Numerics;
namespace Brutal.JoltApi
{
///
///
/// Class that constructs an OffsetCenterOfMassShape
///
///
/// C++:
/// Jolt/Physics/Collision/Shape/OffsetCenterOfMassShape.h:14
///
/// class OffsetCenterOfMassShapeSettings final : public DecoratedShapeSettings
///
///
[InteropHandle]
public readonly partial struct OffsetCenterOfMassShapeSettings : IDisposable
{
///
///
/// Constructor
///
///
/// C++:
/// Jolt/Physics/Collision/Shape/OffsetCenterOfMassShape.h:20
///
/// OffsetCenterOfMassShapeSettings() = default
///
///
public static OffsetCenterOfMassShapeSettings Create() => Jolt.PInvoke.OffsetCenterOfMassShapeSettings_Create();
///
///
/// Construct with shape settings, can be serialized.
///
///
/// C++:
/// Jolt/Physics/Collision/Shape/OffsetCenterOfMassShape.h:23
///
/// OffsetCenterOfMassShapeSettings(Vec3Arg inOffset, const ShapeSettings *inShape)
///
///
public static OffsetCenterOfMassShapeSettings Create(float3 offset, ShapeSettings shape) =>
Jolt.PInvoke.OffsetCenterOfMassShapeSettings_Create_2(offset, shape);
///
///
/// Variant that uses a concrete shape, which means this object cannot be serialized.
///
///
/// C++:
/// Jolt/Physics/Collision/Shape/OffsetCenterOfMassShape.h:26
///
/// OffsetCenterOfMassShapeSettings(Vec3Arg inOffset, const Shape *inShape)
///
///
public static OffsetCenterOfMassShapeSettings Create(float3 offset, Shape shape) =>
Jolt.PInvoke.OffsetCenterOfMassShapeSettings_Create_3(offset, shape);
///
public RTTI GetRTTI() => ((ShapeSettings)this).GetRTTI();
///
public unsafe Ptr CastTo(RTTI rtti) => ((ShapeSettings)this).CastTo(rtti);
///
public Shape CreateShape() => ((ShapeSettings)this).CreateShape();
///
///
/// Offset to be applied to the center of mass of the child shape
///
///
/// C++:
/// Jolt/Physics/Collision/Shape/OffsetCenterOfMassShape.h:31
///
/// Vec3 mOffset
///
///
public float3 GetOffset() => Jolt.PInvoke.OffsetCenterOfMassShapeSettings_GetOffset(this);
///
///
/// Offset to be applied to the center of mass of the child shape
///
///
/// C++:
/// Jolt/Physics/Collision/Shape/OffsetCenterOfMassShape.h:31
///
/// Vec3 mOffset
///
///
public void SetOffset(float3 value) => Jolt.PInvoke.OffsetCenterOfMassShapeSettings_SetOffset(this, value);
public void AddRef() => ((ShapeSettings)this).AddRef();
public void Release() => ((ShapeSettings)this).Release();
public uint GetRefCount() => ((ShapeSettings)this).GetRefCount();
public static implicit operator DecoratedShapeSettings(OffsetCenterOfMassShapeSettings value) =>
Unsafe.BitCast(value);
public static implicit operator ShapeSettings(OffsetCenterOfMassShapeSettings value) =>
Unsafe.BitCast(value);
public void Dispose()
{
if (IsNull())
return;
Release();
}
///
public ShapeSettings GetInnerShape() => ((DecoratedShapeSettings)this).GetInnerShape();
///
public void SetInnerShape(ShapeSettings value) => ((DecoratedShapeSettings)this).SetInnerShape(value);
///
public Shape GetInnerShapePtr() => ((DecoratedShapeSettings)this).GetInnerShapePtr();
///
public void SetInnerShapePtr(Shape value) => ((DecoratedShapeSettings)this).SetInnerShapePtr(value);
///
public void ClearCachedResult() => ((ShapeSettings)this).ClearCachedResult();
///
public ulong GetUserData() => ((ShapeSettings)this).GetUserData();
///
public void SetUserData(ulong value) => ((ShapeSettings)this).SetUserData(value);
}
}