/*
- Copyright (C) 2012-2014 Carl Hetherington <cth@carlh.net>
+ Copyright (C) 2012-2021 Carl Hetherington <cth@carlh.net>
This file is part of DCP-o-matic.
*/
+
/** @file src/cinema_sound_processor.h
* @brief CinemaSoundProcessor class
*/
+
#ifndef DCPOMATIC_CINEMA_SOUND_PROCESSOR_H
#define DCPOMATIC_CINEMA_SOUND_PROCESSOR_H
+
#include <boost/utility.hpp>
+#include <memory>
#include <string>
#include <vector>
+
/** @class CinemaSoundProcessor
* @brief Class to describe a cimema's sound processor.
*
* In other words, the box in the rack that handles sound decoding and processing
* in a cinema.
*/
-class CinemaSoundProcessor : public boost::noncopyable
+class CinemaSoundProcessor
{
public:
CinemaSoundProcessor (std::string i, std::string n, float knee, float below, float above);
virtual ~CinemaSoundProcessor () {}
+ CinemaSoundProcessor (CinemaSoundProcessor const&) = delete;
+ CinemaSoundProcessor& operator=(CinemaSoundProcessor const&) = delete;
+
float db_for_fader_change (float from, float to) const;
/** @return id for our use */
static void setup_cinema_sound_processors ();
static CinemaSoundProcessor const * from_id (std::string id);
static CinemaSoundProcessor const * from_index (int);
- static int as_index (CinemaSoundProcessor const *);
private:
/** id for our use */
float _below;
float _above;
- /** sll available cinema sound processors */
- static std::vector<CinemaSoundProcessor const *> _cinema_sound_processors;
+ /** all available cinema sound processors */
+ static std::vector<std::unique_ptr<const CinemaSoundProcessor>> _cinema_sound_processors;
};
+
#endif