]> git.donarmstrong.com Git - lilypond.git/blob - lily/performer.cc
release: 0.1.7
[lilypond.git] / lily / performer.cc
1 /*
2   performer.cc -- implement Performer
3
4   source file of the GNU LilyPond music typesetter
5
6   (c) 1996, 1997 Han-Wen Nienhuys <hanwen@stack.nl>
7                  Jan Nieuwenhuizen <jan@digicash.com>
8  */
9
10
11 #include "performer-group-performer.hh"
12 #include "debug.hh"
13
14
15 IMPLEMENT_IS_TYPE_B(Performer);
16
17 Performer::Performer()
18 {
19     daddy_perf_l_ = 0;
20     init_b_ =false;
21 }
22
23 Performer::~Performer()
24 {
25 }
26
27 void
28 Performer::do_print() const
29 {
30 }
31
32 void 
33 Performer::play( Audio_element* p ) 
34
35     daddy_perf_l_->play( p ); 
36 }
37
38 int
39 Performer::get_tempo_i()const
40 {
41     return daddy_perf_l_->get_tempo_i();
42 }
43
44 void
45 Performer::print() const
46 {
47 #ifndef NPRINT
48     mtor << "\n" << name() << " {";
49     do_print();
50     mtor << "}";
51 #endif
52 }
53
54 void
55 Performer::process_requests()
56 {
57 }
58
59 bool 
60 Performer::do_try_request( Request* req_l )
61 {
62     return false;
63 }
64
65 bool
66 Performer::try_request(Request*r)
67 {
68     if (!init_b_) { 
69         creation_processing();
70     }
71     return do_try_request(r);
72 }
73
74 void
75 Performer::creation_processing()
76 {
77     if (!init_b_) { 
78         do_creation_processing();
79         init_b_ = true;
80     }
81 }
82
83 void
84 Performer::do_creation_processing()
85 {
86 }
87
88 void
89 Performer::do_removal_processing()
90 {
91 }