Source: midimountain/mcIO.h


Annotated List
Files
Globals
Hierarchy
Index
//=============================================================================
//  TMidiIO class definition
//=============================================================================
// Author  : Adrian Meyer
//           based on Craig Stuart Sapp, craig@ccrma.stanford.edu
//           sequencer class
// Version : 0.2.0
// Log     :
//=============================================================================
// 04.03.2001 building class
//=============================================================================
// to do:
//=============================================================================

#ifndef __MCIO__
#define __MCIO__

#include <mcBase.h>
#include <mcEvent.h>


class TMidiIO: public TMidiBase
{

public:
  TMidiIO( int autoOpen = 1 );
  virtual ~TMidiIO();

  // returns true if this IO device is open
  virtual int        is_open(void) const = 0;

  // Open the device
  virtual int        open(void) = 0;

  // Close the device
  virtual void       close(void) = 0;

  // Read an event
  virtual TMidiEvent *read() = 0;

  // Write an event to the specified device
  virtual void       Write(int aDevice, TMidiEvent *ev) = 0;

  // Start playing (for example start the timer)
  virtual void       Start(void) = 0;

  // Stop playing
  virtual void       Stop(void) = 0;

  // Get the current time in ticks
  virtual long       GetTime(void) = 0;

  // Set the tempo at the specified time
  virtual void       SetTempo(int tempo, long ticks) = 0;

  // Set the timebase value
  virtual void       SetTimebase(int timebase) = 0;

  virtual void       rebuildInfoDatabase  (void) = 0;

  virtual int GetInputCount( void ) const = 0;
  virtual int GetOutputCount( void ) const = 0;

  virtual int GetInputDevice( void ) = 0;      // read input device
  virtual void SetInputDevice( int aInputDevice ) = 0;   // set input device

  virtual int GetOutputDevice( void ) = 0;     // read output device
  virtual void SetOutputDevice( int aOutputDevice ) = 0; // set output device

  virtual const char* GetInputName ( int aDevice ) const = 0;
  virtual const char* GetOutputName ( int aDevice ) const = 0;
};

#endif

Generated by: root@castle on Fri Jul 20 00:33:17 2001, using kdoc 2.0a36.