box2d 3.0.0
A 2D physics engine for games
 
Loading...
Searching...
No Matches
event_types.h
1// SPDX-FileCopyrightText: 2023 Erin Catto
2// SPDX-License-Identifier: MIT
3
4#pragma once
5
6#include "box2d/id.h"
7#include "box2d/manifold.h"
8
9#include <stdbool.h>
10#include <stddef.h>
11#include <stdint.h>
12
15{
16 b2ShapeId sensorShapeId;
17 b2ShapeId visitorShapeId;
19
22{
23 b2ShapeId sensorShapeId;
24 b2ShapeId visitorShapeId;
26
30typedef struct b2SensorEvents
31{
32 b2SensorBeginTouchEvent* beginEvents;
33 b2SensorEndTouchEvent* endEvents;
34 int beginCount;
35 int endCount;
37
41{
42 b2ShapeId shapeIdA;
43 b2ShapeId shapeIdB;
44 b2Manifold manifold;
46
49{
50 b2ShapeId shapeIdA;
51 b2ShapeId shapeIdB;
53
57typedef struct b2ContactEvents
58{
59 b2ContactBeginTouchEvent* beginEvents;
60 b2ContactEndTouchEvent* endEvents;
61 int beginCount;
62 int endCount;
64
67typedef struct b2ContactData
68{
69 b2ShapeId shapeIdA;
70 b2ShapeId shapeIdB;
71 b2Manifold manifold;
Definition event_types.h:41
Definition event_types.h:68
An end touch event is generated when two shapes stop touching.
Definition event_types.h:49
Definition event_types.h:58
Contact manifold convex shapes.
Definition manifold.h:44
A begin touch event is generated when a shape starts to overlap a sensor shape.
Definition event_types.h:15
An end touch event is generated when a shape stops overlapping a sensor shape.
Definition event_types.h:22
Definition event_types.h:31
References a shape instance.
Definition id.h:31