summaryrefslogtreecommitdiff
path: root/drumgizmo/audiooutputenginedl.cc
diff options
context:
space:
mode:
authorBent Bisballe Nyeng <deva@aasimon.org>2014-05-17 21:27:52 +0200
committerBent Bisballe Nyeng <deva@aasimon.org>2014-05-17 21:27:52 +0200
commit0e048dee411cc20beb2a8667e5bb339f9b7fb939 (patch)
treec9bacf6f2491f5ae6feb4f4786688ef5659f5c9b /drumgizmo/audiooutputenginedl.cc
parentb6405171c6a74a5227555a9b75c03f88a5f21ed2 (diff)
New resample feature on output channels.
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: