summaryrefslogtreecommitdiff
path: root/drumgizmo/enginefactory.h
diff options
context:
space:
mode:
authorChristian Glöckner <cgloeckner@freenet.de>2016-01-25 16:26:49 +0100
committerAndré Nusser <andre.nusser@googlemail.com>2016-02-09 09:03:17 +0100
commit67ac001b417e0a5497f02e59cd33a2248964eac5 (patch)
tree53aaf5577086e94adcd47afb90e26be867ed2efb /drumgizmo/enginefactory.h
parentc9edca027eb2d2e257ff4a13fc257385d7c64d39 (diff)
Added docs for enginefactory
Diffstat (limited to 'drumgizmo/enginefactory.h')
-rw-r--r--drumgizmo/enginefactory.h16
1 files changed, 16 insertions, 0 deletions
diff --git a/drumgizmo/enginefactory.h b/drumgizmo/enginefactory.h
index 02a84ae..d7e63ee 100644
--- a/drumgizmo/enginefactory.h
+++ b/drumgizmo/enginefactory.h
@@ -65,23 +65,39 @@
#include "output/jackaudio.h"
#endif
+//! Factory for various input- and output engines
class EngineFactory
{
public:
+ //! Initialized lists of available engines (depending on enabled settings)
EngineFactory();
+ //! Query list of available input engines' names
+ //! \return const reference to the list
const std::list<std::string>& getInputEngines() const;
+
+ //! Query list of available output engines' names
+ //! \return const reference to the list
const std::list<std::string>& getOutputEngines() const;
+ //! Create input engine by name
+ //! \param name Name of the input engine that should be initialized
+ //! \return unique_ptr to input engine or nullptr if engine is not supported
std::unique_ptr<AudioInputEngine> createInput(const std::string& name);
+
+ //! Create input engine by name
+ //! \param name Name of the output engine that should be initialized
+ //! \return unique_ptr to input engine or nullptr if engine is not supported
std::unique_ptr<AudioOutputEngine> createOutput(const std::string& name);
protected:
std::list<std::string> input, output; // available engines
#ifdef USE_JACK
+ // Client that is used by all jack-related engines
std::unique_ptr<JackClient> jack;
+ // Utility to initialize jack (once)
void prepareJack();
#endif