Lumiera  0.pre.03
»edit your freedom«
node-graph-attachment.hpp
Go to the documentation of this file.
1 /*
2  NODE-GRAPH-ATTACHMENT.hpp - Binding from a Fixture-Segment into the low-level-Model
3 
4  Copyright (C)
5  2023, Hermann Vosseler <Ichthyostega@web.de>
6 
7   **Lumiera** is free software; you can redistribute it and/or modify it
8   under the terms of the GNU General Public License as published by the
9   Free Software Foundation; either version 2 of the License, or (at your
10   option) any later version. See the file COPYING for further details.
11 
12 */
13 
14 
27 #ifndef STEAM_FIXTURE_NODE_GRAPH_ATTACHMENT_H
28 #define STEAM_FIXTURE_NODE_GRAPH_ATTACHMENT_H
29 
31 //#include "lib/time/timevalue.hpp"
32 #include "lib/util.hpp"
33 
34 #include <utility>
35 
36 namespace steam {
37 namespace fixture {
38 
39  using engine::ExitNode;
40  using engine::ExitNodes;
41 
42 
55  {
56  ExitNodes exitNodes_;
57 
58  public:
60  : exitNodes_{}
61  { }
62 
63  NodeGraphAttachment (ExitNodes&& exitNodes)
64  : exitNodes_{std::move (exitNodes)}
65  { }
66 
67  // default copy acceptable
68 
69  ExitNode const&
70  operator[] (size_t idx) const
71  {
72  return idx < exitNodes_.size()? exitNodes_[idx]
73  : ExitNode::NIL;
74  }
75 
76  bool
77  empty() const
78  {
79  return util::isnil (exitNodes_);
80  }
81  };
82 
83 
84 
85 }} // namespace steam::fixture
86 #endif /*STEAM_FIXTURE_NODE_GRAPH_ATTACHMENT_H*/
Effective top-level exit point to pull rendered data from the nodes network.
Steam-Layer implementation namespace root.
A top-level point in the render node network where data generation can be driven. ...
Definition: exit-node.hpp:63
Tiny helper functions and shortcuts to be used everywhere Consider this header to be effectively incl...
Binding and access point from a given Segment to access the actual render nodes.
static ExitNode NIL
storage for the »inactive« ExitNode marker
Definition: exit-node.hpp:94