102#ifndef STEAM_ENGINE_PARAM_WEAVING_PATTERN_H
103#define STEAM_ENGINE_PARAM_WEAVING_PATTERN_H
123 using std::make_tuple;
139 template<
class ANCH,
typename...FUNZ>
157 template<
typename FUN>
161 using FunN = std::decay_t<FUN>;
163 ,make_tuple (forward<FUN>(paramFun)))};
166 template<
typename PAR>
175 template<
size_t slot>
179 return std::get<slot> (
functors_) (turnoutSys);
193 template<
size_t slot>
227 return std::apply ([&](
auto&&... paramFun)
229 return ChainCons::build (paramFun (turnoutSys) ...);
238 std::apply ([&](
auto&&... paramFun)
240 ChainCons::emplace (storage, paramFun (turnoutSys) ...);
308 builder.emplaceParamDataBlock (&
block(), turnoutSys);
Block of raw uninitialised storage with array like access.
Handle for a buffer for processing data, abstracting away the actual implementation.
void emplaceParamDataBlock(void *storage, TurnoutSystem &turnoutSys)
invoke all parameter-functors and package all results by placement-new into a »chain-block«
ChainCons::NewFrame buildParamDataBlock(TurnoutSystem &turnoutSys)
invoke all parameter-functors and drop off the result into a »chain-block« (non-copyable)
BlockBuilder(Functors &&funz)
virtual BuffHandle weave(TurnoutSystem &, OptionalBuff=std::nullopt)=0
Communication hub to coordinate and activate the »Render Node Network« performance.
auto & retrieveData(ACC const &getter)
void attachChainBlock(CHAIN &chainBlock)
attach an extension block with further parameters as HeteroData-chain to the embedded FrontBlock
void detachChainBlock(CHAIN &chainBlock)
Types marked with this mix-in may be moved but not copied.
Any copy and copy construction prohibited.
Metaprogramming tools for detecting and transforming function types.
std::optional< BuffHandle > OptionalBuff
Steam-Layer implementation namespace root.
Basic set of definitions and includes commonly used together.
a (static) getter functor able to work on the full extended HeteroData-Chain
static auto & getParamVal(TurnoutSystem &turnoutSys)
Specification record for the setup of a »Param Agent Node«.
auto invokeParamFun(TurnoutSystem &turnoutSys)
intended for unit-testing: invoke one of the embedded param-functors
auto addValSlot(PAR paramVal)
tuple< FUNZ... > Functors
Tuple< ResTypes > ParamTup
auto addSlot(FUN &¶mFun)
ElmTypes< Functors >::template Apply< lib::meta::_FunRet > ResTypes
ParamBuildSpec(Functors &&funz)
BlockBuilder makeBlockBuilder()
Terminal Builder: (destructively) transform this ParamBuildSpec into a BlockBuilder,...
ParamBuildSpec clone()
can be copied if all functors are copyable...
Accessor< idx > makeAccessor()
lib::meta::RebindVariadic< ANCH::template Chain, ParamTup >::Type ChainCons
Storage data frame placed on the call stack.
void emplaceParamDataBlock(BlockBuilder &builder, TurnoutSystem &turnoutSys)
lib::UninitialisedStorage< DataBlock > buffer
Implementation for a Weaving Pattern to conduct extended parameter evaluation.
BuffHandle fix(Feed &feed, TurnoutSystem &turnoutSys)
clean-up: detach the parameter-data-block.
SPEC::ChainCons::NewFrame DataBlock
BlockBuilder blockBuilder_
PostProcessor postProcess_
void weft(Feed &feed, TurnoutSystem &turnoutSys)
recursively invoke the delegate port, while the generated parameter-data is indirectly reachable thro...
void shed(Feed &feed, TurnoutSystem &turnoutSys, OptionalBuff outBuff)
Link the param-data-block into the current TurnoutSystem, possibly post-process the param data.
SPEC::BlockBuilder BlockBuilder
ParamWeavingPattern(BlockBuilder builder, PostProcessor postProc, Port &delegate)
forwarding-ctor to used from within Turnout, to provide actual setup.
function< void(TurnoutSystem &)> PostProcessor
Feed mount(TurnoutSystem &)
Preparation: create a Feed data frame to use as local scope.
friend auto _accessInternal(ParamWeavingPattern &patt)
void pull(Feed &feed, TurnoutSystem &turnoutSys)
Invoke the parameter-functors to create the basic parameter data.
Metaprogramming with tuples-of-types and the std::tuple record.
A actual state of a rendering evaluation parametrised for a single job.
Fixed standard setup used in each Port of the Render Node to generate data.
A raw memory block with proper alignment and array access.
Metaprogramming support to rebuild and rebind variadic templates.