Exemplo n.º 1
0
	inline bool operator==(const Note& other) {
		return time() == other.time() && 
	         note() == other.note() && 
	         length() == other.length() &&
	         velocity() == other.velocity() &&
	         channel()  == other.channel();
	}
Exemplo n.º 2
0
Arquivo: Note.cpp Projeto: 63n/ardour
Note<Time>::Note(const Note<Time>& copy)
	: _on_event(copy._on_event, true)
	, _off_event(copy._off_event, true)
{
	set_id (copy.id());

	assert(_on_event.buffer());
	assert(_off_event.buffer());
	/*
	  assert(copy._on_event.size == 3);
	  _on_event.buffer = _on_event_buffer;
	  memcpy(_on_event_buffer, copy._on_event_buffer, 3);

	  assert(copy._off_event.size == 3);
	  _off_event.buffer = _off_event_buffer;
	  memcpy(_off_event_buffer, copy._off_event_buffer, 3);
	*/

	assert(time() == copy.time());
	assert(end_time() == copy.end_time());
	assert(length() == copy.length());
	assert(note() == copy.note());
	assert(velocity() == copy.velocity());
	assert(_on_event.channel() == _off_event.channel());
	assert(channel() == copy.channel());
}
Exemplo n.º 3
0
	inline bool operator==(const Note<Time>& other) {
		return musical_time_equal (time(), other.time()) &&
			note() == other.note() &&
			musical_time_equal (length(), other.length()) &&
			velocity() == other.velocity() &&
			off_velocity() == other.off_velocity() &&
			channel()  == other.channel();
	}
Exemplo n.º 4
0
Arquivo: Note.cpp Projeto: 63n/ardour
const Note<Time>&
Note<Time>::operator=(const Note<Time>& other)
{
	_on_event = other._on_event;
	_off_event = other._off_event;

	assert(time() == other.time());
	assert(end_time() == other.end_time());
	assert(length() == other.length());
	assert(note() == other.note());
	assert(velocity() == other.velocity());
	assert(_on_event.channel() == _off_event.channel());
	assert(channel() == other.channel());

	return *this;
}