summaryrefslogtreecommitdiff
path: root/src/common.h
diff options
context:
space:
mode:
authorepoch <epoch@hacking.allowed.org>2017-01-03 00:30:28 -0600
committerepoch <epoch@hacking.allowed.org>2017-01-03 00:30:28 -0600
commitebde46bc82bebf478db67abef5b7dc88c014706b (patch)
tree77121f0c18b1845b8c3cfdfec962e9c5b2ec7e67 /src/common.h
parentf7353ec277198b295c6c842a4a4a07b403b2a572 (diff)
downloadhackvr-ebde46bc82bebf478db67abef5b7dc88c014706b.tar.gz
hackvr-ebde46bc82bebf478db67abef5b7dc88c014706b.zip
lots and lots of shit. opengl shit is barely worked on. new pl script to obj2hackvr using more than just triangles.http://hackaday.com/blog/http://hackaday.com/blog/
Diffstat (limited to 'src/common.h')
-rw-r--r--src/common.h59
1 files changed, 17 insertions, 42 deletions
diff --git a/src/common.h b/src/common.h
index 8f59c55..24011f7 100644
--- a/src/common.h
+++ b/src/common.h
@@ -31,68 +31,43 @@ struct camera {
real zoom;
} camera;
-struct c3_line {
+typedef struct c3_line {
char *id;
c3_t p1;
c3_t p2;
-};
+} cs_l_t;
+
+typedef struct cs_shape {
+ char *id;
+ unsigned char len;
+ cs_t p[MAX_SIDES];
+} cs_s_t;
-struct c3_shape {//use array or linked list?
+typedef struct c2_shape {
+ char *id;
+ unsigned char len;
+ c2_t p[MAX_SIDES];
+} c2_s_t;
+
+typedef struct c3_shape {//use array or linked list?
char *id;
unsigned char len;
c3_t p[MAX_SIDES];
-};
+} c3_s_t;
-struct mainwin {
+struct global {
int x;
int y;
- unsigned int depth;
- int mousex;
- int mousey;
- int rmousex;
- int rmousey;
- int buttonpressed;
- unsigned int width;
- unsigned int height;
- unsigned int border_width;
- XColor colors[256];
- int xoff;
int math_error;
- int mapxoff;
- int mapyoff;
- int split_screen;
- int split_flip;//1 or -1
char *user;
- char greyscale;
char headless;
- char drawminimap;//flag
- char draw3d;//flag
char debug;//flag
- char drawsky;//flag
- char zsort;
- char red_and_blue;
- char force_redraw;
char selected_object[256];//meh
real mmz;
- XColor green;
- XColor red;
- XColor blue;
- XColor redblue[2];
- Colormap color_map;
- Display *dpy;
- Window w;
- Pixmap backbuffer;
- Pixmap cleanbackbuffer;
- GC gc;
- GC backgc;
struct c3_shape *shape[SHAPES];
int shapes;
int derp;
- int root_window;
real split;
- int oldfps;
- int fps;
- int oldtime;
};
#endif