diff options
| author | erdgeist <erdgeist@bauklotz.fritz.box> | 2017-04-08 14:21:36 +0200 |
|---|---|---|
| committer | erdgeist <erdgeist@bauklotz.fritz.box> | 2017-04-08 14:21:36 +0200 |
| commit | f2683a4b707cd714b7f540ebf6482563df83d51e (patch) | |
| tree | de4941add99f0eb1642aa57c6af180b4ee70119a /config.h | |
| parent | 78d309a97b782bd6ab2716fa7595bb3f409479e3 (diff) | |
Near complete rewrite.
Diffstat (limited to 'config.h')
| -rw-r--r-- | config.h | 27 |
1 files changed, 18 insertions, 9 deletions
| @@ -1,8 +1,10 @@ | |||
| 1 | #pragma once | 1 | #pragma once |
| 2 | 2 | ||
| 3 | #include <stdint.h> | 3 | #include <stdint.h> |
| 4 | #include "geometry.h" | ||
| 4 | 5 | ||
| 5 | #define MAX_LINECOUNT 32 | 6 | #define MAX_LINECOUNT 32 |
| 7 | #define CALIB_DEBUG | ||
| 6 | 8 | ||
| 7 | extern int g_min_y, g_max_y; | 9 | extern int g_min_y, g_max_y; |
| 8 | 10 | ||
| @@ -37,14 +39,21 @@ typedef enum { | |||
| 37 | playing = 2 | 39 | playing = 2 |
| 38 | } StringPlaying; | 40 | } StringPlaying; |
| 39 | 41 | ||
| 40 | typedef struct { | 42 | typedef enum { |
| 41 | int x0; int y0; | 43 | sel_none = 0, |
| 42 | int x1; int y1; | 44 | sel_min_y = 1, |
| 43 | } LLine; | 45 | sel_max_y = 2, |
| 46 | sel_2_oct = 3, | ||
| 47 | sel_3_oct_top = 4, | ||
| 48 | sel_3_oct_bottom = 5 | ||
| 49 | } ConfigSelect; | ||
| 44 | 50 | ||
| 45 | typedef struct { | 51 | typedef enum { |
| 46 | int x; int y; | 52 | source_none = 0, |
| 47 | } LPoint; | 53 | source_harfe = 1, |
| 54 | source_file = 2, | ||
| 55 | source_edit = 3 | ||
| 56 | } ConfigSource; | ||
| 48 | 57 | ||
| 49 | typedef struct { | 58 | typedef struct { |
| 50 | StringMode mode; | 59 | StringMode mode; |
| @@ -70,6 +79,6 @@ extern StringConfig g_string_conf[MAX_LINECOUNT]; | |||
| 70 | extern int g_string_count; | 79 | extern int g_string_count; |
| 71 | void config_reset(); | 80 | void config_reset(); |
| 72 | int config_handle_line( char *line); | 81 | int config_handle_line( char *line); |
| 73 | void config_dumpglobals(char *out, size_t outsize); | 82 | size_t config_dumpglobals(char *out, size_t outsize); |
| 74 | void config_dumpstring(int string, char *out, size_t outsize); | 83 | size_t config_dumpstring(int string, char *out, size_t outsize); |
| 75 | char *config_midi_note_to_string(int string); | 84 | char *config_midi_note_to_string(int string); |
