satdump/src-core/common/dsp/io/baseband_interface.cpp

26 lines
624 B
C++
Raw Normal View History

2022-05-03 23:53:23 +02:00
#include "baseband_interface.h"
namespace dsp
{
BasebandType basebandTypeFromString(std::string type)
{
if (type == "s16")
return IS_16;
else if (type == "s8")
return IS_8;
else if (type == "f32")
return CF_32;
else if (type == "u8")
return IU_8;
2022-09-16 17:10:28 -07:00
else if (type == "w16")
return WAV_16;
2022-05-03 23:53:23 +02:00
#ifdef BUILD_ZIQ
else if (type == "ziq")
return ZIQ;
#endif
2023-01-16 20:50:34 +01:00
else if (type == "ziq2")
return ZIQ2;
2022-05-03 23:53:23 +02:00
else
throw std::runtime_error("Unknown baseband type " + type);
}
}