mirror of
https://github.com/ahwootech/BRUTAL.git
synced 2026-11-26 13:08:24 +01:00
247 lines
12 KiB
C#
247 lines
12 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/CylinderShape.h#L34">Jolt/Physics/Collision/Shape/CylinderShape.h:34</see>
|
|
/// <br/>
|
|
/// <c>class CylinderShape final : public ConvexShape</c>
|
|
/// </para>
|
|
/// </summary>
|
|
/// <remarks>
|
|
/// <para>
|
|
/// A cylinder
|
|
/// </para>
|
|
/// </remarks>
|
|
[InteropHandle]
|
|
public readonly partial struct CylinderShape : IDisposable
|
|
{
|
|
/// <summary>
|
|
/// <para>
|
|
/// C++:
|
|
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Collision/Shape/CylinderShape.h#L40">Jolt/Physics/Collision/Shape/CylinderShape.h:40</see>
|
|
/// <br/>
|
|
/// <c>CylinderShape()</c>
|
|
/// </para>
|
|
/// </summary>
|
|
/// <remarks>
|
|
/// <para>
|
|
/// Constructor
|
|
/// </para>
|
|
/// </remarks>
|
|
public static CylinderShape Create() => Jolt.PInvoke.CylinderShape_Create();
|
|
/// <summary>
|
|
/// <para>
|
|
/// C++:
|
|
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Collision/Shape/CylinderShape.h#L45">Jolt/Physics/Collision/Shape/CylinderShape.h:45</see>
|
|
/// <br/>
|
|
/// <c>CylinderShape(float inHalfHeight, float inRadius, float inConvexRadius = cDefaultConvexRadius, const PhysicsMaterial *inMaterial = nullptr)</c>
|
|
/// </para>
|
|
/// </summary>
|
|
/// <remarks>
|
|
/// <code>
|
|
/// Create a shape centered around the origin with one top at (0, -inHalfHeight, 0) and the other at (0, inHalfHeight, 0) and radius inRadius.
|
|
/// (internally the convex radius will be subtracted from the cylinder the total cylinder will not grow with the convex radius, but the edges of the cylinder will be rounded a bit).
|
|
/// </code>
|
|
/// </remarks>
|
|
public static CylinderShape Create(float halfHeight, float radius, float convexRadius, PhysicsMaterial material) => Jolt.PInvoke.CylinderShape_Create_2(halfHeight, radius, convexRadius, material);
|
|
/// <summary>
|
|
/// <para>
|
|
/// C++:
|
|
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Collision/Shape/CylinderShape.h#L48">Jolt/Physics/Collision/Shape/CylinderShape.h:48</see>
|
|
/// <br/>
|
|
/// <c>float GetHalfHeight() const</c>
|
|
/// </para>
|
|
/// </summary>
|
|
/// <remarks>
|
|
/// <para>
|
|
/// Get half height of cylinder
|
|
/// </para>
|
|
/// </remarks>
|
|
public float GetHalfHeight() => Jolt.PInvoke.CylinderShape_GetHalfHeight(this);
|
|
/// <summary>
|
|
/// <para>
|
|
/// C++:
|
|
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Collision/Shape/CylinderShape.h#L51">Jolt/Physics/Collision/Shape/CylinderShape.h:51</see>
|
|
/// <br/>
|
|
/// <c>float GetRadius() const</c>
|
|
/// </para>
|
|
/// </summary>
|
|
/// <remarks>
|
|
/// <para>
|
|
/// Get radius of cylinder
|
|
/// </para>
|
|
/// </remarks>
|
|
public float GetRadius() => Jolt.PInvoke.CylinderShape_GetRadius(this);
|
|
/// <summary>
|
|
/// <para>
|
|
/// C++:
|
|
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Collision/Shape/CylinderShape.h#L57">Jolt/Physics/Collision/Shape/CylinderShape.h:57</see>
|
|
/// <br/>
|
|
/// <c>virtual float GetInnerRadius() const override</c>
|
|
/// </para>
|
|
/// </summary>
|
|
/// <remarks>
|
|
/// <para>
|
|
/// See Shape::GetInnerRadius
|
|
/// </para>
|
|
/// </remarks>
|
|
public float GetInnerRadius() => Jolt.PInvoke.CylinderShape_GetInnerRadius(this);
|
|
/// <summary>
|
|
/// <para>
|
|
/// C++:
|
|
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Collision/Shape/CylinderShape.h#L63">Jolt/Physics/Collision/Shape/CylinderShape.h:63</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.CylinderShape_GetSurfaceNormal(this, subShapeID, localSurfacePosition);
|
|
/// <summary>
|
|
/// <para>
|
|
/// C++:
|
|
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Collision/Shape/CylinderShape.h#L73">Jolt/Physics/Collision/Shape/CylinderShape.h:73</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.CylinderShape_Draw(this, renderer, centerOfMassTransform, scale, color, useMaterialColors, drawWireframe);
|
|
/// <summary>
|
|
/// <para>
|
|
/// C++:
|
|
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Collision/Shape/CylinderShape.h#L84">Jolt/Physics/Collision/Shape/CylinderShape.h:84</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.CylinderShape_CollideSoftBodyVertices(this, centerOfMassTransform, scale, vertices, numVertices, collidingShapeIndex);
|
|
/// <summary>
|
|
/// <para>
|
|
/// C++:
|
|
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Collision/Shape/CylinderShape.h#L87">Jolt/Physics/Collision/Shape/CylinderShape.h:87</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.CylinderShape_GetTrianglesStart(this, ref context, box, positionCOM, rotation, scale);
|
|
/// <summary>
|
|
/// <para>
|
|
/// C++:
|
|
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Collision/Shape/CylinderShape.h#L93">Jolt/Physics/Collision/Shape/CylinderShape.h:93</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.CylinderShape_SaveBinaryState(this, stream);
|
|
/// <summary>
|
|
/// <para>
|
|
/// C++:
|
|
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Collision/Shape/CylinderShape.h#L99">Jolt/Physics/Collision/Shape/CylinderShape.h:99</see>
|
|
/// <br/>
|
|
/// <c>virtual float GetVolume() const override</c>
|
|
/// </para>
|
|
/// </summary>
|
|
/// <remarks>
|
|
/// <para>
|
|
/// See Shape::GetVolume
|
|
/// </para>
|
|
/// </remarks>
|
|
public float GetVolume() => Jolt.PInvoke.CylinderShape_GetVolume(this);
|
|
/// <summary>
|
|
/// <para>
|
|
/// C++:
|
|
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Collision/Shape/CylinderShape.h#L102">Jolt/Physics/Collision/Shape/CylinderShape.h:102</see>
|
|
/// <br/>
|
|
/// <c>float GetConvexRadius() const</c>
|
|
/// </para>
|
|
/// </summary>
|
|
/// <remarks>
|
|
/// <para>
|
|
/// Get the convex radius of this cylinder
|
|
/// </para>
|
|
/// </remarks>
|
|
public float GetConvexRadius() => Jolt.PInvoke.CylinderShape_GetConvexRadius(this);
|
|
/// <summary>
|
|
/// <para>
|
|
/// C++:
|
|
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Collision/Shape/CylinderShape.h#L105">Jolt/Physics/Collision/Shape/CylinderShape.h:105</see>
|
|
/// <br/>
|
|
/// <c>virtual bool IsValidScale(Vec3Arg inScale) const override</c>
|
|
/// </para>
|
|
/// </summary>
|
|
/// <remarks>
|
|
/// <para>
|
|
/// See Shape::IsValidScale
|
|
/// </para>
|
|
/// </remarks>
|
|
public bool IsValidScale(float3 scale) => Jolt.PInvoke.CylinderShape_IsValidScale(this, scale);
|
|
/// <summary>
|
|
/// <para>
|
|
/// C++:
|
|
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Collision/Shape/CylinderShape.h#L108">Jolt/Physics/Collision/Shape/CylinderShape.h:108</see>
|
|
/// <br/>
|
|
/// <c>virtual Vec3 MakeScaleValid(Vec3Arg inScale) const override</c>
|
|
/// </para>
|
|
/// </summary>
|
|
/// <remarks>
|
|
/// <para>
|
|
/// See Shape::MakeScaleValid
|
|
/// </para>
|
|
/// </remarks>
|
|
public float3 MakeScaleValid(float3 scale) => Jolt.PInvoke.CylinderShape_MakeScaleValid(this, scale);
|
|
/// <summary>
|
|
/// <para>
|
|
/// C++:
|
|
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Collision/Shape/CylinderShape.h#L111">Jolt/Physics/Collision/Shape/CylinderShape.h:111</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.CylinderShape_sRegister();
|
|
public void AddRef() => Jolt.PInvoke.CylinderShape_AddRef(this);
|
|
public void Release() => Jolt.PInvoke.CylinderShape_Release(this);
|
|
public uint GetRefCount() => Jolt.PInvoke.CylinderShape_GetRefCount(this);
|
|
public static implicit operator ConvexShape(CylinderShape value) => Jolt.PInvoke.CylinderShape_AsConvexShape(value);
|
|
public static implicit operator Shape(CylinderShape value) => Jolt.PInvoke.CylinderShape_AsShape(value);
|
|
public void Dispose()
|
|
{
|
|
if (IsNull()) return;
|
|
Release();
|
|
}
|
|
}
|
|
}
|