=item *
-Perl-5. Most scripts are written in Perl. Most documentation was created
-with the perl's Plain Old Documentation. (I use 5.003)
+Perl-5. Most documentation was created with the perl's Plain Old
+Documentation. (I use 5.003)
=item *
=item *
-A fast computer (a full page of music typically takes 1 minute
-on my 486/133, using the B<--enable-checking> compile. It's lot slower
-than most MusiXTeX preprocessors)
+A fast computer (a full page of music typically takes 1 minute on my
+486/133, using the B<--enable-checking> compile. It's lot slower than
+most MusiXTeX preprocessors)
=back
[This is as close to the ``standard'' reference work for music
notation issues as one is likely to get. MB]
-K. Hader. ``Aus der Werkstatt eines Notenstechers'' Waldheim--Eberle
+Karl Hader. ``Aus der Werkstatt eines Notenstechers'' Waldheim--Eberle
Verlag, Vienna 1948
+[Hader was the leader of the Waldheim-Eberle music publishers. This
+book contains the most important rules on engraving]
+
MPA. Standard music notation specifications for computer programming.
December 1996
-8/Oct/97 LilyPond 0.1.20 1
+8/Oct/97 LilyPond 0.1.21 1
Although not strictly necessary, these are recommended to
have.
- +\bo Perl-5. Most scripts are written in Perl. Most
- documentation was created with the perl's Plain
- Old Documentation. (I use 5.003)
+ +\bo Perl-5. Most documentation was created with the
+ perl's Plain Old Documentation. (I use 5.003)
+\bo Python. Although perl is nice, python is
better. We will shift towards python for build
can be adjusted with -\b-\b-\b--\b-\b-\b-e\be\be\ben\bn\bn\bna\ba\ba\bab\bb\bb\bbl\bl\bl\ble\be\be\be-\b-\b-\b-t\bt\bt\bte\be\be\bex\bx\bx\bx-\b-\b-\b-p\bp\bp\bpr\br\br\bre\be\be\bef\bf\bf\bfi\bi\bi\bix\bx\bx\bx and -\b-\b-\b--\b-\b-\b-e\be\be\ben\bn\bn\bna\ba\ba\bab\bb\bb\bbl\bl\bl\ble\be\be\be-\b-\b-\b-t\bt\bt\bte\be\be\bex\bx\bx\bx-\b-\b-\b-
d\bd\bd\bdi\bi\bi\bir\br\br\br. The above assumes that you are root and have the GNU
development tools, and your make is GNU make. If this is
+ not the case, you can adjust your environment variables to
-8/Oct/97 LilyPond 0.1.20 2
+8/Oct/97 LilyPond 0.1.21 2
INSTALL(1) LilyPond documentation INSTALL(1)
- not the case, you can adjust your environment variables to
your taste:
export CPPFLAGS="-I /home/me/my_include -DWEIRD_FOOBAR"
--enable-mf-dir
Set the directory mf input is in (idem)
+ [obsolete]
-8/Oct/97 LilyPond 0.1.20 3
+8/Oct/97 LilyPond 0.1.21 3
INSTALL(1) LilyPond documentation INSTALL(1)
- [obsolete]
-
--enable-out-dir
Set the directory for machine generated output.
should do the trick.
+ Install the musixtex fonts in a directory which TeX and MF
+ knows (if you are root, look for a directory which
-8/Oct/97 LilyPond 0.1.20 4
+8/Oct/97 LilyPond 0.1.21 4
INSTALL(1) LilyPond documentation INSTALL(1)
- Install the musixtex fonts in a directory which TeX and MF
- knows (if you are root, look for a directory which
contains the directories with AMS and CM source (*.mf)
files. Create a subdir lilypond or musixtex and copy the
fonts into that). Do not forget to rehash TeX (if
-8/Oct/97 LilyPond 0.1.20 5
+
+
+8/Oct/97 LilyPond 0.1.21 5
-8/Oct/97 LilyPond 0.1.20 6
+8/Oct/97 LilyPond 0.1.21 6
+pl 21
+ - shrinking uses more energy than stretching
+ - check IO error on writing (disk full?)
+
+
+*********
+
+oct 8
pl 20
- don't swallow non lyric-stuff in lyrics
- x-position of Stem
* accidental placement
- * bar-checking lyrics.
-
- * check IO error on writing (disk full?)
-
* AFM for font input?
* Make general "spanning"-elements and "placer"-elements
+ * Unicode support?
+
- naming Mozarella, Madeira, Muella, Fontaigna, Feta?
- bf: abbrevs over whole note
- scoping for properties
{ c4
\multi 2 < { \stemup .. } { \stemdown .. } >
- c2 }
-
+ c2
+ }
+
this modifies \stem for the c2
* use properties for:
TOPLEVEL_MAJOR_VERSION = 0
TOPLEVEL_MINOR_VERSION = 1
-TOPLEVEL_PATCH_LEVEL = 20.jcn1
+TOPLEVEL_PATCH_LEVEL = 21
TOPLEVEL_MY_PATCH_LEVEL =
# use the above to send patches, always empty for released version:
% generated automatically by mf-to-table.py version 0.3
-% on Wed Oct 8 16:18:13 1997
+% on Thu Oct 9 11:15:46 1997
% Do not edit
% input from out/font-en-tja16.log
"2" "\quartball" -0.00\pt 5.28\pt -2.20\pt 2.20\pt
}
"foobars" = \table {
- "ufermata" "\ufermata" -6.30\pt 6.30\pt -0.00\pt 6.80\pt
+ "ufermata" "\ufermata" -6.30\pt 6.30\pt -0.30\pt 6.80\pt
"dfermata" "\dfermata" -6.30\pt 6.30\pt -6.80\pt 0.00\pt
"accent" "\sforzatoaccent" -3.60\pt 3.60\pt -2.00\pt 2.00\pt
"staccato" "\staccato" -0.50\pt 0.50\pt -0.50\pt 0.50\pt
"upbow" "\upbow" -2.60\pt 2.60\pt -0.00\pt 7.80\pt
"downbow" "\downbow" -3.50\pt 3.50\pt -0.00\pt 4.00\pt
"turn" "\turn" -4.38\pt 4.38\pt -2.12\pt 2.12\pt
+ "utrill" "\utrill" -0.00\pt 8.00\pt -0.00\pt 6.00\pt
}
"floogbars" = \table {
"3u" "\eighthflag" -0.20\pt 5.17\pt -12.77\pt 0.20\pt
% generated automatically by mf-to-table.py version 0.3
-% on Wed Oct 8 16:18:16 1997
+% on Thu Oct 9 11:15:50 1997
% Do not edit
% input from out/font-en-tja20.log
"2" "\quartball" -0.00\pt 6.61\pt -2.75\pt 2.75\pt
}
"foobars" = \table {
- "ufermata" "\ufermata" -7.88\pt 7.88\pt -0.00\pt 8.50\pt
+ "ufermata" "\ufermata" -7.88\pt 7.88\pt -0.38\pt 8.50\pt
"dfermata" "\dfermata" -7.88\pt 7.88\pt -8.50\pt 0.00\pt
"accent" "\sforzatoaccent" -4.50\pt 4.50\pt -2.50\pt 2.50\pt
"staccato" "\staccato" -0.63\pt 0.63\pt -0.63\pt 0.63\pt
"upbow" "\upbow" -3.25\pt 3.25\pt -0.00\pt 9.75\pt
"downbow" "\downbow" -4.38\pt 4.38\pt -0.00\pt 5.00\pt
"turn" "\turn" -5.47\pt 5.47\pt -2.65\pt 2.65\pt
+ "utrill" "\utrill" -0.00\pt 10.00\pt -0.00\pt 7.50\pt
}
"floogbars" = \table {
"3u" "\eighthflag" -0.25\pt 6.46\pt -15.91\pt 0.25\pt
MAJOR_VERSION = 0
MINOR_VERSION = 1
-PATCH_LEVEL = 20
+PATCH_LEVEL = 21
# use to send patches, always empty for released version:
# include separator: ".postfix", "-pl" makes rpm barf
{
assert (hooke_f_ >= 0);
}
+
+Real
+Idealspacing::energy_f(Real x) const
+{
+ Real dx = (space_f_ - x);
+
+ Real e = sqr(dx);
+ if ( dx < 0)
+ e *= 4; // ugh.
+
+ return hooke_f_ * e;
+}
/// ideal spacing between two columns
struct Idealspacing {
- /// the ideal distance
- Real space_f_;
+ /// the ideal distance
+ Real space_f_;
- /// Hooke's constant: how strong are the "springs" attached to columns
- Real hooke_f_;
+ /// Hooke's constant: how strong are the "springs" attached to columns
+ Real hooke_f_;
- /// the two columns
- int left_i_;
- int right_i_;
+ /// the two columns
+ int left_i_;
+ int right_i_;
- void print() const;
- void OK() const ;
- Idealspacing();
+ Real energy_f (Real x) const;
+ void print() const;
+ void OK() const ;
+ Idealspacing();
};
Score_column* scol_l (int);
void connect (int i,int j, Real,Real);
Line_of_cols error_pcol_l_arr() const;
+ Real calculate_energy_f (Vector) const;
public:
static Line_spacer *constructor();
Midi_stream::~Midi_stream()
{
+ *os_p_ << flush; // ugh. Share with tex_stream.
+ if (!*os_p_)
+ {
+ warning("error syncing file (disk full?)");
+ exit_status_i_ = 1;
+ }
delete os_p_;
}
}
}
+
+Real
+Spring_spacer::calculate_energy_f (Vector solution) const
+{
+ Real e = 0.0;
+ for (PCursor<Idealspacing*> i (ideal_p_list_.top()); i.ok(); i++)
+ {
+ e += i->energy_f(solution(i->right_i_) - solution(i->left_i_));
+ }
+
+ return e;
+}
void
Spring_spacer::lower_bound_solution (Col_hpositions*positions) const
{
start.fill (0.0);
Vector solution_vec (lp.solve (start));
- positions->energy_f_ = lp.eval (solution_vec);
+ positions->energy_f_ = calculate_energy_f (solution_vec);
positions->config = solution_vec;
positions->satisfies_constraints_b_ = check_constraints (solution_vec);
}
WARN << "solution doesn't satisfy constraints.\n" ;
}
position_loose_cols (solution_vec);
- positions->energy_f_ = lp.eval (solution_vec);
+ positions->energy_f_ = calculate_energy_f (solution_vec);
positions->config = solution_vec;
positions->error_col_l_arr_ = error_pcol_l_arr();
(c) 1997 Han-Wen Nienhuys <hanwen@stack.nl>
- TODO
-
- make an abstract interface to output, operations:
-
- move (x,y), put (symbol).
*/
#include <fstream.h>
}
Tex_stream::~Tex_stream()
{
+ *os << flush;
+ if (!*os)
+ {
+ warning("error syncing file (disk full?)");
+ exit_status_i_ = 1;
+ }
delete os;
assert (nest_level == 0);
}
line_len_i_ = 0;
}
-/* *************************************************************** */
Begin3
Titel: LilyPond
-Versie: 0.1.20
+Versie: 0.1.21
Inschrijf datum: 08OCT97
Beschrijving: LilyPond is de muziek typesetter van het GNU Project.
Het programma genereert muziek in zichtbare of
jan@digicash.com (Jan Nieuwenhuizen)
Onderhouden door: hanwen@stack.nl (Han-Wen Nienhuys)
Voornaamste plek: sunsite.unc.edu /pub/Linux/apps
- 395k lilypond-0.1.20.tar.gz
+ 395k lilypond-0.1.21.tar.gz
Oorspronkelijke plek: pcnov095.win.tue.nl /pub/lilypond/
- 395k lilypond-0.1.20.tar.gz
+ 395k lilypond-0.1.21.tar.gz
Copi"eer politie: GPL
End
Begin3
Title: LilyPond
-Version: 0.1.20
+Version: 0.1.21
Entered-date: 08OCT97
Description: LilyPond is the GNU Project music typesetter. The program
generates visual or auditive output from a music
jan@digicash.com (Jan Nieuwenhuizen)
Maintained-by: hanwen@stack.nl (Han-Wen Nienhuys)
Primary-site: sunsite.unc.edu /pub/Linux/apps
- 395k lilypond-0.1.20.tar.gz
+ 395k lilypond-0.1.21.tar.gz
Original-site: pcnov095.win.tue.nl /pub/lilypond/
- 395k lilypond-0.1.20.tar.gz
+ 395k lilypond-0.1.21.tar.gz
Copying-policy: GPL
End
Name: lilypond
-Version: 0.1.20
+Version: 0.1.21
Release: 1
Copyright: GPL
Group: Applications/Publishing
-Source0: pcnov095.win.tue.nl:/pub/lilypond/lilypond-0.1.20.tar.gz
+Source0: pcnov095.win.tue.nl:/pub/lilypond/lilypond-0.1.21.tar.gz
Summary: A preprocessor to make TeX typeset music.
URL: http://www.stack.nl/~hanwen/lilypond
Packager: Han-Wen Nienhuys <hanwen@stack.nl>
* flags
* clefs
* some scripts:
- - {up, down}bow
- toe/heel
- piano pedals,
* braces.
* trills
* maxima notehead
* coda signs.
- * 0 - 9
+ * 0 - 9: bold and italic
- - move to OpusTeX fonts ? (no!)
- - include important spacing dims in TFM?
+ - include important spacing dims in fetalog
- lilyrules.mf for different rules (lines) ?
- check out Adobe Sonata/Petrucci font layout. They are the
standard for Music fonts
+
- hack up GS to do round pixels iso. square pixels. (Printers
don't do square pixels.)
scantokens extra_beginchar;
enddef;
+code:=-1;
+
% starts just as plain mf's beginchar:
% charcode,
% and then adds:
test:= 0;
+
if test = 0:
input feta-eindelijk;
input feta-toevallig;
+stafflines = 5;
+
interline#:=staffsize#/(stafflines-1);
%
radius# + crook_fatness#/2 = h#;
radius# + crook_thinness#/2 = w#;
- set_char_box(w#, w#, 0, h#);
+ set_char_box(w#, w#, crook_thinness#/2, h#);
define_pixels(radius, crook_thinness, crook_fatness);
dot_diam = 4/3 crook_fatness;
fet_endchar;
%
-% FIXME the middle part (NW -> SE) may have some more (ok; it is
-% negative: less) slope
+% Inspired by a computer-set version of auf dem Strom by Baerenreiter.
%
+
fet_beginchar("Turn","turn","turn")
save thin, thick, ball_diam, darkness;
save wd, ht, thick_nibangle, ball_nib_thick;
wd# = 35/16 interline#;
ht# = 18/17 interline#;
- darkness = 1.3 stafflinethickness;
+ darkness = 1.25 stafflinethickness;
set_char_box(wd#/2, wd#/2, ht#/2, ht#/2);
fet_endchar;
+
+
+
+def draw_bulb(expr zl, zr, center_factor, radius_factor)=
+ begingroup;
+ clearxy;
+ save rad, ang;
+
+ ang = angle(zr-zl);
+ z0 = center_factor [zr, zl];
+ rad = center_factor * length(zr-zl);
+
+ z1 = z0 + radius_factor* rad * dir(ang - 100);
+ z2 = z0 + rad * dir(ang - 270);
+ labels(0,1,2);
+ fill zr{dir (ang - 90)} .. z1 .. z2 -- cycle;
+
+ endgroup
+enddef;
+
+fet_beginchar("Trill (`tr')","utrill","utrill")
+
+ save start_angle, ascender_extra, ex, hair_thick, fatness,
+ slant_angle, slant, t_fatness, r_fatness, kerning;
+ pair slant_vec;
+
+ define_pixels(ex, ascender_extra, ascender);
+ ascender_extra# = 1/2 ex#;
+ ascender# = ascender_extra# + ex#;
+ ex# = interline#;
+
+ fatness = 12/40 ex;
+ t_fatness = 8/10 fatness;
+ r_fatness = 8/10 fatness;
+
+ hair_thick = 2/3 blot_diameter;
+
+
+ y1 = ascender;
+ x1l = 0;
+ x1r = t_fatness;
+ penpos1(start_nib_wid, 25);
+
+ z2 = (x1, 7/18 ex);
+ penpos2(start_nib_wid, 25);
+
+ z3l = (11/10 t_fatness, 0);
+
+ z4l = (13/6 t_fatness, 3/8 ex);
+ penpos4(hair_thick, 180);
+
+ 1.9 [z3l, z3r] = z4r;
+ z3 = .5 [z3l, z3r];
+
+
+
+ save t_p, krul_p;
+ path t_p, krul_p, r_p;
+
+
+ t_p := z1l -- z2l{down} .. z3l{right} .. z4l{up} -- z4r{down}
+ .. z3r{left} .. z2r{up} .. z1r -- cycle;
+ fill t_p ;
+
+ krul_ang = 32;
+
+ pickup pencircle scaled hair_thick;
+
+ z5 = (t_fatness/2, 2/3 ex);
+
+ lft x6 = -18/40 ex;
+ y6 = y5 - 1/20 ex;
+
+ z7 = (2 t_fatness, ex);
+
+ krul_p := z4{up} .. tension 1.1 .. z5 .. {down}z6
+ .. tension 1.1 .. z5 --- z7;
+ draw krul_p;
+
+ penpos7(hair_thick, angle (z7-z5) + 90);
+
+ z8l = (2 t_fatness + 2 hair_thick, ex);
+ penpos8(2 hair_thick, 35);
+
+ y9 = 3/4 ex;
+ x9l = 2.8 t_fatness;
+ penpos9(r_fatness, 0);
+
+ x10 = x9;
+ y10 = 0;
+ penpos10(r_fatness, 0);
+
+ r_p := z7l{z7-z5} .. z8l{right} .. z9l{down} --- z10l -- z10r
+ --- z9r{up}
+ .. z8r{left} .. z7r{z5-z7} -- cycle;
+ fill r_p;
+ set_char_box(0,2 interline#, 0,ascender#);
+
+
+ penpos11(1/4 r_fatness, -20);
+ z11r = z9r;
+
+ z13 = (x9 + 2 r_fatness, y11 + 1/16 ex);
+ penpos13(r_fatness, 180);
+ fill z11r{dir 70} .. z13r{down} -- z13l{up} .. z11l{dir 250} -- cycle;
+ penlabels(range 1 thru 15);
+
+ draw_bulb(z13r, z13l, 0.5, 1.5);
+fet_endchar;
+
fet_endgroup("foobars");
mode_setup;
staffsize#:=16pt#;
-stafflines:=5;
-code:=-1;
input feta-generic;
fet_beginfont("font-en-tja", 20);
staffsize#:=20pt#;
-stafflines:=5;
-stafflinethickness#:=0.4pt#;
-code:=-1;
input feta-generic;
font_size 16;
mode_setup;
-test:=0;
-
staffsize#:=16pt#;
-stafflines:=5;
-stafflinethickness#:=0.4pt#;
-input feta-params;
input wat-zie-ik;
end.
font_size 20;
mode_setup;
-test:=0;
-
staffsize#:=20pt#;
-stafflines:=5;
-stafflinethickness#:=0.4pt#;
-input feta-params;
+
input wat-zie-ik;
end.
% part of LilyPond's pretty-but-neat music font
% beams: plat en steil
-%\tracingequations:= tracingonline := 1;
-
+input feta-params;
beamheight#:=0.48interline#;
+
define_pixels(beamheight);
pen beam_pen;
beam_pen:=penrazor scaled beamheight rotated 90;
-% mimic taupin-SLOPES for now -- because lily knows them
ELEM_TAN:=0.05;
SLOPES:=20;
LENGTHS:=6;
ELEM_FACTOR := 2;
ELEM_INITIAL_LEN:=2;
-
-% Beamslopes up
for i := -SLOPES upto SLOPES:
width:= ELEM_INITIAL_LEN;
for j:=1 upto LENGTHS:
% generated automatically by mf-to-table.py version 0.3
-% on Wed Oct 8 16:18:13 1997
+% on Thu Oct 9 11:15:46 1997
% Do not edit
% input from out/font-en-tja16.log
\fetdef\upbow{32}
\fetdef\downbow{33}
\fetdef\turn{34}
+\fetdef\utrill{35}
% floogbars
-\fetdef\eighthflag{35}
-\fetdef\deighthflag{36}
+\fetdef\eighthflag{36}
+\fetdef\deighthflag{37}
% generated automatically by mf-to-table.py version 0.3
-% on Wed Oct 8 16:18:16 1997
+% on Thu Oct 9 11:15:50 1997
% Do not edit
% input from out/font-en-tja20.log
\fetdef\upbow{32}
\fetdef\downbow{33}
\fetdef\turn{34}
+\fetdef\utrill{35}
% floogbars
-\fetdef\eighthflag{35}
-\fetdef\deighthflag{36}
+\fetdef\eighthflag{36}
+\fetdef\deighthflag{37}