mirror of
https://github.com/hyperion-project/hyperion.ng.git
synced 2025-03-01 10:33:28 +00:00
refactor apt/dnf repo
This commit is contained in:
@@ -18,74 +18,69 @@ class AudioGrabberLinux : public AudioGrabber
|
||||
AudioGrabberLinux();
|
||||
~AudioGrabberLinux() override;
|
||||
|
||||
///
|
||||
///
|
||||
/// Process audio buffer
|
||||
///
|
||||
void processAudioBuffer(snd_pcm_sframes_t frames);
|
||||
|
||||
///
|
||||
///
|
||||
/// Is Running Flag
|
||||
///
|
||||
std::atomic<bool> _isRunning;
|
||||
|
||||
///
|
||||
///
|
||||
/// Current capture device
|
||||
///
|
||||
snd_pcm_t * _captureDevice;
|
||||
|
||||
public slots:
|
||||
|
||||
///
|
||||
///
|
||||
/// Start audio capturing session
|
||||
///
|
||||
/// @returns true if successful
|
||||
bool start() override;
|
||||
|
||||
///
|
||||
///
|
||||
/// Stop audio capturing session
|
||||
///
|
||||
void stop() override;
|
||||
|
||||
///
|
||||
///
|
||||
/// Discovery audio devices
|
||||
///
|
||||
QJsonArray discover(const QJsonObject& params) override;
|
||||
|
||||
private:
|
||||
///
|
||||
///
|
||||
/// Refresh audio devices
|
||||
///
|
||||
void refreshDevices();
|
||||
|
||||
///
|
||||
///
|
||||
/// Configure current audio capture interface
|
||||
///
|
||||
bool configureCaptureInterface();
|
||||
|
||||
///
|
||||
///
|
||||
/// Get device name from path
|
||||
///
|
||||
QString getDeviceName(const QString& devicePath) const;
|
||||
|
||||
///
|
||||
///
|
||||
/// Current sample rate
|
||||
///
|
||||
unsigned int _sampleRate;
|
||||
|
||||
///
|
||||
///
|
||||
/// Audio capture thread
|
||||
///
|
||||
pthread_t _audioThread;
|
||||
|
||||
///
|
||||
///
|
||||
/// ALSA device configuration parameters
|
||||
///
|
||||
snd_pcm_hw_params_t * _captureDeviceConfig;
|
||||
};
|
||||
|
||||
///
|
||||
/// Audio processing thread function
|
||||
///
|
||||
static void* AudioThreadRunner(void* params);
|
||||
|
||||
#endif // AUDIOGRABBERLINUX_H
|
||||
|
@@ -555,7 +555,7 @@ namespace hyperion
|
||||
if (pixelNum > 0)
|
||||
{
|
||||
// initial cluster with different colors
|
||||
auto clusters = std::unique_ptr< ColorCluster<ColorRgbScalar> >(new ColorCluster<ColorRgbScalar>[_clusterCount]);
|
||||
std::unique_ptr<ColorCluster<ColorRgbScalar>[]> clusters(new ColorCluster<ColorRgbScalar>[_clusterCount]);
|
||||
for(int k = 0; k < _clusterCount; ++k)
|
||||
{
|
||||
clusters.get()[k].newColor = DEFAULT_CLUSTER_COLORS[k];
|
||||
|
Reference in New Issue
Block a user