mirror of
https://github.com/ahwootech/BRUTAL.git
synced 2026-11-25 20:48:24 +01:00
97 lines
4.1 KiB
C#
97 lines
4.1 KiB
C#
// <auto-generated/>
|
|
// 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
|
|
{
|
|
/// <summary>
|
|
/// <para>
|
|
/// Internal tree structure in broadphase, is essentially a quad AABB tree. Tree is lockless (except for
|
|
/// UpdatePrepare/Finalize() function), modifying objects in the tree will widen the aabbs of parent nodes to
|
|
/// make the node fit. During the UpdatePrepare/Finalize() call the tree is rebuilt to achieve a tight fit
|
|
/// again.
|
|
/// </para>
|
|
/// <para>
|
|
/// C++:
|
|
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/e77f175595e64cb44218cc9d9d56fc365ad0e36a/Jolt/Physics/Collision/BroadPhase/QuadTree.h#L20">Jolt/Physics/Collision/BroadPhase/QuadTree.h:20</see>
|
|
/// <br/>
|
|
/// <c>class QuadTree : public NonCopyable</c>
|
|
/// </para>
|
|
/// </summary>
|
|
[InteropHandle]
|
|
public readonly partial struct QuadTree : IDisposable
|
|
{
|
|
public static QuadTree Create() => Jolt.PInvoke.QuadTree_Create();
|
|
|
|
/// <summary>
|
|
/// <para>
|
|
/// Check if there is anything in the tree
|
|
/// </para>
|
|
/// <para>
|
|
/// C++:
|
|
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/e77f175595e64cb44218cc9d9d56fc365ad0e36a/Jolt/Physics/Collision/BroadPhase/QuadTree.h#L181">Jolt/Physics/Collision/BroadPhase/QuadTree.h:181</see>
|
|
/// <br/>
|
|
/// <c>inline bool HasBodies() const</c>
|
|
/// </para>
|
|
/// </summary>
|
|
public bool HasBodies() => Jolt.PInvoke.QuadTree_HasBodies(this);
|
|
|
|
/// <summary>
|
|
/// <para>
|
|
/// Check if the tree needs an UpdatePrepare/Finalize()
|
|
/// </para>
|
|
/// <para>
|
|
/// C++:
|
|
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/e77f175595e64cb44218cc9d9d56fc365ad0e36a/Jolt/Physics/Collision/BroadPhase/QuadTree.h#L184">Jolt/Physics/Collision/BroadPhase/QuadTree.h:184</see>
|
|
/// <br/>
|
|
/// <c>inline bool IsDirty() const</c>
|
|
/// </para>
|
|
/// </summary>
|
|
public bool IsDirty() => Jolt.PInvoke.QuadTree_IsDirty(this);
|
|
|
|
/// <summary>
|
|
/// <para>
|
|
/// Check if this tree can get an UpdatePrepare/Finalize() or if it needs a DiscardOldTree() first
|
|
/// </para>
|
|
/// <para>
|
|
/// C++:
|
|
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/e77f175595e64cb44218cc9d9d56fc365ad0e36a/Jolt/Physics/Collision/BroadPhase/QuadTree.h#L187">Jolt/Physics/Collision/BroadPhase/QuadTree.h:187</see>
|
|
/// <br/>
|
|
/// <c>inline bool CanBeUpdated() const</c>
|
|
/// </para>
|
|
/// </summary>
|
|
public bool CanBeUpdated() => Jolt.PInvoke.QuadTree_CanBeUpdated(this);
|
|
|
|
/// <summary>
|
|
/// <para>
|
|
/// Will throw away the previous frame's nodes so that we can start building a new tree in the background
|
|
/// </para>
|
|
/// <para>
|
|
/// C++:
|
|
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/e77f175595e64cb44218cc9d9d56fc365ad0e36a/Jolt/Physics/Collision/BroadPhase/QuadTree.h#L198">Jolt/Physics/Collision/BroadPhase/QuadTree.h:198</see>
|
|
/// <br/>
|
|
/// <c>void DiscardOldTree()</c>
|
|
/// </para>
|
|
/// </summary>
|
|
public void DiscardOldTree() => Jolt.PInvoke.QuadTree_DiscardOldTree(this);
|
|
|
|
/// <summary>
|
|
/// <para>
|
|
/// Get the bounding box for this tree
|
|
/// </para>
|
|
/// <para>
|
|
/// C++:
|
|
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/e77f175595e64cb44218cc9d9d56fc365ad0e36a/Jolt/Physics/Collision/BroadPhase/QuadTree.h#L201">Jolt/Physics/Collision/BroadPhase/QuadTree.h:201</see>
|
|
/// <br/>
|
|
/// <c>AABox GetBounds() const</c>
|
|
/// </para>
|
|
/// </summary>
|
|
public AABox GetBounds() => Jolt.PInvoke.QuadTree_GetBounds(this);
|
|
|
|
public void Dispose() => Jolt.PInvoke.QuadTree_Destroy(this);
|
|
}
|
|
}
|