Split: Split libspinscale off from SMO.

Now we can probably begin using libspinscale in Couresilient
without worrying about excessive technical debt later on.
This commit is contained in:
2026-02-22 17:46:27 -04:00
parent 9361a43e40
commit 1c397dfeb5
22 changed files with 350 additions and 310 deletions
+24 -8
View File
@@ -5,24 +5,40 @@
#include <spinscale/asynchronousLoop.h>
#include <spinscale/callback.h>
#include <spinscale/callableTracer.h>
#include <spinscale/componentThread.h>
#include <mind.h>
#include <mindThread.h>
#include <director/director.h>
#include <simulator/simulator.h>
#include <stimBuffApis/stimBuffApiManager.h>
#include <spinscale/marionette.h>
#include <marionette/marionette.h>
namespace smo {
Mind::Mind(void)
: sscl::PuppetApplication(
std::vector<std::shared_ptr<sscl::PuppetThread>>{
std::make_shared<MindThread>(SmoThreadId::DIRECTOR),
std::make_shared<MindThread>(SmoThreadId::SIMULATOR),
std::make_shared<MindThread>(SmoThreadId::SUBCONSCIOUS),
std::make_shared<MindThread>(SmoThreadId::BODY)
std::make_shared<MindThread>(
SmoThreadId::DIRECTOR,
sscl::PuppetComponent::defaultPuppetMain, director,
&MindComponent::preJoltHook),
std::make_shared<MindThread>(
SmoThreadId::SIMULATOR,
sscl::PuppetComponent::defaultPuppetMain, canvas,
&MindComponent::preJoltHook),
std::make_shared<MindThread>(
SmoThreadId::SUBCONSCIOUS,
sscl::PuppetComponent::defaultPuppetMain, subconscious,
&MindComponent::preJoltHook),
std::make_shared<MindThread>(
SmoThreadId::BODY,
sscl::PuppetComponent::defaultPuppetMain, body,
&MindComponent::preJoltHook)
#ifndef CONFIG_WORLD_USE_BODY_THREAD
, std::make_shared<MindThread>(SmoThreadId::WORLD)
, std::make_shared<MindThread>(
SmoThreadId::WORLD,
sscl::PuppetComponent::defaultPuppetMain, world,
&MindComponent::preJoltHook)
#endif
}
),
@@ -223,7 +239,7 @@ void Mind::initializeReq(sscl::Callback<mindLifetimeMgmtOpCbFn> callback)
auto request = std::make_shared<MindLifetimeMgmtOp>(
*this, caller, callback);
sscl::pptr::mrntt.thread->getIoService().post(
mrntt::mrntt.thread->getIoService().post(
STC(std::bind(
&MindLifetimeMgmtOp::initializeReq1_posted,
request.get(), request)));
@@ -235,7 +251,7 @@ void Mind::finalizeReq(sscl::Callback<mindLifetimeMgmtOpCbFn> callback)
auto request = std::make_shared<MindLifetimeMgmtOp>(
*this, caller, callback);
sscl::pptr::mrntt.thread->getIoService().post(
mrntt::mrntt.thread->getIoService().post(
STC(std::bind(
&MindLifetimeMgmtOp::finalizeReq1_posted,
request.get(), request)));