Object stubs updated to new client / parameter relationship

src/FluidBufCompose/FluidBufCompose.cpp
src/FluidBufHPSS/FluidBufHPSS.cpp
src/FluidBufNMF/FluidBufNMF.cpp
src/FluidBufNoveltySlice/FluidBufNoveltySlice.cpp
src/FluidBufSines/FluidBufSines.cpp
src/FluidBufTransients/FluidBufTransients.cpp
src/FluidBufTransientSlice/FluidBufTransientSlice.cpp
src/FluidGain/FluidGain.cpp
src/FluidHPSS/FluidHPSS.cpp
src/FluidNMFMatch/FluidNMFMatch.cpp
src/FluidSines/FluidSines.cpp
src/FluidSTFTPass/FluidSTFTPass.cpp
src/FluidTransients/FluidTransients.cpp
src/FluidTransientSlice/FluidTransientSlice.cpp
nix
Owen Green 7 years ago
parent d42034c911
commit 1d204f97b5

@ -1,74 +1,14 @@
// FD_BufNMF, an NRT buffer NMF Processor
// A tool from the FluCoMa project, funded by the European Research Council (ERC) under the European Unions Horizon 2020 research and innovation programme (grant agreement No 725899)
#include "clients/nrt/BufferComposeNRT.hpp"
#include "fdNRTBase.hpp"
#include "data/FluidTensor.hpp"
#include "clients/common/FluidParams.hpp"
#include "SC_PlugIn.h"
#include <unordered_set>
#include <vector>
#include <clients/nrt/BufferComposeNRT.hpp>
#include <FluidSCWrapper.hpp>
static InterfaceTable *ft;
namespace fluid {
namespace wrapper{
class BufCompose: public NRTCommandBase
{
public:
using client_type = client::BufferComposeClient;
using NRTCommandBase::NRTCommandBase;
~BufCompose() {}
void runCommand(World* world, void* replyAddr, char* completionMsgData, size_t completionMsgSize)
{
cmd<BufCompose, &BufCompose::process, &BufCompose::postProcess, &BufCompose::postComplete>(world, "/BufCompose", replyAddr, completionMsgData, completionMsgSize);
}
bool process(World* world)
{
//sanity check the parameters
bool parametersOk;
client_type::ProcessModel processModel;
std::string whatHappened;//this will give us a message to pass back if param check fails
std::tie(parametersOk,whatHappened,processModel) = bufferCompose.sanityCheck();
if(!parametersOk)
{
Print("fdCompose: %s \n", whatHappened.c_str());
return false;
}
bufferCompose.process(processModel);
mModel = processModel;
return true;
}
bool postProcess(World* world)
{
static_cast<SCBufferView*>(mModel.dst)->assignToRT(world);
return true;
}
bool postComplete(World* w) {
static_cast<SCBufferView*>(mModel.dst)->cleanUp();
return true;
}
std::vector<client::Instance>& parameters()
{
return bufferCompose.getParams();
}
private:
client_type bufferCompose;
client_type::ProcessModel mModel;
};//class
} //namespace wrapper
}//namespace fluid
PluginLoad(OfflineFluidDecompositionUGens) {
ft = inTable;
registerCommand<fluid::wrapper::BufCompose,fluid:: client::BufferComposeClient>(ft, "BufCompose");
fluid::wrapper::printCmd<fluid::client::BufferComposeClient>(ft,"BufCompose","FDCompose");
using namespace fluid::client;
makeSCWrapper<BufferComposeClient, float,float>("BufCompose", BufComposeParams, ft);
// registerCommand<fluid::wrapper::BufCompose,fluid:: client::BufferComposeClient>(ft, "BufCompose");
// fluid::wrapper::printCmd<fluid::client::BufferComposeClient>(ft,"BufCompose","FDCompose");
}

@ -2,7 +2,6 @@
// A tool from the FluCoMa project, funded by the European Research Council (ERC) under the European Unions Horizon 2020 research and innovation programme (grant agreement No 725899)
#include <clients/rt/HPSSClient.hpp>
#include <clients/nrt/FluidNRTClientWrapper.hpp>
#include <FluidSCWrapper.hpp>
static InterfaceTable *ft;
@ -10,5 +9,5 @@ static InterfaceTable *ft;
PluginLoad(OfflineFluidDecompositionUGens) {
ft = inTable;
using namespace fluid::client;
makeSCWrapper<NRTStreamAdaptor<HPSSClient<double,float>>>(ft, "BufHPSS");
makeSCWrapper<NRTHPSS,double,float>("BufHPSS",NRTHPSSParams,ft);
}

@ -6,5 +6,5 @@ static InterfaceTable *ft;
PluginLoad(OfflineFluidDecompositionUGens) {
ft = inTable;
using namespace fluid::client;
makeSCWrapper<NMFClient>(ft, "BufNMF");
makeSCWrapper<NMFClient,double,float>("BufNMF",NMFParams, ft);
}

@ -10,5 +10,5 @@ static InterfaceTable* ft;
PluginLoad(OfflineFluidDecompositionUGens) {
ft = inTable;
using namespace fluid::client;
makeSCWrapper<NoveltyClient>(ft, "BufNoveltySlice");
makeSCWrapper<NoveltyClient,double,float>("BufNoveltySlice",NoveltyParams,ft);
}

@ -10,6 +10,6 @@ static InterfaceTable *ft;
PluginLoad(OfflineFluidDecompositionUGens) {
ft = inTable;
using namespace fluid::client;
makeSCWrapper<NRTStreamAdaptor<SinesClient<double,float>>>(ft, "BufSines");
makeSCWrapper<NRTSines,double,float>("BufSines",NRTSineParams,ft);
}

@ -10,6 +10,5 @@ static InterfaceTable* ft;
PluginLoad(OfflineFluidDecompositionUGens) {
ft = inTable;
using namespace fluid::client;
makeSCWrapper<NRTSliceAdaptor<TransientsSlice<double,float>>>(ft, "BufTransientSlice");
makeSCWrapper<NRTTransientSlice,double,float>("BufTransientSlice",NRTTransientSliceParams, ft);
}

@ -7,5 +7,5 @@ static InterfaceTable *ft;
PluginLoad(OfflineFluidDecompositionUGens) {
ft = inTable;
using namespace fluid::client;
makeSCWrapper<NRTStreamAdaptor<TransientClient<double,float>>>(ft,"BufTransients");
makeSCWrapper<NRTTransients,double,float>("BufTransients",NRTTransientParams,ft);
}

@ -9,5 +9,5 @@ static InterfaceTable *ft;
PluginLoad(FluidGainUgen) {
ft = inTable;
using namespace fluid::client;
makeSCWrapper<GainClient<double,float>>(ft, "FluidGain");
makeSCWrapper<GainClient,double,float>("FluidGain", GainParams,ft);
}

@ -8,7 +8,7 @@ static InterfaceTable *ft;
PluginLoad(FluidSTFTUGen) {
ft = inTable;
using namespace fluid::client;
makeSCWrapper<HPSSClient<double,float>>(ft, "FluidHPSS");
makeSCWrapper<HPSSClient,double,float>("FluidHPSS",HPSSParams,ft);
}

@ -9,7 +9,7 @@ static InterfaceTable *ft;
PluginLoad(FluidSTFTUGen) {
ft = inTable;
using namespace fluid::client;
makeSCWrapper<NMFMatch<double, float>>(ft, "FluidNMFMatch");
makeSCWrapper<NMFMatch,double, float>("FluidNMFMatch",NMFMatchParams,ft);
}

@ -9,5 +9,5 @@ static InterfaceTable *ft;
PluginLoad(FluidSTFTUGen) {
ft = inTable;
using namespace fluid::client;
makeSCWrapper<BaseSTFTClient<double,float>>(ft, "FluidSTFTPass");
makeSCWrapper<BaseSTFTClient,double,float>("FluidSTFTPass",STFTParams,ft);
}

@ -9,6 +9,6 @@ static InterfaceTable *ft;
PluginLoad(FluidSTFTUGen) {
ft = inTable;
using namespace fluid::client;
makeSCWrapper<SinesClient<double,float>>(ft, "FluidSines");
makeSCWrapper<SinesClient,double,float>("FluidSines",SinesParams,ft);
}

@ -9,5 +9,5 @@ static InterfaceTable *ft;
PluginLoad(FluidSTFTUGen) {
ft = inTable;
using namespace fluid::client;
makeSCWrapper<TransientsSlice<double,float>>(ft, "FluidTransientSlice");
makeSCWrapper<TransientsSlice,double,float>("FluidTransientSlice",TransientParams,ft);
}

@ -1,16 +1,13 @@
// A tool from the FluCoMa project, funded by the European Research Council (ERC) under the European Unions Horizon 2020 research and innovation programme (grant agreement No 725899)
#include <clients/rt/TransientClient.hpp>
#include <FluidSCWrapper.hpp>
static InterfaceTable *ft;
PluginLoad(FluidSTFTUGen) {
ft = inTable;
// registerUnit<fluid::wrapper::FluidTransients>(ft, "FluidTransients");
using namespace fluid::client;
makeSCWrapper<TransientClient<double,float>>(ft, "FluidTransients");
makeSCWrapper<TransientClient, double, float>("FluidTransients", TransientParams, ft);
}

Loading…
Cancel
Save