Revert "update fret diagrams regression test"
[lilypond/csorensen.git] / Documentation / user / converters.itely
blobadf3d3107de8db49864ac4e8996d9723b9efa4ee
1 @c -*- coding: utf-8; mode: texinfo; -*-
2 @c This file is part of lilypond-program.tely
3 @ignore
4     Translation of GIT committish: FILL-IN-HEAD-COMMITTISH
6     When revising a translation, copy the HEAD committish of the
7     version that you are working on.  See TRANSLATION for details.
8 @end ignore
10 @c \version "2.11.38"
12 @node Converting from other formats
13 @chapter Converting from other formats
15 Music can be entered also by importing it from other formats.  This
16 chapter documents the tools included in the distribution to do so.
17 There are other tools that produce LilyPond input, for example GUI
18 sequencers and XML converters.  Refer to the
19 @uref{http://@/lilypond@/.org,website} for more details.
21 These are separate programs from @command{lilypond} itself, and are run
22 on the command-line; see @ref{Command-line usage} for more information.
25 @knownissues
26 We unfortunately do not have the resources to maintain these
27 programs; please consider them @qq{as-is}.  Patches are appreciated, but
28 bug reports will almost certainly not be resolved.
30 @menu
31 * Invoking midi2ly::            Importing MIDI.
32 * Invoking musicxml2ly::        Importing MusicXML.
33 * Invoking abc2ly::             Importing ABC.      
34 * Invoking etf2ly::             Importing Finale.
35 * Generating LilyPond files::   GUIs, transcribers, and algorithmic composition programs.
36 @end menu
40 @node Invoking midi2ly
41 @section Invoking @command{midi2ly}
43 @cindex MIDI
45 @command{midi2ly} translates a Type@tie{}1 MIDI file to a LilyPond source
46 file.
48 MIDI (Music Instrument Digital Interface) is a standard for digital
49 instruments: it specifies cabling, a serial protocol and a file
50 format.  The MIDI file format is a de facto standard format for
51 exporting music from other programs, so this capability may come in
52 useful when importing files from a program that has a converter for a
53 direct format.
55 @command{midi2ly} converts tracks into @rinternals{Staff} and
56 channels into @rinternals{Voice} contexts.  Relative mode is used
57 for pitches, durations are only written when necessary.
59 It is possible to record a MIDI file using a digital keyboard, and
60 then convert it to @file{.ly}.  However, human players are not
61 rhythmically exact enough to make a MIDI to LY conversion trivial.
62 When invoked with quantizing (@code{-s} and @code{-d} options)
63 @command{midi2ly} tries to compensate for these timing errors, but is not
64 very good at this.  It is therefore not recommended to use @command{midi2ly}
65 for human-generated midi files.
68 It is invoked from the command-line as follows,
69 @example
70 midi2ly [@var{option}]@dots{} @var{midi-file}
71 @end example
73 Note that by @q{command-line}, we mean the command line of the
74 operating system.  See @ref{Converting from other formats}, for
75 more information about this.
77 The following options are supported by @command{midi2ly}.
79 @table @code
80 @item -a, --absolute-pitches
81 Print absolute pitches.
83 @item -d, --duration-quant=@var{DUR}
84 Quantize note durations on @var{DUR}.
86 @item -e, --explicit-durations
87 Print explicit durations.
89 @item -h,--help
90 Show summary of usage.
92 @item -k, --key=@var{acc}[:@var{minor}]
93 Set default key.  @math{@var{acc} > 0} sets number of sharps;
94 @math{@var{acc} < 0} sets number of flats.  A minor key is indicated by
95 @code{:1}.
97 @item -o, --output=@var{file}
98 Write output to @var{file}.
100 @item -s, --start-quant=@var{DUR}
101 Quantize note starts on DUR.
103 @item -t, --allow-tuplet=@var{DUR}*@var{NUM}/@var{DEN}
104 Allow tuplet durations @var{DUR}*@var{NUM}/@var{DEN}.
106 @item -V, --verbose
107 Be verbose.
109 @item -v, --version
110 Print version number.
112 @item -w, --warranty
113 Show warranty and copyright.
115 @item -x, --text-lyrics
116 Treat every text as a lyric.
117 @end table
120 @knownissues
122 Overlapping notes in an arpeggio will not be correctly rendered.  The
123 first note will be read and the others will be ignored.  Set them all
124 to a single duration and add phrase markings or pedal indicators.
127 @node Invoking musicxml2ly
128 @section Invoking @code{musicxml2ly}
130 @uref{http://@/www.@/recordare@/.com/xml@/.html,MusicXML} is an XML dialect
131 for representing music notation.
133 @command{musicxml2ly} extracts the notes from part-wise MusicXML
134 files, and writes it to a .ly file.  It is invoked from the command-line.
136 Note that by @q{command-line}, we mean the command line of the
137 operating system.  See @ref{Converting from other formats}, for
138 more information about this.
140 The following options are supported by @command{musicxml2ly}:
142 @table @code
143 @item -h,--help
144 print usage and option summary.
145 @item -o,--output=@var{file}
146 set output filename to @var{file}. (default: print to stdout)
147 @item -v,--version
148 print version information.
149 @end table
152 @node Invoking abc2ly
153 @section Invoking @code{abc2ly}
155 @cindex ABC
157 ABC is a fairly simple ASCII based format.  It is described at the ABC site:
159 @quotation
160 @uref{http://@/www@/.walshaw@/.plus@/.com/@/abc/@/abc2mtex/@/abc@/.txt}.
161 @end quotation
163 @command{abc2ly} translates from ABC to LilyPond.  It is invoked as follows:
165 @example
166 abc2ly [@var{option}]@dots{} @var{abc-file}
167 @end example
169 The following options are supported by @command{abc2ly}:
171 @table @code
172 @item -h,--help
173 this help
174 @item -o,--output=@var{file}
175 set output filename to @var{file}.
176 @item -v,--version
177 print version information.
178 @end table
180 There is a rudimentary facility for adding LilyPond code to the ABC
181 source file.  If you say:
183 @example
184 %%LY voices \set autoBeaming = ##f
185 @end example
187 This will cause the text following the keyword @q{voices} to be inserted
188 into the current voice of the LilyPond output file.
190 Similarly,
192 @example
193 %%LY slyrics more words
194 @end example
196 will cause the text following the @q{slyrics} keyword to be inserted
197 into the current line of lyrics.
200 @knownissues
202 The ABC standard is not very @q{standard}.  For extended features
203 (e.g., polyphonic music) different conventions exist.
205 Multiple tunes in one file cannot be converted.
207 ABC synchronizes words and notes at the beginning of a line;
208 @command{abc2ly} does not.
210 @command{abc2ly} ignores the ABC beaming.
213 @node Invoking etf2ly
214 @section Invoking @command{etf2ly}
216 @cindex ETF
217 @cindex enigma
218 @cindex Finale
219 @cindex Coda Technology
221 ETF (Enigma Transport Format) is a format used by Coda Music
222 Technology's Finale product.  @command{etf2ly} will convert part of an ETF
223 file to a ready-to-use LilyPond file.
225 It is invoked from the command-line as follows.
227 @example
228 etf2ly [@var{option}]@dots{} @var{etf-file}
229 @end example
231 Note that by @q{command-line}, we mean the command line of the
232 operating system.  See @ref{Converting from other formats}, for
233 more information about this.
235 The following options are supported by @command{etf2ly}:
237 @table @code
238 @item -h,--help
239 this help
240 @item -o,--output=FILE
241 set output filename to FILE
242 @item -v,--version
243 version information
244 @end table
247 @knownissues
249 The list of articulation scripts is incomplete.  Empty measures
250 confuse @command{etf2ly}.  Sequences of grace notes are ended improperly.
253 @node Generating LilyPond files
254 @section Generating LilyPond files
256 @cindex External programs, generating LilyPond files
258 LilyPond itself does not come with support for any other formats, but
259 there are some external tools that also generate LilyPond files.
261 These tools include
263 @itemize
264 @item
265 @uref{http://@/denemo@/.sourceforge@/.net/,Denemo}, a graphical score editor.
266 @item
267 @uref{http://www@/.volny@/.cz/smilauer/rumor/rumor@/.html,Rumor}, a realtime
268 monophonic MIDI to LilyPond converter.
269 @item
270 @uref{http://nicolas@/.sceaux@/.free@/.fr/lilypond/lyqi@/.html,lyqi}, an
271 Emacs major mode.
272 @item
273 @uref{http://@/www@/.nongnu@/.org/@/xml2ly/, xml2ly}, which imports
274 @uref{http://@/www@/.musicxml@/.com/xml@/.html,MusicXML}
275 @item
276 @uref{http://@/noteedit@/.berlios@/.de,NoteEdit}
277 which imports @uref{http://@/www@/.musicxml@/.com/xml@/.html,MusicXML}
278 @item
279 @uref{http://@/www@/.rosegardenmusic@/.com,Rosegarden},
280 which imports MIDI
281 @item
282 @uref{http://@/common-lisp@/.net/project/fomus/,FOMUS},
283 a LISP library to generate music notation 
284 @end itemize