A holder for contact filtering data. More...
#include <Filter.hpp>
Public Types | |
using | bits_type = std::uint16_t |
Bits type definition. More... | |
using | index_type = std::int16_t |
Index type definition. More... | |
Public Attributes | |
bits_type | categoryBits = 0x0001 |
The collision category bits. More... | |
bits_type | maskBits = 0xFFFF |
The collision mask bits. More... | |
index_type | groupIndex = 0 |
Group index. More... | |
Related Functions | |
(Note that these are not member functions.) | |
PLAYRHO_CONSTEXPR bool | operator== (const Filter lhs, const Filter rhs) noexcept |
Equality operator. More... | |
PLAYRHO_CONSTEXPR bool | operator!= (const Filter lhs, const Filter rhs) noexcept |
Inequality operator. More... | |
bool | ShouldCollide (const Filter filterA, const Filter filterB) noexcept |
Determines whether collision processing should be performed. More... | |
Detailed Description
A holder for contact filtering data.
- Note
- This data structure size is 6-bytes.
Definition at line 33 of file Filter.hpp.
Member Typedef Documentation
◆ bits_type
using playrho::Filter::bits_type = std::uint16_t |
Bits type definition.
Definition at line 37 of file Filter.hpp.
◆ index_type
using playrho::Filter::index_type = std::int16_t |
Index type definition.
Definition at line 41 of file Filter.hpp.
Friends And Related Function Documentation
◆ operator==()
|
related |
Equality operator.
Definition at line 66 of file Filter.hpp.
◆ operator!=()
|
related |
Inequality operator.
Definition at line 75 of file Filter.hpp.
◆ ShouldCollide()
Determines whether collision processing should be performed.
Definition at line 82 of file Filter.hpp.
Member Data Documentation
◆ categoryBits
bits_type playrho::Filter::categoryBits = 0x0001 |
The collision category bits.
- Note
- Normally you would just set one bit.
Definition at line 47 of file Filter.hpp.
◆ maskBits
bits_type playrho::Filter::maskBits = 0xFFFF |
The collision mask bits.
This states the categories that this shape would accept for collision.
Definition at line 53 of file Filter.hpp.
◆ groupIndex
index_type playrho::Filter::groupIndex = 0 |
Group index.
Collision groups allow a certain group of objects to never collide (negative) or always collide (positive). Zero means no collision group. Non-zero group filtering always wins against the mask bits.
Definition at line 61 of file Filter.hpp.
The documentation for this struct was generated from the following file:
- Dynamics/Filter.hpp