2025-05-31 20:26:47 +02:00
|
|
|
#include "common/cpu_features.h"
|
2023-02-12 23:29:51 +01:00
|
|
|
#include "core/plugin.h"
|
|
|
|
|
#include "logger.h"
|
|
|
|
|
|
|
|
|
|
#include "dvbs/module_dvbs_demod.h"
|
|
|
|
|
#include "dvbs2/module_dvbs2_demod.h"
|
2024-03-04 16:15:39 +01:00
|
|
|
#include "dvbs2/module_s2_ts_extractor.h"
|
2023-02-12 23:29:51 +01:00
|
|
|
|
|
|
|
|
class DVBSupport : public satdump::Plugin
|
|
|
|
|
{
|
|
|
|
|
public:
|
2025-05-31 20:26:47 +02:00
|
|
|
std::string getID() { return "dvb_support"; }
|
2023-02-12 23:29:51 +01:00
|
|
|
|
|
|
|
|
void init()
|
|
|
|
|
{
|
2024-09-08 12:25:42 -04:00
|
|
|
#ifdef DVB_HAS_SSE41
|
|
|
|
|
if (!cpu_features::get_cpu_features().CPU_X86_SSE41)
|
|
|
|
|
{
|
|
|
|
|
logger->error("CPU Does not support SSE4_1. Extension plugin NOT loading!");
|
|
|
|
|
return;
|
|
|
|
|
}
|
|
|
|
|
#endif
|
2025-05-31 20:26:47 +02:00
|
|
|
|
|
|
|
|
satdump::eventBus->register_handler<satdump::pipeline::RegisterModulesEvent>(registerPluginsHandler);
|
2023-02-12 23:29:51 +01:00
|
|
|
}
|
|
|
|
|
|
2025-05-31 20:26:47 +02:00
|
|
|
static void registerPluginsHandler(const satdump::pipeline::RegisterModulesEvent &evt)
|
2023-02-12 23:29:51 +01:00
|
|
|
{
|
2025-05-31 20:26:47 +02:00
|
|
|
REGISTER_MODULE_EXTERNAL(evt.modules_registry, satdump::pipeline::dvb::DVBSDemodModule);
|
|
|
|
|
REGISTER_MODULE_EXTERNAL(evt.modules_registry, satdump::pipeline::dvb::DVBS2DemodModule);
|
2023-03-04 17:29:34 +00:00
|
|
|
REGISTER_MODULE_EXTERNAL(evt.modules_registry, dvbs2::S2TStoTCPModule);
|
2023-02-12 23:29:51 +01:00
|
|
|
}
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
PLUGIN_LOADER(DVBSupport)
|