summaryrefslogtreecommitdiffstats
path: root/src/VLCInput.h
diff options
context:
space:
mode:
authorMatthias P. Braendli <matthias.braendli@mpb.li>2016-03-04 21:02:15 +0100
committerMatthias P. Braendli <matthias.braendli@mpb.li>2016-03-04 21:02:15 +0100
commit61b5ba527efef75565336dfa87f0a2432dd5f50b (patch)
tree611f00a2b1a9b9f1e6a5a4b71eff3f5a027485bd /src/VLCInput.h
parent891bb2592944aa2be2d81e1583e73e632e70537f (diff)
downloadODR-AudioEnc-61b5ba527efef75565336dfa87f0a2432dd5f50b.tar.gz
ODR-AudioEnc-61b5ba527efef75565336dfa87f0a2432dd5f50b.tar.bz2
ODR-AudioEnc-61b5ba527efef75565336dfa87f0a2432dd5f50b.zip
Add -L option to give arbitrary options to VLC
Diffstat (limited to 'src/VLCInput.h')
-rw-r--r--src/VLCInput.h15
1 files changed, 11 insertions, 4 deletions
diff --git a/src/VLCInput.h b/src/VLCInput.h
index 27d6237..d583008 100644
--- a/src/VLCInput.h
+++ b/src/VLCInput.h
@@ -49,12 +49,14 @@ class VLCInput
unsigned channels,
unsigned verbosity,
std::string& gain,
- std::string& cache) :
+ std::string& cache,
+ std::vector<std::string>& additional_opts) :
m_uri(uri),
m_verbosity(verbosity),
m_channels(channels),
m_rate(rate),
m_cache(cache),
+ m_additional_opts(additional_opts),
m_gain(gain),
m_vlc(nullptr),
m_mp(nullptr) { }
@@ -106,6 +108,9 @@ class VLCInput
// Whether to enable network caching in VLC or not
std::string m_cache;
+ // Given as-is to libvlc
+ std::vector<std::string> m_additional_opts;
+
// value for the VLC compressor filter
std::string m_gain;
@@ -130,8 +135,9 @@ class VLCInputDirect : public VLCInput
unsigned channels,
unsigned verbosity,
std::string& gain,
- std::string& cache) :
- VLCInput(uri, rate, channels, verbosity, gain, cache) {}
+ std::string& cache,
+ std::vector<std::string>& additional_opts) :
+ VLCInput(uri, rate, channels, verbosity, gain, cache, additional_opts) {}
/* Read exactly length bytes into buf.
* Blocks if not enough data is available,
@@ -153,8 +159,9 @@ class VLCInputThreaded : public VLCInput
unsigned verbosity,
std::string& gain,
std::string& cache,
+ std::vector<std::string>& additional_opts,
SampleQueue<uint8_t>& queue) :
- VLCInput(uri, rate, channels, verbosity, gain, cache),
+ VLCInput(uri, rate, channels, verbosity, gain, cache, additional_opts),
m_fault(false),
m_running(false),
m_queue(queue) {}