BEAST/BSE - Better Audio System and Sound Engine  0.8.2
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines
bsesummation.genidl.hh
Go to the documentation of this file.
00001 
00002 /*-------- begin ../sfi/sfidl generated code --------*/
00003 
00004 
00005 
00006 #include <bse/bsecxxplugin.hh>
00007 
00008 
00009 /* enum prototypes */
00010 
00011 
00012 /* choice prototypes */
00013 
00014 
00015 /* record prototypes */
00016 
00017 
00018 /* sequence prototypes */
00019 
00020 
00021 /* class prototypes */
00022 namespace Bse {
00023 class SummationBase;
00024 class Summation;
00025 #define BSE_TYPE_SUMMATION              BSE_CXX_DECLARED_CLASS_TYPE (Bse, Summation)
00026 #define BSE_IS_SUMMATION(o) (::Bse::CxxBase::instance_is_a (o, BSE_TYPE_SUMMATION))
00027 
00028 
00029 /* enum definitions */
00030 
00031 
00032 /* sequence definitions */
00033 
00034 
00035 /* record definitions */
00036 
00037 
00038 /* enum declarations */
00039 
00040 
00041 /* sequence type declarations */
00042 
00043 
00044 /* record type declarations */
00045 
00046 
00047 /* procedure prototypes */
00048 
00049 
00050 /* class definitions */
00051 BSE_CXX_DECLARE_CLASS (Summation);
00052 class SummationBase : public ::Bse::Effect {
00053   template<bool> static inline const unsigned char* inlined_pixstream();
00054 public:
00055   static inline const unsigned char* pixstream () { return inlined_pixstream<true>(); }
00056   static void               class_init (::Bse::CxxBaseClass *klass);
00057   static inline const char* options   () { return ""; }
00058   static inline const char* category  () { static const char *c = NULL;
00059     return c ? c : c = sfi_category_concat ("/Modules",  ("/Routing/Summation")); }
00060   static inline const char* i18n_category  () { static const char *c = NULL;
00061     return c ? c : c = sfi_category_concat ("/Modules", _("/Routing/Summation")); }
00062   static inline const char* blurb     () { return _("The Summation module adds up all inputs connected to its multi-connect input streams. The sum of all inputs connected to 'Audio In1' is available at 'Audio Sum1', and similarly, 'Audio Sum2' is the accumulatiuon signal of all streams connected to 'Audio In2'. A difference signal between 'Audio Sum1' and 'Audio Sum2' is also generated and is available at 'Audio Diff'."); }
00063   static inline const char* authors   () { return "Tim Janik"; }
00064   static inline const char* license   () { return _("GNU Lesser General Public License"); }
00065   static inline const char* type_name () { return "BseSummation"; }
00066 public:
00067   enum {
00068     JCHANNEL_AUDIO_IN1,
00069     JCHANNEL_AUDIO_IN2,
00070     N_JCHANNELS
00071   };
00072 public:
00073   enum {
00074     OCHANNEL_AUDIO_OUT1,
00075     OCHANNEL_AUDIO_DIFF,
00076     OCHANNEL_AUDIO_OUT2,
00077     N_OCHANNELS
00078   };
00079 protected:
00080   enum SummationPropertyID {
00081   };
00082 public:
00083   /* "transport" structure to configure synthesis modules from properties */
00084   struct SummationProperties {
00085     typedef SummationPropertyID IDType;
00086     explicit SummationProperties (SummationBase *p) 
00087     {
00088     }
00089   };
00090 protected:
00091   typedef void AutoUpdateCategory;
00092 protected:
00093 public:
00094   void get_property (SummationPropertyID prop_id, ::Bse::Value &value, GParamSpec *pspec)
00095   {
00096     switch (prop_id) {
00097     };
00098   }
00099   void set_property (SummationPropertyID prop_id, const ::Bse::Value &value, GParamSpec *pspec)
00100   {
00101     switch (prop_id) {
00102     };
00103     property_changed (SummationPropertyID (prop_id));
00104     update_modules();
00105     switch (prop_id) {
00106     default: ;
00107     };
00108   }
00109   virtual bool editable_property (SummationPropertyID prop_id, GParamSpec *pspec)
00110   {
00111     return true;
00112   }
00113   virtual void get_candidates (SummationPropertyID prop_id, ::Bse::PropertyCandidatesHandle &pch, GParamSpec *pspec)
00114   {
00115   }
00116   void property_updated (SummationPropertyID prop_id, guint64 tick_stamp, double prop_value, GParamSpec *pspec)
00117   {
00118     bool seen_change = false;
00119     switch (prop_id) {
00120     default: ;
00121     };
00122     if (seen_change &&
00123         property_changed (SummationPropertyID (prop_id)))
00124       update_modules();
00125   }
00126 private:
00127   static struct StaticData {
00128     int dummy;
00129   } static_data;
00130 protected:
00131   virtual bool property_changed (SummationPropertyID) { return false; }
00132   virtual ~SummationBase ()
00133   {
00134   }
00135 public:
00136 };
00137 
00138 
00139 /* choice implementations */
00140 
00141 
00142 /* record implementations */
00143 
00144 
00145 /* sequence implementations */
00146 
00147 
00148 /* class implementations */
00149 void
00150 SummationBase::class_init (::Bse::CxxBaseClass *klass)
00151 {
00152   klass->set_accessors (::Bse::cxx_get_property_trampoline<SummationBase, SummationPropertyID>,
00153                         ::Bse::cxx_set_property_trampoline<SummationBase, SummationPropertyID>,
00154                         ::Bse::cxx_editable_property_trampoline<SummationBase, SummationPropertyID>,
00155                         ::Bse::cxx_get_candidates_trampoline<SummationBase, SummationPropertyID>,
00156                         NULL);
00157   klass->add_jchannel ("audio_in1", _("Audio In1"), _("Audio input 1"), JCHANNEL_AUDIO_IN1);
00158   klass->add_jchannel ("audio_in2", _("Audio In2"), _("Audio input 2"), JCHANNEL_AUDIO_IN2);
00159   klass->add_ochannel ("audio_out1", _("Audio Sum1"), _("Accumulated audio output 1"), OCHANNEL_AUDIO_OUT1);
00160   klass->add_ochannel ("audio_diff", _("Audio Diff"), _("Difference between audio outputs 1 and 2"), OCHANNEL_AUDIO_DIFF);
00161   klass->add_ochannel ("audio_out2", _("Audio Sum2"), _("Accumulated audio output 2"), OCHANNEL_AUDIO_OUT2);
00162 }
00163 
00164 
00165 /* procedure implementations */
00166 
00167 
00168 /* bsesummation.idl type registrations */
00169 #define BSE_CXX_REGISTER_ALL_TYPES_FROM_BSESUMMATION_IDL() \
00170   BSE_CXX_REGISTER_EFFECT (Summation); \
00171   /* bsesummation.idl type registrations done */
00172 } // Bse
00173 template<bool> const unsigned char*
00174 ::Bse::SummationBase::inlined_pixstream()
00175 {
00176   /* GdkPixbuf RGBA C-Source image dump 1-byte-run-length-encoded */
00177 
00178 #ifdef __SUNPRO_C
00179 #pragma align 4 (local_pixstream)
00180 #endif
00181 #ifdef __GNUC__
00182 static const guint8 local_pixstream[] __attribute__ ((__aligned__ (4))) = 
00183 #else
00184 static const guint8 local_pixstream[] = 
00185 #endif
00186 { ""
00187   /* Pixbuf magic (0x47646b50) */
00188   "GdkP"
00189   /* length: header (24) + pixel_data (900) */
00190   "\0\0\3\234"
00191   /* pixdata_type (0x2010002) */
00192   "\2\1\0\2"
00193   /* rowstride (256) */
00194   "\0\0\1\0"
00195   /* width (64) */
00196   "\0\0\0@"
00197   /* height (64) */
00198   "\0\0\0@"
00199   /* pixel_data: */
00200   "\377\0\0\0\0\377\0\0\0\0\377\0\0\0\0\223\0\0\0\0\203\0\0\0\377\232\0"
00201   "\0\0\0\203\0\0\0\377\240\0\0\0\0\203\0\0\0\377\232\0\0\0\0\203\0\0\0"
00202   "\377\240\0\0\0\0\203\0\0\0\377\232\0\0\0\0\203\0\0\0\377\240\0\0\0\0"
00203   "\203\0\0\0\377\232\0\0\0\0\203\0\0\0\377\240\0\0\0\0\203\0\0\0\377\232"
00204   "\0\0\0\0\203\0\0\0\377\240\0\0\0\0\203\0\0\0\377\232\0\0\0\0\203\0\0"
00205   "\0\377\240\0\0\0\0\203\0\0\0\377\232\0\0\0\0\203\0\0\0\377\240\0\0\0"
00206   "\0\203\0\0\0\377\232\0\0\0\0\203\0\0\0\377\240\0\0\0\0\203\0\0\0\377"
00207   "\232\0\0\0\0\203\0\0\0\377\227\0\0\0\0\225\0\0\0\377\210\0\0\0\0\225"
00208   "\0\0\0\377\216\0\0\0\0\225\0\0\0\377\210\0\0\0\0\225\0\0\0\377\216\0"
00209   "\0\0\0\225\0\0\0\377\210\0\0\0\0\225\0\0\0\377\227\0\0\0\0\203\0\0\0"
00210   "\377\232\0\0\0\0\203\0\0\0\377\240\0\0\0\0\203\0\0\0\377\232\0\0\0\0"
00211   "\203\0\0\0\377\240\0\0\0\0\203\0\0\0\377\232\0\0\0\0\203\0\0\0\377\240"
00212   "\0\0\0\0\203\0\0\0\377\232\0\0\0\0\203\0\0\0\377\240\0\0\0\0\203\0\0"
00213   "\0\377\232\0\0\0\0\203\0\0\0\377\240\0\0\0\0\203\0\0\0\377\232\0\0\0"
00214   "\0\203\0\0\0\377\240\0\0\0\0\203\0\0\0\377\232\0\0\0\0\203\0\0\0\377"
00215   "\240\0\0\0\0\203\0\0\0\377\232\0\0\0\0\203\0\0\0\377\240\0\0\0\0\203"
00216   "\0\0\0\377\232\0\0\0\0\203\0\0\0\377\377\0\0\0\0\377\0\0\0\0\377\0\0"
00217   "\0\0\377\0\0\0\0\377\0\0\0\0\245\0\0\0\0\203\0\0\0\377\232\0\0\0\0\203"
00218   "\0\0\0\377\240\0\0\0\0\203\0\0\0\377\232\0\0\0\0\203\0\0\0\377\240\0"
00219   "\0\0\0\203\0\0\0\377\232\0\0\0\0\203\0\0\0\377\240\0\0\0\0\203\0\0\0"
00220   "\377\232\0\0\0\0\203\0\0\0\377\240\0\0\0\0\203\0\0\0\377\232\0\0\0\0"
00221   "\203\0\0\0\377\240\0\0\0\0\203\0\0\0\377\232\0\0\0\0\203\0\0\0\377\240"
00222   "\0\0\0\0\203\0\0\0\377\232\0\0\0\0\203\0\0\0\377\240\0\0\0\0\203\0\0"
00223   "\0\377\232\0\0\0\0\203\0\0\0\377\240\0\0\0\0\203\0\0\0\377\232\0\0\0"
00224   "\0\203\0\0\0\377\227\0\0\0\0\225\0\0\0\377\210\0\0\0\0\225\0\0\0\377"
00225   "\216\0\0\0\0\225\0\0\0\377\210\0\0\0\0\225\0\0\0\377\216\0\0\0\0\225"
00226   "\0\0\0\377\210\0\0\0\0\225\0\0\0\377\227\0\0\0\0\203\0\0\0\377\232\0"
00227   "\0\0\0\203\0\0\0\377\240\0\0\0\0\203\0\0\0\377\232\0\0\0\0\203\0\0\0"
00228   "\377\240\0\0\0\0\203\0\0\0\377\232\0\0\0\0\203\0\0\0\377\240\0\0\0\0"
00229   "\203\0\0\0\377\232\0\0\0\0\203\0\0\0\377\240\0\0\0\0\203\0\0\0\377\232"
00230   "\0\0\0\0\203\0\0\0\377\240\0\0\0\0\203\0\0\0\377\232\0\0\0\0\203\0\0"
00231   "\0\377\240\0\0\0\0\203\0\0\0\377\232\0\0\0\0\203\0\0\0\377\240\0\0\0"
00232   "\0\203\0\0\0\377\232\0\0\0\0\203\0\0\0\377\240\0\0\0\0\203\0\0\0\377"
00233   "\232\0\0\0\0\203\0\0\0\377\377\0\0\0\0\377\0\0\0\0\377\0\0\0\0\223\0"
00234   "\0\0\0"};
00235 
00236 
00237 
00238   return local_pixstream;
00239 }
00240 
00241 /*-------- end ../sfi/sfidl generated code --------*/
00242 
00243 
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines