BEAST/BSE - Better Audio System and Sound Engine  0.8.2
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines
davguitar.hh
Go to the documentation of this file.
00001  // Licensed GNU LGPL v2.1 or later: http://www.gnu.org/licenses/lgpl.html
00002 #ifndef __DAV_GUITAR_H__
00003 #define __DAV_GUITAR_H__
00004 
00005 #include <bse/bseplugin.hh>
00006 #include <bse/bsesource.hh>
00007 
00008 #ifdef __cplusplus
00009 extern "C" {
00010 #endif /* __cplusplus */
00011 
00012 /* --- object type macros --- */
00013 #define DAV_TYPE_GUITAR              (type_id_guitar)
00014 #define DAV_GUITAR(object)           (G_TYPE_CHECK_INSTANCE_CAST ((object), DAV_TYPE_GUITAR, DavGuitar))
00015 #define DAV_GUITAR_CLASS(class)      (G_TYPE_CHECK_CLASS_CAST ((class), DAV_TYPE_GUITAR, DavGuitar))
00016 #define DAV_IS_GUITAR(object)        (G_TYPE_CHECK_INSTANCE_TYPE ((object), DAV_TYPE_GUITAR))
00017 #define DAV_IS_GUITAR_CLASS(class)   (G_TYPE_CHECK_CLASS_TYPE ((class), DAV_TYPE_GUITAR))
00018 #define DAV_GUITAR_GET_CLASS(object) (G_TYPE_INSTANCE_GET_CLASS ((object), DAV_TYPE_GUITAR, DavGuitarClass))
00019 
00020 struct WaveGuide {
00021   gfloat  freq;
00022   gfloat  lowpass_data, lowpass_coeff;
00023   gint    wavelen;
00024   gint    pos;
00025   gfloat *data;
00026 };
00027 struct DavGuitar : BseSource {
00028   gfloat hipass_data, hipass_coeff;
00029   gint      body_taps[6];
00030   WaveGuide strings[6];
00031   WaveGuide body;
00032   gfloat    trigger_vel;
00033   gfloat    metallic_factor;
00034   gfloat    snap_factor;
00035 };
00036 struct DavGuitarClass : BseSourceClass
00037 {};
00038 
00039 enum
00040 {
00041   DAV_GUITAR_OCHANNEL_NONE,
00042   DAV_GUITAR_OCHANNEL_MONO
00043 };
00044 
00045 #ifdef __cplusplus
00046 }
00047 #endif /* __cplusplus */
00048 #endif /* __DAV_GUITAR_H__ */
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines