7#ifndef PXR_IMAGING_HD_INSTANCING_AWARE_COLLECTION_EXPRESSION_EVALUATOR_H
8#define PXR_IMAGING_HD_INSTANCING_AWARE_COLLECTION_EXPRESSION_EVALUATOR_H
11#include "pxr/imaging/hd/api.h"
13#include "pxr/imaging/hd/collectionExpressionEvaluator.h"
17#include "pxr/usd/sdf/path.h"
19PXR_NAMESPACE_OPEN_SCOPE
82 const HdInstanceProxyViewSceneIndexRefPtr &proxyViewSceneIndex,
107 bool includeInstanceProxyMatches =
false)
const;
132 bool includeInstanceProxyMatches,
139 void _CollectProxyMatches(
141 bool includeProxyPaths,
144 SdfPathSet *matchedProxyPaths)
const;
150 void _TraverseProxyDescendants(
152 SdfPathSet *proxyPaths)
const;
166PXR_NAMESPACE_CLOSE_SCOPE
Evaluates SdfPathExpressions with prims from a given HdSceneIndex.
bool IsEmpty() const
Returns true if the evaluator has an invalid scene index or an empty underlying SdfPathExpressionEval...
MatchKind
Option to configure the paths returned by PopulateMatches.
A scene index that provides a topological view of the scene as though instancing were not being used.
A wrapper around HdCollectionExpressionEvaluator that uses the "unrolled" instance proxy view of the ...
SdfPathSet nonInstanceMatches
Paths of prims that matched the expression excluding outermost instance prim paths.
HD_API MatchResult GetAllMatches(const SdfPath &rootPath, HdCollectionExpressionEvaluator::MatchKind matchKind, bool includeInstanceProxyMatches=false) const
Convenience wrapper that calls AppendAllMatches() on a default-constructed MatchResult and returns it...
SdfPathSet partiallyMatchedInstances
Outermost instance prim paths where SOME but not all instance proxy descendants match the expression.
HD_API SdfPredicateFunctionResult Match(const SdfPath &path) const
Evaluates the expression at path using the evaluator backed by the proxy view's input scene.
bool IsEmpty() const
Returns true if the evaluator that uses the proxy view's input scene has no valid scene index or expr...
HD_API HdInstancingAwareCollectionExpressionEvaluator(const HdInstanceProxyViewSceneIndexRefPtr &proxyViewSceneIndex, const SdfPathExpression &expr, const HdCollectionPredicateLibrary &predicateLib)
Constructs an evaluator for expr evaluated against the input scene of proxyViewSceneIndex using predi...
SdfPathSet matchedInstanceProxyPaths
Instance proxy prim paths that matched the expression.
HD_API void AppendAllMatches(const SdfPath &rootPath, HdCollectionExpressionEvaluator::MatchKind matchKind, bool includeInstanceProxyMatches, MatchResult *const result) const
Accumulates two-pass match results into result.
SdfPathSet fullyMatchedInstances
Outermost instance prim paths where ALL instance proxy descendants match the expression.
HdInstancingAwareCollectionExpressionEvaluator()=default
Default constructor. Constructs an empty evaluator.
Result type for AppendAllMatches.
Objects of this class represent a logical expression syntax tree consisting of SdfPathPattern s,...
A path value used to locate objects in layers or scenegraphs.
Represents the result of a predicate function: a pair of the boolean result and a Constancy token ind...
Represents a library of predicate functions for use with SdfPredicateExpression.
Pointer storage with deletion detection.
Standard pointer typedefs.
#define TF_DECLARE_REF_PTRS(type)
Define standard ref pointer types.
Pointer storage with deletion detection.