]> git.donarmstrong.com Git - lilypond.git/commitdiff
lilypond-1.1.52
authorfred <fred>
Tue, 26 Mar 2002 22:14:34 +0000 (22:14 +0000)
committerfred <fred>
Tue, 26 Mar 2002 22:14:34 +0000 (22:14 +0000)
Documentation/topdocs/INSTALL.yo
flower/include/array.icc
input/bugs/grace-grace.fly [new file with mode: 0644]
input/bugs/hairy-grace.ly [new file with mode: 0644]
lily/include/auto-beam-engraver.hh
lily/include/stem-info.hh
lily/stem-info.cc
ly/params.ly
mutopia/E.Satie/gnossienne-4.ly

index 36590d31852cf5db841eec3adcd508f4f7b02bad..5dd12b7ffc5db32a7c02e0b6caf9e47ea992b2c7 100644 (file)
@@ -290,6 +290,10 @@ verb(
        rpm -i /usr/src/redhat/RPMS/i386/lilypond-x.y.z
 )
 
+Precompiled i386 eRedHat RPMS are available from
+lurl(http://linux.umbc.edu/software/lilypond/rpms/).
+
+
 
 sect(DEBIAN GNU/LINUX)
 
index 807382880e61624d90875ff9f325dec28de9c5d6..be8e95d680b0bb141abf754f16a4866b28c88545 100644 (file)
@@ -22,7 +22,18 @@ template<class T> INLINE void
 arrcpy (T*dest, T*src, int count)
 {
   for (int i_shadows_local=0; i_shadows_local < count ; i_shadows_local++)
+#ifdef __powerpc__
+    {
+      /*
+       urg: wierd egcs-1.1.2 bug on ppc
+       bug report filed
+      */
+      *dest = *src;
+      dest++, src++;
+    }
+#else
     *dest++ = *src++;
+#endif
 }
 
 template<class T> INLINE void
diff --git a/input/bugs/grace-grace.fly b/input/bugs/grace-grace.fly
new file mode 100644 (file)
index 0000000..8b43d9d
--- /dev/null
@@ -0,0 +1,2 @@
+% core
+\grace a8 \grace b8 c4
diff --git a/input/bugs/hairy-grace.ly b/input/bugs/hairy-grace.ly
new file mode 100644 (file)
index 0000000..e7a3af1
--- /dev/null
@@ -0,0 +1,14 @@
+%hairy grace stuff:
+
+\score{
+       \context Staff=foo \notes\relative c''{
+               % two auto beams 
+               d4 \grace c8 d8 \grace { d16 c16 } d8 c2
+               \property Voice.verticalDirection = 1
+               % colliding beams
+               d4 \grace c8 d8 \grace { d16 c16 } d8 c2
+               \property Voice.verticalDirection = 0
+               % leger lines
+               d,,4 \grace c8 d8 \grace { d16 c16 } d8 c2
+       }
+}
index 6f3eefff8cf12b3caa150daef667866baba4ec1d..18b5ffceb042cb38dbe899319d7a77cd5c236e49 100644 (file)
@@ -32,6 +32,7 @@ private:
   Beam* create_beam_p ();
   void end_beam ();
   void junk_beam ();
+  bool same_grace_state_b (Score_element* e);
   void typeset_beam ();
 
   Moment shortest_mom_;
index a909ac952e39062e93f9c5d686652fb8552b45c2..e631280c58b6e35253befbd9620ff311b0dea507 100644 (file)
@@ -23,7 +23,6 @@ struct Stem_info {
   Real interstaff_f_;
   Stem* stem_l_;
 
-
   Stem_info ();
   Stem_info (Stem *, int);
 };
index 0cbab88f4d23091c72de4f685c1d8054b39452b3..2993559a848849a5a8a812b0facca82022936a55 100644 (file)
@@ -57,12 +57,15 @@ Stem_info::Stem_info (Stem*s, int mult)
 
   // for simplicity, we calculate as if dir == UP
   idealy_f_ *= beam_dir_;
-  
+
+  bool grace_b = stem_l_->get_elt_property (grace_scm_sym) != SCM_BOOL_F;
+
   int stem_max = (int)rint(paper_l->get_var ("stem_max"));
-  Real min_stem_f = paper_l->get_var (String ("minimum_stem_length")
-                                    + to_str (mult_i_ <? stem_max));
-  Real stem_f = paper_l->get_var (String ("stem_length")
-                                + to_str (mult_i_ <? stem_max))* internote_f;
+  String type_str = grace_b ? "grace_" : "";
+  Real min_stem_f = paper_l->get_var (type_str + "minimum_stem_length"
+                                     + to_str (mult_i_ <? stem_max));
+  Real stem_f = paper_l->get_var (type_str + "stem_length"
+                                 + to_str (mult_i_ <? stem_max))* internote_f;
 
   if (!beam_dir_ || (beam_dir_ == dir_))
     /* normal beamed stem */
@@ -78,9 +81,24 @@ Stem_info::Stem_info (Stem*s, int mult)
       idealy_f_ += stem_f;
       miny_f_ += min_stem_f;
 
-      // lowest beam of (UP) beam must never be lower than second staffline
-      miny_f_ = miny_f_ >? (- 2 * internote_f - beam_f
-       + (mult_i_ > 0) * beam_f + interbeam_f * (mult_i_ - 1));
+      /*
+       lowest beam of (UP) beam must never be lower than second staffline
+
+       Hmm, reference (Wanske?)
+
+       Although this (additional) rule is probably correct,
+       I expect that highest beam (UP) should also never be lower
+       than middle staffline, just as normal stems.
+       
+      */
+      if (!grace_b)
+       {
+         //highest beam of (UP) beam must never be lower than middle staffline
+         miny_f_ = miny_f_ >? 0;
+         //lowest beam of (UP) beam must never be lower than second staffline
+         miny_f_ = miny_f_ >? (- 2 * internote_f - beam_f
+                               + (mult_i_ > 0) * beam_f + interbeam_f * (mult_i_ - 1));
+       }
     }
   else
     /* knee */
index 8762d5bb878e7e60394f7eaafd75490be499c30f..c3bbd2edadf24eda57558cd79b8403c7e01b0b45 100644 (file)
@@ -12,6 +12,7 @@ interline = \staffheight / 4.0;
 % thickness of stafflines
 staffline = \interline / 10.0;
 
+% urg, need grace_ versions of these too?
 beam_thickness = 0.52 * (\interline - \staffline);
 interbeam = (2.0 * \interline + \staffline - \beam_thickness) / 2.0;
 interbeam4 = (3.0 * \interline - \beam_thickness) / 3.0;
@@ -27,12 +28,26 @@ stem_length1 = 5.;
 stem_length2 = 4.;
 stem_length3 = 3.;
 
+% urg.
+% if only these ugly arrays were scm,
+% we could override them in the Grace context
+grace_factor = 0.8;
+grace_stem_length0 = \stem_length0 * \grace_factor;
+grace_stem_length1 = \stem_length1 * \grace_factor;
+grace_stem_length2 = \stem_length2 * \grace_factor;
+grace_stem_length3 = \stem_length3 * \grace_factor;
+
 % only used for beams
 minimum_stem_length0 = 0.0 ; % not used
 minimum_stem_length1 = 3. ;
 minimum_stem_length2 = 2.5;
 minimum_stem_length3 = 2.0;
 
+grace_minimum_stem_length0 = 0.0 ; % not used
+grace_minimum_stem_length1 = \minimum_stem_length1 * \grace_factor;
+grace_minimum_stem_length2 = \minimum_stem_length2 * \grace_factor;
+grace_minimum_stem_length3 = \minimum_stem_length3 * \grace_factor;
+
 % stems in unnatural (forced) direction should be shortened,
 % according to [Roush & Gourlay].  Their suggestion to knock off
 % a whole staffspace seems a bit drastical: we'll do half.
@@ -42,6 +57,12 @@ forced_stem_shorten1 = \forced_stem_shorten0;
 forced_stem_shorten2 = \forced_stem_shorten1;
 forced_stem_shorten3 = \forced_stem_shorten2;
 
+% don't shorten grace stems, always up
+grace_forced_stem_shorten0 = 0.;
+grace_forced_stem_shorten1 = \grace_forced_stem_shorten0;
+grace_forced_stem_shorten2 = \grace_forced_stem_shorten1;
+grace_forced_stem_shorten3 = \grace_forced_stem_shorten2;
+
 % there are several ways to calculate the direction of a beam
 % 
 % * MAJORITY : number count of up or down notes
index e1bd1a22e7c1389dc771cc3ad40fbd74bd386f12..26fbb528fb68c3caea9d39cc8b8179cd90c69dbb 100644 (file)
 global = \notes {
   \key a \minor;
   \time 6/4;
-%  \cadenza 1;
   \skip 1.*34;
   \bar ".|";
 }
   
-x = \context Voice=x \notes {
-  % no beams in grace notes
-  \property Voice.beamAuto = "0"
-}
-
 upper = \context Staff=treble \notes\relative c''{
   \clef violin;
-  \stemup
-  \context Voice=one
+  \property Voice.verticalDirection = 1
   r2 r r 
   r2 r r
-  r4 a'8--(\< a--  a-- a-- c-- \!b--  a--\> gis f \!e 
-  % grace hack
-  < { es8 )c } \context Voice=x { \stemup s8*1/2 \tiny b8*1/2 ~ } > r4 r2 r
+  r4 a'8--(\< a--  a-- a-- c-- \!b-- a--\> gis f \!e 
+  es8 \grace b({ ))c r4 r2 r
   r2 r r
-  r4 a'8--(\< a--  a-- a-- c-- \!b--  a--\> gis f \!e 
-  < { es8 )c } \context Voice=x { \stemup s8*1/2 \tiny b8*1/2 ~ } > r4 r2 r
-  r4 g16( a bes a  g a bes a g a bes a  g a bes a g fis es fis 
-  % urg, what a syntax
-  )d4 \tiny fis8 ( *1/2  \normalsize ) gis4*3/4 ~ gis8 r r4 r2
-  r4 g16( a bes a  g a bes a g a bes a  g a bes a g fis es fis 
-  )d4 \tiny fis8(*1/2 \normalsize )gis4*3/4 ~ gis8 r r4 r2
-  \tiny a8(*1/2  \normalsize )f4*3/4 ~ f8 r r2 r
-  r2 r4 a8( b c d c b \tiny b8(*1/2 \normalsize 
-  < { )e8*1/2 )g,8 } \context Voice=x { \stemup s8*1/4 \tiny a8*1/2 ~ } > r4 r2 r
+  r4 a'8--(\< a--  a-- a-- c-- \!b-- a--\> gis f \!e 
+  es8 } \grace b({ ))c r4 r2 r
+  r4 g16( a bes a  g a bes a g a bes a g a bes a g fis es fis 
+  )d4 } \grace fis8()gis4 ~ gis8 r r4 r2
+  r4 g16( a bes a  g a bes a g a bes a g a bes a g fis es fis 
+  )d4 \grace fis8()gis4 ~ gis8 r r4 r2
+  \grace a8()f4 ~ f8 r r2 r
+  r2 r4 a8( b c d c b \grace b8()e \grace a,())g r4 r2 r
   r2 r4 a8( b c d c b  a b c d c b a b c d c b 
-  \tiny b8(*1/2 \normalsize 
-  < { )e8*1/2 )g,8 } \context Voice=x { \stemup s8*1/4 \tiny a8*1/2 ~ } > r4 r2 r
-  a2( \tiny e'8(*1/2 \normalsize )f4*3/4 ~ )f8 r r2
+  \grace b8()e \grace a,())g r4 r2 r
+  a2( \grace e'8()f4 ~ )f8 r r2
   r2 r r
-  fis,4( \tiny dis8*1/2 \normalsize <)cis4*3/4 ais> r2 r
-  \tiny b'8(*1/2 \normalsize 
-  < { )a8*1/2 a8 } \context Voice=x { \stemup s8*1/4 \tiny b8*1/2 ~ } > r4 r2 r
+  fis,4( \grace dis8<)cis4 ais> r2 r
+  \grace b'8()a \grace b()a r4 r2 r
   r4 a'8--(\< a--  a-- a-- c-- \!b--  a--\> gis f \!e 
-  < { es8 )c } \context Voice=x { \stemup s8*1/2 \tiny b8*1/2 ~ } > r4 r2 r
-  d,4( \tiny fis8(*1/2 \normalsize )gis4*3/4 ~ )gis8 r r4 r2
+  es8 \grace b())c r4 r2 r
+  d,4( \grace fis8()gis4 ~ )gis8 r r4 r2
   f4 ~ f8 r r2 r
   f'8( g a b a g f g a b a g 
-  \tiny f8(*1/2 \normalsize 
-  < { )g8*1/2 )e8 } \context Voice=x { \stemup s8*1/4 \tiny d8*1/2 ~ } > r4 r2 r
+  \grace f8()g \grace d)e r4 r2 r
   f8( g a b a g f g a b a g 
-  \tiny f8(*1/2 \normalsize 
-  < { )g8*1/2 )e8 } \context Voice=x { \stemup s8*1/4 \tiny d8*1/2 ~ } > r4 r2 r
-  a,2( \tiny e'8(*1/2 \normalsize )f4*3/4 ~ )f8 r r2
+  \grace f8()g8 \grace d())e r4 r2 r
+  a,2( \grace e'8() f4 ~ )f8 r r2
   r2 r r
-  fis,4( \tiny dis8*1/2 \normalsize <)cis4*3/4 ais> r2 r
+  fis,4( \grace dis8<)cis4 ais> r2 r
   <e1 g b e> ~ <e g b e>
 }
 
 basloopje = \notes\relative c{
-%      \property Voice.beamAutoEnd = "1/2"
 %  d,8( a' d f a d f d a f d )a
   d,8( a' d f a \translator Staff=treble d f d \translator Staff=bass a f d )a
 }
 
-%{
-bassbeam = \notes{
-  [s2] [s8 \translator Staff=treble s s s] [\translator Staff=bass s2]
-%   [s2] [s2] [s2]
-}
-%}
-
-
 lower = \context Voice=two \notes \relative c{
   \stemdown
   \property Staff.slurVerticalDirection = 1
@@ -162,8 +139,8 @@ lower = \context Voice=two \notes \relative c{
       \remove "Time_signature_engraver";
     }
   }
-  \midi {
-    \tempo 4 = 54;
-  }
+% broken 1.1.51.hwn2
+%  \midi {
+%    \tempo 4 = 54;
+%  }
 }
-