mirror of
https://github.com/hyperion-project/hyperion.ng.git
synced 2025-03-01 10:33:28 +00:00
Removed bootsequence library
Former-commit-id: 5f3f927236a26ae00299a8e7a914e98ace3b328a
This commit is contained in:
@@ -3,7 +3,6 @@ add_executable(hyperiond
|
||||
hyperiond.cpp)
|
||||
|
||||
target_link_libraries(hyperiond
|
||||
bootsequence
|
||||
hyperion
|
||||
xbmcvideochecker
|
||||
effectengine
|
||||
|
@@ -15,9 +15,6 @@
|
||||
// Hyperion includes
|
||||
#include <hyperion/Hyperion.h>
|
||||
|
||||
// Bootsequence includes
|
||||
#include <bootsequence/BootSequenceFactory.h>
|
||||
|
||||
#ifdef ENABLE_DISPMANX
|
||||
// Dispmanx grabber includes
|
||||
#include <dispmanx-grabber/DispmanxWrapper.h>
|
||||
@@ -96,14 +93,20 @@ int main(int argc, char** argv)
|
||||
std::cout << "Hyperion created and initialised" << std::endl;
|
||||
|
||||
// create boot sequence if the configuration is present
|
||||
BootSequence * bootSequence = nullptr;
|
||||
if (config.isMember("bootsequence"))
|
||||
{
|
||||
bootSequence = BootSequenceFactory::createBootSequence(&hyperion, config["bootsequence"]);
|
||||
const Json::Value effectConfig = config["bootsequence"];
|
||||
|
||||
if (bootSequence != nullptr)
|
||||
// Get the parameters for the bootsequence
|
||||
const std::string effectName = effectConfig["effect"].asString();
|
||||
const unsigned duration_ms = effectConfig["duration_ms"].asUInt();
|
||||
const int priority = 0;
|
||||
|
||||
// int retVal = -1;
|
||||
// QMetaObject::invokeMethod(hyperion, "setEffect", Q_RETURN_ARG(int, retVal), Q_ARG(std::string, effectName), Q_ARG(Json::Value, Json::Value()), Q_ARG(int, priority), Q_ARG(int, duration_ms));
|
||||
// if (retVal == 0)
|
||||
if (hyperion.setEffect(effectName, Json::Value(), priority, duration_ms) == 0)
|
||||
{
|
||||
bootSequence->start();
|
||||
std::cout << "Boot sequence created and started" << std::endl;
|
||||
}
|
||||
}
|
||||
@@ -185,7 +188,6 @@ int main(int argc, char** argv)
|
||||
std::cout << "Application closed with code " << rc << std::endl;
|
||||
|
||||
// Delete all component
|
||||
delete bootSequence;
|
||||
#ifdef ENABLE_DISPMANX
|
||||
delete dispmanx;
|
||||
#endif
|
||||
|
Reference in New Issue
Block a user