#include "upmixer_a.h"
#include "audio_buffers.h"
#include "audio_mapping.h"
-#include <boost/make_shared.hpp>
#include "i18n.h"
using std::string;
using std::min;
using std::vector;
-using boost::shared_ptr;
-using boost::make_shared;
+using std::shared_ptr;
UpmixerA::UpmixerA (int sampling_rate)
: _left (0.02, 1900.0 / sampling_rate, 4800.0 / sampling_rate)
shared_ptr<AudioProcessor>
UpmixerA::clone (int sampling_rate) const
{
- return make_shared<UpmixerA> (sampling_rate);
+ return shared_ptr<AudioProcessor> (new UpmixerA (sampling_rate));
}
shared_ptr<AudioBuffers>
/* Mix of L and R; -6dB down in amplitude (3dB in terms of power) */
shared_ptr<AudioBuffers> in_LR = in_L->clone ();
- in_LR->accumulate_frames (in_R.get(), 0, 0, in_R->frames ());
+ in_LR->accumulate_frames (in_R.get(), in_R->frames(), 0, 0);
in_LR->apply_gain (-6);
/* Run filters */
all_out.push_back (_ls.run (in_L));
all_out.push_back (_rs.run (in_R));
- shared_ptr<AudioBuffers> out = make_shared<AudioBuffers> (channels, in->frames ());
+ shared_ptr<AudioBuffers> out (new AudioBuffers (channels, in->frames ()));
int const N = min (channels, 6);
for (int i = 0; i < N; ++i) {
}
}
-vector<string>
+vector<NamedChannel>
UpmixerA::input_names () const
{
- vector<string> n;
- n.push_back (_("Upmix L"));
- n.push_back (_("Upmix R"));
+ vector<NamedChannel> n;
+ n.push_back (NamedChannel(_("Upmix L"), 0));
+ n.push_back (NamedChannel(_("Upmix R"), 1));
return n;
}