mirror of
https://github.com/ahwootech/BRUTAL.git
synced 2026-11-29 06:28:25 +01:00
first
This commit is contained in:
parent
bd62d51ec9
commit
b578433e37
1 changed files with 784842 additions and 0 deletions
45
Brutal.Jolt/Manual/PInvoke.ClosestPoint.cs
Normal file
45
Brutal.Jolt/Manual/PInvoke.ClosestPoint.cs
Normal file
|
|
@ -0,0 +1,45 @@
|
|||
using System.Runtime.InteropServices;
|
||||
using Brutal.Numerics;
|
||||
|
||||
namespace Brutal.JoltApi;
|
||||
|
||||
// Hand-written LibraryImports for JPH::ClosestPoint free functions (JoltClosestPointShim.cpp).
|
||||
// These are templates the parse can't bind.
|
||||
public static partial class Jolt
|
||||
{
|
||||
public static unsafe partial class PInvoke
|
||||
{
|
||||
[LibraryImport("jolt", EntryPoint = "Jolt_ClosestPointGetBaryCentricCoordinates")]
|
||||
public static partial Brutal.Bool8 ClosestPointGetBaryCentricCoordinates(
|
||||
float3 a,
|
||||
float3 b,
|
||||
out float u,
|
||||
out float v
|
||||
);
|
||||
|
||||
[LibraryImport("jolt", EntryPoint = "Jolt_ClosestPointGetBaryCentricCoordinates_2")]
|
||||
public static partial Brutal.Bool8 ClosestPointGetBaryCentricCoordinates_2(
|
||||
float3 a,
|
||||
float3 b,
|
||||
float3 c,
|
||||
out float u,
|
||||
out float v,
|
||||
out float w
|
||||
);
|
||||
|
||||
[LibraryImport("jolt", EntryPoint = "Jolt_ClosestPointGetClosestPointOnLine")]
|
||||
public static partial float3 ClosestPointGetClosestPointOnLine(float3 a, float3 b, out uint set);
|
||||
|
||||
[LibraryImport("jolt", EntryPoint = "Jolt_ClosestPointGetClosestPointOnTriangle")]
|
||||
public static partial float3 ClosestPointGetClosestPointOnTriangle(float3 a, float3 b, float3 c, out uint set);
|
||||
|
||||
[LibraryImport("jolt", EntryPoint = "Jolt_ClosestPointGetClosestPointOnTetrahedron")]
|
||||
public static partial float3 ClosestPointGetClosestPointOnTetrahedron(
|
||||
float3 a,
|
||||
float3 b,
|
||||
float3 c,
|
||||
float3 d,
|
||||
out uint set
|
||||
);
|
||||
}
|
||||
}
|
||||
Loading…
Reference in a new issue