Class Utils_Geometry
Inheritance
Utils_Geometry
Assembly: fwt.core.dll
Syntax
public static class Utils_Geometry
Methods
CalculateFrustumPlanes(Camera, Allocator, Plane[])
Calculates frustum planes of given camera and saves data to the newly created native array of 6 planes.
Can use provided array parameter to avoid allocations.
Declaration
public static NativeArray<Plane> CalculateFrustumPlanes(this Camera camera, Allocator allocator, Plane[] planes = null)
Parameters
| Type |
Name |
Description |
| Camera |
camera |
|
| Allocator |
allocator |
|
| Plane[] |
planes |
An array of 6 Planes
|
Returns
| Type |
Description |
| NativeArray<Plane> |
|
CalculateFrustumPlanes(Camera, NativeArray<Plane>, Plane[])
Calculates frustum planes of given camera and saves data to the provided native array of 6 planes.
Can use provided array parameter to avoid allocations.
Declaration
public static NativeArray<Plane> CalculateFrustumPlanes(this Camera camera, NativeArray<Plane> result6items, Plane[] planes = null)
Parameters
| Type |
Name |
Description |
| Camera |
camera |
|
| NativeArray<Plane> |
result6items |
|
| Plane[] |
planes |
An array of 6 Planes
|
Returns
| Type |
Description |
| NativeArray<Plane> |
|
CalculateFrustumPlanes(Camera, Plane[])
Calculates frustum planes of given camera and saves data to the provided native array of 6 planes.
Can use provided array parameter to avoid allocations.
Declaration
public static FixedArray8<Plane> CalculateFrustumPlanes(this Camera camera, Plane[] planes = null)
Parameters
| Type |
Name |
Description |
| Camera |
camera |
|
| Plane[] |
planes |
An array of 6 Planes
|
Returns
LineLineIntersection(out float3, float3, float3, float3, float3)
Declaration
public static bool LineLineIntersection(out float3 intersection, float3 linePoint1, float3 lineVec1, float3 linePoint2, float3 lineVec2)
Parameters
| Type |
Name |
Description |
| float3 |
intersection |
|
| float3 |
linePoint1 |
|
| float3 |
lineVec1 |
|
| float3 |
linePoint2 |
|
| float3 |
lineVec2 |
|
Returns
TestPlanesAABB(FixedArray8<Plane>, Bounds)
Declaration
[BurstCompile]
public static bool TestPlanesAABB(FixedArray8<Plane> planes, Bounds bounds)
Parameters
| Type |
Name |
Description |
| FixedArray8<Plane> |
planes |
|
| Bounds |
bounds |
|
Returns
TestPlanesAABB(NativeArray<Plane>, Bounds)
Declaration
[BurstCompile]
public static bool TestPlanesAABB(NativeArray<Plane> planes, Bounds bounds)
Parameters
| Type |
Name |
Description |
| NativeArray<Plane> |
planes |
|
| Bounds |
bounds |
|
Returns