inspect-quants is set.
Beam_configuration *best = NULL;
+ bool debug =
+ to_boolean (beam->layout ()->lookup_variable (ly_symbol2scm ("debug-beam-scoring")));
SCM inspect_quants = beam->get_property ("inspect-quants");
if (to_boolean (beam->layout ()->lookup_variable (ly_symbol2scm ("debug-beam-scoring")))
&& scm_is_pair (inspect_quants))
{
+ debug = true;
best = force_score (inspect_quants, configs);
}
else
for (vsize i = 0; i < configs.size(); i++)
queue.push(configs[i]);
-
/*
TODO
Interval final_positions = best->y;
#if DEBUG_BEAM_SCORING
- if (to_boolean (beam->layout ()->lookup_variable (ly_symbol2scm ("debug-beam-scoring"))))
+ if (debug)
{
// debug quanting
int completed = 0;
}
string card = best->score_card_ + to_string (" c%d/%d", completed, configs.size());
- beam->set_property ("quant-score", ly_string2scm (card));
+ beam->set_property ("annotation", ly_string2scm (card));
}
#endif
#if (DEBUG_BEAM_SCORING)
SCM annotation = me->get_property ("annotation");
- if (!scm_is_string (annotation))
- {
- SCM debug = me->layout ()->lookup_variable (ly_symbol2scm ("debug-beam-scoring"));
- if (to_boolean (debug))
- annotation = me->get_property ("quant-score");
- }
-
if (scm_is_string (annotation))
{
extract_grob_set (me, "stems", stems);
"neutral-direction "
"normal-stems "
"positions "
- "quant-score "
"quantized-positions "
"shorten "
"stems "
SCM end_ys = me->get_property ("positions");
SCM inspect_quants = me->get_property ("inspect-quants");
+ bool debug_slurs = to_boolean (me->layout ()
+ ->lookup_variable (ly_symbol2scm ("debug-slur-scoring")));
+
if (is_number_pair (inspect_quants))
- end_ys = inspect_quants;
+ {
+ debug_slurs = true;
+ end_ys = inspect_quants;
+ }
Slur_configuration *best = NULL;
if (is_number_pair (end_ys))
best = state.get_best_curve ();
#if DEBUG_SLUR_SCORING
- bool debug_slurs = to_boolean (me->layout ()
- ->lookup_variable (ly_symbol2scm ("debug-slur-scoring")));
if (debug_slurs)
{
string total = best->card ();
total += to_string (" TOTAL=%.2f idx=%d", best->score (), best->index_);
- me->set_property ("quant-score", ly_string2scm (total));
+ me->set_property ("annotation", ly_string2scm (total));
}
#endif
#if DEBUG_SLUR_SCORING
SCM annotation = me->get_property ("annotation");
- if (!scm_is_string (annotation))
- {
- SCM debug = me->layout ()->lookup_variable (ly_symbol2scm ("debug-slur-scoring"));
- if (to_boolean (debug))
- annotation = me->get_property ("quant-score");
- }
-
if (scm_is_string (annotation))
{
string str;
"line-thickness "
"note-columns "
"positions "
- "quant-score "
"ratio "
"thickness "
);
for (vsize i = 0; i < base.size (); i++)
{
string card = base.complete_tie_card (i);
- specifications_[i].tie_grob_->set_property ("quant-score",
+ specifications_[i].tie_grob_->set_property ("annotation",
ly_string2scm (card));
}
}
#if DEBUG_TIE_SCORING
SCM annotation = me->get_property ("annotation");
- if (!scm_is_string (annotation))
- {
- SCM debug = me->layout ()->lookup_variable (ly_symbol2scm ("debug-tie-scoring"));
- if (to_boolean (debug))
- annotation = me->get_property ("quant-score");
- }
if (scm_is_string (annotation))
{
string str;
"head-direction "
"line-thickness "
"neutral-direction "
- "quant-score "
"staff-position "
"thickness "
);
(pure-Y-extent ,number-pair? "The estimated height of a system.")
(pure-Y-offset-in-progress ,boolean? "A debugging aid for catching
cyclic dependencies.")
-
- (quant-score ,string? "The beam quanting score; stored for
-debugging.")
(quantize-position ,boolean? "If set, a vertical alignment is aligned
to be within staff spaces.")
(quantized-positions ,number-pair? "The beam positions after