TOPLEVEL_MAJOR_VERSION = 0
TOPLEVEL_MINOR_VERSION = 0
-TOPLEVEL_PATCH_LEVEL = 73
+TOPLEVEL_PATCH_LEVEL = 74
# use to send patches, always empty for released version:
# include separator: ".postfix", "-pl" makes rpm barf
-TOPLEVEL_MY_PATCH_LEVEL = pre.jcn1
+TOPLEVEL_MY_PATCH_LEVEL = pre
Those deserving special mention (in no particular order):
Esther, Marijke, Heike, Inge, Judith, Hannah, Auke, Ilse, Evelyn,
-Maartje, Suzanne, Ilse (gee, again?), my friends in the
-Eindhovens Jongeren Ensemble and last (but certainly not least)
+Maartje, Suzanne, Ilse (gee, again?) and last (but certainly not least)
Janneke!
- HW
+ HWN
That's a nice thought, Wendy. I've got a few too, to spread
the credits a bit (Again, no particular order) Michelle, Illushka,
JCN
+
+Of course, our other friends in the `Eindhovens Jongeren Ensemble'
+(http://www.stack.nl/~hanwen/eje.html) cannot go unmentioned too.
+
+
--- * ---
[ And now the serious part ]
dynamics (both absolute and hairpin style) clef changes, meter
changes, cadenza-mode, key changes, repeat bars
-[Kudos to the FSF, all linux hackers, and --of course-- especially
+[Kudos to the FSF, all Linux hackers, and --of course-- especially
GrandMaster Linus T, for The Kernel and The Announce :-]
Han-Wen Nienhuys <hanwen@stack.nl>
wrote.
A\bA\bA\bAU\bU\bU\bUT\bT\bT\bTH\bH\bH\bHO\bO\bO\bOR\bR\bR\bRS\bS\bS\bS
- +\bo Han-Wen Nienhuys <hanwen@stack.nl>
+ +\bo Han-Wen Nienhuys <hanwen@stack.nl>,
+ http://www.stack.nl/~hanwen
Main author, all files files except mentioned below
- +\bo Jan Nieuwenhuizen <jan@digicash.com>
+ +\bo Jan Nieuwenhuizen <jan@digicash.com>,
+ http://www.digicash.com/~jan
lily/midi-*, mi2mu/*, parts flower/string*.cc,
make/*.make, */Makefile parts of
Documentation/mudela.pod, lib/*source-file*,
lib/duration.cc, lib/source, flower/*{list,cursor}*,
+ lily/rest-collision*, conflily, cygnus w32 stuff
and corresponding header files.
-
-
-
-30/Jun/97 LilyPond 0.0.73 1
+7/Jul/97 LilyPond 0.0.74 1
+This file documents bugs which were "re-introduced" in various pl's
+
+pl69
+ * slurs.ly
+
+pl68:
+ * opening rests wohltemperirt
+
+ * lyrics broken,
+
+ * midi broken
=item *
-Han-Wen Nienhuys <hanwen@stack.nl>
+Han-Wen Nienhuys <hanwen@stack.nl>, http://www.stack.nl/~hanwen
Main author, all files files except mentioned below
=item *
-Jan Nieuwenhuizen <jan@digicash.com>
+Jan Nieuwenhuizen <jan@digicash.com>, http://www.digicash.com/~jan
lily/midi-*, mi2mu/*, parts flower/string*.cc, make/*.make, */Makefile
parts of Documentation/mudela.pod, lib/*source-file*, lib/duration.cc,
-lib/source, flower/*{list,cursor}*,
+lib/source, flower/*{list,cursor}*, lily/rest-collision*, conflily,
+cygnus w32 stuff
and corresponding header files.
down == -1
Intervals are pictured lying on a horizontal numberline (Interval[-1]
-is the minimum)
+is the minimum). The 2D plane has +x on the right, +y pointing up.
GNU LilyPond uses MusiXTeX fonts and TeX for its output. This is not a key
issue: in a future version, GNU LilyPond might bypass TeX, but at the moment
-TeX is very convenient for producing output.
+TeX is convenient for producing output.
=item *
=head1 GOAL
-Provide the users with free software for:
+Provide musicians with free software for
- - composing
- - setting
- - playing
- - sequencing
- - interchanging music
+=over 4
+
+=item -
+
+composing
+
+=item -
+
+engraving
+
+=item -
+
+playing
+
+=item -
+
+sequencing
+
+=item -
+
+interchanging music
+
+=back
and possibly for
- - arranging
- - performing
+=over 4
+
+=item -
+
+arranging
+
+=item -
+
+performing
+
+=back
Music publishers make lots of money out of selling sheet music which
is in the public domain (the composers died a long time ago). It is
usually prohibited to xerox the sheet music. Publishers have two
-arguments for not allowing this: high prices are there to guarantee
+arguments to justify this policy: the high prices are there to guarantee
diversity (keeping lots of stock is expensive), and to encourage new
work being composed.
The public deserves free tools for composing and printing.
+In general, the same arguments as for software hold for music. See
+Stallmans articles on free software.
+
=head1 REQUIREMENTS
=item *
-Libraries for reading, writing various audio/music/notation formats.
+Libraries for reading and writing various audio/music/notation
+formats.
=back
-=head1 NAME
+=head1 NAME
Lily Literature -- reading on music engraving/typesetting/etc.
=head1 DESCRIPTION
A list of resources on music printing/writing and engraving. Please
-note that don't have access to most material.
+note that don't have access to most material.
-[What I do know, I've commented inside brackets. They are just
-my personal comments, not to be taken too seriously]
+[What I do know, I've commented inside brackets. They are just my
+personal comments, not to be taken too seriously]
-=head2 Music engraving
+=head2 Music engraving: references
-Wanske, Helene. ``Musiknotation --- Von der Syntax des Notenstichs
-zum EDV-gesteuerten Notensatz'', Schott-Verlag, Mainz 1988. ISBN
-3-7957-2886-x.
+Helene Wanske. ``Musiknotation --- Von der Syntax des Notenstichs zum
+EDV-gesteuerten Notensatz'', Schott-Verlag, Mainz 1988.ISBN 3-7957-2886-x.
[I. A very thorough overview of engraving practices of various
craftsmen. It includes detailed specs of characters, dimensions etc.
II. a thorough overview of a (by now antiquated) automated system
called Ikarus; EDV Means e(lektronischen) D(aten)v(erarbeitung),
-electronic data processing]
+electronic data processing HWN]
Maxwell Weaner and Walter Boelke, Standard Music Notation Practice,
revised edition by Arnold Broido and Daniel Dorff. Music Publisher's
Association of the United States Inc., 1993.
-Ross, Ted. ``Teach yourself the art of music engraving and
-processing'' (3rd edition). Hansen House, Miami Beach, FL.
-
- Hansen House
- 1820 West Ave.
- Miami, FL 33139
- (305) 532-5461
+Ted Ross. ``Teach yourself the art of music engraving and processing''
+(3rd edition). Hansen House, Miami Beach, FLorida.
[This is about I<engraving> i.e. professional music typesetting, and
includes some good spacing tables MB]
-Read, Gardner. ``Modern Rhythmic Notation.'' Indiana University Press, 1978.
+Gardner Read. ``Modern Rhythmic Notation.'' Indiana University Press,
+1978.
-Read, Gardner. ``Music Notation'' (2nd edition). Taplinger Publishing,
+Gardner Read. ``Music Notation'' (2nd edition). Taplinger Publishing,
New York.
-[This is as close to the ``standard'' reference work for music notation issues
-as one is likely to get. MB]
+[This is as close to the ``standard'' reference work for music
+notation issues as one is likely to get. MB]
+
+MPA. Standard music notation specifications for computer programming.
+December 1996
-=head2 Related papers
+[Pamphlet explaining some fine points in music font design HWN]
+=head2 Notation with computers
-Byrd, Donald. ``Music Notation by Computer''. Diss. Indiana Univ.,
-1985.
+Donald Byrd. ``Music Notation by Computer''. Dissertation Indiana
+University, 1985.
-Byrd, Donaldn. ``A System for Music Printing by Computer.''
-Computers and the Humanities, 8 (1974), 161-72.
+Donald Byrd. ``A System for Music Printing by Computer.'' Computers
+and the Humanities, 8 (1974), 161-72.
-Smith, Leland. ``Editing and Printing Music by Computer.'' Journal
-of Music Theory, 17 (1973), 292-309.
+Leland Smith. ``Editing and Printing Music by Computer.'' Journal of
+Music Theory, 17 (1973), 292-309.
[If I remember correctly, this was concerned more with an input
language than with the typography. SP.]
-Gomberg, David A. ``A Computer-Oriented System for Music Printing.'' Diss.
-Washington Univ. 1975.
+David A Gomberg. ``A Computer-Oriented System for Music Printing.''
+Dissertation Washington University. 1975.
-Hewlett, Walter B. and Eleanor Selfridge-Field. Directory of Computer
-Assisted Research in Musicology. Menlo Park, CA: Center for Computer
-Assisted Research in the Humanities.
+Walter B Hewlett. and Eleanor Selfridge-Field. ``Directory of Computer
+Assisted Research in Musicology''. Menlo Park, CA: Center for Computer
+Assisted Research in the Humanities.
[Annual editions since 1985, many containing surveys of music
typesetting technology. SP]
+Wael A. Hegazy and John S. Gourlay. ``Optimal line breaking in music''. In
+Document Manipulation and Typography, J.C. van Vliet (ed) 1988.
-W.A. Hegazy and J. S. Gourlay. Optimal line breaking in music. In
-``Document Manipulation and Typography'', J.C. van Vliet (ed) 1988.
-
-[This generalizes TeX's breaking algorithm to music]
+[This generalizes TeX's breaking algorithm to music HWN]
-David A. Gomberg; A Computer-oriented System for Music Printing.
+David A. Gomberg; ``A Computer-oriented System for Music Printing.''
Computers and the Humanities, Vol.11, pp 63-80.
-J. Gourlay, ``Spacing a Line of Music,'' Technical Report
+John S. Gourlay. ``Spacing a Line of Music,'' Technical Report
OSU-CISRC-10/87-TR35, Department of Computer and Information Science,
The Ohio State University, 1987.
-J. Gourlay, A. Parrish, D. Roush, F. Sola, Y. Tien, ``Computer
-Formatting of Music,'' Technical Report OSU-CISRC-2/87-TR3,
-Department of Computer and Information Science, The Ohio State
-University, 1987.
+John S. Gourlay, A. Parrish, D. Roush, F. Sola, Y. Tien. ``Computer
+Formatting of Music,'' Technical Report OSU-CISRC-2/87-TR3, Department
+of Computer and Information Science, The Ohio State University, 1987.
-W. Hegazy, ``On the Implementation of the MusiCopy Language
+Wael A. Hegazy. ``On the Implementation of the MusiCopy Language
Processor,'' Technical Report OSU-CISRC-10/87-TR34, Department of
Computer and Information Science, The Ohio State University, 1987.
-A. Parrish and J. Gourlay, ``Computer Formatting of Musical
-Simultaneities,'' Technical Report OSU-CISRC-10/87-TR28, Department
-of Computer and Information Science, The Ohio State University, 1987.
+A. Parrish and John S. Gourlay. ``Computer Formatting of Musical
+Simultaneities,'' Technical Report OSU-CISRC-10/87-TR28, Department of
+Computer and Information Science, The Ohio State University, 1987.
-D. Roush, ``Music Formatting Guidelines,'' Technical Report
+D. Roush. ``Music Formatting Guidelines,'' Technical Report
OSU-CISRC-3/88-TR10, Department of Computer and Information Science,
The Ohio State University, 1988.
-F. Sola, ``Computer Design of Musical Slurs, Ties and Phrase
-Marks,'' Technical Report OSU-CISRC-10/87-TR32, Department of
-Computer and Information Science, The Ohio State University, 1987.
+F. Sola. ``Computer Design of Musical Slurs, Ties and Phrase Marks,''
+Technical Report OSU-CISRC-10/87-TR32, Department of Computer and
+Information Science, The Ohio State University, 1987.
-F. Sola and D. Roush, ``Design of Musical Beams,'' Technical
-Report OSU-CISRC-10/87-TR30, Department of Computer and Information
-Science, The Ohio State University, 1987.
+F. Sola and D. Roush. ``Design of Musical Beams,'' Technical Report
+OSU-CISRC-10/87-TR30, Department of Computer and Information Science,
+The Ohio State University, 1987.
-J. S. Gourlay. A language for music printing. In ``Communications of
-the ACM''. Vol. 29(5), 388--401, 1986.
+John. S. Gourlay. ``A language for music printing'', Communications
+of the ACM, Vol. 29(5), 388--401, 1986.
[This paper describes a vapourware music setting system and an input
-language to go with it. ]
+language to go with it. HWN]
-D. Blostein and L. Haken, The Lime Music Editor: A Diagram Editor
-Involving Complex Translations, Software Practice and Experience,
-Vol. 24, No. 3, March 1994, pp. 289-306.
+Dorothea Blostein and Lippold Haken, ``The Lime Music Editor: A Diagram
+Editor Involving Complex Translations'', Software Practice and
+Experience, Vol. 24, No. 3, March 1994, pp. 289-306.
[A description of various conversions, decisions and issues relating
-to this interactive editor]
+to this interactive editor HWN]
-L. Haken and D. Blostein, The Tilia Music Representation:
+Lippold Haken and Dorothea Blostein, ``The Tilia Music Representation:
Extensibility, Abstraction, and Notation Contexts for the Lime Music
-Editor, Computer Music Journal, Vol. 17, No. 3, 1993, pp. 43-58
+Editor'', Computer Music Journal, Vol. 17, No. 3, 1993, pp. 43-58
[A description of Lime internals (which resemble older (before
-0.0.68pre) LilyPond data structures somewhat)]
+0.0.68pre) LilyPond data structures somewhat) HWN]
-L. Haken and D. Blostein, A New Algorithm for Horizontal Spacing of
-Printed Music, International Computer Music Conference, Banff,
-Sept. 1995, pp. 118-119.
+Lippold Haken and Dorothea Blostein, ``A New Algorithm for Horizontal
+Spacing of Printed Music'', International Computer Music Conference,
+Banff, Sept. 1995, pp. 118-119.
[This describes an algorithm which uses springs between adjacent
-columns. This algorithm is a "subclass" of the LilyPond algorithm.]
+columns. This algorithm is a "subclass" of the LilyPond algorithm. HWN]
-D. Blostein and L. Haken, Justification of Printed Music,
-Communications of the ACM, VolJ34, No. 3, March 1991, pp. 88-99.
+Dorothea Blostein and Lippold Haken, ``Justification of Printed Music'',
+Communications of the ACM, VolJ34, No. 3, March 1991, pp. 88-99.
[This paper provides a shallow overview of the algorithm used in LIME
-for spacing individual lines.]
+for spacing individual lines. HWN]
-Gary M. Rader, ``Creating Printed Music Automatically''. Computer Vol
+Gary M. Rader. ``Creating Printed Music Automatically''. Computer Vol
29(6), June 1996, pp 61--69.
[Describes a system called MusicEase, and explains that it uses
"constraints" (which go unexplained) to automatically position various
-elements.]
+elements. HWN]
Stephen Dowland Page. ``Computer Tools for Music Information
-Retrieval''. Dissertation Univ of Oxford, 1988.
+Retrieval''. Dissertation University of Oxford, 1988.
[Don't ask Stephen for a copy. Write to the Bodleian Library, Oxford,
-or to the British Library, instead.]
+or to the British Library, instead. SP]
+
+Ren\'e Roelofs. ``Een Geautomatiseerd Systeem voor het Afdrukken van
+Muziek'' afstudeerscriptie Bestuurlijke informatica, no 45327, Erasmus
+universiteit Rotterdam, 1991. (``An automated system for printing
+music'' Master's Thesis Managerial Computer Science.)
+
+[This thesis describes a simplistic (monophonic) typesetting system,
+and focuses on the breaking algorithm, which is taken from Hegazy &
+Gourlay HWN]
+
+Miguel Filgueiras and Jos\'e Paulo Leal. ``Representation and
+manipulation of music documents in SceX''. Electronic Publishing,
+vol. 6 (4), 507--518, 1993.
+
+Eric Foxley, Music --- A language for typesetting music scores.
+Software --- Practice and Experience, Vol. 17(8), 485--502, 1987.
+
+[A paper on a TROFF preprocessor to typeset music. The output shown is
+not very sophisticated, and contains some typographical atrocities HWN]
+
+Miguel Filgueiras, ``Implementing a Symbolic Music Processing
+System''. LIACC, Universidade do Porto, 1996; submitted.
-=head2 Further reading
+Miguel Filgueiras, ``Some Music Typesetting Algorithms''. LIACC,
+Universidade do Porto, forthcoming.
-Chlapik, Herbert. ``Die Praxis des Notengraphikers''. Doblinger, 1987.
+=head2 Engraving: further reading
+
+Herbert Chlapik. ``Die Praxis des Notengraphikers''. Doblinger, 1987.
ISBN 3-9000 035-96-2.
[An clearly written book for the casually interested reader. It shows
-some of the conventions and difficulties in printing music]
+some of the conventions and difficulties in printing music HWN]
The University of Colorado Music Engraving page.
http://obenamots.cc.colorado.edu/Musicpress/engraving.html
-More on GNU Music: http://dept-info.labri.u-bordeaux.fr/~strandh/Gsharp
-
-Tablature: http://wabakimi.carleton.ca/~phacket2/guitar/tabfaq.html
-
-Donato, Anthony. Preparing Music Manuscript. Englewood Cliffs:
+Anthony Donato. Preparing Music Manuscript. Englewood Cliffs:
Prentice-Hall, 1963.
Donemus. ``Uitgeven van muziek''. Donemus Amsterdam, 1900
-Heussenstamm, George. The Norton Manual of Music Notation. New York:
+George Heussenstamm. The Norton Manual of Music Notation. New York:
Norton, 1987.
-Karkoshka, Erdhard. Notation in New Music. Trans. Ruth Koenig. New York:
-Praeger Publishers, 1972. Out of print.
-
-Roelofs, Ren\'e. ``Een Geautomatiseerd Systeem voor het Afdrukken van
-Muziek'' afstudeerscriptie Bestuurlijke informatica, no 45327, Erasmus
-universiteit Rotterdam, 1991. (``An automated system for printing
-music'' Master's Thesis Managerial Computer Science.)
-
-[This thesis describes a simplistic (monophonic) typesetting system,
-and focuses on the breaking algorithm, which is taken from Hegazy & Gourlay]
+Erdhard Karkoshka. ``Notation in New Music. Trans. Ruth
+Koenig''. Praeger Publishers, New York, 1972. Out of print.
C. Roemer, The Art of Music Copying. Roerick music co., Sherman Oaks
(CA), 1973.
-Rosecrans, Glen. Music Notation Primer. New York: Passantino, 1979.
+Glen Rosecrans. Music Notation Primer. New York: Passantino, 1979.
-Stone, Kurt. Music Notation in the Twentieth Century. New York: Norton, 1980.
+Kurt Stone. Music Notation in the Twentieth Century. New York: Norton,
+1980.
-=head2 other stuff
+=head2 other stuff
-Peter S. Langston, Unix music tools at Bellcore.
-Software --- Practice and Experience, Vol. 20(S1), S1/47--S1/61, 1990.
-[This paper deals with some command-line tools for music editing and
-playback. It doesn't mention notation issues, but does come with the
-grand idea (not) of using music to monitor complex systems. Imagine your
-nuclear plant supervisor to use AC/DC for checking the reactor]
+More on GNU Music:
+http://dept-info.labri.u-bordeaux.fr/~strandh/Gsharp
-Cindy Grande, NIFF6a Notation Interchange File Format.
-Grande Software Inc., 1995. ftp://blackbox.cartah.washington.edu/pub/
-
-[Specs for NIFF, a comprehensive but binary (yuk) format for notation]
+Tablature: http://wabakimi.carleton.ca/~phacket2/guitar/tabfaq.html
-Miguel Filgueiras and Jos\'e Paulo Leal. Representation and
-manipulation of music documents in SceX. Electronic Publishing,
-vol. 6 (4), 507--518, 1993.
-Eric Foxley, Music --- A language for typesetting music scores.
-Software --- Practice and Experience, Vol. 17(8), 485--502, 1987.
+Peter S. Langston, ``Unix music tools at Bellcore''. Software ---
+Practice and Experience, Vol. 20(S1), S1/47--S1/61, 1990.
-[A paper on a TROFF preprocessor to typeset music. The output shown is
-not very sophisticated, and contains some typographical atrocities]
+[This paper deals with some command-line tools for music editing and
+playback. It doesn't mention notation issues, but does come with the
+grand idea (not) of using music to monitor complex systems. Imagine
+your nuclear plant supervisor to use AC/DC for checking the reactor HWN]
-Alexander Brinkman, PASCAL Programming for Music Research.
-The University of Chicago Press, 1990.
+Cindy Grande, NIFF6a Notation Interchange File Format. Grande
+Software Inc., 1995. ftp://blackbox.cartah.washington.edu/pub/
-Miguel Filgueiras, Implementing a Symbolic Music Processing
-System. LIACC, Universidade do Porto, 1996; submitted.
+[Specs for NIFF, a comprehensive but binary (yuk) format for notation HWN]
-Miguel Filgueiras, Some Music Typesetting Algorithms. LIACC,
-Universidade do Porto, forthcoming.
+Alexander Brinkman, ``PASCAL Programming for Music Research''. The
+University of Chicago Press, 1990.
=head1 AUTHORS
-Refs contributed by Han-Wen Nienhuys, Miguel Filgueiras, Mark
+References contributed by Han-Wen Nienhuys, Miguel Filgueiras, Mark
Basinski, Dorothea Blostein, Stephen Page, Jan Nieuwenhuizen.
This should really be redone in BibTeX
A preprocessor to MusixTeX by Jan Nieuwenhuizen and Han-Wen Nienhuys.
It is outdated by its successor, LilyPond.
-=item Music, http://www.cs.nott.ac.uk/Departement/Staff/ef/printing.html
+=item LilyPond, http://www.stack.nl/~hanwen/lilypond/index.html
-A TROFF preprocessor by Eric Foxley
+Added for completeness. You are currently reading her documentation.
-MusE
+=item Music, http://www.cs.nott.ac.uk/Department/Staff/ef/printing.html
-A-R Music Engraving, by A-R Editions, Inc. Professional engraving on
-Sun boxen.
-
-=item Mup, http://www.arkkra.com/
-
-A program which creates PS from a script input. Although it comes with
-C source code, it is Shareware.
+A TROFF preprocessor by Eric Foxley
=item PMX, http://www.gmd.de/Misc/Music/
MusixTeX is a macro package for TeX to typeset polyphonic or
instrumental music by Daniel Taupin, Ross Mitchell and Andreas
-Egler. It includes a font set with lots symbols
+Egler. It includes a full-featured set of fonts.
=item ABC2MTeX, http://www.gmd.de/Misc/Music/
-A preprocessor to MusixTeX by Chris Walshaw for way of transcribing folk
-and traditional music.
+A preprocessor to MusixTeX by Chris Walshaw for transcribing folk and
+traditional music.
=item SceX http://www.ncc.up.pt/~mig/SceX.html
=head2 Proprietary
+=item Scribe, http://
+
+A formatter for medieval scores.
+
+=item Mup, http://www.arkkra.com/
+
+A program which creates PS from a script input. Although it comes with
+C source code, it is Shareware.
+
=item MusicEase, http://mesa.colorado.edu/~grader/musicez.html
Described in Computer vol 29(6). Shareware
=item Sibelius, http://www.acorn.co.uk/developers/sibelius
-Finale
+=item Finale
-Score
+=item Score
-Personal Composer
+=item Personal Composer
+=item MusE
+A-R Music Engraving, by A-R Editions, Inc. Professional engraving on
+Sun boxen.
=item Mozart, http://www.mozart.co.uk/
A shareware windows package
-Capella
+=item Capella
-Encore
+=item Encore
-Musicator
+=item Musicator
=head2 Unknown
-7/Jul/97 LilyPond 0.0.73 1
+7/Jul/97 LilyPond 0.0.74 1
-7/Jul/97 LilyPond 0.0.73 2
+7/Jul/97 LilyPond 0.0.74 2
-7/Jul/97 LilyPond 0.0.73 3
+7/Jul/97 LilyPond 0.0.74 3
-7/Jul/97 LilyPond 0.0.73 4
+7/Jul/97 LilyPond 0.0.74 4
-7/Jul/97 LilyPond 0.0.73 5
+7/Jul/97 LilyPond 0.0.74 5
-pl 72pre.jcn1
-
- - naming fixes; some iter*() explicitations
- - removed acceptor.hh
- - second draft of midi (audio/...) based on engraver hierarchy
-
+pl 74pre
+ - Input_engraver -> Input_translator
+ - bf: span start/stop is now a "used" col.
+ - Rest_column/Rest_collisions bugfixes
+ - bf: crescendi.
+ - Spanner do_print()
+
+******
+july 7
pl 73pre
- some refs doco.
- move Input_engraver into Paper_def
Most of the items are marked in the code as well, with full explanation.
grep for TODO and ugh/ugr
+ * Redo MIDI output to use Translators
+ - remember more horizontal info than melodics:
+ - tempo change
+ - repeat
+ - slurs
+ - dynamics etc.
+
* pushgroup/popgroup
* strict separation between visual and auditive processing.
* implement better breaking algorithm
* update 20 pt table
-
- * use Hungarian throughout code
* decent TeX page layout
PROJECTS
+ * grace notes
+ - adapt for multiple font sizes.
+ - make separate class for Grace_*_engravers
+ (which is at Voice_gravs level)
+ - move stem, beam, slur into baseclass to adapt for (fixed size) grace notes.
+
* accidentals per Voice_group
* Convert all ref/bib stuff into BibTeX.
- separate visual from rhythmic info even more
- beams over bars
- * Redo MIDI output to use Translators
- - remember more horizontal info than melodics:
- - tempo change
- - repeat
- - slurs
- - dynamics etc.
-
* Redo font support
- - use GSharp fonts?
- rename mf fonts to avoid conflicts with musixtex
- - check (c) issues
- use own fonts/update musixtex fonts/find older (c)-less fonts
- hack up mf sources for decent spacing info (and then
read AFM/TFM directly, for text too)
+ - use MF to generate rules.
* lines:
- Ledger lines, should be separate item: Ledger_lines, Ledger_lines
BUGS
- * spurious Weird stem size warnings
-
* fix mysterious Flex malloc bug
* should adjust stemlength for flag number.
* SPEED!
- * grace notes
-
-
-FURTHER FOR ORCHESTRAL SCORE:
-
* multibar rests
* barnumbers, markers
local $base="lilypond/";
-local @examples=("multi", "wohltemperirt" ,"standchen", "toccata-fuga-E", "scsii-menuetto", "collisions");
+local @examples=("multi", "wohltemperirt" ,"standchen", "toccata-fuga-E",
+ "scsii-menuetto", "collisions", "cadenza", "scales");
# rhythm, scales,
#ifndef ITERATE_HH
#define ITERATE_HH
-/*
- ugh.
- jcn: kjoet.
- if we wouldn't have had this, things might have been
- just a little bit easier to read, imho.
- (it does save quite some disk space, though)
- */
+
#define iterator(set) typeof((set).top())
#define iterator_bot(set) typeof((set).bottom())
% setup for Request->Element conversion. Guru-only
%
-\requestengraver {
- "Score_engraver"
+\requesttranslator {
+ Engraver Score_engraver
\alias "Score";
+
\consists "Bar_align_engraver";
\consists "Clef_align_engraver";
\consists "Key_align_engraver";
\consists "Meter_align_engraver";
\consists "Score_horizontal_align_engraver";
+
\consists "Vertical_align_engraver";
\consists "Span_bar_engraver";
- \contains\requestengraver {
- "Staff_engravers"
+ \contains\requesttranslator {
+ Engraver "Staff_engravers"
\alias "Staff";
\consists "Bar_engraver";
\consists "Clef_engraver";
\consists "Staff_sym_engraver";
\consists "Collision_engraver";
\consists "Rest_collision_engraver";
- \contains \requestengraver {
- "Voice_group_engravers"
+ \contains \requesttranslator {
+ Engraver "Voice_group_engravers"
\alias "Voice_group";
\consists "Dynamic_engraver";
\consists "Stem_beam_engraver";
\consists "Script_engraver";
\consists "Note_column_engraver";
\consists "Slur_engraver";
- \contains \requestengraver {
- "Engraver_group_engraver"
+ \contains \requesttranslator {
+ Engraver "Engraver_group_engraver"
\alias "Voice";
\consists "Note_head_engraver" ;
\consists "Tie_engraver";
}
}
- \contains\requestengraver {
- "Staff_engravers"
+ \contains\requesttranslator {
+ Engraver "Staff_engravers"
\alias "Lyric";
- \contains\requestengraver{
- "Voice_group_engravers"
+ \contains\requesttranslator{
+ Engraver "Voice_group_engravers"
\alias "Voice_group";
- \contains\requestengraver{
- "Engraver_group_engraver"
+ \contains\requesttranslator{
+ Engraver "Engraver_group_engraver"
\consists "Lyric_engraver";
\consists "Swallow_engraver";
}
+++ /dev/null
-
-default_midi = \midi {
- \tempo 4:60;
- \include "performer.ini"
-}
+++ /dev/null
-%
-% setup for Request->Element conversion. Guru-only
-%
-
-\requestperformer {
- "Score_performer"
- \alias "Score";
- \consists "Clef_performer";
- \consists "Key_performer";
- \consists "Meter_performer";
- \consists "Tempo_performer";
-
- \contains\requestperformer {
- "Staff_performers"
- \alias "Midi";
- \contains\requestperformer{
- "Voice_group_performers"
- \alias "Voice_group";
- \contains\requestperformer{
- "Performer_group_performer"
- \consists "Lyric_performer";
- \consists "Note_performer";
- }
- }
- }
-}
\include "script.ini"
\include "paper16.ini"
-% ugh
-\include "midi.ini"
-
left = -1
right = 1
up = 1
"1" "\wholerest" 0.0\pt 6.0\pt 0.0\pt 2.0\pt
"2" "\halfrest" 0.0\pt 6.0\pt -2.0\pt 0.0\pt
"2o" "\outsidehalfrest" 0.0\pt 6.0\pt -2.0\pt 0.0\pt
+ "4o" "\quartrest" -5.0\pt 2.0\pt -5.0\pt 5.0\pt
+ "8o" "\eighthrest" 0.0\pt 5.0\pt 0.0\pt 8.0\pt
+ "16o" "\sixteenthrest" 0.0\pt 6.0\pt 0.0\pt 12.0\pt
"4" "\quartrest" -5.0\pt 2.0\pt -5.0\pt 5.0\pt
"8" "\eighthrest" 0.0\pt 5.0\pt 0.0\pt 8.0\pt
"16" "\sixteenthrest" 0.0\pt 6.0\pt 0.0\pt 12.0\pt
\cadenza 1;
\grouping 1*4;\duration 8;\octave c';
- \clef \violin ;
+ \clef "violin";
c'4.\mf g8
[e'^"accel" ~ d' c' b]
[b~ c'] g-\fermata
- \bar \empty;
+ \bar "empty";
c [c_"rubato" e g c']
\octave c'';
e4. e [g ~ f_"rit" e d]
\duration 16;
dis4~ e4
- \bar \empty ;
+ \bar "" ;
r8 [c d] [e f g gis]
\duration 4;
a-> 'f~ 'e g
f-> 'd~ 'cis e
\duration 8;
d4^\fermata
- \bar \empty ;
+ \bar "" ;
r8 'a ['b cis]
\duration 16; [d cis d e]
'b4
\octave c'; [2/3 d'8 c'8 a8]1/1
g2
- \bar \empty ;
+ \bar "" ;
[g c e g] [c' e g c']\octave c'';
[e 'g c e] g4^\fermata %~ % BUG!
- \bar \empty ;
+ \bar "" ;
[g8.(_"a tempo" e g8. )e]
a4. g8 [f8 e8 d8 c8]
'g2 d2^"tr"
Tested Features: local key, key, forced accidentals
EndMudelaHeader
%}
-\version "0.0.58";
+\version "0.0.61";
blah = \melodic{
}
\score{
- \staff {
- melodicregs
- blah
- }
+ \blah
+
}
% \lbheel \lbheel \lfheel \lftoe
% \rbheel \rbtoe \rfheel \rftoe
-\version "0.0.58";
+\version "0.0.61";
\score{
- \staff{ melodicregs
\melodic {
\meter 4/4;
\key fis cis;
[d-\lfheel e-\rbtoe fis-\ltoe e-\rbtoe]
[d-\lfheel e-\rbtoe fis-\lheel e] [d e fis e] [d e fis e] |
d4 r4 r4 [b-\rtoe a-\ltoe b-\rtoe fis-\ltoe] |
- }
}
\paper{}
}
+%{MudelaHeader
+
+ filename: scales.ly
+ title:
+ description:
+ composers:
+ entered-by: HWN
+ copyright: public domain
+
+ Tested Features: scripts, beams, transposition,
+EndMudelaHeader
+%}
+
%
% scales with accents.
%
Tested Features: scripts, text.
EndMudelaHeader
%}
-\version "0.0.58";
+\version "0.0.61";
-blah = \staff{ melodicregs
-
- \melodic {
+blah = \melodic {
\octave c';
'c ->-.-\fermata-"text"
c ->-.-\fermata-"text"
[c-\lheel \< d-\lheel e-\lheel \! f-\lheel]
[d'-\lheel \> e'-\lheel f'-\lheel \! g'-\lheel]
}
-}
+
\score{
- blah
- \paper{
- \symboltables {table_sixteen}
- }
+ \blah
+
}
MAJOR_VERSION = 0
MINOR_VERSION = 0
-PATCH_LEVEL = 73
+PATCH_LEVEL = 74
# use to send patches, always empty for released version:
# include separator: ".postfix", "-pl" makes rpm barf
-MY_PATCH_LEVEL = pre.jcn1
+MY_PATCH_LEVEL = pre
# a bit of a hack to keep exec size under control.
stablecc=atom.cc command-request.cc musical-request.cc bar.cc boxes.cc \
keyword.cc leastsquares.cc \
- lookup.cc molecule.cc meter.cc\
- paper-def.cc parser.cc lexer.cc qlp.cc qlpsolve.cc\
+ lookup.cc meter.cc\
+ parser.cc lexer.cc qlp.cc qlpsolve.cc\
template1.cc template2.cc template3.cc template4.cc\
template5.cc template6.cc version.cc tex-stream.cc tex.cc\
- identifier.cc note.cc voice-gravs.cc\
+ identifier.cc note.cc
{
#ifndef NPRINT
mtor << "slope " <<slope << "left ypos " << left_pos;
- Spanner::print();
+ Spanner::do_print();
#endif
}
/*
inside_staff_b_ = false;
}
-Molecule*
-Crescendo::brew_molecule_p() const
+Interval
+Crescendo::symbol_height()const
{
- Molecule* m_p =0;
- Real x_off_dim=0.0;
- Real absdyn_dim = 10 PT; // ugh
-
- m_p = new Molecule;
+ return get_symbol().dim.y;
+}
+
+static Real absdyn_dim = 10 PT; // ugh
+
+Symbol
+Crescendo::get_symbol()const
+{
Real w_dim = width().length();
if ( left_dyn_b_ ) {
w_dim -= absdyn_dim;
- x_off_dim += absdyn_dim;
}
if ( right_dyn_b_ ) {
w_dim -= absdyn_dim;
warning("Crescendo too small");
w_dim = 0;
}
- Real lookup_wid = w_dim * 0.9; // make it slightly smaller.
+// Real lookup_wid = w_dim * 0.9; // make it slightly smaller.
- Symbol s( paper()->lookup_l()->hairpin( lookup_wid, grow_dir_i_ < 0) );
+ return Symbol( paper()->lookup_l()->hairpin( w_dim, grow_dir_i_ < 0) );
+}
+
+Molecule*
+Crescendo::brew_molecule_p() const
+{
+ Molecule* m_p =0;
+ Real x_off_dim=0.0;
+ if ( left_dyn_b_)
+ x_off_dim += absdyn_dim;
+
+ m_p = new Molecule;
+ Symbol s(get_symbol());
m_p->add(Atom(s));
- int pos = get_position_i(s.dim.y);
- m_p->translate(Offset(x_off_dim + 0.05 * w_dim,
- pos * paper()->internote_f()));
+ m_p->translate(Offset(x_off_dim, pos_i_ * paper()->internote_f()));
return m_p;
}
#include "debug.hh"
#include "p-score.hh"
#include "score-elem.hh"
-#include "input-engraver.hh"
+#include "input-translator.hh"
+Engraver* get_engraver_p(String);
Engraver_group_engraver::~Engraver_group_engraver()
{
Engraver_group_engraver::Engraver_group_engraver()
{
- igrav_l_ =0;
+ itrans_l_ =0;
}
void
Engraver_group_engraver::set_feature(Feature d)
{
- PCursor<Engraver*> i(grav_list_.top());
- // why the while construct?
+ iter_top(grav_list_, i);
while (i.ok()) {
// this construction to ensure clean deletion
Engraver *grav_l = i++;
void
Engraver_group_engraver::sync_features()
{
- PCursor<Engraver*> i(grav_list_.top());
+ iter_top(grav_list_, i);
while (i.ok()) {
+
Engraver *grav_l = i++;
grav_l->sync_features();
}
void
Engraver_group_engraver::do_pre_move_processing()
{
- PCursor<Engraver*> i(grav_list_.top());
+ iter_top(grav_list_, i);
while (i.ok()) {
+
Engraver *grav_l = i++;
grav_l->pre_move_processing();
}
void
Engraver_group_engraver::do_process_requests()
{
- PCursor<Engraver*> i(grav_list_.top());
+ iter_top(grav_list_, i);
while (i.ok()) {
+
Engraver *grav_l = i++;
grav_l->process_requests();
}
void
Engraver_group_engraver::do_post_move_processing()
{
- PCursor<Engraver*> i(grav_list_.top());
+ iter_top(grav_list_, i);
while (i.ok()) {
// this construction to ensure clean deletion
Engraver *grav_l = i++;
if (parent_b)
return true;
- for (PCursor<Engraver*> i(grav_list_.top()); i.ok(); i++)
- if (i->contains_b(grav_l))
+ for (iter_top(grav_list_, j); j.ok(); j++)
+ if (j->contains_b(grav_l))
return true;
return false;
}
{
group_l_arr_.substitute((Engraver_group_engraver*)grav_l,0);
nongroup_l_arr_.substitute(grav_l,0);
- PCursor<Engraver*> grav_cur( grav_list_.find(grav_l) );
+ iterator(grav_list_) grav_cur= grav_list_.find(grav_l);
return grav_cur.remove_p();
}
{
#ifndef NPRINT
mtor << "ID: " << id_str_ << "\n";
- for (PCursor<Engraver*> i(grav_list_.top()); i.ok(); i++)
+ for (iter_top(grav_list_, i); i.ok(); i++)
i->print();
#endif
}
Engraver_group_engraver::find_get_translator_l(String n,String id)
{
Translator * ret=0;
- Input_engraver * igrav_l= igrav_l_-> recursive_find ( n );
- if (igrav_l ) {
+ Input_translator * itrans_l= itrans_l_-> recursive_find ( n );
+ if (itrans_l ) {
ret = find_engraver_l(n,id);
if (!ret) {
Engraver_group_engraver * group =
- igrav_l-> get_group_engraver_p();
+ itrans_l-> get_group_engraver_p();
add(group);
ret = group;
- if (group->igrav_l_->is_name_b( n ) )
+ if (group->itrans_l_->is_name_b( n ) )
ret ->id_str_ = id;
else
return ret->find_get_translator_l(n,id);
void
Engraver_group_engraver::do_removal_processing()
{
- for (PCursor<Engraver*> i(grav_list_.top()); i.ok(); i++)
+ for (iter( grav_list_.top(), i); i.ok(); i++)
i->do_removal_processing();
}
if ( is_bottom_engraver_b() )
return daddy_grav_l_->get_default_interpreter();
- Engraver_group_engraver *grav_p= igrav_l_->
- get_default_igrav_l()->get_group_engraver_p();
+ Engraver_group_engraver *grav_p= itrans_l_->
+ get_default_itrans_l()->get_group_engraver_p();
add(grav_p );
if (grav_p->is_bottom_engraver_b())
return grav_p;
bool
Engraver_group_engraver::is_bottom_engraver_b()const
{
- return !igrav_l_->get_default_igrav_l();
+ return !itrans_l_->get_default_itrans_l();
}
/*
- global-gravs.cc -- implement
+ global-gravs.cc -- implement Engraver,Performer ctors
source file of the GNU LilyPond music typesetter
#include "proto.hh"
#include "plist.hh"
-#include "input-engraver.hh"
+#include "input-translator.hh"
#include "debug.hh"
#include "engraver.hh"
static Array<Engraver_table_entry> *grav_table=0;
void
-add_Engraver(String s, Grav_ctor f)
+add_engraver(String s, Grav_ctor f)
{
if (!grav_table)
grav_table = new Array<Engraver_table_entry>;
error("Unknown engraver `" + s +"\'");
return 0;
}
+
+#if 0
+
+struct Performer_table_entry
+{
+ String name_str_;
+ Perf_ctor ctor_l_;
+ Performer_table_entry(String s, Perf_ctor f) {
+ name_str_ =s;
+ ctor_l_ = f;
+ }
+ Performer_table_entry()
+ {
+ ctor_l_ =0;
+ }
+}
+
+static Array<Performer_table_entry> *perf_table=0;
+
+void
+add_performer(String s, Perf_ctor f)
+{
+ if (!perf_table)
+ perf_table = new Array<Performer_table_entry>;
+
+ perf_table->push(Performer_table_entry(s, f));
+}
+
+
+Performer*
+get_performer_p(String s)
+{
+ for (int i=0; i < perf_table->size(); i++) {
+ if ((*perf_table)[i].name_str_ == s)
+ return (*(*perf_table)[i].ctor_l_)();
+ }
+ error("Unknown performer `" + s +"\'");
+ return 0;
+}
+#endif
+++ /dev/null
-/*
- global-performers.cc -- implement
-
- source file of the GNU LilyPond music typesetter
-
- (c) 1997 Han-Wen Nienhuys <hanwen@stack.nl>
- Jan Nieuwenhuizen <jan@digicash.com>
-*/
-
-#include "proto.hh"
-#include "plist.hh"
-#include "input-performer.hh"
-#include "debug.hh"
-#include "performer.hh"
-
-struct Performer_table_entry {
- String name_str_;
- Perf_ctor ctor_l_;
- Performer_table_entry(String s, Perf_ctor f) {
- name_str_ =s;
- ctor_l_ = f;
- }
- Performer_table_entry()
- {
- ctor_l_ =0;
- }
-};
-
-static Array<Performer_table_entry> *perf_table=0;
-
-void
-add_Performer(String s, Perf_ctor f)
-{
- if (!perf_table)
- perf_table = new Array<Performer_table_entry>;
-
- perf_table->push(Performer_table_entry(s, f));
-}
-
-
-Performer*
-get_performer_p(String s)
-{
- for (int i=0; i < perf_table->size(); i++) {
- if ((*perf_table)[i].name_str_ == s)
- return (*(*perf_table)[i].ctor_l_)();
- }
- error("Unknown performer `" + s +"\'");
- return 0;
-}
*/
#include <assert.h>
-#include "midi-def.hh"
#include "paper-def.hh"
#include "score.hh"
#include "identifier.hh"
#include "my-lily-lexer.hh"
#include "debug.hh"
+
#include "symtable.hh"
#include "lookup.hh"
#include "script-def.hh"
#include "request.hh"
-#include "input-engraver.hh"
-#include "input-performer.hh"
+#include "input-translator.hh"
IMPLEMENT_STATIC_NAME(Identifier);
IMPLEMENT_IS_TYPE_B(Identifier);
DEFAULT_PRINT(Music_id,Music , music);
DEFAULT_PRINT(Request_id, Request, request);
DEFAULT_PRINT(Score_id, Score, score);
-DEFAULT_PRINT(Input_gravs_id, Input_engraver, igravs);
-DEFAULT_PRINT(Input_perfs_id, Input_performer, iperfs);
-DEFAULT_PRINT(Midi_def_id,Midi_def, mididef);
+DEFAULT_PRINT(Input_trans_id, Input_translator, itrans);
DEFAULT_PRINT(Paper_def_id,Paper_def, paperdef);
void
implement_id_class(Music_id, Music, music);
implement_id_class(Score_id, Score, score);
implement_id_class(Request_id, Request, request);
-implement_id_class(Input_gravs_id, Input_engraver, igravs);
-implement_id_class(Input_perfs_id, Input_performer, iperfs);
-implement_id_class(Midi_def_id, Midi_def, mididef);
+implement_id_class(Input_trans_id, Input_translator, itrans);
implement_id_class(Paper_def_id, Paper_def, paperdef);
Identifier::Identifier(Identifier const&)
virtual_accessor(Music_id, Music, music);
default_accessor(Score_id, Score, score);
virtual_accessor(Request_id, Request, request);
-default_accessor(Input_gravs_id, Input_engraver, igravs);
-default_accessor(Input_perfs_id, Input_performer, iperfs);
-default_accessor(Midi_def_id, Midi_def, mididef);
+default_accessor(Input_trans_id, Input_translator, itrans);
default_accessor(Paper_def_id, Paper_def, paperdef);
+/*
+ acceptor.hh -- declare Translator
+
+ source file of the GNU LilyPond music typesetter
+
+ (c) 1997 Han-Wen Nienhuys <hanwen@stack.nl>
+*/
+
+
+#ifndef ACCEPTOR_HH
+#define ACCEPTOR_HH
+#error
+
+#include "string.hh"
+#include "lily-proto.hh"
+#include "interpreter.hh"
+#include "virtual-methods.hh"
+
+class Translator {
+public:
+ String id_str_;
+
+ int iterator_count_;
+
+ virtual Interpreter * interpreter_l() { return 0; }
+
+ /// Score_engraver = 0, Staff_engravers = 1, etc)
+ virtual int depth_i()const=0;
+ virtual Translator *find_get_translator_l(String name, String id)=0;
+ virtual Translator *ancestor_l(int l=1)=0;
+ virtual ~Translator(){}
+ NAME_MEMBERS();
+ Translator();
+ virtual Translator *get_default_interpreter()=0;
+};
+
+class Interpreter : public virtual Translator {
+public:
+ virtual bool interpret_request_b(Request*) { return false;}
+};
+#endif // ACCEPTOR_HH
protected:
SCORE_ELEM_CLONE(Crescendo);
virtual Molecule*brew_molecule_p()const;
+ virtual Interval symbol_height()const;
NAME_MEMBERS();
private:
+ Symbol get_symbol()const;
};
#ifndef ENGRAVERGROUP_HH
#define ENGRAVERGROUP_HH
-#include "lily-proto.hh"
#include "parray.hh"
#include "plist.hh"
#include "score-elem-info.hh"
virtual bool removable_b()const;
public:
- Input_engraver * igrav_l_;
+ Input_translator * itrans_l_;
void check_removal();
Engraver_group_engraver();
~Engraver_group_engraver();
return new c; \
} \
c ## init () { \
- add_Engraver(c::static_name(), globalctor); \
+ add_engraver(c::static_name(), globalctor); \
\
} \
} _ ## c ## init;
typedef Engraver*(*Grav_ctor)(void);
-void add_Engraver(String s, Grav_ctor f);
+void add_engraver(String s, Grav_ctor f);
#endif // ENGRAVER_HH
+++ /dev/null
-
-/*
- global-performers.hh -- declare global performer stuff
-
- source file of the GNU LilyPond music typesetter
-
- (c) 1996, 1997 Han-Wen Nienhuys <hanwen@stack.nl>
- Jan Nieuwenhuizen <jan@digicash.com>
-*/
-
-#ifndef GLOBAL_PERFORMER_HH
-#define GLOBAL_PERFORMER_HH
-
-/**
- A macro to automate administration of performers
- */
-#define ADD_THIS_PERFORMER( c ) \
-struct c ## init { \
- static Performer* globalctor () \
- { \
- return new c;\
- } \
- c ## init () \
- { \
- add_Performer( c::static_name(), globalctor ); \
- } \
-} _ ## c ## init;
-
-// typedef Performer*(*Perf_ctor)(void); c++ ?
-typedef Performer*(*Perf_ctor)();
-void add_Performer(String s, Perf_ctor f);
-
-#endif // GLOBAL_PERFORMER_HH
-#endif // GLOBAL_TRANSLATOR_HH
+#endif // Global_translator_HH
NAME_MEMBERS();
void error(String);
IDACCESSOR(Music, music)
- IDACCESSOR(Input_engraver, igravs)
- IDACCESSOR(Input_performer, iperfs)
+ IDACCESSOR(Input_translator, itrans)
IDACCESSOR(General_script_def, script)
IDACCESSOR(Symtables, symtables)
- IDACCESSOR(Midi_def, mididef)
IDACCESSOR(Paper_def, paperdef)
IDACCESSOR(Lookup,lookup)
IDACCESSOR(Real,real)
declare_id_class(Int_id, int, intid);
declare_id_class(Score_id, Score, score);
declare_id_class(Request_id, Request, request);
-declare_id_class(Input_gravs_id, Input_engraver, igravs);
-declare_id_class(Input_perfs_id, Input_performer, iperfs);
-declare_id_class(Midi_def_id,Midi_def, mididef);
+declare_id_class(Input_trans_id, Input_translator, itrans);
declare_id_class(Paper_def_id,Paper_def, paperdef);
#endif // IDENTIFIER_
+++ /dev/null
-/*
- input-engraver.hh -- declare Input_engraver
-
- source file of the GNU LilyPond music typesetter
-
- (c) 1997 Han-Wen Nienhuys <hanwen@stack.nl>
-*/
-
-
-#ifndef INPUT_ENGRAVER_HH
-#define INPUT_ENGRAVER_HH
-
-#include "plist.hh"
-#include "string.hh"
-#include "lily-proto.hh"
-#include "input.hh"
-#include "string.hh"
-#include "varray.hh"
-
-struct Input_engraver_list : public Pointer_list<Input_engraver*>
-{
- Input_engraver_list(Input_engraver_list const &);
- Input_engraver_list(){}
-};
-
-struct Input_engraver : Input {
- Input_engraver_list contains_igrav_p_list_;
- Array<String> consists_str_arr_;
- Array<String> alias_str_arr_;
- String type_str_;
-
- void add(Input_engraver *);
- bool is_name_b(String);
- bool accept_req_b();
- bool accepts_b(String);
- void print() const;
- Engraver_group_engraver * get_group_engraver_p();
- Input_engraver * get_default_igrav_l();
- Input_engraver * recursive_find(String nm);
- Input_engraver * find_igrav_l(String nm);
-};
-
-
-Engraver*get_engraver_p(String s);
-
-#endif // INPUT_ENGRAVER_HH
+++ /dev/null
-/*
- input-performer.hh -- declare Input_performer
-
- source file of the GNU LilyPond music typesetter
-
- (c) 1997 Han-Wen Nienhuys <hanwen@stack.nl>
- Jan Nieuwenhuizen <jan@digicash.com>
-*/
-
-#ifndef INPUT_PERFORMER_HH
-#define INPUT_PERFORMER_HH
-
-#include "plist.hh"
-#include "string.hh"
-#include "lily-proto.hh"
-#include "input.hh"
-#include "string.hh"
-#include "varray.hh"
-
-struct Input_performer_list : public Pointer_list<Input_performer*>
-{
- Input_performer_list(Input_performer_list const &);
- Input_performer_list(){}
-};
-
-struct Input_performer : Input {
- Input_performer_list contains_iperf_p_list_;
- Array<String> consists_str_arr_;
- Array<String> alias_str_arr_;
- String type_str_;
-
- void add(Input_performer *);
- bool is_name_b(String);
- bool accept_req_b();
- bool accepts_b(String);
- void print() const;
- Performer_group_performer * get_group_performer_p();
- Input_performer * get_default_iperf_l();
- Input_performer * recursive_find(String nm);
- Input_performer * find_iperf_l(String nm);
-};
-
-
-Performer*get_performer_p(String s);
-
-#endif // INPUT_PERFORMER_HH
--- /dev/null
+/*
+ input-translator.hh -- declare Input_translator
+
+ source file of the GNU LilyPond music typesetter
+
+ (c) 1997 Han-Wen Nienhuys <hanwen@stack.nl>
+*/
+
+
+#ifndef INPUT_TRANSLATOR_HH
+#define INPUT_TRANSLATOR_HH
+
+#include "plist.hh"
+#include "string.hh"
+#include "lily-proto.hh"
+#include "input.hh"
+#include "string.hh"
+#include "varray.hh"
+
+struct Input_translator_list : public Pointer_list<Input_translator*>
+{
+ Input_translator_list(Input_translator_list const &);
+ Input_translator_list(){}
+};
+
+struct Input_translator : Input {
+ Input_translator_list contains_itrans_p_list_;
+ Array<String> consists_str_arr_;
+ Array<String> alias_str_arr_;
+ String base_str_;
+ String type_str_;
+ String default_id_str_;
+
+ void add(Input_translator *);
+ bool is_name_b(String);
+ bool accept_req_b();
+ bool accepts_b(String);
+ void print() const;
+ Engraver_group_engraver * get_group_engraver_p();
+ // Performer_group_performer * get_group_performer_p();
+ Input_translator * get_default_itrans_l();
+ Input_translator * recursive_find(String nm);
+ Input_translator * find_itrans_l(String nm);
+};
+Engraver* get_engraver_p(String);
+Performer* get_performer_p(String);
+
+#endif // Input_translator_HH
struct Clef_change_req;
struct Clef_item;
struct Clef_engraver;
-struct Clef_performer;
struct Col_hpositions;
struct Chord;
struct Colinfo;
struct Identifier;
struct Interpreter;
struct Input_file;
-struct Input_engraver;
-struct Input_performer;
+struct Input_translator;
struct Input_score;
struct Item;
struct Key;
struct Key_change_req;
struct Key_item;
struct Key_engraver;
-struct Key_performer;
struct Keyword;
struct Keyword_table;
struct Lily_stream;
struct Meter;
struct Meter_change_req;
struct Meter_engraver;
-struct Meter_performer;
struct Midi_def;
struct Midi_duration;
struct Midi_header;
struct My_lily_parser;
struct Note_column;
struct Note_column_engraver;
-struct Note_performer;
struct Note_req;
struct Note_head;
struct Note_head_engraver;
struct Notename_table;
struct Offset;
struct Output;
+struct Performer;
struct PCol;
struct PScore;
struct Paper_def;
struct Pulk_voices;
struct Rational;
struct Engraver_group_engraver;
-struct Performer;
-struct Performer_group_performer;
struct Request;
struct Request_column;
struct Engraver;
*/
-#ifndef MIDI_DEF_HH
-#define MIDI_DEF_HH
+#ifndef MIDIDEF_HH
+#define MIDIDEF_HH
#include "lily-proto.hh"
#include "real.hh"
#include "string.hh"
/// output file name
String outfile_str_;
- Assoc<String, Real> *real_vars_p_;
- Input_performer* iperf_p_;
-
/// duration of whole note
Real whole_seconds_f_;
Midi_def();
- Midi_def( Midi_def const& midi_c_r );
+ Midi_def(Midi_def const& midi_c_r);
~Midi_def();
Real duration_to_seconds_f(Moment);
- Global_translator* get_global_translator_p() const;
- Real get_var( String s ) const;
int get_tempo_i( Moment moment );
- void print() const;
- void set( Input_performer* iperf_p );
- void set_var( String s, Real r );
void set_tempo( Moment moment, int count_per_minute_i );
+ void print() const;
};
-#endif // MIDI_DEF_HH
+#endif // MIDIDEF_HH //
+++ /dev/null
-/*
- midi-walker.hh -- declare Midi_walker
-
- (c) 1996,97 Han-Wen Nienhuys, Jan Nieuwenhuizen <jan@digicash.com>
- */
-
-#ifndef MIDIWALKER_HH
-#define MIDIWALKER_HH
-
-
-#include "lily-proto.hh"
-
-#if 0
-
-/*
- sketch. . .
-
- It would be totally cool to share code with the Engraver hierarchy,
- but this is very tough i think.
-
- */
-
-class Voice_performer_group_performer : public Performer_group_performer {
-
-};
-
-#endif
-
-#endif // MIDIWALKER_HH
-
-
#include "lily-proto.hh"
#include "plist.hh"
+#include "varray.hh"
#include "moment.hh"
class Music_iterator {
public:
Music_iterator *daddy_iter_l_;
NAME_MEMBERS();
- Translator *report_to_l_;
+ Array<Translator *>report_to_l_arr_;
+
+ Translator *report_to_l()const;
static Music_iterator* static_get_iterator_p(Music*,Translator*);
Music_iterator* get_iterator_p(Music*)const;
void set_translator(Translator*);
+ void push_translator(Translator*);
+ void pop_translator();
+
+
Music_iterator();
virtual void process_and_next(Moment until);
Input pop_spot();
Paper_def*default_paper();
- Midi_def*default_midi();
void do_yyparse();
void parser_error(String);
void clear_notenames();
+++ /dev/null
-/*
- note-performer.hh -- declare Note_performer
-
- (c) 1996, 1997 Han-Wen Nienhuys <hanwen@stack.nl>
- Jan Nieuwenhuizen <jan@digicash.com>
- */
-
-#ifndef NOTE_PERFORMER_HH
-#define NOTE_PERFORMER_HH
-
-#include "performer.hh"
-
-class Note_performer : public Performer {
- Melodic_req* current_l_;
- Moment off_mom_;
- Moment on_mom_;
-
-public:
- virtual void process_request() {
- if ( when() == off_mom_ )
- play_event( Note_event( current_l_->pitch() ) );
-};
-
-#endif // NOTE_PERFORMER_HH
Real hpos; // should use ptr?
bool error_mark_b_;
+ bool used_b_ ; // manual override..
PScore * pscore_l_;
Lookup *lookup_p_;
Assoc<String, Real> *real_vars_p_;
- Input_engraver * igrav_p_;
+ Input_translator * itrans_p_;
public:
String outfile_str_;
void reinit();
Paper_def();
void set(Lookup*);
- void set (Input_engraver * );
+ void set (Input_translator * );
Global_translator * get_global_translator_p()const;
~Paper_def();
Paper_def(Paper_def const&);
+++ /dev/null
-/*
- performer-group-performer.hh -- declare Performer_group_performer
-
- (c) 1996, 1997 Han-Wen Nienhuys <hanwen@stack.nl>
- Jan Nieuwenhuizen <jan@digicash.com>
- */
-
-#ifndef PERFORMER_GROUP_PERFORMER_HH
-#define PERFORMER_GROUP_PERFORMER_HH
-
-#include "lily-proto.hh"
-#include "parray.hh"
-#include "plist.hh"
-#include "performer.hh"
-#include "translator.hh"
-
-/**
- Group a number of performers. Usually delegates everything to its contents.
-*/
-
-class Performer_group_performer : public Performer, public virtual Translator {
- Pointer_list<Performer*> perf_p_list_;
-
- Link_array<Performer_group_performer> group_l_arr_;
- Link_array<Performer> nongroup_l_arr_;
-
-public:
- Input_performer* iperf_l_;
-
- virtual bool try_request( Request* req_l );
- virtual void add( Performer* perf_p );
-};
-
-#endif // PERFORMER_GROUP_PERFORMER_HH
-
+++ /dev/null
-/*
- performer.hh -- declare Performer
-
- (c) 1996, 1997 Han-Wen Nienhuys <hanwen@stack.nl>
- Jan Nieuwenhuizen <jan@digicash.com>
- */
-
-#ifndef PERFORMER_HH
-#define PERFORMER_HH
-
-#include "lily-proto.hh"
-
-class Performer {
- Performer_group_performer* daddy_perf_l_;
-
-public:
- NAME_MEMBERS();
- Performer();
- virtual ~Performer();
-
- void print() const;
-
- virtual void play_event( Midi_item i );
- virtual bool try_request( Request* req_l );
-};
-
-#include "global-performers.hh"
-
-#endif // PERFORMER_HH
void add(Note_head *);
void add(Stem *);
NAME_MEMBERS();
- void translate_y(Real dy);
Rest_column();
+ void translate_heads(int dy);
protected:
virtual void do_print() const;
virtual void do_substitute_dependency(Score_elem*, Score_elem*);
+++ /dev/null
-/*
- score-performer.hh -- declare Score_performer
-
- (c) 1996, 1997 Han-Wen Nienhuys <hanwen@stack.nl>
- Jan Nieuwenhuizen <jan@digicash.com>
- */
-
-#ifndef SCORE_PERFORMER_HH
-#define SCORE_PERFORMER_HH
-
-#include "performer-group-performer.hh"
-#include "global-translator.hh"
-
-class Score_performer:
- public Performer_group_performer, public Global_translator
-{
- Midi_file* file_p_;
- Moment prev_mom_;
-
-public:
- virtual void play_event( Midi_item i );
- virtual void prepare( Moment mom );
-};
-
-#endif // SCORE_PERFORMER_HH
private:
void run_translator(Global_translator*);
- void midi_output();
void paper_output();
-
/// do midi stuff
void midi();
*/
class Script : public Item, public Staff_side {
- int pos_i_;
-
Stem *stem_l_;
/* *************** */
Molecule *brew_molecule_p()const;
virtual void do_substitute_dependency(Score_elem*,Score_elem*);
virtual void do_print() const;
- virtual void do_post_processing();
+ virtual Interval symbol_height()const;
virtual void do_pre_processing();
virtual Interval do_width() const;
private:
void set_default_dir();
- void set_default_index();
- Symbol symbol()const;
public:
General_script_def *specs_l_;
+++ /dev/null
-/*
- staff-performer.hh -- declare Staff_performer
-
- (c) 1996, 1997 Han-Wen Nienhuys <hanwen@stack.nl>
- Jan Nieuwenhuizen <jan@digicash.com>
- */
-
-#ifndef STAFF_PERFORMER_HH
-#define STAFF_PERFORMER_HH
-
-#include "performer-group-performer.hh"
-
-class Staff_performer : public Performer_group_performer
-{
- int midi_track_i_;
-
-public:
- String instrument_str()
- virtual void play_event( Midi_item i );
-};
-
-#endif // STAFF_PERFORMER_HH
#define STAFF_SIDE_HH
#include "score-elem.hh"
+#include "interval.hh"
-/// A symbol which sits along the staff
+/** A symbol which sits along a staff
+
+ Should override translate_y() ?
+ */
class Staff_side : virtual Score_elem {
Link_array<Score_elem> support_l_arr_;
int staff_size_i_;
Interval support_height()const;
Staff_symbol* staff_sym_l_;
+ int get_position_i()const;
void read_staff_sym();
public:
Vertical dir of symbol relative to staff. -1 = below staff?
*/
int dir_i_;
+ Interval sym_int_;
/// follow the support inside the staff?
bool inside_staff_b_;
+ int pos_i_;
+
void set_staffsym(Staff_symbol * );
Staff_side();
NAME_MEMBERS();
protected:
+ virtual Interval symbol_height() const;
virtual void do_substitute_dependency(Score_elem *, Score_elem*);
- int get_position_i()const;
- int get_position_i(Interval)const;
+ virtual void do_post_processing();
};
#endif // STAFF_SIDE_HH
/*
- staff-sym-grav.hh -- declare
+ staff-sym-grav.hh -- declare Staff_sym_engraver
source file of the GNU LilyPond music typesetter
Staff_sym_engraver();
NAME_MEMBERS();
protected:
+ virtual ~Staff_sym_engraver();
virtual void do_process_requests();
virtual void fill_staff_info(Staff_info&);
virtual void do_removal_processing();
public:
- int pos_i_;
-
/// do I have width?
bool fat_b_;
protected:
General_script_def * tdef_p_;
- virtual void set_default_index();
+ virtual Interval symbol_height()const;
+
virtual Molecule* brew_molecule_p() const;
- virtual void do_post_processing();
virtual void do_pre_processing();
};
+++ /dev/null
-/*
- voice-group-performer.hh -- declare Voice_group_performer
-
- (c) 1996, 1997 Han-Wen Nienhuys <hanwen@stack.nl>
- Jan Nieuwenhuizen <jan@digicash.com>
- */
-
-#ifndef VOICE_GROUP_PERFORMER_HH
-#define VOICE_GROUP_PERFORMER_HH
-
-#include "performer-group-performer.hh"
-
-class Voice_performer_group_performer : public Performer_group_performer {
-
-};
-
-#if 0
-class Voice_performer :
- public Performer_group_performer, public Interpreter
-{
-
-};
-#endif
-
-#endif // VOICE_GROUP_PERFORMER_HH
+++ /dev/null
-/*
- input-engraver.cc -- implement Input_engraver
-
- source file of the GNU LilyPond music typesetter
-
- (c) 1997 Han-Wen Nienhuys <hanwen@stack.nl>
-*/
-
-#include "debug.hh"
-#include "engraver.hh"
-#include "input-engraver.hh"
-#include "parray.hh"
-#include "input-engraver.hh"
-#include "engraver-group.hh"
-
-bool
-Input_engraver::is_name_b(String n)
-{
- for (int i=0; i < alias_str_arr_.size(); i++)
- if (alias_str_arr_[i] == n)
- return true;
- return false;
-}
-
-void
-Input_engraver::print() const
-{
-#ifndef NPRINT
- mtor << "type " << type_str_;
- mtor << "Consists of ";
- for (int i=0; i< consists_str_arr_.size(); i++)
- mtor << consists_str_arr_[i] << ',';
- mtor << "contains " ;
- for (PCursor<Input_engraver*> i(contains_igrav_p_list_.top()); i.ok(); i++)
- i->print();
-#endif
-}
-
-
-
-Input_engraver *
-Input_engraver::recursive_find(String nm)
-{
- if ( is_name_b( nm) )
- return this;
-
- Input_engraver * r =0;
- PCursor<Input_engraver*> i(contains_igrav_p_list_.top());
- for (; !r &&i.ok(); i++) {
- if (i->recursive_find(nm))
- r = i.ptr();
- }
-
- return r;
-}
-
-Input_engraver *
-Input_engraver::find_igrav_l(String nm)
-{
- for (PCursor<Input_engraver*> i(contains_igrav_p_list_.top()); i.ok(); i++)
- if (i->is_name_b( nm))
- return i;
-
- return 0;
-}
-
-
-Engraver_group_engraver *
-Input_engraver::get_group_engraver_p()
-{
- Engraver_group_engraver * grav_p = (Engraver_group_engraver*)
- get_engraver_p(type_str_);
-
- for (int i=0; i < consists_str_arr_.size(); i++) {
- grav_p->add( get_engraver_p( consists_str_arr_[i]) );
- }
- grav_p -> igrav_l_ = this;
- return grav_p;
-}
-
-
-bool
-Input_engraver::accept_req_b()
-{
- return ! contains_igrav_p_list_.size();
-}
-
-void
-Input_engraver::add(Input_engraver *ip)
-{
- contains_igrav_p_list_.bottom().add(ip);
-}
-
-Input_engraver*
-Input_engraver::get_default_igrav_l()
-{
- if ( contains_igrav_p_list_.size() )
- return contains_igrav_p_list_.top();
- else
- return 0;
-}
-
-
-Input_engraver_list::Input_engraver_list(Input_engraver_list const &s)
-{
- for (PCursor<Input_engraver*> pc(s); pc.ok(); pc++) {
- Input_engraver *q = pc;
- Input_engraver *p=new Input_engraver(*q) ;
- bottom().add(p);
- }
-}
+++ /dev/null
-/*
- input-performer.cc -- implement Input_performer
-
- source file of the GNU LilyPond music typesetter
-
- (c) 1997 Han-Wen Nienhuys <hanwen@stack.nl>
- Jan Nieuwenhuizen <jan@digicash.com>
-*/
-
-#include "debug.hh"
-#include "performer.hh"
-#include "input-performer.hh"
-#include "parray.hh"
-#include "input-performer.hh"
-#include "performer-group-performer.hh"
-
-bool
-Input_performer::is_name_b(String n)
-{
- for (int i=0; i < alias_str_arr_.size(); i++)
- if (alias_str_arr_[i] == n)
- return true;
- return false;
-}
-
-void
-Input_performer::print() const
-{
-#ifndef NPRINT
- mtor << "type " << type_str_;
- mtor << "Consists of ";
- for (int i=0; i< consists_str_arr_.size(); i++)
- mtor << consists_str_arr_[i] << ',';
- mtor << "contains " ;
- for (PCursor<Input_performer*> i(contains_iperf_p_list_.top()); i.ok(); i++)
- i->print();
-#endif
-}
-
-
-
-Input_performer *
-Input_performer::recursive_find(String nm)
-{
- if ( is_name_b( nm) )
- return this;
-
- Input_performer * r =0;
- PCursor<Input_performer*> i(contains_iperf_p_list_.top());
- for (; !r &&i.ok(); i++) {
- if (i->recursive_find(nm))
- r = i.ptr();
- }
-
- return r;
-}
-
-Input_performer *
-Input_performer::find_iperf_l(String nm)
-{
- for (PCursor<Input_performer*> i(contains_iperf_p_list_.top()); i.ok(); i++)
- if (i->is_name_b( nm))
- return i;
-
- return 0;
-}
-
-
-Performer_group_performer *
-Input_performer::get_group_performer_p()
-{
- Performer_group_performer * perf_p = (Performer_group_performer*)
- get_performer_p(type_str_);
-
- for (int i=0; i < consists_str_arr_.size(); i++) {
- perf_p->add( get_performer_p( consists_str_arr_[i]) );
- }
- perf_p -> iperf_l_ = this;
- return perf_p;
-}
-
-
-bool
-Input_performer::accept_req_b()
-{
- return ! contains_iperf_p_list_.size();
-}
-
-void
-Input_performer::add(Input_performer *ip)
-{
- contains_iperf_p_list_.bottom().add(ip);
-}
-
-Input_performer*
-Input_performer::get_default_iperf_l()
-{
- if ( contains_iperf_p_list_.size() )
- return contains_iperf_p_list_.top();
- else
- return 0;
-}
-
-
-Input_performer_list::Input_performer_list(Input_performer_list const &s)
-{
- for (PCursor<Input_performer*> pc(s); pc.ok(); pc++) {
- Input_performer *q = pc;
- Input_performer *p=new Input_performer(*q) ;
- bottom().add(p);
- }
-}
--- /dev/null
+/*
+ input-translator.cc -- implement Input_translator
+
+ source file of the GNU LilyPond music typesetter
+
+ (c) 1997 Han-Wen Nienhuys <hanwen@stack.nl>
+*/
+
+//#include "translator-admin.hh"
+#include "debug.hh"
+#include "engraver.hh"
+#include "input-translator.hh"
+#include "parray.hh"
+#include "input-translator.hh"
+#include "engraver-group.hh"
+
+bool
+Input_translator::is_name_b(String n)
+{
+ for (int i=0; i < alias_str_arr_.size(); i++)
+ if (alias_str_arr_[i] == n)
+ return true;
+ return false;
+}
+
+void
+Input_translator::print() const
+{
+#ifndef NPRINT
+ mtor << base_str_ <<" " << type_str_<<" {\n";
+ mtor << "Consists of ";
+ for (int i=0; i< consists_str_arr_.size(); i++)
+ mtor << consists_str_arr_[i] << ',';
+ if (contains_itrans_p_list_.size())
+ mtor << "\nContains " ;
+ for (iter(contains_itrans_p_list_.top(), i); i.ok(); i++)
+ i->print();
+ mtor << "}\n";
+#endif
+}
+
+
+
+Input_translator *
+Input_translator::recursive_find(String nm)
+{
+ if ( is_name_b( nm) )
+ return this;
+
+ Input_translator * r =0;
+ iter(contains_itrans_p_list_.top(), i);
+ for (; !r &&i.ok(); i++) {
+ if (i->recursive_find(nm))
+ r = i.ptr();
+ }
+
+ return r;
+}
+
+Input_translator *
+Input_translator::find_itrans_l(String nm)
+{
+ for (iter(contains_itrans_p_list_.top(), i); i.ok(); i++)
+ if (i->is_name_b( nm))
+ return i;
+
+ return 0;
+}
+
+
+Engraver_group_engraver *
+Input_translator::get_group_engraver_p()
+{
+ assert (base_str_ == "Engraver");
+ Engraver_group_engraver * grav_p = (Engraver_group_engraver*)
+ get_engraver_p(type_str_);
+
+ for (int i=0; i < consists_str_arr_.size(); i++) {
+ grav_p->add( get_engraver_p( consists_str_arr_[i]) );
+ }
+ grav_p->itrans_l_ = this;
+ grav_p->id_str_ = default_id_str_;
+ return grav_p;
+}
+
+#if 0
+Performer_group_performer*
+Input_translator::get_group_performer_p()
+{
+ assert (base_str_ == "Performer");
+ Performer_group_performer * grav_p = (Performer_group_performer*)
+ get_performer_p(type_str_);
+
+ for (int i=0; i < consists_str_arr_.size(); i++) {
+ grav_p->add( get_performer_p( consists_str_arr_[i]) );
+ }
+ grav_p->itrans_l_ = this;
+ grav_p->id_str_ = default_id_str_;
+ return grav_p;
+}
+#endif
+
+bool
+Input_translator::accept_req_b()
+{
+ return ! contains_itrans_p_list_.size();
+}
+
+void
+Input_translator::add(Input_translator *ip)
+{
+ contains_itrans_p_list_.bottom().add(ip);
+}
+
+Input_translator*
+Input_translator::get_default_itrans_l()
+{
+ if ( contains_itrans_p_list_.size() )
+ return contains_itrans_p_list_.top();
+ else
+ return 0;
+}
+
+
+Input_translator_list::Input_translator_list(Input_translator_list const &s)
+{
+ for (PCursor<Input_translator*> pc(s); pc.ok(); pc++) {
+ Input_translator *q = pc;
+ Input_translator *p=new Input_translator(*q) ;
+ bottom().add(p);
+ }
+}
#include <math.h>
#include "misc.hh"
#include "midi-def.hh"
-#include "input-performer.hh"
-#include "performer-group-performer.hh"
-#include "assoc-iter.hh"
-
#include "debug.hh"
// classes, alphasorted
Midi_def::Midi_def()
{
- outfile_str_ = "lelie.midi";
- iperf_p_ = 0;
- real_vars_p_ = new Assoc<String,Real>;
- // ugh
set_tempo( Moment( 1, 4 ), 60 );
+ outfile_str_ = "lelie.midi";
}
-Midi_def::Midi_def( Midi_def const& s )
+Midi_def::Midi_def( Midi_def const& midi_c_r )
{
- whole_seconds_f_ = s.whole_seconds_f_;
- iperf_p_ = s.iperf_p_ ? new Input_performer( *s.iperf_p_ ) : 0;
- real_vars_p_ = new Assoc<String,Real> ( *s.real_vars_p_ );
- outfile_str_ = s.outfile_str_;
+ whole_seconds_f_ = midi_c_r.whole_seconds_f_;
+ outfile_str_ = midi_c_r.outfile_str_;
}
Midi_def::~Midi_def()
{
- delete iperf_p_;
- delete real_vars_p_;
}
Real
-Midi_def::duration_to_seconds_f( Moment mom )
+Midi_def::duration_to_seconds_f( Moment moment )
{
- if ( !mom )
+ if (!moment)
return 0;
- return Moment( whole_seconds_f_ ) * mom;
-}
-
-Global_translator*
-Midi_def::get_global_translator_p() const
-{
- return iperf_p_->get_group_performer_p()->global_l();
-}
-
-Real
-Midi_def::get_var( String s ) const
-{
- if ( !real_vars_p_->elt_b( s ) )
- error ( "unknown midi variable `" + s + "'" );
- return real_vars_p_->elem( s );
+ return Moment( whole_seconds_f_ ) * moment;
}
int
Midi_def::print() const
{
#ifndef NPRINT
- mtor << "Midi {";
- mtor << "4/min: " << Real( 60 ) / ( whole_seconds_f_ * 4 );
+ mtor << "Midi {4/min: " << Real( 60 ) / ( whole_seconds_f_ * 4 );
mtor << "out: " << outfile_str_;
- for (Assoc_iter<String,Real> i( *real_vars_p_ ); i.ok(); i++) {
- mtor << i.key() << "= " << i.val() << "\n";
- }
mtor << "}\n";
#endif
}
-void
-Midi_def::set( Input_performer* iperf_p )
-{
- delete iperf_p_;
- iperf_p_ = iperf_p;
-}
-
void
Midi_def::set_tempo( Moment moment, int count_per_minute_i )
{
whole_seconds_f_ = Moment( count_per_minute_i ) / Moment( 60 ) / moment;
}
-
-void
-Midi_def::set_var( String s, Real r )
-{
- real_vars_p_->elem( s ) = r;
-}
-
{
#ifndef NPRINT
mtor << name() << "{";
- mtor << "report to " << report_to_l_ << " (" << report_to_l_->name() << ")\n";
+ mtor << "report to " << report_to_l() << " (" << report_to_l()->name() << ")\n";
mtor << "next at " << next_moment() << " ";
do_print();
mtor << "}\n";
Translator*
Music_iterator::get_req_translator_l()
{
- assert(report_to_l_);
- if (report_to_l_->is_bottom_engraver_b() )
- return report_to_l_;
+ assert(report_to_l());
+ if (report_to_l()->is_bottom_engraver_b() )
+ return report_to_l();
- set_translator( report_to_l_->get_default_interpreter() );
- return report_to_l_;
+ set_translator( report_to_l()->get_default_interpreter() );
+ return report_to_l();
}
void
-Music_iterator::set_translator(Translator*trans)
-{
- if (report_to_l_==trans)
- return;
+Music_iterator::push_translator(Translator*t)
+{
+ if (t) {
+ report_to_l_arr_.push(t);
+ t->iterator_count_ ++;
+ }
+}
+
+void
+Music_iterator::pop_translator()
+{
+ if (report_to_l()) {
+ report_to_l()->iterator_count_ --;
+ report_to_l_arr_.pop();
+ }
+}
+
+Translator*
+Music_iterator::report_to_l()const
+{
+ if (! report_to_l_arr_.size() )
+ return 0;
+ return report_to_l_arr_.top();
+}
- if (report_to_l_)
- report_to_l_->iterator_count_ --;
- report_to_l_ = trans;
-
- if (report_to_l_)
- report_to_l_->iterator_count_ ++;
+void
+Music_iterator::set_translator(Translator*reg)
+{
+ if (report_to_l()==reg)
+ return;
+ pop_translator();
+ push_translator(reg);
}
void
}
}
- if (! p->report_to_l_ )
+ if (! p->report_to_l() )
p ->set_translator(report_l);
return p;
Music_iterator*
Music_iterator::get_iterator_p(Music*m)const
{
- Music_iterator*p = static_get_iterator_p(m,report_to_l_);
+ Music_iterator*p = static_get_iterator_p(m,report_to_l());
p->daddy_iter_l_ = (Music_iterator*)this;
p->construct_children();
return p;
Music_iterator::Music_iterator()
{
daddy_iter_l_ =0;
- report_to_l_ = 0;
first_b_ = true;
}
void
Chord_iterator::construct_children()
{
- int j = 0;
- for(PCursor<Music*> i(chord_C_->music_p_list_.top()); //, int j = 0;
- i.ok(); j++, i++) {
+ int j =0;
+ for(iter(chord_C_->music_p_list_.top(), i); i.ok(); j++, i++) {
+
Music_iterator * mi = get_iterator_p( i.ptr());
- set_translator(mi->report_to_l_->ancestor_l( chord_C_->multi_level_i_ ));
+ set_translator(mi->report_to_l()->ancestor_l( chord_C_->multi_level_i_ ));
if ( mi->ok() )
children_p_list_.bottom().add( mi );
else
Chord_iterator::do_print() const
{
#ifndef NPRINT
- for (PCursor<Music_iterator*> i(children_p_list_.top()); i.ok(); i++) {
+ for (iter(children_p_list_.top(), i); i.ok(); i++ ) {
i->print();
- }
+ }
#endif
}
void
Chord_iterator::process_and_next(Moment until)
{
- for (PCursor<Music_iterator*> i(children_p_list_.top()); i.ok(); ) {
+ for (iter(children_p_list_.top(), i); i.ok(); ) {
if (i->next_moment() == until) {
i->process_and_next(until);
}
Chord_iterator::next_moment()const
{
Moment next_ = INFTY;
- for (PCursor<Music_iterator*> i(children_p_list_.top()); i.ok(); i++)
+ for (iter(children_p_list_.top(), i); i.ok(); i++)
next_ = next_ <? i->next_moment() ;
return next_;
}
{
if (ok()) {
iter_p_ = Music_iterator::get_iterator_p( ptr() );
- if (iter_p_->report_to_l_->depth_i() > report_to_l_->depth_i())
- set_translator(iter_p_->report_to_l_);
+ if (iter_p_->report_to_l()->depth_i() > report_to_l()->depth_i())
+ set_translator(iter_p_->report_to_l());
}
}
Request_iterator::process_and_next(Moment m)
{
if ( first_b_ ) {
- bool gotcha = daddy_iter_l_->report_to_l_->try_request(req_l_);
+ bool gotcha = daddy_iter_l_->report_to_l()->try_request(req_l_);
if (!gotcha)
req_l_->warning("Junking request: " + String(req_l_->name()));
first_b_ = false;
Change_iterator::process_and_next(Moment mom)
{
#if 0
+ if ( id[0] == '-') {
+
+
Engraver_group_engraver *group_l =
- report_to_l_->find_get_grav_l(change_l_->type_str_,
- change_l_->id_str_);
+ report_to_l()->find_get_translator_l(change_l_->type_str_,
+ change_l_->id_str_);
- report_to_l_->daddy_grav_l_->remove_engraver_p(report_to_l_);
- group_l->add(report_to_l_);
+ report_to_l()->daddy_grav_l_->remove_engraver_p(report_to_l());
+ group_l->add(report_to_l());
#endif
Music_iterator::process_and_next(mom);
}
{"id", ID},
{"in", IN_T},
{"init_end", INIT_END},
- {"requestengraver", REQUESTENGRAVER},
- {"requestperformer", REQUESTPERFORMER},
+ {"requesttranslator", REQUESTENGRAVER},
{"lyric", LYRIC},
{"key", KEY},
{"melodic" , MELODIC},
+++ /dev/null
-/*
- note-performer.cc -- implement Note_performer
-
- (c) 1996, 1997 Han-Wen Nienhuys <hanwen@stack.nl>
- Jan Nieuwenhuizen <jan@digicash.com>
- */
-
-#if 0
-#include "note-performer.hh"
-
-void
-process_request()
-{
- if ( when() == off_mom_ )
- play_event( Note_event( current_l_->pitch() ) );
-}
-#endif
could use cleanup
*/
#include <ctype.h>
+
#include "my-lily-lexer.hh"
#include "string.hh"
#include "real.hh"
#include "musical-request.hh"
#include "command-request.hh"
#include "music-list.hh"
-#include "script.hh"
#include "identifier.hh"
#include "varray.hh"
#include "text-def.hh"
if (rest_b_) {
if (balltype_i_ == 1)
- position_i_ = 6;
+ position_i_ += 6;
else if (balltype_i_ == 2)
- position_i_ = 4;
+ position_i_ += 4;
}
}
if (!line_l_) {
its.junk_links();
}
- if (prebreak_p_) prebreak_p_->clean_breakable_items();
- if (postbreak_p_) postbreak_p_->clean_breakable_items();
+ if (prebreak_p_)
+ prebreak_p_->clean_breakable_items();
+ if (postbreak_p_)
+ postbreak_p_->clean_breakable_items();
}
int
PCol::rank_i() const
{
- assert(rank_i_ != -1);
return rank_i_;
}
PCol::PCol(PCol *parent)
{
+ used_b_ = false;
error_mark_b_ = false;
daddy_l_ = parent;
prebreak_p_=0;
bool
PCol::used_b()const
{
- return breakable_b() || its.size();
+ return breakable_b() || its.size()|| used_b_;
}
{
spanners.bottom().add(span_p);
span_p->pscore_l_=this;
+
+ if ( span_p->left_col_l_)
+ span_p->left_col_l_->used_b_ = true;
+ if ( span_p->right_col_l_)
+ span_p->right_col_l_->used_b_ = true;
+
// do not init start/stop fields. These are for broken spans only.
span_p->add_processing();
}
mtor << "\n elements: ";
for (iter_top(elem_p_list_,cc); cc.ok(); cc++)
cc->print();
+ mtor << "\n unbroken spanners: ";
+ for (iter(spanners.top(), i); i.ok(); i++)
+ i->print();
mtor << "\ncolumns: ";
for (iter_top(cols,cc); cc.ok(); cc++)
cc->print();
#include "debug.hh"
#include "lookup.hh"
#include "dimen.hh"
-#include "input-engraver.hh"
+#include "input-translator.hh"
#include "engraver-group.hh"
#include "assoc-iter.hh"
Paper_def::Paper_def()
{
- igrav_p_ = 0;
+ itrans_p_ = 0;
lookup_p_ = 0;
real_vars_p_ = new Assoc<String,Real>;
outfile_str_ = "lelie.tex";
Paper_def::~Paper_def()
{
- delete igrav_p_;
+ delete itrans_p_;
delete real_vars_p_;
delete lookup_p_;
}
Paper_def::Paper_def(Paper_def const&s)
{
- igrav_p_ = s.igrav_p_ ? new Input_engraver( *s.igrav_p_):0;
+ itrans_p_ = s.itrans_p_ ? new Input_translator( *s.itrans_p_):0;
lookup_p_ = s.lookup_p_? new Lookup(*s.lookup_p_) : 0;
lookup_p_->paper_l_ = this;
real_vars_p_ = new Assoc<String,Real> (*s.real_vars_p_);
}
void
-Paper_def::set(Input_engraver * igrav_p)
+Paper_def::set(Input_translator * itrans_p)
{
- delete igrav_p_;
- igrav_p_ = igrav_p;
+ delete itrans_p_;
+ itrans_p_ = itrans_p;
}
void
mtor << "Paper {";
mtor << "out: " <<outfile_str_;
lookup_p_->print();
+ itrans_p_->print();
for (Assoc_iter<String,Real> i(*real_vars_p_); i.ok(); i++) {
mtor << i.key() << "= " << i.val() << "\n";
}
Global_translator*
Paper_def::get_global_translator_p() const
{
- return igrav_p_->get_group_engraver_p()->global_l();
+ return itrans_p_->get_group_engraver_p()->global_l();
}
%{ // -*-Fundamental-*-
-
-/*
- parser.y -- lily parser
-
- source file of the GNU LilyPond music typesetter
-
- (c) 1997 Han-Wen Nienhuys <hanwen@stack.nl>
- Jan Nieuwenhuizen <jan@digicash.com>
-*/
-
#include <iostream.h>
-// mmm
#define MUDELA_VERSION "0.0.61"
#include "script-def.hh"
#include "musical-request.hh"
#include "my-lily-parser.hh"
#include "text-def.hh"
-#include "input-engraver.hh"
-#include "input-performer.hh"
+#include "input-translator.hh"
#include "score.hh"
#include "music-list.hh"
Chord * chord;
Duration *duration;
Identifier *id;
- Input_engraver * igravs;
- Input_performer * iperfs;
+ Input_translator * iregs;
Music *music;
Music_list *musiclist;
Score *score;
%token GROUPING
%token GROUP
%token REQUESTENGRAVER
-%token REQUESTPERFORMER
%token HSHIFT
%token IN_T
%token ID
%token <id> REAL_IDENTIFIER
%token <id> INT_IDENTIFIER
%token <id> SCORE_IDENTIFIER
-%token <id> MIDI_IDENTIFIER
%token <id> PAPER_IDENTIFIER
%token <id> REQUEST_IDENTIFIER
%token <real> REAL
%type <id> old_identifier
%type <symbol> symboldef
%type <symtable> symtable symtable_body
-%type <igravs> input_engraver_spec input_engraver_spec_body
-%type <iperfs> input_performer_spec input_performer_spec_body
+%type <iregs> input_translator_spec input_translator_spec_body
%left PRIORITY
$$ = new Paper_def_id(*$1, $3, PAPER_IDENTIFIER);
delete $1;
}
- | declarable_identifier '=' midi_block {
- $$ = new Midi_def_id(*$1, $3, MIDI_IDENTIFIER);
- delete $1;
- }
| declarable_identifier '=' script_definition {
$$ = new Script_id(*$1, $3, SCRIPT_IDENTIFIER);
delete $1;
-input_engraver_spec:
- REQUESTENGRAVER '{' input_engraver_spec_body '}'
+input_translator_spec:
+ REQUESTENGRAVER '{' input_translator_spec_body '}'
{ $$ = $3; }
;
-input_engraver_spec_body:
- STRING {
- $$ = new Input_engraver;
- $$->type_str_ =*$1;
+input_translator_spec_body:
+ STRING STRING {
+ $$ = new Input_translator;
+ $$->base_str_ = *$1;
+ $$->type_str_ =*$2;
$$->set_spot ( THIS->here_input() );
delete $1;
+ delete $2;
}
- | input_engraver_spec_body ALIAS STRING ';' {
- $$-> alias_str_arr_.push(*$3);
- delete $3;
- }
- | input_engraver_spec_body CONSISTS STRING ';' {
- $$-> consists_str_arr_.push(*$3);
+ | input_translator_spec_body ID STRING ';' {
+ $$-> default_id_str_ = *$3;
delete $3;
}
- | input_engraver_spec_body CONTAINS input_engraver_spec {
- $$->add($3);
- }
- ;
-
-input_performer_spec:
- REQUESTPERFORMER '{' input_performer_spec_body '}'
- { $$ = $3; }
- ;
-
-input_performer_spec_body:
- STRING {
- $$ = new Input_performer;
- $$->type_str_ =*$1;
- $$->set_spot ( THIS->here_input() );
- delete $1;
- }
- | input_performer_spec_body ALIAS STRING ';' {
+ | input_translator_spec_body ALIAS STRING ';' {
$$-> alias_str_arr_.push(*$3);
delete $3;
}
- | input_performer_spec_body CONSISTS STRING ';' {
+ | input_translator_spec_body CONSISTS STRING ';' {
$$-> consists_str_arr_.push(*$3);
delete $3;
}
- | input_performer_spec_body CONTAINS input_performer_spec {
+ | input_translator_spec_body CONTAINS input_translator_spec {
$$->add($3);
}
;
-
/*
SCORE
*/
paper_body:
/* empty */ {
- $$ = THIS->default_paper(); // paper / video / engrave
+ $$ = THIS->default_paper();
}
| paper_body OUTPUT STRING ';' { $$->outfile_str_ = *$3;
delete $3;
| paper_body STRING '=' REAL ';' {
$$->set_var(*$2, $4);
}
- | paper_body input_engraver_spec {
+ | paper_body input_translator_spec {
$$->set( $2 );
}
| paper_body error {
'{' midi_body '}' { $$ = $3; }
;
-midi_body: /* empty */ {
- $$ = THIS->default_midi(); // midi / audio / perform
+midi_body: {
+ $$ = new Midi_def;
}
| midi_body OUTPUT STRING ';' {
$$->outfile_str_ = *$3;
| midi_body TEMPO notemode_duration ':' int ';' {
$$->set_tempo( $3->length(), $5 );
}
- | midi_body input_performer_spec {
- $$->set( $2 );
- }
| midi_body error {
}
;
+
+
+
/*
MUSIC
*/
return id ? id->paperdef(true) : new Paper_def ;
}
-Midi_def*
-My_lily_parser::default_midi()
-{
- Identifier *id = lexer_p_->lookup_identifier( "default_midi" );
- return id ? id->mididef(true) : new Midi_def ;
-}
-
+++ /dev/null
-/*
- performer-group-performer.cc -- implement Performer_group_performer
-
- (c) 1996, 1997 Han-Wen Nienhuys <hanwen@stack.nl>
- Jan Nieuwenhuizen <jan@digicash.com>
- */
-
-#if 0
- bool try_request( Request* req_l )
- {
- bool hebbes_b =false;
- for (int i =0; !hebbes_b && i < nongroup_l_arr_.size() ; i++)
- hebbes_b =nongroup_l_arr_[i]->try_request(req_l);
- if (!hebbes_b)
- hebbes_b = daddy_grav_l_->try_request(req_l);
- return hebbes_b ;
- }
-#endif
+++ /dev/null
-/*
- performer.cc -- declare Performer
-
- (c) 1996, 1997 Han-Wen Nienhuys <hanwen@stack.nl>
- Jan Nieuwenhuizen <jan@digicash.com>
- */
-
-#if 0
-
-#include "lily-proto.hh"
-#include "performer.hh"
-#include "performer-group-performer.hh"
-
-IMPLEMENT_STATIC_NAME(Performer);
-IMPLEMENT_IS_TYPE_B(Performer);
-
-Performer::Performer()
-{
-}
-
-Performer::~Performer()
-{
-}
-
-bool
-Performer::try_request( Request* req_l );
-{
- return daddy_perf_l_->try_request( req_l );
-}
-
-void
-Performer::play_event( Midi_item i )
-{
- daddy_perf_l_->play_event( i );
-}
-
-void
-Performer::print() const
-{
-#ifndef NPRINT
- mtor << "\n" << name() << " {";
- do_print();
- mtor << "}";
-#endif
-}
-
-
-#endif
if (!(stem_l->beams_left_i_ || stem_l->beams_right_i_))
return;
- Real inter_f = paper()->internote_f();
int dir_i = rest_l_arr_[0]->dir_i_;
int midpos = 4;
#if 1
#else // nogo: stem_start not set for rests?
int pos = (stem_l->stem_start_f() - midpos) + dir_i * 2;
#endif
- Real dy = pos * inter_f;
- rest_l_arr_[0]->translate_y(dy);
+ rest_l_arr_[0]->translate_heads(pos);
}
void
if (rest_l_arr_.size() + ncol_l_arr_.size() < 2 )
return;
- Real inter_f = paper()->internote_f();
-
// meisjes met meisjes
if (!ncol_l_arr_.size()) {
- Real dy = rest_l_arr_.size() > 2 ? 6 * inter_f : 4 * inter_f;
- rest_l_arr_[0]->translate_y(dy);
+ int dy = rest_l_arr_.size() > 2 ? 6 : 4;
+ rest_l_arr_[0]->translate_heads(dy);
// top is last element...
- rest_l_arr_.top()->translate_y(-dy);
+ rest_l_arr_.top()->translate_heads(-dy);
}
// meisjes met jongetjes
else {
#if 0 // breendet: rests go always under
// geen gemug, trug op je rug
int dir_i = -1;
- rest_l_arr_[0]->translate_y(dir_i * 3 * inter_f);
+ rest_l_arr_[0]->translate_heads(dir_i * 3 );
#else
// int dir_i = - ncol_l_arr_[0]->dir_i_;
int dir_i = rest_l_arr_[0]->dir_i_;
// hope it's 4: if it works->doco
int midpos = 4;
- // minimum move
+
+ // minimum move
int minpos = 4;
+
// quart rest height
+ // UGH Should get dims from table!
int size_i = 6;
+
int sep_i = 3 + size_i / 2;
for (int i = 0; i < ncol_l_arr_.size(); i++) {
// how to know whether to sort?
ncol_l_arr_[i]->sort();
for ( int j = 0; j < ncol_l_arr_[i]->head_l_arr_.size(); j++ )
- minpos = minpos >? dir_i * ( ncol_l_arr_[i]->head_l_arr_[j]->position_i_ - midpos ) + sep_i;
+ minpos = minpos >? dir_i *
+ (ncol_l_arr_[i]->head_l_arr_[j]->position_i_ -midpos ) + sep_i;
}
- Real dy = dir_i * minpos * inter_f;
- rest_l_arr_[0]->translate_y(dy);
+ rest_l_arr_[0]->translate_heads(dir_i * minpos );
#endif
}
}
(n)? (Note_head*)n->item() : 0);
}
-/*
- Are you sure. Horizontal_vertical_group_item::translate_y could handle this
+
+/**
+ translate the rest symbols
*/
void
-Rest_column::translate_y(Real dy_f)
+Rest_column::translate_heads(int dy_i)
{
for (int i=0; i < head_l_arr_.size(); i++)
- head_l_arr_[i]->translate_y(dy_f);
+ head_l_arr_[i]->position_i_ += dy_i;
}
+
/*
- score-grav.cc -- implement Score_engraver
+ score-reg.cc -- implement Score_engraver
source file of the GNU LilyPond music typesetter
+++ /dev/null
-/*
- score-performer.cc -- implement Score_performer
-
- (c) 1996, 1997 Han-Wen Nienhuys <hanwen@stack.nl>
- Jan Nieuwenhuizen <jan@digicash.com>
- */
-
-#if 0
-
-#include "score-performer.hh"
-
-void
-Score_performer::play_event( Midi_item i )
-{
- file_p_->output( i );
-}
-
-void
-Score_performer::prepare(Moment m)
-{
- file_p_->move( mom.prev_ );
-}
-
-#endif
Score::process()
{
paper();
- midi();
}
-void
-Score::midi()
-{
-#if 0
- if (!midi_p_)
- return;
-
- *mlog << "\nCreating elements ..." << flush;
-// pscore_p_ = new PScore(paper_p_);
-
- Global_translator * score_trans= paper_p_->get_global_translator_p();
- run_translator( score_trans );
- delete score_trans;
-
- if( errorlevel_i_){
- // should we? hampers debugging.
- warning("Errors found, /*not processing score*/");
-// return;
- }
- print();
- *mlog << endl;
-// pscore_p_->process();
-
- // output
- midi_output();
-#endif
-}
-
void
Score::paper()
{
// output
paper_output();
+
}
/**
}
void
-Score::midi_output()
+Score::midi()
{
#if 0
if (!midi_p_)
specs_l_ = 0;
inside_staff_b_ = false;
stem_l_ = 0;
- pos_i_ = 0;
dir_i_ = 0;
}
assert(dir_i_);
}
-void
-Script::set_default_index()
-{
- pos_i_ = get_position_i(specs_l_->get_atom(paper(), dir_i_).extent().y);
-}
Interval
Script::do_width() const
inside_staff_b_ = specs_l_->inside_b();
}
-void
-Script::do_post_processing()
+Interval
+Script::symbol_height()const
{
- set_default_index();
+ return specs_l_->get_atom(paper(), dir_i_).extent().y;
}
Molecule*
void
Spanner_elem_group::do_print() const
{
+#ifndef NPRINT
+ Spanner::do_print();
Horizontal_vertical_group::do_print();
+#endif
}
void
Spanner::do_print()const
{
+#ifndef NPRINT
+ mtor << "Between col " <<
+ left_col_l_->rank_i() << ", " << right_col_l_->rank_i() ;
if (broken_into_l_arr_.size())
mtor << "with broken pieces\n";
+#endif
}
void
+++ /dev/null
-/*
- staff-performer.cc -- implement Staff_performer
-
- (c) 1996, 1997 Han-Wen Nienhuys <hanwen@stack.nl>
- Jan Nieuwenhuizen <jan@digicash.com>
- */
-
-#if 0
-
-#include "staff-performer.hh"
-
-String
-Staff_performer::instrument_str()
-{
- return Translator::id_str_;
-}
-
-void
-Staff_performer::play_event( Midi_item i )
-{
- i.track_i_ = midi_track_i_;
- Performer::play_event( i );
-}
-
-#endif
Staff_side::Staff_side()
{
+ pos_i_ =0;
+ sym_int_ = Interval(0,0);
staff_size_i_ = 0;
staff_sym_l_=0;
dir_i_ =0;
return int(rint(Real(y)/inter_f)); // should ret a float?
}
-int
-Staff_side::get_position_i(Interval sym_dim) const
-{
- int i= get_position_i();
- if (dir_i_)
- return i+ int(rint(- sym_dim[-dir_i_] / paper()->internote_f()));
- else
- return i;
+Interval
+Staff_side::symbol_height() const
+{
+ return Interval(0,0);
}
+void
+Staff_side::do_post_processing()
+{
+ sym_int_ = symbol_height();
+ pos_i_ = get_position_i( );
+ if (dir_i_)
+ pos_i_ += int(rint(- sym_int_[-dir_i_] / paper()->internote_f()));
+}
void
Staff_side::do_substitute_dependency(Score_elem*o, Score_elem*n)
i.staff_sym_l_ = span_p_;
}
+Staff_sym_engraver::~Staff_sym_engraver()
+{
+ assert( !span_p_);
+}
+
Staff_sym_engraver::Staff_sym_engraver()
{
span_p_ = 0;
void
Staff_symbol::do_print()const
{
+#ifndef NPRINT
+ Spanner::do_print();
mtor << "lines: " << no_lines_i_;
+#endif
}
Molecule*
#include "symbol.hh"
#include "request.hh"
-#include "input-engraver.hh"
-#include "input-performer.hh"
+#include "input-translator.hh"
#include "molecule.hh"
#include "plist.tcc"
#include "pcursor.tcc"
IPL_instantiate(Atom);
-IPL_instantiate(Input_engraver);
-IPL_instantiate(Input_performer);
+IPL_instantiate(Input_translator);
#include "proto.hh"
#include "plist.tcc"
#include "engraver.hh"
-#include "performer.hh"
IPL_instantiate(Engraver);
-IPL_instantiate(Performer);
dir_i_ = d;
fat_b_ = false;
tdef_p_ = tdef_l->clone();
- pos_i_ =0;
}
Text_item::~Text_item()
delete tdef_p_;
}
-void
-Text_item::set_default_index()
-{
- pos_i_ = get_position_i(
- tdef_p_->get_atom(paper(), dir_i_).extent().y );
-}
-
void
Text_item::do_pre_processing()
{
dir_i_ = -1;
}
-void
-Text_item::do_post_processing()
+Interval
+Text_item::symbol_height()const
{
- set_default_index();
+ return tdef_p_->get_atom(paper(), dir_i_).sym_.dim.y;
}
-
Molecule*
Text_item::brew_molecule_p() const
+++ /dev/null
-/*
- voice-group-performer.cc -- implement Voice_group_performer
-
- (c) 1996, 1997 Han-Wen Nienhuys <hanwen@stack.nl>
- Jan Nieuwenhuizen <jan@digicash.com>
- */
-
-#if 0
-
-#include "voice-group-performer.hh"
-
-#endif
Begin3
Title: LilyPond
-Version: 0.0.73pre
-Entered-date: 07/03/97
+Version: 0.0.74pre
+Entered-date: 07/08/97
Description: LilyPond is a program which converts a music-script (mudela) into
TeX output, or MIDI to produce multi-staff scores. Features include multiple
meters, clefs, keys, lyrics, versatile input-language, cadenzas
jan@digicash.com (Jan Nieuwenhuizen)
Maintained-by: hanwen@stack.nl (Han-Wen Nienhuys)
Primary-site: pcnov095.win.tue.nl /pub/lilypond/
- 300k lilypond-0.0.73pre.tar.gz
+ 300k lilypond-0.0.74pre.tar.gz
Alternate-site:
Original-site:
Platform: unix/win32, GNU C++
Name: lilypond
-Version: 0.0.73pre
+Version: 0.0.74pre
Release: 1
Copyright: GPL
Group: Applications/Publishing
-Source0: pcnov095.win.tue.nl:/pub/lilypond/lilypond-0.0.73pre.tar.gz
+Source0: pcnov095.win.tue.nl:/pub/lilypond/lilypond-0.0.74pre.tar.gz
Summary: A preprocessor to make TeX typeset music.
URL: http://www.stack.nl/~hanwen/lilypond
Packager: Han-Wen Nienhuys <hanwen@stack.nl>
%prep
%setup
%build
-configure --enable-checking --disable-debugging --enable-printing --prefix=/usr --enable-optimise --enable-shared
+./configure --enable-checking --disable-debugging --enable-printing --prefix=/usr --enable-optimise --enable-shared
make all
%install
rm -rf $RPM_BUILD_ROOT
%prep
%setup
%build
-configure --enable-checking --disable-debugging --enable-printing --prefix=/usr --enable-optimise --enable-shared
+./configure --enable-checking --disable-debugging --enable-printing --prefix=/usr --enable-optimise --enable-shared
make all
%install
rm -rf $RPM_BUILD_ROOT