]> git.donarmstrong.com Git - lilypond.git/blob - lily/performer.cc
release: 0.1.11
[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   DOUT << "\n" << name() << " {";
49   do_print();
50   DOUT << "}";
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     {
70         creation_processing();
71     }
72   return do_try_request (r);
73 }
74
75 void
76 Performer::creation_processing()
77 {
78   if (!init_b_) 
79     {
80         do_creation_processing();
81         init_b_ = true;
82     }
83 }
84
85 void
86 Performer::do_creation_processing()
87 {
88 }
89
90 void
91 Performer::do_removal_processing()
92 {
93 }