|
HDK
|
#include <isolatedSubnetwork.h>
Public Types | |
| using | ConnectionSet = pxr_tsl::robin_set< VdfConnection *, TfHash > |
| A set of isolated connections. More... | |
| using | EditFilter = TfFunctionRef< bool(const VdfNode *)> |
Public Member Functions | |
| VdfIsolatedSubnetwork (const VdfIsolatedSubnetwork &)=delete | |
| VdfIsolatedSubnetwork & | operator= (const VdfIsolatedSubnetwork &)=delete |
| VDF_API | ~VdfIsolatedSubnetwork () |
| VDF_API bool | AddIsolatedBranch (VdfConnection *connection, EditFilter canDelete) |
| VDF_API bool | AddIsolatedBranch (VdfNode *node, EditFilter canDelete) |
| VDF_API void | RemoveIsolatedObjectsFromNetwork () |
| const std::vector< VdfNode * > & | GetIsolatedNodes () const |
| Returns the set of isolated nodes. More... | |
| const ConnectionSet & | GetIsolatedConnections () const |
| Returns the set of isolated nodes. More... | |
Static Public Member Functions | |
| static VDF_API std::unique_ptr < VdfIsolatedSubnetwork > | IsolateBranch (VdfConnection *connection, EditFilter canDelete) |
| static VDF_API std::unique_ptr < VdfIsolatedSubnetwork > | IsolateBranch (VdfNode *node, EditFilter canDelete) |
| static VDF_API std::unique_ptr < VdfIsolatedSubnetwork > | New (VdfNetwork *network) |
A VdfIsolatedSubnetwork builds a collection of VdfNodes and VdfConnections that are disconnected from the owning network.
Building an isolated subnetwork proceeds in three phases:
Definition at line 48 of file isolatedSubnetwork.h.
A set of isolated connections.
Definition at line 58 of file isolatedSubnetwork.h.
| using VdfIsolatedSubnetwork::EditFilter = TfFunctionRef<bool(const VdfNode *)> |
A function that returns true if the given node is allowed to be isolated and deleted.
Definition at line 62 of file isolatedSubnetwork.h.
|
delete |
| VDF_API VdfIsolatedSubnetwork::~VdfIsolatedSubnetwork | ( | ) |
| VDF_API bool VdfIsolatedSubnetwork::AddIsolatedBranch | ( | VdfConnection * | connection, |
| EditFilter | canDelete | ||
| ) |
Isolates all nodes and connections reachable via input connections from connection that are not connected via additional output connections to other parts of the network.
Note that connection is added to the set of isolated objects.
The canDelete object is used to prune the traversal.
| VDF_API bool VdfIsolatedSubnetwork::AddIsolatedBranch | ( | VdfNode * | node, |
| EditFilter | canDelete | ||
| ) |
Isolates all nodes and connections reachable via input connections from node that are not connected via additional output connections to other parts of the network.
The canDelete object is used to prune the traversal.
node has output connections or canDelete returns false for node, no objects are added to the isolated subnetwork and false is returned.
|
inline |
Returns the set of isolated nodes.
Definition at line 159 of file isolatedSubnetwork.h.
|
inline |
Returns the set of isolated nodes.
Definition at line 154 of file isolatedSubnetwork.h.
|
static |
Isolates all nodes and connections reachable via input connections from connection that are not connected via additional output connections to other parts of the network.
Note that connection is added to the set of isolated objects.
The canDelete object is used to prune the traversal.
Removes the isolated objects from the network and returns a unique pointer to the isolated network object that holds onto the isolated nodes and connections. When the isolated network object is deleted, the isolated nodes and connections are deleted.
|
static |
Isolates all nodes and connections reachable via input connections from node that are not connected via additional output connections to other parts of the network.
The canDelete object is used to prune the traversal.
Removes the isolated objects from the network and returns a strong reference to the isolated network object that holds onto the isolated nodes and connections. When the isolated network object is deleted, the isolated nodes and connections are deleted.
node has output connections.
|
static |
Creates an empty isolated subnetwork.
The subnetwork can be populated via calls to the AddIsolatedBranch methods.
|
delete |
Removes all isolated objects from the network.
This method is called upon destruction, if it isn't called before then.