source file of the GNU LilyPond music typesetter
- (c) 2005--2006 Han-Wen Nienhuys <hanwen@xs4all.nl>
+ (c) 2005--2007 Han-Wen Nienhuys <hanwen@xs4all.nl>
*/
#include "cpu-timer.hh"
#include "global-context.hh"
SCM output = g->get_output ();
progress_indication ("\n");
- unsmob_music_output (output)->process ();
+
+ if (Music_output *od = unsmob_music_output (output))
+ od->process ();
+
return output;
}
}
LY_DEFINE (ly_make_global_context, "ly:make-global-context",
- 1, 1, 0, (SCM output_def, SCM key),
+ 1, 0, 0, (SCM output_def),
"Set up a global interpretation context, using the output\n"
"block @var{output_def}.\n"
"The context is returned.\n"
-
- "\n\nOptionally, this routine takes an Object-key to\n"
- "to uniquely identify the Score block containing it.\n")
+ )
{
Output_def *odef = unsmob_output_def (output_def);
SCM_ASSERT_TYPE (odef, output_def, SCM_ARG1, __FUNCTION__,
"Output definition");
- Global_context *glob = new Global_context (odef, unsmob_key (key));
+ Global_context *glob = new Global_context (odef);
if (!glob)
{
}
LY_DEFINE (ly_run_translator, "ly:run-translator",
- 2, 1, 0, (SCM mus, SCM output_def, SCM key),
+ 2, 1, 0, (SCM mus, SCM output_def),
"Process @var{mus} according to @var{output_def}. \n"
"An interpretation context is set up,\n"
"and @var{mus} is interpreted with it. \n"
"Optionally, this routine takes an Object-key to\n"
"to uniquely identify the Score block containing it.\n")
{
- SCM glob = ly_make_global_context (output_def, key);
+ SCM glob = ly_make_global_context (output_def);
ly_make_global_translator (glob);
ly_interpret_music_expression (mus, glob);
return glob;