summaryrefslogtreecommitdiff
path: root/dat.h
diff options
context:
space:
mode:
authorrodri <rgl@antares-labs.eu>2020-02-20 22:02:08 +0000
committerrodri <rgl@antares-labs.eu>2020-02-20 22:02:08 +0000
commit168a16b70a928ed64061bdac7fc9d52235c3f9fc (patch)
tree50ad23804ba927af802d42f2b7a450200fcbf2a7 /dat.h
downloadballistics-168a16b70a928ed64061bdac7fc9d52235c3f9fc.tar.gz
ballistics-168a16b70a928ed64061bdac7fc9d52235c3f9fc.tar.bz2
ballistics-168a16b70a928ed64061bdac7fc9d52235c3f9fc.zip
git release.
Diffstat (limited to 'dat.h')
-rw-r--r--dat.h32
1 files changed, 32 insertions, 0 deletions
diff --git a/dat.h b/dat.h
new file mode 100644
index 0000000..f1aff88
--- /dev/null
+++ b/dat.h
@@ -0,0 +1,32 @@
+#define DEG 0.01745329251994330
+#define Eg 9.81
+#define PIX2M 0.001
+#define M2PIX (1.0/PIX2M)
+
+enum {
+ STACK = 8192,
+ SEC = 1000,
+ FPS = 60,
+};
+
+enum {
+ Stheta = 0,
+ Spos,
+ Svel,
+ Sdeltax,
+ Seta,
+ SLEN,
+};
+
+typedef struct Vector Vector;
+typedef double Matrix[3][3];
+typedef struct Projectile Projectile;
+
+struct Vector {
+ double x, y, w;
+};
+
+struct Projectile {
+ Vector p, v;
+ double mass;
+};