15 #include <vsg/io/FileSystem.h>
16 #include <vsg/io/Options.h>
17 #include <vsg/nodes/Node.h>
18 #include <vsg/vk/Semaphore.h>
40 template<
class N,
class V>
41 static void t_traverse(N& node, V& visitor)
43 for (
auto& child : node.children)
45 if (child.node) child.node->accept(visitor);
49 void traverse(
Visitor& visitor)
override { t_traverse(*
this, visitor); }
50 void traverse(
ConstVisitor& visitor)
const override { t_traverse(*
this, visitor); }
51 void traverse(
RecordTraversal& visitor)
const override { t_traverse(*
this, visitor); }
55 void read(
Input& input)
override;
56 void write(
Output& output)
const override;
60 double minimumScreenHeightRatio = 0.0;
69 using Children = std::array<Child, 2>;
72 bool highResActive(uint64_t frameCount, uint64_t inactiveAge = 3)
const
74 return (frameCount - frameHighResLastUsed.load()) <= inactiveAge;
84 mutable std::atomic<double> priority{0.0};
86 mutable std::atomic_uint64_t frameHighResLastUsed{0};
87 mutable std::atomic_uint requestCount{0};
89 enum RequestStatus :
unsigned int
101 mutable std::atomic<RequestStatus> requestStatus{NoRequest};
102 mutable uint32_t index = 0;
104 ref_ptr<Node> pending;
122 uint32_t previous = 0;
125 List* list =
nullptr;
128 using Elements = std::vector<Element>;
135 void resize(uint32_t new_size);
137 void inactive(
const PagedLOD* plod);
144 bool check(
const List& list);
146 void print(std::ostream& out);
Definition: ConstVisitor.h:147
Definition: PagedLOD.h:36
int compare(const Object &rhs) const override
compare two objects, return -1 if this object is less than rhs, return 0 if it's equal,...
RecordTraversal traverses a scene graph doing view frustum culling and invoking state/commands to rec...
Definition: RecordTraversal.h:61
Definition: Visitor.h:147
Definition: PagedLOD.h:121
Definition: PagedLOD.h:113
Definition: PagedLOD.h:109
Definition: PagedLOD.h:59