Blender V5.3
pipeline_from_collection.h
Go to the documentation of this file.
1/* SPDX-FileCopyrightText: 2024 Blender Authors
2 *
3 * SPDX-License-Identifier: GPL-2.0-or-later */
4
8
9#pragma once
10
11#include "pipeline.h"
12
13namespace blender {
14
15struct Collection;
16
17namespace deg {
18
19/* Optimized builders for dependency graph built from a given Collection.
20 *
21 * General notes:
22 *
23 * - We pull in all bases if their objects are in the set of IDs. This allows to have proper
24 * visibility and other flags assigned to the objects.
25 * All other bases (the ones which points to object which is outside of the set of IDs) are
26 * completely ignored.
27 */
28
30 public:
31 FromCollectionBuilderPipeline(blender::Depsgraph *graph, Collection *collection);
32
33 protected:
34 std::unique_ptr<DepsgraphNodeBuilder> construct_node_builder() override;
35 std::unique_ptr<DepsgraphRelationBuilder> construct_relation_builder() override;
36
37 void build_nodes(DepsgraphNodeBuilder &node_builder) override;
38 void build_relations(DepsgraphRelationBuilder &relation_builder) override;
39
40 private:
41 Set<ID *> ids_;
42};
43
44} // namespace deg
45} // namespace blender
void build_nodes(DepsgraphNodeBuilder &node_builder) override
FromCollectionBuilderPipeline(blender::Depsgraph *graph, Collection *collection)
void build_relations(DepsgraphRelationBuilder &relation_builder) override
std::unique_ptr< DepsgraphRelationBuilder > construct_relation_builder() override
std::unique_ptr< DepsgraphNodeBuilder > construct_node_builder() override
BMesh Iterators.