mexvex_els_calculate.hh 661 Bytes
/**
 * mexvex_els_calculate.h   
 */

#ifndef MEXVEX_ELS_CALCULATE_HH_
#define MEXVEX_ELS_CALCULATE_HH_

#include <vector>

/**
 * @brief MEX/VEX ELS  decoding
 * @return  
 */
typedef std::vector<float> FloatVector;
typedef const FloatVector& RCFloatVector;

FloatVector mexvex_els_calculate(const std::vector<short>& ELS,const short& TimeCompres, const short& EnergyCompres, unsigned int Angle)
{
	FloatVector lElsCalculate;
	for (unsigned int iEn = 0; iEn < 128; iEn++) {// 128 Energy Steps
		lElsCalculate.push_back(((float)ELS[iEn + Angle *128])/(float)TimeCompres/(float)EnergyCompres);
	}
	return lElsCalculate;
}


#endif /* MEXVEX_ELS_CALCULATE_HH_ */