# HG changeset patch # User Daniele Nicolodi # Date 1436476102 -7200 # Node ID 1de805d2d37a24e3a2781b015e8733fffe85cb73 # Parent dfbee05fe464bc545544a8a60b37ab64dc86f5c4 Reuse beatnote enum also for dedrift reference selection diff -r dfbee05fe464 -r 1de805d2d37a FXAnalyse.c --- a/FXAnalyse.c Thu Jul 09 23:05:43 2015 +0200 +++ b/FXAnalyse.c Thu Jul 09 23:08:22 2015 +0200 @@ -346,11 +346,6 @@ // dedrift -enum { - DEDRIFT_REFERENCE_MICROWAVE = 0, - DEDRIFT_REFERENCE_HG = 1, -}; - struct dedrift { int enabled; // dedrift enabled int proportional; // enable proportional correction @@ -374,7 +369,7 @@ struct dedrift dedrift = { .enabled = FALSE, .proportional = FALSE, - .reference = DEDRIFT_REFERENCE_MICROWAVE, + .reference = MICROWAVE, .sign = +1, .x2 = FALSE, .keep_freq = TRUE, @@ -1538,10 +1533,10 @@ // select dedrift reference double f = 0.0; switch (dedrift.reference) { - case DEDRIFT_REFERENCE_MICROWAVE: + case MICROWAVE: f = Math2; break; - case DEDRIFT_REFERENCE_HG: + case HG: f = Ch2 * 1062.5 / 1542.2; break; }