cwSfScore.h : Added 'perfCnt` to event_t.
This commit is contained in:
parent
ccb9b7363f
commit
513bc82381
@ -960,7 +960,7 @@ cw::rc_t cw::sfscore::destroy( handle_t& hRef )
|
||||
void cw::sfscore::clear_all_performance_data( handle_t h )
|
||||
{
|
||||
sfscore_t* p = _handleToPtr(h);
|
||||
std::for_each( p->eventA, p->eventA + p->eventN, [](event_t& e){ e.perfFl=false; e.perfVel=0, e.perfSec=0, e.perfMatchCost=std::numeric_limits<double>::max(); } );
|
||||
std::for_each( p->eventA, p->eventA + p->eventN, [](event_t& e){ e.perfFl=false; e.perfCnt=0; e.perfVel=0, e.perfSec=0, e.perfMatchCost=std::numeric_limits<double>::max(); } );
|
||||
std::for_each( p->setA, p->setA + p->setN, [](set_t& s){ s.perfEventCnt=0; s.perfUpdateCnt=false; } );
|
||||
}
|
||||
|
||||
@ -997,7 +997,8 @@ cw::rc_t cw::sfscore::set_perf( handle_t h, unsigned event_idx, double secs, uin
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
e->perfCnt += 1;
|
||||
e->perfFl = true;
|
||||
e->perfVel = vel;
|
||||
e->perfSec = secs;
|
||||
|
@ -53,15 +53,17 @@ namespace cw
|
||||
unsigned varN; // Length of varA[]
|
||||
|
||||
unsigned bpm; // beats per minute
|
||||
double bpm_rval;
|
||||
double bpm_rval; //
|
||||
double relTempo; // relative tempo (1=min tempo)
|
||||
|
||||
bool perfFl; // has this event been performed
|
||||
unsigned perfCnt; // count of time this event was performed (if perfCnt > 1 then the event was duplicated during performance)
|
||||
double perfSec; // performance event time
|
||||
uint8_t perfVel; // performance event velocity
|
||||
unsigned perfDynLevel; // performance dynamic level
|
||||
double perfMatchCost; // performance match cost (or DBL_MAX if not valid)
|
||||
|
||||
|
||||
} event_t;
|
||||
|
||||
// A 'set' is a collection of events that are grouped in time and all marked with a given attribute.
|
||||
|
Loading…
Reference in New Issue
Block a user