Home | History | Annotate | Download | only in alsa
      1 /**
      2  * \file include/pcm_external.h
      3  * \brief External PCM plugin SDK
      4  * \author Takashi Iwai <tiwai (at) suse.de>
      5  * \date 2005
      6  *
      7  * Extern PCM plugin SDK.
      8  */
      9 
     10 /*
     11  *   This library is free software; you can redistribute it and/or modify
     12  *   it under the terms of the GNU Lesser General Public License as
     13  *   published by the Free Software Foundation; either version 2.1 of
     14  *   the License, or (at your option) any later version.
     15  *
     16  *   This program is distributed in the hope that it will be useful,
     17  *   but WITHOUT ANY WARRANTY; without even the implied warranty of
     18  *   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
     19  *   GNU Lesser General Public License for more details.
     20  *
     21  *   You should have received a copy of the GNU Lesser General Public
     22  *   License along with this library; if not, write to the Free Software
     23  *   Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA
     24  *
     25  */
     26 #ifndef __ALSA_PCM_EXTERNAL_H
     27 #define __ALSA_PCM_EXTERNAL_H
     28 
     29 #include "pcm.h"
     30 
     31 #ifdef __cplusplus
     32 extern "C" {
     33 #endif
     34 
     35 /**
     36  *  \defgroup Plugin_SDK External PCM plugin SDK
     37  *  \{
     38  */
     39 
     40 /**
     41  * Define the object entry for external PCM plugins
     42  */
     43 #define SND_PCM_PLUGIN_ENTRY(name) _snd_pcm_##name##_open
     44 
     45 /**
     46  * Define the symbols of the given plugin with versions
     47  */
     48 #define SND_PCM_PLUGIN_SYMBOL(name) SND_DLSYM_BUILD_VERSION(SND_PCM_PLUGIN_ENTRY(name), SND_PCM_DLSYM_VERSION);
     49 
     50 /**
     51  * Define the plugin
     52  */
     53 #define SND_PCM_PLUGIN_DEFINE_FUNC(plugin) \
     54 int SND_PCM_PLUGIN_ENTRY(plugin) (snd_pcm_t **pcmp, const char *name,\
     55 				  snd_config_t *root, snd_config_t *conf, \
     56 				  snd_pcm_stream_t stream, int mode)
     57 
     58 #include "pcm_ioplug.h"
     59 #include "pcm_extplug.h"
     60 
     61 int snd_pcm_parse_control_id(snd_config_t *conf, snd_ctl_elem_id_t *ctl_id, int *cardp,
     62 			     int *cchannelsp, int *hwctlp);
     63 
     64 /** \} */
     65 
     66 #ifdef __cplusplus
     67 }
     68 #endif
     69 
     70 #endif /* __ALSA_PCM_EXTERNAL_H */
     71