> Agent-readable docs index: /llms.txt. Download /docs.zip to grep all markdown files locally.

---
title: Plane
icon: square
---

# <ApiPageIcon icon="square" />Plane

<ApiExposes data="[{&#x22;k&#x22;:&#x22;CDATA&#x22;,&#x22;c&#x22;:&#x22;method&#x22;,&#x22;s&#x22;:&#x22;VPlane&#x22;,&#x22;h&#x22;:&#x22;#vplane&#x22;},{&#x22;k&#x22;:&#x22;CTYPE&#x22;,&#x22;c&#x22;:&#x22;ctor&#x22;,&#x22;s&#x22;:&#x22;VPlane&#x22;,&#x22;h&#x22;:&#x22;#vplane-1&#x22;},{&#x22;k&#x22;:&#x22;ENUM&#x22;,&#x22;c&#x22;:&#x22;enum&#x22;,&#x22;s&#x22;:&#x22;SideType&#x22;,&#x22;h&#x22;:&#x22;#sidetype&#x22;},{&#x22;k&#x22;:&#x22;CDATA&#x22;,&#x22;c&#x22;:&#x22;method&#x22;,&#x22;s&#x22;:&#x22;Frustum_t&#x22;,&#x22;h&#x22;:&#x22;#frustum_t&#x22;},{&#x22;k&#x22;:&#x22;OBJECT&#x22;,&#x22;c&#x22;:&#x22;method&#x22;,&#x22;s&#x22;:&#x22;fourplanes_t&#x22;,&#x22;h&#x22;:&#x22;#fourplanes_t&#x22;},{&#x22;k&#x22;:&#x22;CTYPE&#x22;,&#x22;c&#x22;:&#x22;ctor&#x22;,&#x22;s&#x22;:&#x22;Frustum_t&#x22;,&#x22;h&#x22;:&#x22;#frustum_t-1&#x22;}]" />

## VPlane<ApiTag label="cdata" href="/cs2/api_reference/tutorials/ffi-crash-course#ctype-and-cdata" title="cdata<struct VPlane>" />

<ApiSymbol inherits="[{&#x22;n&#x22;:&#x22;VPlane&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vplane#vplane-1&#x22;}]" />

A plane, stored as a normal with a length of 1 and a distance along that normal. A point
`p` is on the plane when `p:Dot(m_Normal) == m_Dist`. The side that the normal points to is
the front of the plane.

The `SECONDARYVIEWMODE_PLANAR_REFLECTION` render attribute uses a plane. Both matrix types
can transform a plane with `TransformPlane`. `mathlib` can build reflection and projection
matrices from planes.

The `==` operator compares the normal and the distance and returns `false` when the other
value is not a `VPlane`.

```cpp lines=false
typedef struct VPlane {
    Vector m_Normal;
    float m_Dist;
} VPlane;
```

<ApiMembers>
  <ApiMember kind="prop" name="VPlane.m_Dist" summary="The distance from the origin to the plane, measured along the normal." ret="[[{&#x22;s&#x22;:&#x22;number&#x22;,&#x22;k&#x22;:&#x22;prim&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/lua/base#number&#x22;}]]" />

  <ApiMember kind="prop" name="VPlane.m_Normal" summary="The normal of the plane. It should have a length of 1." ret="[[{&#x22;s&#x22;:&#x22;Vector&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vector#vector-1&#x22;}]]" />
</ApiMembers>

<Heading level={2} id="vplane-1">
  VPlane

  <ApiTag label="ctype · callable" href="/cs2/api_reference/tutorials/ffi-crash-course#ctype-and-cdata" title="ctype<struct VPlane>" />
</Heading>

Call `VPlane()` to create a plane with every field set to 0. Call `VPlane(normal, dist)` to
set the normal and the distance. The normal is stored as given. Call `VPlane(normal, point)`
to create a plane through a point. The normal is normalized first. Call `VPlane(a, b, c)` to
create a plane through three points in clockwise order. Call `VPlane(other)` to make a copy
of another plane.

Any other arguments throw an error.

<ApiMembers>
  <ApiMember kind="ctor" name="VPlane()" summary="A plane with every field set to 0." syntax="VPlane()" mm="__call" sig="[{&#x22;s&#x22;:&#x22;VPlane&#x22;},{&#x22;s&#x22;:&#x22;(&#x22;},{&#x22;s&#x22;:&#x22;)&#x22;},{&#x22;s&#x22;:&#x22;: &#x22;},{&#x22;s&#x22;:&#x22;VPlane&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vplane#vplane&#x22;}]" ret="[[{&#x22;s&#x22;:&#x22;VPlane&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vplane#vplane&#x22;}]]" />

  <ApiMember kind="ctor" name="VPlane(normal, dist)" syntax="VPlane(normal, dist)" mm="__call" sig="[{&#x22;s&#x22;:&#x22;VPlane&#x22;},{&#x22;s&#x22;:&#x22;(&#x22;},{&#x22;s&#x22;:&#x22;normal&#x22;},{&#x22;s&#x22;:&#x22;: &#x22;},{&#x22;s&#x22;:&#x22;Vector&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vector#vector-1&#x22;},{&#x22;s&#x22;:&#x22;|&#x22;},{&#x22;s&#x22;:&#x22;VectorAligned&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vectoraligned#vectoraligned&#x22;},{&#x22;s&#x22;:&#x22;, &#x22;},{&#x22;s&#x22;:&#x22;dist&#x22;},{&#x22;s&#x22;:&#x22;: &#x22;},{&#x22;s&#x22;:&#x22;number&#x22;,&#x22;k&#x22;:&#x22;prim&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/lua/base#number&#x22;},{&#x22;s&#x22;:&#x22;)&#x22;},{&#x22;s&#x22;:&#x22;: &#x22;},{&#x22;s&#x22;:&#x22;VPlane&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vplane#vplane&#x22;}]" ret="[[{&#x22;s&#x22;:&#x22;VPlane&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vplane#vplane&#x22;}]]" params="[{&#x22;n&#x22;:&#x22;normal&#x22;,&#x22;t&#x22;:[{&#x22;s&#x22;:&#x22;Vector&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vector#vector-1&#x22;},{&#x22;s&#x22;:&#x22;|&#x22;},{&#x22;s&#x22;:&#x22;VectorAligned&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vectoraligned#vectoraligned&#x22;}]},{&#x22;n&#x22;:&#x22;dist&#x22;,&#x22;t&#x22;:[{&#x22;s&#x22;:&#x22;number&#x22;,&#x22;k&#x22;:&#x22;prim&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/lua/base#number&#x22;}]}]" />

  <ApiMember kind="ctor" name="VPlane(normal, point)" summary="The normal is normalized." syntax="VPlane(normal, point)" mm="__call" sig="[{&#x22;s&#x22;:&#x22;VPlane&#x22;},{&#x22;s&#x22;:&#x22;(&#x22;},{&#x22;s&#x22;:&#x22;normal&#x22;},{&#x22;s&#x22;:&#x22;: &#x22;},{&#x22;s&#x22;:&#x22;Vector&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vector#vector-1&#x22;},{&#x22;s&#x22;:&#x22;|&#x22;},{&#x22;s&#x22;:&#x22;VectorAligned&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vectoraligned#vectoraligned&#x22;},{&#x22;s&#x22;:&#x22;, &#x22;},{&#x22;s&#x22;:&#x22;point&#x22;},{&#x22;s&#x22;:&#x22;: &#x22;},{&#x22;s&#x22;:&#x22;Vector&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vector#vector-1&#x22;},{&#x22;s&#x22;:&#x22;|&#x22;},{&#x22;s&#x22;:&#x22;VectorAligned&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vectoraligned#vectoraligned&#x22;},{&#x22;s&#x22;:&#x22;)&#x22;},{&#x22;s&#x22;:&#x22;: &#x22;},{&#x22;s&#x22;:&#x22;VPlane&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vplane#vplane&#x22;}]" ret="[[{&#x22;s&#x22;:&#x22;VPlane&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vplane#vplane&#x22;}]]" params="[{&#x22;n&#x22;:&#x22;normal&#x22;,&#x22;t&#x22;:[{&#x22;s&#x22;:&#x22;Vector&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vector#vector-1&#x22;},{&#x22;s&#x22;:&#x22;|&#x22;},{&#x22;s&#x22;:&#x22;VectorAligned&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vectoraligned#vectoraligned&#x22;}]},{&#x22;n&#x22;:&#x22;point&#x22;,&#x22;t&#x22;:[{&#x22;s&#x22;:&#x22;Vector&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vector#vector-1&#x22;},{&#x22;s&#x22;:&#x22;|&#x22;},{&#x22;s&#x22;:&#x22;VectorAligned&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vectoraligned#vectoraligned&#x22;}]}]" />

  <ApiMember kind="ctor" name="VPlane(a, b, c)" summary="A plane through three points in clockwise order." syntax="VPlane(a, b, c)" mm="__call" sig="[{&#x22;s&#x22;:&#x22;VPlane&#x22;},{&#x22;s&#x22;:&#x22;(&#x22;},{&#x22;s&#x22;:&#x22;a&#x22;},{&#x22;s&#x22;:&#x22;: &#x22;},{&#x22;s&#x22;:&#x22;Vector&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vector#vector-1&#x22;},{&#x22;s&#x22;:&#x22;|&#x22;},{&#x22;s&#x22;:&#x22;VectorAligned&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vectoraligned#vectoraligned&#x22;},{&#x22;s&#x22;:&#x22;, &#x22;},{&#x22;s&#x22;:&#x22;b&#x22;},{&#x22;s&#x22;:&#x22;: &#x22;},{&#x22;s&#x22;:&#x22;Vector&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vector#vector-1&#x22;},{&#x22;s&#x22;:&#x22;|&#x22;},{&#x22;s&#x22;:&#x22;VectorAligned&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vectoraligned#vectoraligned&#x22;},{&#x22;s&#x22;:&#x22;, &#x22;},{&#x22;s&#x22;:&#x22;c&#x22;},{&#x22;s&#x22;:&#x22;: &#x22;},{&#x22;s&#x22;:&#x22;Vector&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vector#vector-1&#x22;},{&#x22;s&#x22;:&#x22;|&#x22;},{&#x22;s&#x22;:&#x22;VectorAligned&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vectoraligned#vectoraligned&#x22;},{&#x22;s&#x22;:&#x22;)&#x22;},{&#x22;s&#x22;:&#x22;: &#x22;},{&#x22;s&#x22;:&#x22;VPlane&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vplane#vplane&#x22;}]" ret="[[{&#x22;s&#x22;:&#x22;VPlane&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vplane#vplane&#x22;}]]" params="[{&#x22;n&#x22;:&#x22;a&#x22;,&#x22;t&#x22;:[{&#x22;s&#x22;:&#x22;Vector&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vector#vector-1&#x22;},{&#x22;s&#x22;:&#x22;|&#x22;},{&#x22;s&#x22;:&#x22;VectorAligned&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vectoraligned#vectoraligned&#x22;}]},{&#x22;n&#x22;:&#x22;b&#x22;,&#x22;t&#x22;:[{&#x22;s&#x22;:&#x22;Vector&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vector#vector-1&#x22;},{&#x22;s&#x22;:&#x22;|&#x22;},{&#x22;s&#x22;:&#x22;VectorAligned&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vectoraligned#vectoraligned&#x22;}]},{&#x22;n&#x22;:&#x22;c&#x22;,&#x22;t&#x22;:[{&#x22;s&#x22;:&#x22;Vector&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vector#vector-1&#x22;},{&#x22;s&#x22;:&#x22;|&#x22;},{&#x22;s&#x22;:&#x22;VectorAligned&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vectoraligned#vectoraligned&#x22;}]}]" />

  <ApiMember kind="ctor" name="VPlane(self)" syntax="VPlane(self)" mm="__call" sig="[{&#x22;s&#x22;:&#x22;VPlane&#x22;},{&#x22;s&#x22;:&#x22;(&#x22;},{&#x22;s&#x22;:&#x22;self&#x22;},{&#x22;s&#x22;:&#x22;: &#x22;},{&#x22;s&#x22;:&#x22;VPlane&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vplane#vplane&#x22;},{&#x22;s&#x22;:&#x22;)&#x22;},{&#x22;s&#x22;:&#x22;: &#x22;},{&#x22;s&#x22;:&#x22;VPlane&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vplane#vplane&#x22;}]" ret="[[{&#x22;s&#x22;:&#x22;VPlane&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vplane#vplane&#x22;}]]" params="[{&#x22;n&#x22;:&#x22;self&#x22;,&#x22;t&#x22;:[{&#x22;s&#x22;:&#x22;VPlane&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vplane#vplane&#x22;}]}]" />

  <ApiMember kind="fn" name="VPlane.Init" summary="Sets the normal and the distance of the plane. The normal is stored as given." args="plane, normal, dist" sig="[{&#x22;s&#x22;:&#x22;VPlane.Init&#x22;},{&#x22;s&#x22;:&#x22;(&#x22;},{&#x22;s&#x22;:&#x22;plane&#x22;},{&#x22;s&#x22;:&#x22;: &#x22;},{&#x22;s&#x22;:&#x22;VPlane&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vplane#vplane&#x22;},{&#x22;s&#x22;:&#x22;, &#x22;},{&#x22;s&#x22;:&#x22;normal&#x22;},{&#x22;s&#x22;:&#x22;: &#x22;},{&#x22;s&#x22;:&#x22;Vector&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vector#vector-1&#x22;},{&#x22;s&#x22;:&#x22;, &#x22;},{&#x22;s&#x22;:&#x22;dist&#x22;},{&#x22;s&#x22;:&#x22;: &#x22;},{&#x22;s&#x22;:&#x22;number&#x22;,&#x22;k&#x22;:&#x22;prim&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/lua/base#number&#x22;},{&#x22;s&#x22;:&#x22;)&#x22;}]" params="[{&#x22;n&#x22;:&#x22;plane&#x22;,&#x22;t&#x22;:[{&#x22;s&#x22;:&#x22;VPlane&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vplane#vplane&#x22;}],&#x22;d&#x22;:&#x22;The plane to change.&#x22;},{&#x22;n&#x22;:&#x22;normal&#x22;,&#x22;t&#x22;:[{&#x22;s&#x22;:&#x22;Vector&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vector#vector-1&#x22;}],&#x22;d&#x22;:&#x22;The normal.&#x22;},{&#x22;n&#x22;:&#x22;dist&#x22;,&#x22;t&#x22;:[{&#x22;s&#x22;:&#x22;number&#x22;,&#x22;k&#x22;:&#x22;prim&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/lua/base#number&#x22;}],&#x22;d&#x22;:&#x22;The distance along the normal.&#x22;}]" />

  <ApiMember kind="fn" name="VPlane.InitFromPointAndNormal" summary="Sets the plane so that it goes through a point. The normal is normalized first." args="plane, point, normal" sig="[{&#x22;s&#x22;:&#x22;VPlane.InitFromPointAndNormal&#x22;},{&#x22;s&#x22;:&#x22;(&#x22;},{&#x22;s&#x22;:&#x22;plane&#x22;},{&#x22;s&#x22;:&#x22;: &#x22;},{&#x22;s&#x22;:&#x22;VPlane&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vplane#vplane&#x22;},{&#x22;s&#x22;:&#x22;, &#x22;},{&#x22;s&#x22;:&#x22;point&#x22;},{&#x22;s&#x22;:&#x22;: &#x22;},{&#x22;s&#x22;:&#x22;Vector&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vector#vector-1&#x22;},{&#x22;s&#x22;:&#x22;, &#x22;},{&#x22;s&#x22;:&#x22;normal&#x22;},{&#x22;s&#x22;:&#x22;: &#x22;},{&#x22;s&#x22;:&#x22;Vector&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vector#vector-1&#x22;},{&#x22;s&#x22;:&#x22;)&#x22;}]" params="[{&#x22;n&#x22;:&#x22;plane&#x22;,&#x22;t&#x22;:[{&#x22;s&#x22;:&#x22;VPlane&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vplane#vplane&#x22;}],&#x22;d&#x22;:&#x22;The plane to change.&#x22;},{&#x22;n&#x22;:&#x22;point&#x22;,&#x22;t&#x22;:[{&#x22;s&#x22;:&#x22;Vector&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vector#vector-1&#x22;}],&#x22;d&#x22;:&#x22;A point on the plane.&#x22;},{&#x22;n&#x22;:&#x22;normal&#x22;,&#x22;t&#x22;:[{&#x22;s&#x22;:&#x22;Vector&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vector#vector-1&#x22;}],&#x22;d&#x22;:&#x22;The normal.&#x22;}]" />

  <ApiMember kind="fn" name="VPlane.InitFromClockwisePoints" summary="Sets the plane so that it goes through three points. The normal is the normalized cross product of `c - a` and `b - a`." args="plane, a, b, c" sig="[{&#x22;s&#x22;:&#x22;VPlane.InitFromClockwisePoints&#x22;},{&#x22;s&#x22;:&#x22;(&#x22;},{&#x22;s&#x22;:&#x22;plane&#x22;},{&#x22;s&#x22;:&#x22;: &#x22;},{&#x22;s&#x22;:&#x22;VPlane&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vplane#vplane&#x22;},{&#x22;s&#x22;:&#x22;, &#x22;},{&#x22;s&#x22;:&#x22;a&#x22;},{&#x22;s&#x22;:&#x22;: &#x22;},{&#x22;s&#x22;:&#x22;Vector&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vector#vector-1&#x22;},{&#x22;s&#x22;:&#x22;, &#x22;},{&#x22;s&#x22;:&#x22;b&#x22;},{&#x22;s&#x22;:&#x22;: &#x22;},{&#x22;s&#x22;:&#x22;Vector&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vector#vector-1&#x22;},{&#x22;s&#x22;:&#x22;, &#x22;},{&#x22;s&#x22;:&#x22;c&#x22;},{&#x22;s&#x22;:&#x22;: &#x22;},{&#x22;s&#x22;:&#x22;Vector&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vector#vector-1&#x22;},{&#x22;s&#x22;:&#x22;)&#x22;}]" params="[{&#x22;n&#x22;:&#x22;plane&#x22;,&#x22;t&#x22;:[{&#x22;s&#x22;:&#x22;VPlane&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vplane#vplane&#x22;}],&#x22;d&#x22;:&#x22;The plane to change.&#x22;},{&#x22;n&#x22;:&#x22;a&#x22;,&#x22;t&#x22;:[{&#x22;s&#x22;:&#x22;Vector&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vector#vector-1&#x22;}]},{&#x22;n&#x22;:&#x22;b&#x22;,&#x22;t&#x22;:[{&#x22;s&#x22;:&#x22;Vector&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vector#vector-1&#x22;}]},{&#x22;n&#x22;:&#x22;c&#x22;,&#x22;t&#x22;:[{&#x22;s&#x22;:&#x22;Vector&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vector#vector-1&#x22;}]}]" />

  <ApiMember kind="fn" name="VPlane.Copy" summary="Copies one plane into another plane." args="src, dst" sig="[{&#x22;s&#x22;:&#x22;VPlane.Copy&#x22;},{&#x22;s&#x22;:&#x22;(&#x22;},{&#x22;s&#x22;:&#x22;src&#x22;},{&#x22;s&#x22;:&#x22;: &#x22;},{&#x22;s&#x22;:&#x22;VPlane&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vplane#vplane&#x22;},{&#x22;s&#x22;:&#x22;, &#x22;},{&#x22;s&#x22;:&#x22;dst&#x22;},{&#x22;s&#x22;:&#x22;: &#x22;},{&#x22;s&#x22;:&#x22;VPlane&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vplane#vplane&#x22;},{&#x22;s&#x22;:&#x22;)&#x22;}]" params="[{&#x22;n&#x22;:&#x22;src&#x22;,&#x22;t&#x22;:[{&#x22;s&#x22;:&#x22;VPlane&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vplane#vplane&#x22;}],&#x22;d&#x22;:&#x22;The plane to copy from.&#x22;},{&#x22;n&#x22;:&#x22;dst&#x22;,&#x22;t&#x22;:[{&#x22;s&#x22;:&#x22;VPlane&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vplane#vplane&#x22;}],&#x22;d&#x22;:&#x22;The plane to copy into.&#x22;}]" />

  <ApiMember kind="fn" name="VPlane.DistTo" summary="Returns the signed distance from a point to the plane. The distance is positive in front of the plane and negative behind it." args="plane, point" sig="[{&#x22;s&#x22;:&#x22;VPlane.DistTo&#x22;},{&#x22;s&#x22;:&#x22;(&#x22;},{&#x22;s&#x22;:&#x22;plane&#x22;},{&#x22;s&#x22;:&#x22;: &#x22;},{&#x22;s&#x22;:&#x22;VPlane&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vplane#vplane&#x22;},{&#x22;s&#x22;:&#x22;, &#x22;},{&#x22;s&#x22;:&#x22;point&#x22;},{&#x22;s&#x22;:&#x22;: &#x22;},{&#x22;s&#x22;:&#x22;Vector&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vector#vector-1&#x22;},{&#x22;s&#x22;:&#x22;)&#x22;},{&#x22;s&#x22;:&#x22;: &#x22;},{&#x22;s&#x22;:&#x22;number&#x22;,&#x22;k&#x22;:&#x22;prim&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/lua/base#number&#x22;}]" ret="[[{&#x22;s&#x22;:&#x22;number&#x22;,&#x22;k&#x22;:&#x22;prim&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/lua/base#number&#x22;}]]" params="[{&#x22;n&#x22;:&#x22;plane&#x22;,&#x22;t&#x22;:[{&#x22;s&#x22;:&#x22;VPlane&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vplane#vplane&#x22;}],&#x22;d&#x22;:&#x22;The plane to read.&#x22;},{&#x22;n&#x22;:&#x22;point&#x22;,&#x22;t&#x22;:[{&#x22;s&#x22;:&#x22;Vector&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vector#vector-1&#x22;}],&#x22;d&#x22;:&#x22;The point to measure.&#x22;}]" nodiscard />

  <ApiMember kind="fn" name="VPlane.IntersectLineSegment" summary="Finds the point where a segment crosses the plane. If the segment crosses the plane, this function returns `true` and the point. Otherwise it returns `false` and `nil`." args="plane, start, stop" sig="[{&#x22;s&#x22;:&#x22;VPlane.IntersectLineSegment&#x22;},{&#x22;s&#x22;:&#x22;(&#x22;},{&#x22;s&#x22;:&#x22;plane&#x22;},{&#x22;s&#x22;:&#x22;: &#x22;},{&#x22;s&#x22;:&#x22;VPlane&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vplane#vplane&#x22;},{&#x22;s&#x22;:&#x22;, &#x22;},{&#x22;s&#x22;:&#x22;start&#x22;},{&#x22;s&#x22;:&#x22;: &#x22;},{&#x22;s&#x22;:&#x22;Vector&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vector#vector-1&#x22;},{&#x22;s&#x22;:&#x22;, &#x22;},{&#x22;s&#x22;:&#x22;stop&#x22;},{&#x22;s&#x22;:&#x22;: &#x22;},{&#x22;s&#x22;:&#x22;Vector&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vector#vector-1&#x22;},{&#x22;s&#x22;:&#x22;)&#x22;},{&#x22;s&#x22;:&#x22;: &#x22;},{&#x22;s&#x22;:&#x22;boolean&#x22;,&#x22;k&#x22;:&#x22;prim&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/lua/base#boolean&#x22;},{&#x22;s&#x22;:&#x22;, &#x22;},{&#x22;s&#x22;:&#x22;Vector&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vector#vector-1&#x22;},{&#x22;s&#x22;:&#x22;?&#x22;}]" ret="[[{&#x22;s&#x22;:&#x22;boolean&#x22;,&#x22;k&#x22;:&#x22;prim&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/lua/base#boolean&#x22;}],[{&#x22;s&#x22;:&#x22;Vector&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vector#vector-1&#x22;},{&#x22;s&#x22;:&#x22;?&#x22;}]]" params="[{&#x22;n&#x22;:&#x22;plane&#x22;,&#x22;t&#x22;:[{&#x22;s&#x22;:&#x22;VPlane&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vplane#vplane&#x22;}],&#x22;d&#x22;:&#x22;The plane to read.&#x22;},{&#x22;n&#x22;:&#x22;start&#x22;,&#x22;t&#x22;:[{&#x22;s&#x22;:&#x22;Vector&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vector#vector-1&#x22;}],&#x22;d&#x22;:&#x22;The start of the segment.&#x22;},{&#x22;n&#x22;:&#x22;stop&#x22;,&#x22;t&#x22;:[{&#x22;s&#x22;:&#x22;Vector&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vector#vector-1&#x22;}],&#x22;d&#x22;:&#x22;The end of the segment.&#x22;}]" returns="[{&#x22;n&#x22;:&#x22;ok&#x22;,&#x22;t&#x22;:[{&#x22;s&#x22;:&#x22;boolean&#x22;,&#x22;k&#x22;:&#x22;prim&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/lua/base#boolean&#x22;}]},{&#x22;n&#x22;:&#x22;intersection&#x22;,&#x22;t&#x22;:[{&#x22;s&#x22;:&#x22;Vector&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vector#vector-1&#x22;},{&#x22;s&#x22;:&#x22;?&#x22;}]}]" nodiscard>
    <ApiNotes>
      If the segment is parallel to the plane and lies on the plane, this function returns `true`
      and a copy of `start`.
    </ApiNotes>
  </ApiMember>

  <ApiMember kind="fn" name="VPlane.GetPointSide" summary="Returns the side of the plane that a point is on, as a `SideType` value. A point is on the plane when its distance to the plane is less than `epsilon`." args="plane, point, epsilon?" sig="[{&#x22;s&#x22;:&#x22;VPlane.GetPointSide&#x22;},{&#x22;s&#x22;:&#x22;(&#x22;},{&#x22;s&#x22;:&#x22;plane&#x22;},{&#x22;s&#x22;:&#x22;: &#x22;},{&#x22;s&#x22;:&#x22;VPlane&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vplane#vplane&#x22;},{&#x22;s&#x22;:&#x22;, &#x22;},{&#x22;s&#x22;:&#x22;point&#x22;},{&#x22;s&#x22;:&#x22;: &#x22;},{&#x22;s&#x22;:&#x22;Vector&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vector#vector-1&#x22;},{&#x22;s&#x22;:&#x22;[, &#x22;},{&#x22;s&#x22;:&#x22;epsilon&#x22;},{&#x22;s&#x22;:&#x22;: &#x22;},{&#x22;s&#x22;:&#x22;number&#x22;,&#x22;k&#x22;:&#x22;prim&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/lua/base#number&#x22;},{&#x22;s&#x22;:&#x22;]&#x22;},{&#x22;s&#x22;:&#x22;)&#x22;},{&#x22;s&#x22;:&#x22;: &#x22;},{&#x22;s&#x22;:&#x22;integer&#x22;,&#x22;k&#x22;:&#x22;prim&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/lua/base#integer&#x22;}]" ret="[[{&#x22;s&#x22;:&#x22;integer&#x22;,&#x22;k&#x22;:&#x22;prim&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/lua/base#integer&#x22;}]]" params="[{&#x22;n&#x22;:&#x22;plane&#x22;,&#x22;t&#x22;:[{&#x22;s&#x22;:&#x22;VPlane&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vplane#vplane&#x22;}],&#x22;d&#x22;:&#x22;The plane to read.&#x22;},{&#x22;n&#x22;:&#x22;point&#x22;,&#x22;t&#x22;:[{&#x22;s&#x22;:&#x22;Vector&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vector#vector-1&#x22;}],&#x22;d&#x22;:&#x22;The point to check.&#x22;},{&#x22;n&#x22;:&#x22;epsilon&#x22;,&#x22;t&#x22;:[{&#x22;s&#x22;:&#x22;number&#x22;,&#x22;k&#x22;:&#x22;prim&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/lua/base#number&#x22;}],&#x22;d&#x22;:&#x22;The distance from the plane at which a point stops counting as `SIDE_ON`. The default is 0.01.&#x22;,&#x22;o&#x22;:true}]" nodiscard />

  <ApiMember kind="fn" name="VPlane.GetPointSideExact" summary="Returns `SIDE_FRONT` if the point is in front of the plane. Otherwise it returns `SIDE_BACK`. A point that is exactly on the plane returns `SIDE_BACK`. This function never returns `SIDE_ON`." args="plane, point" sig="[{&#x22;s&#x22;:&#x22;VPlane.GetPointSideExact&#x22;},{&#x22;s&#x22;:&#x22;(&#x22;},{&#x22;s&#x22;:&#x22;plane&#x22;},{&#x22;s&#x22;:&#x22;: &#x22;},{&#x22;s&#x22;:&#x22;VPlane&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vplane#vplane&#x22;},{&#x22;s&#x22;:&#x22;, &#x22;},{&#x22;s&#x22;:&#x22;point&#x22;},{&#x22;s&#x22;:&#x22;: &#x22;},{&#x22;s&#x22;:&#x22;Vector&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vector#vector-1&#x22;},{&#x22;s&#x22;:&#x22;)&#x22;},{&#x22;s&#x22;:&#x22;: &#x22;},{&#x22;s&#x22;:&#x22;integer&#x22;,&#x22;k&#x22;:&#x22;prim&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/lua/base#integer&#x22;}]" ret="[[{&#x22;s&#x22;:&#x22;integer&#x22;,&#x22;k&#x22;:&#x22;prim&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/lua/base#integer&#x22;}]]" params="[{&#x22;n&#x22;:&#x22;plane&#x22;,&#x22;t&#x22;:[{&#x22;s&#x22;:&#x22;VPlane&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vplane#vplane&#x22;}],&#x22;d&#x22;:&#x22;The plane to read.&#x22;},{&#x22;n&#x22;:&#x22;point&#x22;,&#x22;t&#x22;:[{&#x22;s&#x22;:&#x22;Vector&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vector#vector-1&#x22;}],&#x22;d&#x22;:&#x22;The point to check.&#x22;}]" nodiscard />

  <ApiMember kind="fn" name="VPlane.BoxOnPlaneSide" summary="Returns the side of the plane that a box is on, as a `SideType` value. If the box is completely in front of the plane, it returns `SIDE_FRONT`. If it is completely behind the plane, it returns `SIDE_BACK`. If the plane cuts through the box, it returns `SIDE_ON`." args="plane, mins, maxs" sig="[{&#x22;s&#x22;:&#x22;VPlane.BoxOnPlaneSide&#x22;},{&#x22;s&#x22;:&#x22;(&#x22;},{&#x22;s&#x22;:&#x22;plane&#x22;},{&#x22;s&#x22;:&#x22;: &#x22;},{&#x22;s&#x22;:&#x22;VPlane&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vplane#vplane&#x22;},{&#x22;s&#x22;:&#x22;, &#x22;},{&#x22;s&#x22;:&#x22;mins&#x22;},{&#x22;s&#x22;:&#x22;: &#x22;},{&#x22;s&#x22;:&#x22;Vector&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vector#vector-1&#x22;},{&#x22;s&#x22;:&#x22;, &#x22;},{&#x22;s&#x22;:&#x22;maxs&#x22;},{&#x22;s&#x22;:&#x22;: &#x22;},{&#x22;s&#x22;:&#x22;Vector&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vector#vector-1&#x22;},{&#x22;s&#x22;:&#x22;)&#x22;},{&#x22;s&#x22;:&#x22;: &#x22;},{&#x22;s&#x22;:&#x22;integer&#x22;,&#x22;k&#x22;:&#x22;prim&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/lua/base#integer&#x22;}]" ret="[[{&#x22;s&#x22;:&#x22;integer&#x22;,&#x22;k&#x22;:&#x22;prim&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/lua/base#integer&#x22;}]]" params="[{&#x22;n&#x22;:&#x22;plane&#x22;,&#x22;t&#x22;:[{&#x22;s&#x22;:&#x22;VPlane&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vplane#vplane&#x22;}],&#x22;d&#x22;:&#x22;The plane to read.&#x22;},{&#x22;n&#x22;:&#x22;mins&#x22;,&#x22;t&#x22;:[{&#x22;s&#x22;:&#x22;Vector&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vector#vector-1&#x22;}],&#x22;d&#x22;:&#x22;The minimum corner of the box.&#x22;},{&#x22;n&#x22;:&#x22;maxs&#x22;,&#x22;t&#x22;:[{&#x22;s&#x22;:&#x22;Vector&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vector#vector-1&#x22;}],&#x22;d&#x22;:&#x22;The maximum corner of the box.&#x22;}]" nodiscard />

  <ApiMember kind="fn" name="VPlane.BoxOnPlaneSide" summary="Returns the side of the plane that a box is on. This is the same as the version with `mins` and `maxs`, with the box given as one `AABB_t`." id="VPlane-BoxOnPlaneSide-2" args="plane, bounds" sig="[{&#x22;s&#x22;:&#x22;VPlane.BoxOnPlaneSide&#x22;},{&#x22;s&#x22;:&#x22;(&#x22;},{&#x22;s&#x22;:&#x22;plane&#x22;},{&#x22;s&#x22;:&#x22;: &#x22;},{&#x22;s&#x22;:&#x22;VPlane&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vplane#vplane&#x22;},{&#x22;s&#x22;:&#x22;, &#x22;},{&#x22;s&#x22;:&#x22;bounds&#x22;},{&#x22;s&#x22;:&#x22;: &#x22;},{&#x22;s&#x22;:&#x22;AABB_t&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/aabb#aabb_t&#x22;},{&#x22;s&#x22;:&#x22;)&#x22;},{&#x22;s&#x22;:&#x22;: &#x22;},{&#x22;s&#x22;:&#x22;integer&#x22;,&#x22;k&#x22;:&#x22;prim&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/lua/base#integer&#x22;}]" ret="[[{&#x22;s&#x22;:&#x22;integer&#x22;,&#x22;k&#x22;:&#x22;prim&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/lua/base#integer&#x22;}]]" params="[{&#x22;n&#x22;:&#x22;plane&#x22;,&#x22;t&#x22;:[{&#x22;s&#x22;:&#x22;VPlane&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vplane#vplane&#x22;}],&#x22;d&#x22;:&#x22;The plane to read.&#x22;},{&#x22;n&#x22;:&#x22;bounds&#x22;,&#x22;t&#x22;:[{&#x22;s&#x22;:&#x22;AABB_t&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/aabb#aabb_t&#x22;}],&#x22;d&#x22;:&#x22;The box to check.&#x22;}]" nodiscard />

  <ApiMember kind="fn" name="VPlane.PointInFront" summary="Returns `true` if the point is in front of the plane. A point that is exactly on the plane returns `false`." args="plane, point" sig="[{&#x22;s&#x22;:&#x22;VPlane.PointInFront&#x22;},{&#x22;s&#x22;:&#x22;(&#x22;},{&#x22;s&#x22;:&#x22;plane&#x22;},{&#x22;s&#x22;:&#x22;: &#x22;},{&#x22;s&#x22;:&#x22;VPlane&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vplane#vplane&#x22;},{&#x22;s&#x22;:&#x22;, &#x22;},{&#x22;s&#x22;:&#x22;point&#x22;},{&#x22;s&#x22;:&#x22;: &#x22;},{&#x22;s&#x22;:&#x22;Vector&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vector#vector-1&#x22;},{&#x22;s&#x22;:&#x22;)&#x22;},{&#x22;s&#x22;:&#x22;: &#x22;},{&#x22;s&#x22;:&#x22;boolean&#x22;,&#x22;k&#x22;:&#x22;prim&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/lua/base#boolean&#x22;}]" ret="[[{&#x22;s&#x22;:&#x22;boolean&#x22;,&#x22;k&#x22;:&#x22;prim&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/lua/base#boolean&#x22;}]]" params="[{&#x22;n&#x22;:&#x22;plane&#x22;,&#x22;t&#x22;:[{&#x22;s&#x22;:&#x22;VPlane&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vplane#vplane&#x22;}],&#x22;d&#x22;:&#x22;The plane to read.&#x22;},{&#x22;n&#x22;:&#x22;point&#x22;,&#x22;t&#x22;:[{&#x22;s&#x22;:&#x22;Vector&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vector#vector-1&#x22;}],&#x22;d&#x22;:&#x22;The point to check.&#x22;}]" nodiscard />

  <ApiMember kind="fn" name="VPlane.ReflectPoint" summary="Moves a point to its mirror position on the other side of the plane. The point that you pass is changed." args="plane, point" sig="[{&#x22;s&#x22;:&#x22;VPlane.ReflectPoint&#x22;},{&#x22;s&#x22;:&#x22;(&#x22;},{&#x22;s&#x22;:&#x22;plane&#x22;},{&#x22;s&#x22;:&#x22;: &#x22;},{&#x22;s&#x22;:&#x22;VPlane&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vplane#vplane&#x22;},{&#x22;s&#x22;:&#x22;, &#x22;},{&#x22;s&#x22;:&#x22;point&#x22;},{&#x22;s&#x22;:&#x22;: &#x22;},{&#x22;s&#x22;:&#x22;Vector&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vector#vector-1&#x22;},{&#x22;s&#x22;:&#x22;)&#x22;}]" params="[{&#x22;n&#x22;:&#x22;plane&#x22;,&#x22;t&#x22;:[{&#x22;s&#x22;:&#x22;VPlane&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vplane#vplane&#x22;}],&#x22;d&#x22;:&#x22;The plane to read.&#x22;},{&#x22;n&#x22;:&#x22;point&#x22;,&#x22;t&#x22;:[{&#x22;s&#x22;:&#x22;Vector&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vector#vector-1&#x22;}],&#x22;d&#x22;:&#x22;The point to reflect.&#x22;}]" />

  <ApiMember kind="fn" name="VPlane.ReflectDirection" summary="Mirrors a direction across the plane. The direction that you pass is changed." args="plane, dir" sig="[{&#x22;s&#x22;:&#x22;VPlane.ReflectDirection&#x22;},{&#x22;s&#x22;:&#x22;(&#x22;},{&#x22;s&#x22;:&#x22;plane&#x22;},{&#x22;s&#x22;:&#x22;: &#x22;},{&#x22;s&#x22;:&#x22;VPlane&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vplane#vplane&#x22;},{&#x22;s&#x22;:&#x22;, &#x22;},{&#x22;s&#x22;:&#x22;dir&#x22;},{&#x22;s&#x22;:&#x22;: &#x22;},{&#x22;s&#x22;:&#x22;Vector&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vector#vector-1&#x22;},{&#x22;s&#x22;:&#x22;)&#x22;}]" params="[{&#x22;n&#x22;:&#x22;plane&#x22;,&#x22;t&#x22;:[{&#x22;s&#x22;:&#x22;VPlane&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vplane#vplane&#x22;}],&#x22;d&#x22;:&#x22;The plane to read.&#x22;},{&#x22;n&#x22;:&#x22;dir&#x22;,&#x22;t&#x22;:[{&#x22;s&#x22;:&#x22;Vector&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vector#vector-1&#x22;}],&#x22;d&#x22;:&#x22;The direction to reflect.&#x22;}]" />

  <ApiMember kind="fn" name="VPlane.ConvertToPlaneEquation" summary="Returns the plane as the equation `Ax + By + Cz + D = 0`. The X, Y and Z components of the result are the normal, and the W component is `-m_Dist`." args="plane" sig="[{&#x22;s&#x22;:&#x22;VPlane.ConvertToPlaneEquation&#x22;},{&#x22;s&#x22;:&#x22;(&#x22;},{&#x22;s&#x22;:&#x22;plane&#x22;},{&#x22;s&#x22;:&#x22;: &#x22;},{&#x22;s&#x22;:&#x22;VPlane&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vplane#vplane&#x22;},{&#x22;s&#x22;:&#x22;)&#x22;},{&#x22;s&#x22;:&#x22;: &#x22;},{&#x22;s&#x22;:&#x22;Vector4D&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vector4d#vector4d&#x22;}]" ret="[[{&#x22;s&#x22;:&#x22;Vector4D&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vector4d#vector4d&#x22;}]]" params="[{&#x22;n&#x22;:&#x22;plane&#x22;,&#x22;t&#x22;:[{&#x22;s&#x22;:&#x22;VPlane&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vplane#vplane&#x22;}],&#x22;d&#x22;:&#x22;The plane to read.&#x22;}]" nodiscard />

  <ApiMember kind="fn" name="VPlane.Flip" summary="Returns a new plane in the same position that faces the other way. Both the normal and the distance are negated." args="plane" sig="[{&#x22;s&#x22;:&#x22;VPlane.Flip&#x22;},{&#x22;s&#x22;:&#x22;(&#x22;},{&#x22;s&#x22;:&#x22;plane&#x22;},{&#x22;s&#x22;:&#x22;: &#x22;},{&#x22;s&#x22;:&#x22;VPlane&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vplane#vplane&#x22;},{&#x22;s&#x22;:&#x22;)&#x22;},{&#x22;s&#x22;:&#x22;: &#x22;},{&#x22;s&#x22;:&#x22;VPlane&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vplane#vplane&#x22;}]" ret="[[{&#x22;s&#x22;:&#x22;VPlane&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vplane#vplane&#x22;}]]" params="[{&#x22;n&#x22;:&#x22;plane&#x22;,&#x22;t&#x22;:[{&#x22;s&#x22;:&#x22;VPlane&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vplane#vplane&#x22;}],&#x22;d&#x22;:&#x22;The plane to read.&#x22;}]" nodiscard />

  <ApiMember kind="fn" name="VPlane.GetPointOnPlane" summary="Returns the point of the plane that is nearest to the origin. This is `m_Normal * m_Dist`." args="plane" sig="[{&#x22;s&#x22;:&#x22;VPlane.GetPointOnPlane&#x22;},{&#x22;s&#x22;:&#x22;(&#x22;},{&#x22;s&#x22;:&#x22;plane&#x22;},{&#x22;s&#x22;:&#x22;: &#x22;},{&#x22;s&#x22;:&#x22;VPlane&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vplane#vplane&#x22;},{&#x22;s&#x22;:&#x22;)&#x22;},{&#x22;s&#x22;:&#x22;: &#x22;},{&#x22;s&#x22;:&#x22;Vector&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vector#vector-1&#x22;}]" ret="[[{&#x22;s&#x22;:&#x22;Vector&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vector#vector-1&#x22;}]]" params="[{&#x22;n&#x22;:&#x22;plane&#x22;,&#x22;t&#x22;:[{&#x22;s&#x22;:&#x22;VPlane&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vplane#vplane&#x22;}],&#x22;d&#x22;:&#x22;The plane to read.&#x22;}]" nodiscard />

  <ApiMember kind="fn" name="VPlane.SnapPointToPlane" summary="Moves a point along the normal until it is on the plane, and returns the new point." args="plane, point" sig="[{&#x22;s&#x22;:&#x22;VPlane.SnapPointToPlane&#x22;},{&#x22;s&#x22;:&#x22;(&#x22;},{&#x22;s&#x22;:&#x22;plane&#x22;},{&#x22;s&#x22;:&#x22;: &#x22;},{&#x22;s&#x22;:&#x22;VPlane&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vplane#vplane&#x22;},{&#x22;s&#x22;:&#x22;, &#x22;},{&#x22;s&#x22;:&#x22;point&#x22;},{&#x22;s&#x22;:&#x22;: &#x22;},{&#x22;s&#x22;:&#x22;Vector&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vector#vector-1&#x22;},{&#x22;s&#x22;:&#x22;)&#x22;},{&#x22;s&#x22;:&#x22;: &#x22;},{&#x22;s&#x22;:&#x22;Vector&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vector#vector-1&#x22;}]" ret="[[{&#x22;s&#x22;:&#x22;Vector&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vector#vector-1&#x22;}]]" params="[{&#x22;n&#x22;:&#x22;plane&#x22;,&#x22;t&#x22;:[{&#x22;s&#x22;:&#x22;VPlane&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vplane#vplane&#x22;}],&#x22;d&#x22;:&#x22;The plane to read.&#x22;},{&#x22;n&#x22;:&#x22;point&#x22;,&#x22;t&#x22;:[{&#x22;s&#x22;:&#x22;Vector&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vector#vector-1&#x22;}],&#x22;d&#x22;:&#x22;The point to move.&#x22;}]" nodiscard />

  <ApiMember kind="fn" name="VPlane.CalculateClosestPointOnPlane" summary="Returns the point of the plane that is nearest to the given point." args="plane, point" sig="[{&#x22;s&#x22;:&#x22;VPlane.CalculateClosestPointOnPlane&#x22;},{&#x22;s&#x22;:&#x22;(&#x22;},{&#x22;s&#x22;:&#x22;plane&#x22;},{&#x22;s&#x22;:&#x22;: &#x22;},{&#x22;s&#x22;:&#x22;VPlane&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vplane#vplane&#x22;},{&#x22;s&#x22;:&#x22;, &#x22;},{&#x22;s&#x22;:&#x22;point&#x22;},{&#x22;s&#x22;:&#x22;: &#x22;},{&#x22;s&#x22;:&#x22;Vector&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vector#vector-1&#x22;},{&#x22;s&#x22;:&#x22;)&#x22;},{&#x22;s&#x22;:&#x22;: &#x22;},{&#x22;s&#x22;:&#x22;Vector&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vector#vector-1&#x22;}]" ret="[[{&#x22;s&#x22;:&#x22;Vector&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vector#vector-1&#x22;}]]" params="[{&#x22;n&#x22;:&#x22;plane&#x22;,&#x22;t&#x22;:[{&#x22;s&#x22;:&#x22;VPlane&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vplane#vplane&#x22;}],&#x22;d&#x22;:&#x22;The plane to read.&#x22;},{&#x22;n&#x22;:&#x22;point&#x22;,&#x22;t&#x22;:[{&#x22;s&#x22;:&#x22;Vector&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vector#vector-1&#x22;}],&#x22;d&#x22;:&#x22;The point to project.&#x22;}]" nodiscard />

  <ApiMember kind="fn" name="VPlane.IntersectWithPlane" summary="Finds the line where two planes meet. This function returns `true` and two points on that line. If the planes are parallel, it returns `false` and `nil` for both points." args="plane, other" sig="[{&#x22;s&#x22;:&#x22;VPlane.IntersectWithPlane&#x22;},{&#x22;s&#x22;:&#x22;(&#x22;},{&#x22;s&#x22;:&#x22;plane&#x22;},{&#x22;s&#x22;:&#x22;: &#x22;},{&#x22;s&#x22;:&#x22;VPlane&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vplane#vplane&#x22;},{&#x22;s&#x22;:&#x22;, &#x22;},{&#x22;s&#x22;:&#x22;other&#x22;},{&#x22;s&#x22;:&#x22;: &#x22;},{&#x22;s&#x22;:&#x22;VPlane&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vplane#vplane&#x22;},{&#x22;s&#x22;:&#x22;)&#x22;},{&#x22;s&#x22;:&#x22;: &#x22;},{&#x22;s&#x22;:&#x22;boolean&#x22;,&#x22;k&#x22;:&#x22;prim&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/lua/base#boolean&#x22;},{&#x22;s&#x22;:&#x22;, &#x22;},{&#x22;s&#x22;:&#x22;Vector&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vector#vector-1&#x22;},{&#x22;s&#x22;:&#x22;?&#x22;},{&#x22;s&#x22;:&#x22;, &#x22;},{&#x22;s&#x22;:&#x22;Vector&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vector#vector-1&#x22;},{&#x22;s&#x22;:&#x22;?&#x22;}]" ret="[[{&#x22;s&#x22;:&#x22;boolean&#x22;,&#x22;k&#x22;:&#x22;prim&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/lua/base#boolean&#x22;}],[{&#x22;s&#x22;:&#x22;Vector&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vector#vector-1&#x22;},{&#x22;s&#x22;:&#x22;?&#x22;}],[{&#x22;s&#x22;:&#x22;Vector&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vector#vector-1&#x22;},{&#x22;s&#x22;:&#x22;?&#x22;}]]" params="[{&#x22;n&#x22;:&#x22;plane&#x22;,&#x22;t&#x22;:[{&#x22;s&#x22;:&#x22;VPlane&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vplane#vplane&#x22;}],&#x22;d&#x22;:&#x22;The first plane.&#x22;},{&#x22;n&#x22;:&#x22;other&#x22;,&#x22;t&#x22;:[{&#x22;s&#x22;:&#x22;VPlane&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vplane#vplane&#x22;}],&#x22;d&#x22;:&#x22;The second plane.&#x22;}]" returns="[{&#x22;n&#x22;:&#x22;ok&#x22;,&#x22;t&#x22;:[{&#x22;s&#x22;:&#x22;boolean&#x22;,&#x22;k&#x22;:&#x22;prim&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/lua/base#boolean&#x22;}]},{&#x22;n&#x22;:&#x22;point1&#x22;,&#x22;t&#x22;:[{&#x22;s&#x22;:&#x22;Vector&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vector#vector-1&#x22;},{&#x22;s&#x22;:&#x22;?&#x22;}]},{&#x22;n&#x22;:&#x22;point2&#x22;,&#x22;t&#x22;:[{&#x22;s&#x22;:&#x22;Vector&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vector#vector-1&#x22;},{&#x22;s&#x22;:&#x22;?&#x22;}]}]" nodiscard>
    <ApiNotes>
      The second point is the first point plus the cross product of the two normals.
    </ApiNotes>
  </ApiMember>

  <ApiMember kind="fn" name="VPlane.IsZero" summary="Returns `true` if the distance is exactly 0 and each component of the normal is between -1e-9 and 1e-9." args="plane" sig="[{&#x22;s&#x22;:&#x22;VPlane.IsZero&#x22;},{&#x22;s&#x22;:&#x22;(&#x22;},{&#x22;s&#x22;:&#x22;plane&#x22;},{&#x22;s&#x22;:&#x22;: &#x22;},{&#x22;s&#x22;:&#x22;VPlane&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vplane#vplane&#x22;},{&#x22;s&#x22;:&#x22;)&#x22;},{&#x22;s&#x22;:&#x22;: &#x22;},{&#x22;s&#x22;:&#x22;boolean&#x22;,&#x22;k&#x22;:&#x22;prim&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/lua/base#boolean&#x22;}]" ret="[[{&#x22;s&#x22;:&#x22;boolean&#x22;,&#x22;k&#x22;:&#x22;prim&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/lua/base#boolean&#x22;}]]" params="[{&#x22;n&#x22;:&#x22;plane&#x22;,&#x22;t&#x22;:[{&#x22;s&#x22;:&#x22;VPlane&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vplane#vplane&#x22;}],&#x22;d&#x22;:&#x22;The plane to check.&#x22;}]" nodiscard />
</ApiMembers>

## SideType<ApiTag label="enum" />

The side of a plane that a point or a box is on.

<ApiEnum name="SideType" values="[[&#x22;SIDE_FRONT&#x22;,&#x22;0&#x22;,&#x22;In front of the plane, on the side that the normal points to.&#x22;],[&#x22;SIDE_BACK&#x22;,&#x22;1&#x22;,&#x22;Behind the plane.&#x22;],[&#x22;SIDE_ON&#x22;,&#x22;2&#x22;,&#x22;On the plane.&#x22;]]" />

## Frustum\_t<ApiTag label="cdata" href="/cs2/api_reference/tutorials/ffi-crash-course#ctype-and-cdata" title="cdata<struct Frustum_t>" />

<ApiSymbol inherits="[{&#x22;n&#x22;:&#x22;Frustum_t&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vplane#frustum_t-1&#x22;}]" />

A view frustum with up to eight planes. The normals of the planes point into the frustum.
The planes are stored in two `fourplanes_t` groups, with four planes in each group. Each
plane uses one lane of the SIMD arrays in its group.

The `m_frustumStruct` field of the view setup has this type.
`mathlib.FrustumPlanesFromMatrix` builds a frustum from a clip to world matrix.

A lane that is not used has a normal of `(0, 0, 0)` and a distance of `-FLT_MAX`, so it never
culls anything.

```cpp lines=false
typedef struct __declspec(align(16)) fourplanes_t {
    float nX[4], nY[4], nZ[4], dist[4];
    float xSign[4], ySign[4], zSign[4];
    float nXAbs[4], nYAbs[4], nZAbs[4];
} fourplanes_t;

typedef struct __declspec(align(16)) Frustum_t {
    fourplanes_t m_Planes[2];
} Frustum_t;
```

<ApiMembers>
  <ApiMember kind="prop" name="Frustum_t.m_Planes" summary="An array of 2 groups. The first index is 0." ret="[[{&#x22;s&#x22;:&#x22;fourplanes_t&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vplane#fourplanes_t&#x22;},{&#x22;s&#x22;:&#x22;[&#x22;},{&#x22;s&#x22;:&#x22;]&#x22;}]]" />
</ApiMembers>

## fourplanes\_t<ApiTag label="object type" />

<ApiMembers>
  <ApiMember kind="prop" name="fourplanes_t.dist" summary="The distance for each of the 4 lanes." ret="[[{&#x22;s&#x22;:&#x22;number&#x22;,&#x22;k&#x22;:&#x22;prim&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/lua/base#number&#x22;},{&#x22;s&#x22;:&#x22;[&#x22;},{&#x22;s&#x22;:&#x22;]&#x22;}]]" />

  <ApiMember kind="prop" name="fourplanes_t.nX" summary="The X component of the normal for each of the 4 lanes." ret="[[{&#x22;s&#x22;:&#x22;number&#x22;,&#x22;k&#x22;:&#x22;prim&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/lua/base#number&#x22;},{&#x22;s&#x22;:&#x22;[&#x22;},{&#x22;s&#x22;:&#x22;]&#x22;}]]" />

  <ApiMember kind="prop" name="fourplanes_t.nXAbs" summary="The absolute value of the X component of the normal for each of the 4 lanes." ret="[[{&#x22;s&#x22;:&#x22;number&#x22;,&#x22;k&#x22;:&#x22;prim&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/lua/base#number&#x22;},{&#x22;s&#x22;:&#x22;[&#x22;},{&#x22;s&#x22;:&#x22;]&#x22;}]]" />

  <ApiMember kind="prop" name="fourplanes_t.nY" summary="The Y component of the normal for each of the 4 lanes." ret="[[{&#x22;s&#x22;:&#x22;number&#x22;,&#x22;k&#x22;:&#x22;prim&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/lua/base#number&#x22;},{&#x22;s&#x22;:&#x22;[&#x22;},{&#x22;s&#x22;:&#x22;]&#x22;}]]" />

  <ApiMember kind="prop" name="fourplanes_t.nYAbs" summary="The absolute value of the Y component of the normal for each of the 4 lanes." ret="[[{&#x22;s&#x22;:&#x22;number&#x22;,&#x22;k&#x22;:&#x22;prim&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/lua/base#number&#x22;},{&#x22;s&#x22;:&#x22;[&#x22;},{&#x22;s&#x22;:&#x22;]&#x22;}]]" />

  <ApiMember kind="prop" name="fourplanes_t.nZ" summary="The Z component of the normal for each of the 4 lanes." ret="[[{&#x22;s&#x22;:&#x22;number&#x22;,&#x22;k&#x22;:&#x22;prim&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/lua/base#number&#x22;},{&#x22;s&#x22;:&#x22;[&#x22;},{&#x22;s&#x22;:&#x22;]&#x22;}]]" />

  <ApiMember kind="prop" name="fourplanes_t.nZAbs" summary="The absolute value of the Z component of the normal for each of the 4 lanes." ret="[[{&#x22;s&#x22;:&#x22;number&#x22;,&#x22;k&#x22;:&#x22;prim&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/lua/base#number&#x22;},{&#x22;s&#x22;:&#x22;[&#x22;},{&#x22;s&#x22;:&#x22;]&#x22;}]]" />

  <ApiMember kind="prop" name="fourplanes_t.xSign" summary="For each of the 4 lanes, all bits are set when the X component of the normal is negative." ret="[[{&#x22;s&#x22;:&#x22;number&#x22;,&#x22;k&#x22;:&#x22;prim&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/lua/base#number&#x22;},{&#x22;s&#x22;:&#x22;[&#x22;},{&#x22;s&#x22;:&#x22;]&#x22;}]]" />

  <ApiMember kind="prop" name="fourplanes_t.ySign" summary="The same as `xSign`, for the Y component." ret="[[{&#x22;s&#x22;:&#x22;number&#x22;,&#x22;k&#x22;:&#x22;prim&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/lua/base#number&#x22;},{&#x22;s&#x22;:&#x22;[&#x22;},{&#x22;s&#x22;:&#x22;]&#x22;}]]" />

  <ApiMember kind="prop" name="fourplanes_t.zSign" summary="The same as `xSign`, for the Z component." ret="[[{&#x22;s&#x22;:&#x22;number&#x22;,&#x22;k&#x22;:&#x22;prim&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/lua/base#number&#x22;},{&#x22;s&#x22;:&#x22;[&#x22;},{&#x22;s&#x22;:&#x22;]&#x22;}]]" />
</ApiMembers>

<Heading level={2} id="frustum_t-1">
  Frustum_t

  <ApiTag label="ctype · callable" href="/cs2/api_reference/tutorials/ffi-crash-course#ctype-and-cdata" title="ctype<struct Frustum_t>" />
</Heading>

Call `Frustum_t()` to create a frustum with no planes, which culls nothing. Call
`Frustum_t(planes)` with a Lua array of up to eight `VPlane` values to store them in order.
Call `Frustum_t(other)` to make a copy of another frustum. Any other argument throws an
error.

<ApiMembers>
  <ApiMember kind="ctor" name="Frustum_t()" summary="A frustum with no planes, which culls nothing." syntax="Frustum_t()" mm="__call" sig="[{&#x22;s&#x22;:&#x22;Frustum_t&#x22;},{&#x22;s&#x22;:&#x22;(&#x22;},{&#x22;s&#x22;:&#x22;)&#x22;},{&#x22;s&#x22;:&#x22;: &#x22;},{&#x22;s&#x22;:&#x22;Frustum_t&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vplane#frustum_t&#x22;}]" ret="[[{&#x22;s&#x22;:&#x22;Frustum_t&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vplane#frustum_t&#x22;}]]" />

  <ApiMember kind="ctor" name="Frustum_t(planes)" summary="A frustum with up to eight planes." syntax="Frustum_t(planes)" mm="__call" sig="[{&#x22;s&#x22;:&#x22;Frustum_t&#x22;},{&#x22;s&#x22;:&#x22;(&#x22;},{&#x22;s&#x22;:&#x22;planes&#x22;},{&#x22;s&#x22;:&#x22;: &#x22;},{&#x22;s&#x22;:&#x22;VPlane&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vplane#vplane&#x22;},{&#x22;s&#x22;:&#x22;[&#x22;},{&#x22;s&#x22;:&#x22;]&#x22;},{&#x22;s&#x22;:&#x22;)&#x22;},{&#x22;s&#x22;:&#x22;: &#x22;},{&#x22;s&#x22;:&#x22;Frustum_t&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vplane#frustum_t&#x22;}]" ret="[[{&#x22;s&#x22;:&#x22;Frustum_t&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vplane#frustum_t&#x22;}]]" params="[{&#x22;n&#x22;:&#x22;planes&#x22;,&#x22;t&#x22;:[{&#x22;s&#x22;:&#x22;VPlane&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vplane#vplane&#x22;},{&#x22;s&#x22;:&#x22;[&#x22;},{&#x22;s&#x22;:&#x22;]&#x22;}]}]" />

  <ApiMember kind="ctor" name="Frustum_t(self)" syntax="Frustum_t(self)" mm="__call" sig="[{&#x22;s&#x22;:&#x22;Frustum_t&#x22;},{&#x22;s&#x22;:&#x22;(&#x22;},{&#x22;s&#x22;:&#x22;self&#x22;},{&#x22;s&#x22;:&#x22;: &#x22;},{&#x22;s&#x22;:&#x22;Frustum_t&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vplane#frustum_t&#x22;},{&#x22;s&#x22;:&#x22;)&#x22;},{&#x22;s&#x22;:&#x22;: &#x22;},{&#x22;s&#x22;:&#x22;Frustum_t&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vplane#frustum_t&#x22;}]" ret="[[{&#x22;s&#x22;:&#x22;Frustum_t&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vplane#frustum_t&#x22;}]]" params="[{&#x22;n&#x22;:&#x22;self&#x22;,&#x22;t&#x22;:[{&#x22;s&#x22;:&#x22;Frustum_t&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vplane#frustum_t&#x22;}]}]" />

  <ApiMember kind="fn" name="Frustum_t.SetPlane" summary="Stores a plane at an index and updates its sign and absolute value lanes. Indexes 0 to 3 are in the first group, and indexes 4 to 7 are in the second group." args="frustum, index, plane" sig="[{&#x22;s&#x22;:&#x22;Frustum_t.SetPlane&#x22;},{&#x22;s&#x22;:&#x22;(&#x22;},{&#x22;s&#x22;:&#x22;frustum&#x22;},{&#x22;s&#x22;:&#x22;: &#x22;},{&#x22;s&#x22;:&#x22;Frustum_t&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vplane#frustum_t&#x22;},{&#x22;s&#x22;:&#x22;, &#x22;},{&#x22;s&#x22;:&#x22;index&#x22;},{&#x22;s&#x22;:&#x22;: &#x22;},{&#x22;s&#x22;:&#x22;integer&#x22;,&#x22;k&#x22;:&#x22;prim&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/lua/base#integer&#x22;},{&#x22;s&#x22;:&#x22;, &#x22;},{&#x22;s&#x22;:&#x22;plane&#x22;},{&#x22;s&#x22;:&#x22;: &#x22;},{&#x22;s&#x22;:&#x22;VPlane&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vplane#vplane&#x22;},{&#x22;s&#x22;:&#x22;)&#x22;}]" params="[{&#x22;n&#x22;:&#x22;frustum&#x22;,&#x22;t&#x22;:[{&#x22;s&#x22;:&#x22;Frustum_t&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vplane#frustum_t&#x22;}],&#x22;d&#x22;:&#x22;The frustum to change.&#x22;},{&#x22;n&#x22;:&#x22;index&#x22;,&#x22;t&#x22;:[{&#x22;s&#x22;:&#x22;integer&#x22;,&#x22;k&#x22;:&#x22;prim&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/lua/base#integer&#x22;}],&#x22;d&#x22;:&#x22;The index of the plane, from 0 to 7.&#x22;},{&#x22;n&#x22;:&#x22;plane&#x22;,&#x22;t&#x22;:[{&#x22;s&#x22;:&#x22;VPlane&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vplane#vplane&#x22;}],&#x22;d&#x22;:&#x22;The plane to store.&#x22;}]" />

  <ApiMember kind="fn" name="Frustum_t.GetPlane" summary="Returns the plane at an index." args="frustum, index" sig="[{&#x22;s&#x22;:&#x22;Frustum_t.GetPlane&#x22;},{&#x22;s&#x22;:&#x22;(&#x22;},{&#x22;s&#x22;:&#x22;frustum&#x22;},{&#x22;s&#x22;:&#x22;: &#x22;},{&#x22;s&#x22;:&#x22;Frustum_t&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vplane#frustum_t&#x22;},{&#x22;s&#x22;:&#x22;, &#x22;},{&#x22;s&#x22;:&#x22;index&#x22;},{&#x22;s&#x22;:&#x22;: &#x22;},{&#x22;s&#x22;:&#x22;integer&#x22;,&#x22;k&#x22;:&#x22;prim&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/lua/base#integer&#x22;},{&#x22;s&#x22;:&#x22;)&#x22;},{&#x22;s&#x22;:&#x22;: &#x22;},{&#x22;s&#x22;:&#x22;VPlane&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vplane#vplane&#x22;}]" ret="[[{&#x22;s&#x22;:&#x22;VPlane&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vplane#vplane&#x22;}]]" params="[{&#x22;n&#x22;:&#x22;frustum&#x22;,&#x22;t&#x22;:[{&#x22;s&#x22;:&#x22;Frustum_t&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vplane#frustum_t&#x22;}],&#x22;d&#x22;:&#x22;The frustum to read.&#x22;},{&#x22;n&#x22;:&#x22;index&#x22;,&#x22;t&#x22;:[{&#x22;s&#x22;:&#x22;integer&#x22;,&#x22;k&#x22;:&#x22;prim&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/lua/base#integer&#x22;}],&#x22;d&#x22;:&#x22;The index of the plane, from 0 to 7.&#x22;}]" nodiscard />

  <ApiMember kind="fn" name="Frustum_t.SetPlanes" summary="Removes every plane, then stores the planes of a Lua array in order, starting at index 0." args="frustum, planes" sig="[{&#x22;s&#x22;:&#x22;Frustum_t.SetPlanes&#x22;},{&#x22;s&#x22;:&#x22;(&#x22;},{&#x22;s&#x22;:&#x22;frustum&#x22;},{&#x22;s&#x22;:&#x22;: &#x22;},{&#x22;s&#x22;:&#x22;Frustum_t&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vplane#frustum_t&#x22;},{&#x22;s&#x22;:&#x22;, &#x22;},{&#x22;s&#x22;:&#x22;planes&#x22;},{&#x22;s&#x22;:&#x22;: &#x22;},{&#x22;s&#x22;:&#x22;VPlane&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vplane#vplane&#x22;},{&#x22;s&#x22;:&#x22;[&#x22;},{&#x22;s&#x22;:&#x22;]&#x22;},{&#x22;s&#x22;:&#x22;)&#x22;}]" params="[{&#x22;n&#x22;:&#x22;frustum&#x22;,&#x22;t&#x22;:[{&#x22;s&#x22;:&#x22;Frustum_t&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vplane#frustum_t&#x22;}],&#x22;d&#x22;:&#x22;The frustum to change.&#x22;},{&#x22;n&#x22;:&#x22;planes&#x22;,&#x22;t&#x22;:[{&#x22;s&#x22;:&#x22;VPlane&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vplane#vplane&#x22;},{&#x22;s&#x22;:&#x22;[&#x22;},{&#x22;s&#x22;:&#x22;]&#x22;}],&#x22;d&#x22;:&#x22;Up to eight planes.&#x22;}]" />

  <ApiMember kind="fn" name="Frustum_t.GetPlanes" summary="Returns the first `count` planes as a Lua array." args="frustum, count?" sig="[{&#x22;s&#x22;:&#x22;Frustum_t.GetPlanes&#x22;},{&#x22;s&#x22;:&#x22;(&#x22;},{&#x22;s&#x22;:&#x22;frustum&#x22;},{&#x22;s&#x22;:&#x22;: &#x22;},{&#x22;s&#x22;:&#x22;Frustum_t&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vplane#frustum_t&#x22;},{&#x22;s&#x22;:&#x22;[, &#x22;},{&#x22;s&#x22;:&#x22;count&#x22;},{&#x22;s&#x22;:&#x22;: &#x22;},{&#x22;s&#x22;:&#x22;integer&#x22;,&#x22;k&#x22;:&#x22;prim&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/lua/base#integer&#x22;},{&#x22;s&#x22;:&#x22;]&#x22;},{&#x22;s&#x22;:&#x22;)&#x22;},{&#x22;s&#x22;:&#x22;: &#x22;},{&#x22;s&#x22;:&#x22;VPlane&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vplane#vplane&#x22;},{&#x22;s&#x22;:&#x22;[&#x22;},{&#x22;s&#x22;:&#x22;]&#x22;}]" ret="[[{&#x22;s&#x22;:&#x22;VPlane&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vplane#vplane&#x22;},{&#x22;s&#x22;:&#x22;[&#x22;},{&#x22;s&#x22;:&#x22;]&#x22;}]]" params="[{&#x22;n&#x22;:&#x22;frustum&#x22;,&#x22;t&#x22;:[{&#x22;s&#x22;:&#x22;Frustum_t&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vplane#frustum_t&#x22;}],&#x22;d&#x22;:&#x22;The frustum to read.&#x22;},{&#x22;n&#x22;:&#x22;count&#x22;,&#x22;t&#x22;:[{&#x22;s&#x22;:&#x22;integer&#x22;,&#x22;k&#x22;:&#x22;prim&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/lua/base#integer&#x22;}],&#x22;d&#x22;:&#x22;The number of planes, from 0 to 8. The default is 6.&#x22;,&#x22;o&#x22;:true}]" nodiscard />

  <ApiMember kind="fn" name="Frustum_t.Clear" summary="Removes every plane, so the frustum culls nothing." args="frustum" sig="[{&#x22;s&#x22;:&#x22;Frustum_t.Clear&#x22;},{&#x22;s&#x22;:&#x22;(&#x22;},{&#x22;s&#x22;:&#x22;frustum&#x22;},{&#x22;s&#x22;:&#x22;: &#x22;},{&#x22;s&#x22;:&#x22;Frustum_t&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vplane#frustum_t&#x22;},{&#x22;s&#x22;:&#x22;)&#x22;}]" params="[{&#x22;n&#x22;:&#x22;frustum&#x22;,&#x22;t&#x22;:[{&#x22;s&#x22;:&#x22;Frustum_t&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vplane#frustum_t&#x22;}],&#x22;d&#x22;:&#x22;The frustum to change.&#x22;}]" />

  <ApiMember kind="fn" name="Frustum_t.CullPoint" summary="Returns `true` if the point is behind any plane of the frustum. A point that is exactly on a plane is not culled." args="frustum, point" sig="[{&#x22;s&#x22;:&#x22;Frustum_t.CullPoint&#x22;},{&#x22;s&#x22;:&#x22;(&#x22;},{&#x22;s&#x22;:&#x22;frustum&#x22;},{&#x22;s&#x22;:&#x22;: &#x22;},{&#x22;s&#x22;:&#x22;Frustum_t&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vplane#frustum_t&#x22;},{&#x22;s&#x22;:&#x22;, &#x22;},{&#x22;s&#x22;:&#x22;point&#x22;},{&#x22;s&#x22;:&#x22;: &#x22;},{&#x22;s&#x22;:&#x22;Vector&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vector#vector-1&#x22;},{&#x22;s&#x22;:&#x22;)&#x22;},{&#x22;s&#x22;:&#x22;: &#x22;},{&#x22;s&#x22;:&#x22;boolean&#x22;,&#x22;k&#x22;:&#x22;prim&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/lua/base#boolean&#x22;}]" ret="[[{&#x22;s&#x22;:&#x22;boolean&#x22;,&#x22;k&#x22;:&#x22;prim&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/lua/base#boolean&#x22;}]]" params="[{&#x22;n&#x22;:&#x22;frustum&#x22;,&#x22;t&#x22;:[{&#x22;s&#x22;:&#x22;Frustum_t&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vplane#frustum_t&#x22;}],&#x22;d&#x22;:&#x22;The frustum to read.&#x22;},{&#x22;n&#x22;:&#x22;point&#x22;,&#x22;t&#x22;:[{&#x22;s&#x22;:&#x22;Vector&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vector#vector-1&#x22;}],&#x22;d&#x22;:&#x22;The point to test.&#x22;}]" nodiscard />

  <ApiMember kind="fn" name="Frustum_t.CullBox" summary="Returns `true` if the box is completely behind any plane of the frustum." args="frustum, mins, maxs" sig="[{&#x22;s&#x22;:&#x22;Frustum_t.CullBox&#x22;},{&#x22;s&#x22;:&#x22;(&#x22;},{&#x22;s&#x22;:&#x22;frustum&#x22;},{&#x22;s&#x22;:&#x22;: &#x22;},{&#x22;s&#x22;:&#x22;Frustum_t&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vplane#frustum_t&#x22;},{&#x22;s&#x22;:&#x22;, &#x22;},{&#x22;s&#x22;:&#x22;mins&#x22;},{&#x22;s&#x22;:&#x22;: &#x22;},{&#x22;s&#x22;:&#x22;Vector&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vector#vector-1&#x22;},{&#x22;s&#x22;:&#x22;, &#x22;},{&#x22;s&#x22;:&#x22;maxs&#x22;},{&#x22;s&#x22;:&#x22;: &#x22;},{&#x22;s&#x22;:&#x22;Vector&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vector#vector-1&#x22;},{&#x22;s&#x22;:&#x22;)&#x22;},{&#x22;s&#x22;:&#x22;: &#x22;},{&#x22;s&#x22;:&#x22;boolean&#x22;,&#x22;k&#x22;:&#x22;prim&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/lua/base#boolean&#x22;}]" ret="[[{&#x22;s&#x22;:&#x22;boolean&#x22;,&#x22;k&#x22;:&#x22;prim&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/lua/base#boolean&#x22;}]]" params="[{&#x22;n&#x22;:&#x22;frustum&#x22;,&#x22;t&#x22;:[{&#x22;s&#x22;:&#x22;Frustum_t&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vplane#frustum_t&#x22;}],&#x22;d&#x22;:&#x22;The frustum to read.&#x22;},{&#x22;n&#x22;:&#x22;mins&#x22;,&#x22;t&#x22;:[{&#x22;s&#x22;:&#x22;Vector&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vector#vector-1&#x22;}],&#x22;d&#x22;:&#x22;The minimum corner of the box.&#x22;},{&#x22;n&#x22;:&#x22;maxs&#x22;,&#x22;t&#x22;:[{&#x22;s&#x22;:&#x22;Vector&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vector#vector-1&#x22;}],&#x22;d&#x22;:&#x22;The maximum corner of the box.&#x22;}]" nodiscard />

  <ApiMember kind="fn" name="Frustum_t.CullBox" summary="Returns `true` if the box is completely behind any plane of the frustum. This is the same as the version with `mins` and `maxs`, with the box given as one `AABB_t`." id="Frustum_t-CullBox-2" args="frustum, bounds" sig="[{&#x22;s&#x22;:&#x22;Frustum_t.CullBox&#x22;},{&#x22;s&#x22;:&#x22;(&#x22;},{&#x22;s&#x22;:&#x22;frustum&#x22;},{&#x22;s&#x22;:&#x22;: &#x22;},{&#x22;s&#x22;:&#x22;Frustum_t&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vplane#frustum_t&#x22;},{&#x22;s&#x22;:&#x22;, &#x22;},{&#x22;s&#x22;:&#x22;bounds&#x22;},{&#x22;s&#x22;:&#x22;: &#x22;},{&#x22;s&#x22;:&#x22;AABB_t&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/aabb#aabb_t&#x22;},{&#x22;s&#x22;:&#x22;)&#x22;},{&#x22;s&#x22;:&#x22;: &#x22;},{&#x22;s&#x22;:&#x22;boolean&#x22;,&#x22;k&#x22;:&#x22;prim&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/lua/base#boolean&#x22;}]" ret="[[{&#x22;s&#x22;:&#x22;boolean&#x22;,&#x22;k&#x22;:&#x22;prim&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/lua/base#boolean&#x22;}]]" params="[{&#x22;n&#x22;:&#x22;frustum&#x22;,&#x22;t&#x22;:[{&#x22;s&#x22;:&#x22;Frustum_t&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/vplane#frustum_t&#x22;}],&#x22;d&#x22;:&#x22;The frustum to read.&#x22;},{&#x22;n&#x22;:&#x22;bounds&#x22;,&#x22;t&#x22;:[{&#x22;s&#x22;:&#x22;AABB_t&#x22;,&#x22;k&#x22;:&#x22;class&#x22;,&#x22;h&#x22;:&#x22;/cs2/api_reference/mathlib/aabb#aabb_t&#x22;}],&#x22;d&#x22;:&#x22;The box to test.&#x22;}]" nodiscard />
</ApiMembers>
