]> git.donarmstrong.com Git - lilypond.git/blob - lily/include/midi-def.hh
patch::: 0.0.73pre.jcn1: epsilon performance
[lilypond.git] / lily / include / midi-def.hh
1 /*
2   midi-def.hh -- declare Midi_def
3
4   source file of the GNU LilyPond music typesetter
5
6   (c) 1997 Jan Nieuwenhuizen <jan@digicash.com>
7 */
8
9
10 #ifndef MIDI_DEF_HH
11 #define MIDI_DEF_HH
12 #include "lily-proto.hh"
13 #include "real.hh"
14 #include "string.hh"
15 #include "moment.hh"
16
17
18 /** 
19  */
20 struct Midi_def {
21     // ugh!
22     static int den_i_s;
23     static int num_i_s;
24
25     /// output file name
26     String outfile_str_;
27
28     Assoc<String, Real> *real_vars_p_;
29     Input_performer* iperf_p_;
30
31     /// duration of whole note
32     Real whole_seconds_f_;
33
34     Midi_def();
35     Midi_def( Midi_def const& midi_c_r );
36     ~Midi_def();
37
38     Real duration_to_seconds_f(Moment);
39     Global_translator* get_global_translator_p() const;
40     Real get_var( String s ) const;
41     int get_tempo_i( Moment moment );
42     void print() const;
43     void set( Input_performer* iperf_p );
44     void set_var( String s, Real r );
45     void set_tempo( Moment moment, int count_per_minute_i );
46 };
47
48 #endif // MIDI_DEF_HH
49