diff options
author | Matthias P. Braendli <matthias.braendli@mpb.li> | 2014-04-11 11:55:43 +0200 |
---|---|---|
committer | Matthias P. Braendli <matthias.braendli@mpb.li> | 2014-04-11 11:55:43 +0200 |
commit | fa36e03255eb668195f043d39307f3dc2fa5e809 (patch) | |
tree | cc5e69cc8fe5cc50b4bbda52b4ba2d7caf033942 /src/dabInputZmq.h | |
parent | e3e7925934074d61835aa09a642f09bc6cd16d1d (diff) | |
download | dabmux-fa36e03255eb668195f043d39307f3dc2fa5e809.tar.gz dabmux-fa36e03255eb668195f043d39307f3dc2fa5e809.tar.bz2 dabmux-fa36e03255eb668195f043d39307f3dc2fa5e809.zip |
Add zmq buffer options to config file
Diffstat (limited to 'src/dabInputZmq.h')
-rw-r--r-- | src/dabInputZmq.h | 18 |
1 files changed, 11 insertions, 7 deletions
diff --git a/src/dabInputZmq.h b/src/dabInputZmq.h index 11fb49a..a052815 100644 --- a/src/dabInputZmq.h +++ b/src/dabInputZmq.h @@ -76,13 +76,14 @@ class DabInputZmqBase : public DabInputBase, public RemoteControllable { public: - DabInputZmqBase(const std::string name) + DabInputZmqBase(const std::string name, + int buffer_size, int prebuffering) : RemoteControllable(name), m_zmq_context(1), m_zmq_sock(m_zmq_context, ZMQ_SUB), - m_bitrate(0), m_prebuffering(INPUT_ZMQ_DEF_PREBUFFERING), + m_bitrate(0), m_prebuffering(prebuffering), m_enable_input(true), - m_frame_buffer_limit(INPUT_ZMQ_DEF_BUFFER_SIZE) { + m_frame_buffer_limit(buffer_size) { RC_ADD_PARAMETER(enable, "If the input is enabled. Set to zero to empty the buffer."); } @@ -119,8 +120,9 @@ class DabInputZmqBase : public DabInputBase, public RemoteControllable { class DabInputZmqMPEG : public DabInputZmqBase { public: - DabInputZmqMPEG(const std::string name) - : DabInputZmqBase(name) { + DabInputZmqMPEG(const std::string name, + int buffer_size, int prebuffering) + : DabInputZmqBase(name, buffer_size, prebuffering) { RC_ADD_PARAMETER(buffer, "Size of the input buffer [mpeg frames]"); @@ -134,8 +136,9 @@ class DabInputZmqMPEG : public DabInputZmqBase { class DabInputZmqAAC : public DabInputZmqBase { public: - DabInputZmqAAC(const std::string name) - : DabInputZmqBase(name) { + DabInputZmqAAC(const std::string name, + int buffer_size, int prebuffering) + : DabInputZmqBase(name, buffer_size, prebuffering) { RC_ADD_PARAMETER(buffer, "Size of the input buffer [aac superframes]"); @@ -150,3 +153,4 @@ class DabInputZmqAAC : public DabInputZmqBase { #endif // HAVE_INPUT_ZMQ #endif // DAB_INPUT_ZMQ_H + |