Ejemplo n.º 1
0
bool Fan::verifyAndSpecifyTypes(Types const& _inTypes, Types& _outTypes)
{
	Typed<Spectrum> in = _inTypes[0];
	if (!in) return false;
	m_outBins = in->bins() / _outTypes.count();
	// Should be FreqSteppedSpectrum with offset if possible.
	// In general add a method to Spectrum to get a new type based on subset.
	_outTypes = Spectrum(m_outBins, in->frequency());
	return true;
}
Ejemplo n.º 2
0
bool DeciBel::verifyAndSpecifyTypes(Types const& _inTypes, Types& _outTypes)
{
	Typed<Spectrum> in = _inTypes[0];
	if (!in) return false;

	m_min = in->min();
	m_delta = in->max() - m_min;
	m_bins = in->bins();
	in->setRange(0, 60);
	_outTypes[0] = in;

	return true;
}