From f2683a4b707cd714b7f540ebf6482563df83d51e Mon Sep 17 00:00:00 2001 From: erdgeist Date: Sat, 8 Apr 2017 14:21:36 +0200 Subject: Near complete rewrite. --- config.h | 27 ++++++++++++++++++--------- 1 file changed, 18 insertions(+), 9 deletions(-) (limited to 'config.h') diff --git a/config.h b/config.h index d7399fa..64f7689 100644 --- a/config.h +++ b/config.h @@ -1,8 +1,10 @@ #pragma once #include +#include "geometry.h" #define MAX_LINECOUNT 32 +#define CALIB_DEBUG extern int g_min_y, g_max_y; @@ -37,14 +39,21 @@ typedef enum { playing = 2 } StringPlaying; -typedef struct { - int x0; int y0; - int x1; int y1; -} LLine; +typedef enum { + sel_none = 0, + sel_min_y = 1, + sel_max_y = 2, + sel_2_oct = 3, + sel_3_oct_top = 4, + sel_3_oct_bottom = 5 +} ConfigSelect; -typedef struct { - int x; int y; -} LPoint; +typedef enum { + source_none = 0, + source_harfe = 1, + source_file = 2, + source_edit = 3 +} ConfigSource; typedef struct { StringMode mode; @@ -70,6 +79,6 @@ extern StringConfig g_string_conf[MAX_LINECOUNT]; extern int g_string_count; void config_reset(); int config_handle_line( char *line); -void config_dumpglobals(char *out, size_t outsize); -void config_dumpstring(int string, char *out, size_t outsize); +size_t config_dumpglobals(char *out, size_t outsize); +size_t config_dumpstring(int string, char *out, size_t outsize); char *config_midi_note_to_string(int string); -- cgit v1.2.3