AtmoConnection.h
上传用户:kjfoods
上传日期:2020-07-06
资源大小:29949k
文件大小:2k
源码类别:

midi

开发平台:

Unix_Linux

  1. /*
  2.  * AtmoConnection.h: generic/abstract class defining all methods for the
  3.  * communication with the hardware
  4.  *
  5.  * See the README.txt file for copyright information and how to reach the author(s).
  6.  *
  7.  * $Id: a7e6e97c99970138b17023b32f68c96ab60170bb $
  8.  */
  9. #ifndef _AtmoConnection_h_
  10. #define _AtmoConnection_h_
  11. #include "AtmoDefs.h"
  12. #include "AtmoConfig.h"
  13. class CAtmoConnection
  14. {
  15. protected:
  16. CAtmoConfig *m_pAtmoConfig;
  17.     int m_ChannelAssignment[ATMO_NUM_CHANNELS];
  18. public:
  19. CAtmoConnection(CAtmoConfig *cfg);
  20. virtual ~CAtmoConnection(void);
  21. virtual ATMO_BOOL OpenConnection() { return false; }
  22. virtual void CloseConnection() {};
  23. virtual ATMO_BOOL isOpen(void) { return false; }
  24.     virtual ATMO_BOOL SendData(unsigned char numChannels,
  25.                                int red[],
  26.                                int green[],
  27.                                int blue[]) { return false; }
  28.     virtual ATMO_BOOL SendData(tColorPacket data) { return false; }
  29.     virtual ATMO_BOOL setChannelColor(int channel, tRGBColor color) { return false; }
  30.     virtual ATMO_BOOL setChannelValues(int numValues,unsigned char *channel_values) { return false; }
  31.     virtual ATMO_BOOL HardwareWhiteAdjust(int global_gamma,
  32.                                           int global_contrast,
  33.                                           int contrast_red,
  34.                                           int contrast_green,
  35.                                           int contrast_blue,
  36.                                           int gamma_red,
  37.                                           int gamma_green,
  38.                                           int gamma_blue,
  39.                                           ATMO_BOOL storeToEeprom) { return false; }
  40.     virtual void SetChannelAssignment(tChannelAssignment *ca);
  41. };
  42. #endif