/*
 * sndctl  -  a plugin for the Video Disk Recorder
 *        file: mixer.h
 * description: header file for mixer.c
 *
 *      author: Thomas Hildebrandt <toxym@web.de>
 *
 * inspired by and reengineered from 'avolctl'
 * thanks to Martin Prochnow <nordlichtl@martins-kabuff.de>
 */

#ifndef SNDCTL_MIXER_H
#define SNDCTL_MIXER_H

/*
 * cMixer
 * parent class for all types of mixer devices
 */
class cMixer {
  protected:
    struct control{
      long   min;
      long   max;
      string name;
      long   limitL;
      long   limitU;
      char   op;
      int    value;
      long   volume;
    }                *controls;
    int               nrOfControls;

    virtual void           UpdateControls( void ) = 0;
    virtual void           Volumes( void )        = 0;

  public:
    cMixer();
    virtual ~cMixer();

    virtual int    CountControls( void )  = 0;
    vector<string> GetControls( void );
    void           Update( cSoundSet* );
    void           Volume( int );

    virtual bool   IsMixer( string ) = 0;
};

#endif //SNDCTL_MIXER_H
