Toast Engine
Toggle main menu visibility
Loading...
Searching...
No Matches
shape_query.hpp
Go to the documentation of this file.
1
6
7
#pragma once
8
9
#include "
body.hpp
"
10
#include "
shape.hpp
"
11
12
#include <glm/glm.hpp>
13
14
namespace
physics {
15
17
struct
QueryContact
{
18
BodyID
body;
19
ShapeID
shape;
20
glm::vec3 normal = {};
21
glm::vec3 point = {};
22
float
penetration = 0.0f;
23
};
24
25
struct
SweepHit
{
26
bool
hit =
false
;
27
float
fraction = 1.0f;
28
glm::vec3 position = {};
29
glm::vec3 normal = {};
30
glm::vec3 point = {};
31
BodyID
body;
32
ShapeID
shape;
33
};
34
35
}
body.hpp
Body identifiers, creation data, and copied runtime state.
shape.hpp
Shape identifiers, geometry, and runtime records.
physics::BodyID
Definition
body.hpp:20
physics::QueryContact
normal points out of the obstacle toward the query shape
Definition
shape_query.hpp:17
physics::ShapeID
Definition
shape.hpp:29
physics::SweepHit
Definition
shape_query.hpp:25
engine
src
toast
physics
shape_query.hpp
Generated by
1.17.0