Logo Search packages:      
Sourcecode: rosegarden version File versions

void Rosegarden::Quantizer::fixQuantizedValues ( Segment *  s,
Segment::iterator  from,
Segment::iterator  to 
) const

Quantize a section of a Segment, and force the quantized results into the formal absolute time and duration of the events. This is a destructive operation that should not be carried out except on a user's explicit request. (If target is RawEventData, this will do nothing besides quantize. In this case, but no other, unquantize will still work afterwards.)

Definition at line 142 of file Quantizer.cpp.

References quantize().

    assert(m_toInsert.size() == 0);

    quantize(s, from, to);

    if (m_target == RawEventData) return;

    for (Segment::iterator nextFrom = from; from != to; from = nextFrom) {

      timeT t = getFromTarget(*from, AbsoluteTimeValue);
      timeT d = getFromTarget(*from, DurationValue);
      Event *e = new Event(**from, t, d);

Generated by  Doxygen 1.6.0   Back to index