summaryrefslogtreecommitdiff
path: root/drumgizmo/audiooutputenginedl.cc
diff options
context:
space:
mode:
Diffstat (limited to 'drumgizmo/audiooutputenginedl.cc')
-rw-r--r--drumgizmo/audiooutputenginedl.cc12
1 files changed, 12 insertions, 0 deletions
diff --git a/drumgizmo/audiooutputenginedl.cc b/drumgizmo/audiooutputenginedl.cc
index 513d21b..fcedd9d 100644
--- a/drumgizmo/audiooutputenginedl.cc
+++ b/drumgizmo/audiooutputenginedl.cc
@@ -111,6 +111,12 @@ AudioOutputEngineDL::AudioOutputEngineDL(std::string name)
o_bufsize = NULL;
}
+ o_samplerate = (output_samplerate_func_t) dlsym(lib, "samplerate");
+ dlsym_error = dlerror();
+ if(dlsym_error) {
+ o_samplerate = NULL;
+ }
+
ptr = o_create();
if(is_jack_plugin) {
@@ -181,6 +187,12 @@ size_t AudioOutputEngineDL::getBufferSize()
return 1024;
}
+size_t AudioOutputEngineDL::samplerate()
+{
+ if(o_samplerate) return o_samplerate(ptr);
+ return UNKNOWN_SAMPLERATE;
+}
+
#ifdef TEST_AUDIOOUTPUTENGINEDL
//Additional dependency files
//deps: