Skip to content

Engine → Physics → physics_layers.h

physics_layer_mask

Syntax

struct physics_layer_mask

Variables

AccessNameTypeDefaultDescription
publicbitsu320xFFFFFFFFu

Functions

Public

all

[[nodiscard]] static constexpr physics_layer_mask all() noexcept;

Every layer.

includes

[[nodiscard]] constexpr bool includes(
    u8 layer) const noexcept;

True when the layer's bit is set (false for indices of 32 or more).

none

[[nodiscard]] static constexpr physics_layer_mask none() noexcept;

No layer.

only

[[nodiscard]] static constexpr physics_layer_mask only(
    u8 layer) noexcept;

Exactly one layer (indices of 32 or more yield the empty mask).

with

[[nodiscard]] constexpr physics_layer_mask with(
    u8 layer) const noexcept;

This mask with the layer added.

without

[[nodiscard]] constexpr physics_layer_mask without(
    u8 layer) const noexcept;

This mask with the layer removed.

Operator Overloads

Public

operator==

[[nodiscard]] constexpr bool operator==(
    const physics_layer_mask &) const noexcept = default;