-
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathgeometry.h
More file actions
14 lines (9 loc) · 554 Bytes
/
geometry.h
File metadata and controls
14 lines (9 loc) · 554 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
#ifndef GEOMETRY_H
#define GEOMETRY_H
#include "simulation.h"
typedef enum { x, y } axis;
bool check_y_bounce(long double slope, long double table_width, long double table_height, bool positive, point in_point, point *out_point);
bool check_x_bounce(long double slope, long double table_width, long double table_height, bool positive, point in_point, point *out_point);
long double calculate_segment_length(point a, point b);
point calculate_segment_end(long double slope, point p, long double length, bool positive, axis axis);
#endif //GEOMETRY_H