MayaFlux 0.4.0
Digital-First Multimedia Processing Framework
Loading...
Searching...
No Matches
PlotSource.cpp
Go to the documentation of this file.
1#include "PlotSource.hpp"
2
4
8
10
12 : m_container(std::make_shared<Kakshya::PlotContainer>())
13{
14}
15
17 std::string name,
18 uint64_t count,
20 Kakshya::DataModality modality)
21{
22 m_last_index = m_container->add_series(std::move(name), count, role, modality);
23 return *this;
24}
25
26Source& Source::from(std::shared_ptr<Nodes::Node> node)
27{
28 m_container->bind(m_last_index, std::move(node));
29 return *this;
30}
31
32Source& Source::from(std::shared_ptr<Buffers::AudioBuffer> buf)
33{
34 m_container->bind(m_last_index, std::move(buf));
35 return *this;
36}
37
38Source& Source::from(std::shared_ptr<Nodes::Network::NodeNetwork> net)
39{
40 m_container->bind(m_last_index, std::move(net));
41 return *this;
42}
43
44Source& Source::from(std::function<void(std::vector<double>&)> fn)
45{
46 m_container->bind(m_last_index, std::move(fn));
47 return *this;
48}
49
50std::shared_ptr<Kakshya::PlotContainer> Source::build()
51{
52 return std::move(m_container);
53}
54
55} // namespace MayaFlux::Portal::Forma::Plot
size_t count
std::shared_ptr< Kakshya::PlotContainer > build()
Finalise and return the constructed container.
Source & from(std::shared_ptr< Nodes::Node > node)
Bind a Node to the last series added by as().
Source & as(std::string name, uint64_t count, Kakshya::DataDimension::Role role, Kakshya::DataModality modality)
Add a named series and record its index for the next with() call.
std::shared_ptr< Kakshya::PlotContainer > m_container
Chainable builder for PlotContainer construction.
DataModality
Data modality types for cross-modal analysis.
Definition NDData.hpp:81
Role
Semantic role of the dimension.
Definition NDData.hpp:150