NiCMidi 1.1.0
A MIDI library derived from J.D.Koftinoff jdksmidi
MIDISequencerGUIEvent Class Reference

Holds data for a message that the sequencer can send to the GUI to warn it when something happens. More...

#include <notifier.h>

Public Types

enum  {
  GROUP_ALL = 0 , GROUP_CONDUCTOR , GROUP_TRANSPORT , GROUP_TRACK ,
  GROUP_RECORDER , GROUP_USER
}
 Main groups. More...
 
enum  {
  GROUP_CONDUCTOR_TEMPO = 0 , GROUP_CONDUCTOR_TIMESIG , GROUP_CONDUCTOR_KEYSIG , GROUP_CONDUCTOR_MARKER ,
  GROUP_CONDUCTOR_USER
}
 Items in conductor group. More...
 
enum  {
  GROUP_TRANSPORT_START = 0 , GROUP_TRANSPORT_STOP , GROUP_TRANSPORT_MEASURE , GROUP_TRANSPORT_BEAT ,
  GROUP_TRANSPORT_COUNTIN , GROUP_TRANSPORT_USER
}
 Items in transport group. More...
 
enum  {
  GROUP_TRACK_NAME = 0 , GROUP_TRACK_PROGRAM , GROUP_TRACK_NOTE , GROUP_TRACK_VOLUME ,
  GROUP_TRACK_PAN , GROUP_TRACK_CHR , GROUP_TRACK_REV , GROUP_TRACK_USER
}
 Items in track group (the track is in the subgroup) More...
 
enum  { GROUP_RECORDER_RESET , GROUP_RECORDER_START , GROUP_RECORDER_STOP , GROUP_RECORDER_USER }
 Items in recorder group. More...
 
enum  { GROUP_USER_USER = 0 }
 Item in user group. More...
 

Public Member Functions

 MIDISequencerGUIEvent ()
 Default constructor: creates a generic event with all attributes set to 0. More...
 
 MIDISequencerGUIEvent (unsigned long bits_)
 This constructor creates the object directly from its parameters, packed into an unsigned long. More...
 
 MIDISequencerGUIEvent (int group, int subgroup, int item)
 This constructor creates the object starting from its group, subgroup, item. More...
 
 operator unsigned long () const
 Converts the object into an unsigned long. More...
 
int GetGroup () const
 Returns the event group. More...
 
int GetSubGroup () const
 Returns the event subgroup (only effective for GROUP_TRACK events, where it is the track of the event; it is 0 for other groups). More...
 
int GetItem () const
 Returns the event item (i.e. the kind of the event). More...
 
void SetEvent (int group, int subgroup=0, int item=0)
 Sets the event group, subgroup and item. More...
 

Static Public Attributes

static const char group_names [][10]
 An array of strings with readable group names. More...
 
static const char conductor_items_names [][10]
 An array of strings with readable conductor group items names. More...
 
static const char transport_items_names [][10]
 An array of strings with readable transport group items names. More...
 
static const char track_items_names [][10]
 An array of strings with readable track group items names. More...
 
static const char recording_items_names [][10]
 An array of strings with readable recording group items names. More...
 
static const char user_items_names [][10]
 An array of strings with readable user group item names. More...
 

Detailed Description

Holds data for a message that the sequencer can send to the GUI to warn it when something happens.

A MIDISequencerGUIEvent belongs to one of these four groups:

  • GROUP_ALL: generic group, used by the sequencer to request the GUI for a general refresh
  • GROUP_CONDUCTOR: events as tempo, time, key change ...
  • GROUP_TRANSPORT: start, stop ...
  • GROUP_TRACK: note, program, control change ...

Every group has some items, denoting different events, for GROUP_TRACK is also used a subgroup parameter, i.e. the track of the event. Messages are sent by the MIDISequencerGUINotifier class.

Examples
test_win32_player.cpp.

Member Enumeration Documentation

◆ anonymous enum

anonymous enum

Main groups.

Enumerator
GROUP_ALL 

Generic group: used by the MIDISequencer to request a full GUI reset.

GROUP_CONDUCTOR 

Conductor events (time, tempo, etc)

GROUP_TRANSPORT 

Transport events (start, stop, etc)

GROUP_TRACK 

Track events (the subgroup is the track of the event)

GROUP_RECORDER 

Recorder events.

GROUP_USER 

User defined group.

◆ anonymous enum

anonymous enum

Items in conductor group.

Enumerator
GROUP_CONDUCTOR_TEMPO 

Tempo change.

GROUP_CONDUCTOR_TIMESIG 

Timesig change.

GROUP_CONDUCTOR_KEYSIG 

Keysig change.

GROUP_CONDUCTOR_MARKER 

Marker.

GROUP_CONDUCTOR_USER 

User defined item.

◆ anonymous enum

anonymous enum

Items in transport group.

Enumerator
GROUP_TRANSPORT_START 

Sequencer start.

GROUP_TRANSPORT_STOP 

Sequencer stop.

GROUP_TRANSPORT_MEASURE 

Start of a measure.

GROUP_TRANSPORT_BEAT 

Beat marker.

GROUP_TRANSPORT_COUNTIN 

Countin start.

GROUP_TRANSPORT_USER 

User defined item.

◆ anonymous enum

anonymous enum

Items in track group (the track is in the subgroup)

Enumerator
GROUP_TRACK_NAME 

Track got its name.

GROUP_TRACK_PROGRAM 

Program change.

GROUP_TRACK_NOTE 

Note.

GROUP_TRACK_VOLUME 

Volume change.

GROUP_TRACK_PAN 

Pan change.

GROUP_TRACK_CHR 

Chorus change.

GROUP_TRACK_REV 

Reverb change.

GROUP_TRACK_USER 

User defined item.

◆ anonymous enum

anonymous enum

Items in recorder group.

Enumerator
GROUP_RECORDER_RESET 

Recorder reset.

GROUP_RECORDER_START 

Recording start.

GROUP_RECORDER_STOP 

Recording stop.

GROUP_RECORDER_USER 

User defined item.

◆ anonymous enum

anonymous enum

Item in user group.

Enumerator
GROUP_USER_USER 

User defined item.

Constructor & Destructor Documentation

◆ MIDISequencerGUIEvent() [1/3]

MIDISequencerGUIEvent::MIDISequencerGUIEvent ( )
inline

Default constructor: creates a generic event with all attributes set to 0.

◆ MIDISequencerGUIEvent() [2/3]

MIDISequencerGUIEvent::MIDISequencerGUIEvent ( unsigned long  bits_)
inline

This constructor creates the object directly from its parameters, packed into an unsigned long.

◆ MIDISequencerGUIEvent() [3/3]

MIDISequencerGUIEvent::MIDISequencerGUIEvent ( int  group,
int  subgroup,
int  item 
)
inline

This constructor creates the object starting from its group, subgroup, item.

Member Function Documentation

◆ operator unsigned long()

MIDISequencerGUIEvent::operator unsigned long ( ) const
inline

Converts the object into an unsigned long.

◆ GetGroup()

int MIDISequencerGUIEvent::GetGroup ( ) const
inline

Returns the event group.

Examples
test_win32_player.cpp.

◆ GetSubGroup()

int MIDISequencerGUIEvent::GetSubGroup ( ) const
inline

Returns the event subgroup (only effective for GROUP_TRACK events, where it is the track of the event; it is 0 for other groups).

Examples
test_win32_player.cpp.

◆ GetItem()

int MIDISequencerGUIEvent::GetItem ( ) const
inline

Returns the event item (i.e. the kind of the event).

Examples
test_win32_player.cpp.

◆ SetEvent()

void MIDISequencerGUIEvent::SetEvent ( int  group,
int  subgroup = 0,
int  item = 0 
)
inline

Sets the event group, subgroup and item.

Member Data Documentation

◆ group_names

const char MIDISequencerGUIEvent::group_names[][10]
static

An array of strings with readable group names.

◆ conductor_items_names

const char MIDISequencerGUIEvent::conductor_items_names[][10]
static

An array of strings with readable conductor group items names.

◆ transport_items_names

const char MIDISequencerGUIEvent::transport_items_names[][10]
static

An array of strings with readable transport group items names.

◆ track_items_names

const char MIDISequencerGUIEvent::track_items_names[][10]
static

An array of strings with readable track group items names.

◆ recording_items_names

const char MIDISequencerGUIEvent::recording_items_names[][10]
static

An array of strings with readable recording group items names.

◆ user_items_names

const char MIDISequencerGUIEvent::user_items_names[][10]
static

An array of strings with readable user group item names.


The documentation for this class was generated from the following file: