[beast: 7/26] BSE: bseapi.idl: introduce CSynth
- From: Tim Janik <timj src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [beast: 7/26] BSE: bseapi.idl: introduce CSynth
- Date: Mon, 13 Jul 2015 02:27:02 +0000 (UTC)
commit af3dee7ac137d19ff9e191463604755dd6e78b99
Author: Tim Janik <timj gnu org>
Date: Wed Jul 1 03:58:59 2015 +0200
BSE: bseapi.idl: introduce CSynth
bse/Makefile.am | 2 +-
bse/bseapi.idl | 4 ++++
bse/bsecsynth.cc | 15 +++++++++++++++
bse/bsecsynth.hh | 23 +++++++++++++++--------
bse/bsecsynth.proc | 11 -----------
bse/bseobject.cc | 3 +++
6 files changed, 38 insertions(+), 20 deletions(-)
---
diff --git a/bse/Makefile.am b/bse/Makefile.am
index 1bb6cea..6b4ea60 100644
--- a/bse/Makefile.am
+++ b/bse/Makefile.am
@@ -115,7 +115,7 @@ idl_dummy_files = $(strip \
bse_proc_sources = $(strip \
bsecategories.proc bsecontainer.proc bsedatapocket.proc bseeditablesample.proc
bsemidinotifier.proc \
bsejanitor.proc bsepart.proc bseparasite.proc bseprocedure.proc
bseproject.proc bsescripthelper.proc \
- bsesong.proc bsebus.proc bsesource.proc
bsecsynth.proc bsesnet.proc \
+ bsesong.proc bsebus.proc bsesource.proc
bsesnet.proc \
bsetrack.proc bseitem.proc bsewave.proc bsewaveosc.proc
bsewaverepo.proc \
)
bse_proc_gen_sources = $(bse_proc_sources:.proc=.genprc.cc)
diff --git a/bse/bseapi.idl b/bse/bseapi.idl
index d2a1787..c7ce894 100644
--- a/bse/bseapi.idl
+++ b/bse/bseapi.idl
@@ -445,6 +445,10 @@ interface SNet : Super {
bool supports_user_synths (); ///< Check whether users may edit synthesis modules of this network.
};
+/// Customizable synthesis (filter) network container.
+interface CSynth : SNet {
+};
+
/// Container for Track and Part objects, as well as meta data for sequencing.
interface Song : SNet {
Track find_any_track_for_part (Part part); ///< Find the first track that contains part,
suitable to check for orphan parts.
diff --git a/bse/bsecsynth.cc b/bse/bsecsynth.cc
index eb58956..b016422 100644
--- a/bse/bsecsynth.cc
+++ b/bse/bsecsynth.cc
@@ -102,3 +102,18 @@ bse_csynth_get_property (GObject *object,
break;
}
}
+
+
+namespace Bse {
+
+CSynthImpl::CSynthImpl (BseObject *bobj) :
+ SNetImpl (bobj)
+{}
+
+CSynthImpl::~CSynthImpl ()
+{}
+
+// BseCSynth *self = as<BseCSynth*>();
+// other->as<CSynthIfaceP> ();
+
+} // Bse
diff --git a/bse/bsecsynth.hh b/bse/bsecsynth.hh
index 92d9976..223943a 100644
--- a/bse/bsecsynth.hh
+++ b/bse/bsecsynth.hh
@@ -6,7 +6,6 @@
G_BEGIN_DECLS
-/* --- object type macros --- */
#define BSE_TYPE_CSYNTH (BSE_TYPE_ID (BseCSynth))
#define BSE_CSYNTH(object) (G_TYPE_CHECK_INSTANCE_CAST ((object), BSE_TYPE_CSYNTH, BseCSynth))
#define BSE_CSYNTH_CLASS(class) (G_TYPE_CHECK_CLASS_CAST ((class), BSE_TYPE_CSYNTH, BseCSynthClass))
@@ -15,13 +14,21 @@ G_BEGIN_DECLS
#define BSE_CSYNTH_GET_CLASS(object) (G_TYPE_INSTANCE_GET_CLASS ((object), BSE_TYPE_CSYNTH, BseCSynthClass))
#define BSE_CSYNTH_USER_SYNTH(src) ((BSE_OBJECT_FLAGS (src) & BSE_CSYNTH_FLAG_USER_SYNTH) != 0)
+struct BseCSynth : BseSNet {};
+struct BseCSynthClass : BseSNetClass {};
-/* --- BseCSynth object --- */
-struct BseCSynth : BseSNet
-{};
-struct BseCSynthClass : BseSNetClass
-{};
-
-/* --- prototypes --- */
G_END_DECLS
+
+namespace Bse {
+
+class CSynthImpl : public SNetImpl, public virtual CSynthIface {
+protected:
+ virtual ~CSynthImpl ();
+public:
+ explicit CSynthImpl (BseObject*);
+};
+
+} // Bse
+
+
#endif /* __BSE_CSYNTH_H__ */
diff --git a/bse/bseobject.cc b/bse/bseobject.cc
index 1edb08f..ea0008b 100644
--- a/bse/bseobject.cc
+++ b/bse/bseobject.cc
@@ -918,6 +918,7 @@ bse_object_new (GType object_type, const gchar *first_property_name, ...)
#include "bseserver.hh"
#include "bseproject.hh"
#include "bsesong.hh"
+#include "bsecsynth.hh"
#include "bsetrack.hh"
#include "bsecontextmerger.hh"
#include "bsesnet.hh"
@@ -941,6 +942,8 @@ bse_object_new_valist (GType object_type, const gchar *first_property_name, va_l
cxxo = new Bse::ProjectImpl (object);
else if (g_type_is_a (object_type, BSE_TYPE_SONG))
cxxo = new Bse::SongImpl (object);
+ else if (g_type_is_a (object_type, BSE_TYPE_CSYNTH))
+ cxxo = new Bse::CSynthImpl (object);
else if (g_type_is_a (object_type, BSE_TYPE_SNET))
cxxo = new Bse::SNetImpl (object);
else if (g_type_is_a (object_type, BSE_TYPE_SUPER))
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]