//
// Generated by Brutal.Jolt.Generate; do not edit by hand.
#nullable enable
using Brutal.Interop;
using Brutal.Numerics;
namespace Brutal.JoltApi
{
///
///
/// C++:
/// Jolt/Geometry/Plane.h:10
///
/// class Plane
///
///
///
///
/// An infinite plane described by the formula X . Normal + Constant = 0.
///
///
[InteropHandle]
public readonly partial struct Plane : IDisposable
{
///
///
/// C++:
/// Jolt/Geometry/Plane.h:16
///
/// Plane() = default
///
///
///
///
/// Constructor
///
///
public static Plane Create() => Jolt.PInvoke.Plane_Create();
///
///
/// C++:
/// Jolt/Geometry/Plane.h:17
///
/// explicit Plane(Vec4Arg inNormalAndConstant)
///
///
public static Plane Create(float4 normalAndConstant) => Jolt.PInvoke.Plane_Create_2(normalAndConstant);
///
///
/// C++:
/// Jolt/Geometry/Plane.h:18
///
/// Plane(Vec3Arg inNormal, float inConstant)
///
///
public static Plane Create(float3 normal, float constant) => Jolt.PInvoke.Plane_Create_3(normal, constant);
///
///
/// C++:
/// Jolt/Geometry/Plane.h:30
///
/// Vec3 GetNormal() const
///
///
///
///
/// Properties
///
///
public float3 GetNormal() => Jolt.PInvoke.Plane_GetNormal(this);
///
///
/// C++:
/// Jolt/Geometry/Plane.h:31
///
/// void SetNormal(Vec3Arg inNormal)
///
///
public void SetNormal(float3 normal) => Jolt.PInvoke.Plane_SetNormal(this, normal);
///
///
/// C++:
/// Jolt/Geometry/Plane.h:32
///
/// float GetConstant() const
///
///
public float GetConstant() => Jolt.PInvoke.Plane_GetConstant(this);
///
///
/// C++:
/// Jolt/Geometry/Plane.h:33
///
/// void SetConstant(float inConstant)
///
///
public void SetConstant(float constant) => Jolt.PInvoke.Plane_SetConstant(this, constant);
///
///
/// C++:
/// Jolt/Geometry/Plane.h:36
///
/// void StoreFloat4(Float4 *outV) const
///
///
///
///
/// Store as 4 floats
///
///
public unsafe void StoreFloat4(Ptr v) => Jolt.PInvoke.Plane_StoreFloat4(this, v);
///
///
/// C++:
/// Jolt/Geometry/Plane.h:57
///
/// float SignedDistance(Vec3Arg inPoint) const
///
///
///
///
/// Distance point to plane
///
///
public float SignedDistance(float3 point) => Jolt.PInvoke.Plane_SignedDistance(this, point);
///
///
/// C++:
/// Jolt/Geometry/Plane.h:60
///
/// Vec3 ProjectPointOnPlane(Vec3Arg inPoint) const
///
///
///
///
/// Project inPoint onto the plane
///
///
public float3 ProjectPointOnPlane(float3 point) => Jolt.PInvoke.Plane_ProjectPointOnPlane(this, point);
///
///
/// C++:
/// Jolt/Geometry/Plane.h:63
///
/// static bool sIntersectPlanes(const Plane &inP1, const Plane &inP2, const Plane &inP3, Vec3 &outPoint)
///
///
///
///
/// Returns intersection point between 3 planes
///
///
public static bool sIntersectPlanes(Plane p1, Plane p2, Plane p3, out float3 point) => Jolt.PInvoke.Plane_sIntersectPlanes(p1, p2, p3, out point);
public void Dispose() => Jolt.PInvoke.Plane_Destroy(this);
}
}