Jolt Physics
A multi core friendly Game Physics Engine
Loading...
Searching...
No Matches
ShaderPlane.h
Go to the documentation of this file.
1// Jolt Physics Library (https://github.com/jrouwe/JoltPhysics)
2// SPDX-FileCopyrightText: 2025 Jorrit Rouwe
3// SPDX-License-Identifier: MIT
4
5JPH_Plane JPH_PlaneFromPointAndNormal(float3 inPoint, float3 inNormal)
6{
7 return JPH_Plane(inNormal, -dot(inNormal, inPoint));
8}
9
11{
12 return inPlane.xyz;
13}
14
15float JPH_PlaneSignedDistance(JPH_Plane inPlane, float3 inPoint)
16{
17 return dot(inPoint, inPlane.xyz) + inPlane.w;
18}
float4 JPH_Plane
Definition ShaderCore.h:49
float JPH_PlaneSignedDistance(JPH_Plane inPlane, float3 inPoint)
Definition ShaderPlane.h:15
JPH_Plane JPH_PlaneFromPointAndNormal(float3 inPoint, float3 inNormal)
Definition ShaderPlane.h:5
float3 JPH_PlaneGetNormal(JPH_Plane inPlane)
Definition ShaderPlane.h:10