HDK
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
pickTask.h
Go to the documentation of this file.
1 //
2 // Copyright 2019 Pixar
3 //
4 // Licensed under the terms set forth in the LICENSE.txt file available at
5 // https://openusd.org/license.
6 //
7 #ifndef PXR_IMAGING_HDX_PICK_TASK_H
8 #define PXR_IMAGING_HDX_PICK_TASK_H
9 
10 #include "pxr/pxr.h"
11 #include "pxr/imaging/hdx/api.h"
12 
15 #include "pxr/imaging/hd/enums.h"
20 #include "pxr/imaging/hd/task.h"
21 
22 #include "pxr/base/arch/align.h"
24 #include "pxr/base/gf/matrix4d.h"
25 #include "pxr/base/gf/vec2i.h"
26 #include "pxr/base/gf/vec2f.h"
27 #include "pxr/base/gf/vec4i.h"
28 #include "pxr/base/gf/vec4d.h"
29 #include "pxr/usd/sdf/path.h"
30 
31 #include <vector>
32 #include <memory>
33 
35 
36 #define HDX_PICK_TOKENS \
37  /* Task context */ \
38  (pickParams) \
39  \
40  /* Pick target */ \
41  (pickPrimsAndInstances) \
42  (pickFaces) \
43  (pickEdges) \
44  (pickPoints) \
45  (pickPointsAndInstances) \
46  \
47  /* Resolve mode */ \
48  (resolveNearestToCamera) \
49  (resolveNearestToCenter) \
50  (resolveUnique) \
51  (resolveAll) \
52  (resolveDeep)
53 
55 
56 class HdStRenderBuffer;
58 using HdStShaderCodeSharedPtr = std::shared_ptr<class HdStShaderCode>;
59 
60 class Hgi;
61 
62 /// Pick task params. This contains render-style state (for example), but is
63 /// augmented by HdxPickTaskContextParams, which is passed in on the task
64 /// context.
66 {
69  , enableSceneMaterials(true)
70  {}
71 
74 };
75 
76 /// Picking hit structure. This is output by the pick task as a record of
77 /// what objects the picking query found.
78 struct HdxPickHit
79 {
80  /// delegateID of HdSceneDelegate that provided the picked prim.
81  /// Irrelevant for scene indices.
83  /// Path computed from scenePath's in primOrigin data source of
84  /// picked prim and instancers if provided by scene index.
85  /// Otherwise, path in render index.
87  /// Only supported for scene delegates, see HdxPrimOriginInfo for
88  /// scene indices.
92  int edgeIndex;
96  /// normalizedDepth is in the range [0,1]. Nb: the pick depth buffer won't
97  /// contain items drawn with materialTag "displayInOverlay" for simplicity.
99 
100  inline bool IsValid() const {
101  return !objectId.IsEmpty();
102  }
103 
104  HDX_API
105  size_t GetHash() const;
106 };
107 
108 using HdxPickHitVector = std::vector<HdxPickHit>;
109 
110 /// Information about an instancer instancing a picked object (or an
111 /// instancer instancing such an instancer and so on).
113 {
114  /// The path of the instancer in the scene index.
116  /// The prim origin data source of the instancer.
117  HdContainerDataSourceHandle instancerPrimOrigin;
118 
119  /// For implicit instancing (native instancing in USD), the path of
120  /// the picked instance in the scene index.
122 
123  /// The prim origin data source of the picked (implicit) instance
124  ///
125  /// Note that typically, exactly one of instancePrimOrigin
126  /// or instancerPrimOrigin will contain data depending on whether
127  /// the instancing at the current level was implicit or not,
128  /// respectively. This is because for implicit instancing, there is no
129  /// authored instancer in the original scene (e.g., no USD instancer
130  /// prim for USD native instancing).
131  ///
132  /// For non-nested implicit instancing, the scenePath of the
133  /// instancePrimOrigin will be an absolute path.
134  /// For nested implicit instancing, the scenePath of the instancePrimOrigin
135  /// is an absolute path for the outer instancer context and a relative
136  /// path otherwise.
137  /// The relative path corresponds to an instance within a prototype that
138  /// was itself instanced. It is relative to the prototype's root.
139  ///
140  HdContainerDataSourceHandle instancePrimOrigin;
141  /// Index of the picked instance.
143 };
144 
145 /// A helper to extract information about the picked prim that allows
146 /// modern applications to identify a prim and, e.g., obtain the scene path
147 /// such as the path of the corresponding UsdPrim.
148 ///
149 /// Note that this helper assumes that we use scene indices and that the
150 /// primOrigin data source was populated for each pickable prim in the
151 /// scene index. Typically, an application will populate the scenePath in the
152 /// primOrigin data source. But the design allows an application to populate
153 /// the primOrigin container data source with arbitrary data that helps to
154 /// give context about a prim and identify the picked prim.
155 ///
156 /// Note that legacy applications using scene delegates cannot use
157 /// HdxPrimOriginInfo and have to translate the scene index path to a scene
158 /// path using the scene delegate API
159 /// HdSceneDelegate::GetScenePrimPath and
160 /// HdSceneDelegate::ConvertIndexPathToCachePath.
161 ///
163 {
164  /// Query terminal scene index of render index for information about
165  /// picked prim.
166  HDX_API
167  static HdxPrimOriginInfo
168  FromPickHit(HdRenderIndex * renderIndex,
169  const HdxPickHit &hit);
170 
171  /// Vectorized implementation of function to query terminal scene index
172  /// of render index for information about picked prim. Amortizes the cost
173  /// of computing the array of all instace indices and locations for
174  /// instancers.
175  HDX_API
176  static std::vector<HdxPrimOriginInfo>
177  FromPickHits(HdRenderIndex * renderIndex,
178  const std::vector<HdxPickHit> &hits);
179 
180  /// Combines instance scene paths and prim scene path to obtain the full
181  /// scene path.
182  ///
183  /// The scene path is extracted from the prim origin container data
184  /// source by using the given key.
185  ///
186  HDX_API
188  const TfToken &nameInPrimOrigin =
189  HdPrimOriginSchemaTokens->scenePath) const;
190 
191  /// Computes an HdInstancerContext object (equivalent to the one computed
192  /// by GetScenePrimPath) from the vector of HdxInstancerContext objects.
193  /// Note that while HdxInstancerContext has a wealth of data about both
194  /// scene instancers and hydra-created instancers, HdInstancerContext
195  /// is meant to be just a list of (scene instancer, local instance id)
196  /// tuples, used by some clients (e.g. usdview) for selection processing.
197  HDX_API
199  const TfToken &nameInPrimOrigin =
200  HdPrimOriginSchemaTokens->scenePath) const;
201 
202  /// Information about the instancers instancing the picked object.
203  /// The outer most instancer will be first.
204  std::vector<HdxInstancerContext> instancerContexts;
205  /// The prim origin data source for the picked prim if provided
206  /// by the scene index.
207  HdContainerDataSourceHandle primOrigin;
208 };
209 
210 /// Pick task context params. This contains task params that can't come from
211 /// the scene delegate (like resolution mode and pick location, that might
212 /// be resolved late), as well as the picking collection and the output
213 /// hit vector.
214 /// 'pickTarget': The target of the pick operation, which may influence the
215 /// data filled in the HdxPickHit(s).
216 /// The available options are:
217 /// HdxPickTokens->pickPrimsAndInstances
218 /// HdxPickTokens->pickFaces
219 /// HdxPickTokens->pickEdges
220 /// HdxPickTokens->pickPoints
221 /// HdxPickTokens->pickPointsAndInstances
222 ///
223 /// 'resolveMode': Dictates the resolution of which hit(s) are returned in
224 /// 'outHits'.
225 /// The available options are:
226 /// 1. HdxPickTokens->resolveNearestToCamera : Returns the hit whose
227 /// position is nearest to the camera
228 /// 2. HdxPickTokens->resolveNearestToCenter : Returns the hit whose
229 /// position is nearest to center of the pick location/region.
230 /// 3. HdxPickTokens->resolveUnique : Returns the unique hits, by hashing
231 /// the relevant member fields of HdxPickHit. The 'pickTarget'
232 /// influences this operation. For e.g., the subprim indices are ignored
233 /// when the pickTarget is pickPrimsAndInstances.
234 /// 4. HdxPickTokens->resolveAll: Returns all the hits for the pick location
235 /// or region. The number of hits returned depends on the resolution
236 /// used and may have duplicates.
237 /// 5. HdxPickTokens->resolveDeep: Returns the unique hits not only of visible
238 /// geometry but also of all the geometry hiding behind. The 'pickTarget'
239 /// influences this operation. For e.g., the subprim indices are ignored
240 /// when the pickTarget is pickPrimsAndInstances.
241 ///
243 {
244  using DepthMaskCallback = std::function<void(void)>;
245 
247  : resolution(128, 128)
248  , maxNumDeepEntries(32000)
249  , pickTarget(HdxPickTokens->pickPrimsAndInstances)
250  , resolveMode(HdxPickTokens->resolveNearestToCamera)
251  , doUnpickablesOcclude(false)
252  , viewMatrix(1)
253  , projectionMatrix(1)
254  , clipPlanes()
255  , depthMaskCallback(nullptr)
256  , collection()
257  , alphaThreshold(0.0001f)
258  , outHits(nullptr)
259  {}
260 
268  std::vector<GfVec4d> clipPlanes;
273 };
274 
275 /// \class HdxPickTask
276 ///
277 /// A task for running picking queries against the current scene.
278 /// This task generates an id buffer for a "pick frustum" (normally the
279 /// camera frustum with the near plane narrowed to an (x,y) location and a
280 /// pick radius); then it resolves that id buffer into a series of prim paths.
281 /// The "Hit" output also contains subprim picking results (e.g. picked face,
282 /// edge, point, instance) and the intersection point in scene worldspace.
283 ///
284 /// HdxPickTask takes an HdxPickTaskParams through the scene delegate, and
285 /// HdxPickTaskContextParams through the task context as "pickParams".
286 /// It produces a hit vector, in the task context as "pickHits".
287 class HdxPickTask : public HdTask
288 {
289 public:
291 
292  HDX_API
293  HdxPickTask(HdSceneDelegate* delegate, SdfPath const& id);
294 
295  HDX_API
296  ~HdxPickTask() override;
297 
298  /// Sync the render pass resources
299  HDX_API
300  void Sync(HdSceneDelegate* delegate,
301  HdTaskContext* ctx,
302  HdDirtyBits* dirtyBits) override;
303 
304  /// Prepare the pick task
305  HDX_API
306  void Prepare(HdTaskContext* ctx,
307  HdRenderIndex* renderIndex) override;
308 
309  /// Execute the pick task
310  HDX_API
311  void Execute(HdTaskContext* ctx) override;
312 
313  HDX_API
314  const TfTokenVector &GetRenderTags() const override;
315 
316  /// Utility: Given a UNorm8Vec4 pixel, unpack it into an int32 ID.
317  static inline int DecodeIDRenderColor(unsigned char const idColor[4]) {
318  return (int32_t(idColor[0] & 0xff) << 0) |
319  (int32_t(idColor[1] & 0xff) << 8) |
320  (int32_t(idColor[2] & 0xff) << 16) |
321  (int32_t(idColor[3] & 0xff) << 24);
322  }
323 
324 private:
325  HdxPickTaskParams _params;
326  HdxPickTaskContextParams _contextParams;
327  TfTokenVector _renderTags;
328  bool _useOverlayPass;
329 
330  // We need to cache a pointer to the render index so Execute() can
331  // map prim ID to paths.
332  HdRenderIndex *_index;
333 
334  void _InitIfNeeded();
335  void _CreateAovBindings();
336  void _CleanupAovBindings();
337  void _ResizeOrCreateBufferForAOV(
338  const HdRenderPassAovBinding& aovBinding);
339 
340  void _ConditionStencilWithGLCallback(
342  HdRenderBuffer const * depthStencilBuffer);
343 
344  bool _UseOcclusionPass() const;
345  bool _UseOverlayPass() const;
346  void _UpdateUseOverlayPass();
347 
348  void _ClearPickBuffer();
349  void _ResolveDeep();
350 
351  template<typename T>
353  _ReadAovBuffer(TfToken const & aovName) const;
354 
355  HdRenderBuffer const * _FindAovBuffer(TfToken const & aovName) const;
356 
357  // Create a shared render pass each for pickables, unpickables, and
358  // items in overlay (which may draw on top even when occluded).
359  HdRenderPassSharedPtr _pickableRenderPass;
360  HdRenderPassSharedPtr _occluderRenderPass;
361  HdRenderPassSharedPtr _overlayRenderPass;
362 
363  // Having separate render pass states allows us to use different
364  // shader mixins if we choose to (we don't currently).
365  HdRenderPassStateSharedPtr _pickableRenderPassState;
366  HdRenderPassStateSharedPtr _occluderRenderPassState;
367  HdRenderPassStateSharedPtr _overlayRenderPassState;
368 
369  Hgi* _hgi;
370 
371  std::vector<std::unique_ptr<HdStRenderBuffer>> _pickableAovBuffers;
372  HdRenderPassAovBindingVector _pickableAovBindings;
373  HdRenderPassAovBinding _occluderAovBinding;
374  size_t _pickableDepthIndex;
375  TfToken _depthToken;
376  std::unique_ptr<HdStRenderBuffer> _overlayDepthStencilBuffer;
377  HdRenderPassAovBindingVector _overlayAovBindings;
378 
379  // pick buffer used for deep selection
380  HdBufferArrayRangeSharedPtr _pickBuffer;
381 
382  HdxPickTask() = delete;
383  HdxPickTask(const HdxPickTask &) = delete;
384  HdxPickTask &operator =(const HdxPickTask &) = delete;
385 };
386 
387 /// A utility class for resolving ID buffers into hits.
389 public:
390 
391  // Pick result takes a tuple of ID buffers:
392  // - (primId, instanceId, elementId, edgeId, pointId)
393  // along with some geometric buffers:
394  // - (depth, Neye)
395  // ... and resolves them into a series of hits, using one of the
396  // algorithms specified below.
397  //
398  // index is used to fill in the HdxPickHit structure;
399  // pickTarget is used to determine what a valid hit is;
400  // viewMatrix, projectionMatrix, depthRange are used for unprojection
401  // to calculate the worldSpaceHitPosition and worldSpaceHitNormal.
402  // bufferSize is the size of the ID buffers, and subRect is the sub-region
403  // of the id buffers to iterate over in the resolution algorithm.
404  //
405  // All buffers need to be the same size, if passed in. It's legal for
406  // only the depth and primId buffers to be provided; everything else is
407  // optional but provides a richer picking result.
408  HDX_API
409  HdxPickResult(int const* primIds,
410  int const* instanceIds,
411  int const* elementIds,
412  int const* edgeIds,
413  int const* pointIds,
414  int const* neyes,
415  float const* depths,
416  HdRenderIndex const *index,
417  TfToken const& pickTarget,
418  GfMatrix4d const& viewMatrix,
419  GfMatrix4d const& projectionMatrix,
420  GfVec2f const& depthRange,
421  GfVec2i const& bufferSize,
422  GfVec4i const& subRect);
423 
424  HDX_API
425  ~HdxPickResult();
426 
427  HDX_API
428  HdxPickResult(HdxPickResult &&);
429  HDX_API
430  HdxPickResult& operator=(HdxPickResult &&);
431 
432  /// Return whether the result was given well-formed parameters.
433  HDX_API
434  bool IsValid() const;
435 
436  /// Return the nearest single hit point. Note that this method may be
437  /// considerably more efficient, as it only needs to construct a single
438  /// Hit object.
439  HDX_API
440  void ResolveNearestToCamera(HdxPickHitVector* allHits) const;
441 
442  /// Return the nearest single hit point from the center of the viewport.
443  /// Note that this method may be considerably more efficient, as it only
444  /// needs to construct a single Hit object.
445  HDX_API
446  void ResolveNearestToCenter(HdxPickHitVector* allHits) const;
447 
448  /// Return all hit points. Note that this may contain redundant objects,
449  /// however it allows access to all depth values for a given object.
450  HDX_API
451  void ResolveAll(HdxPickHitVector* allHits) const;
452 
453  /// Return the set of unique hit points, keeping only the nearest depth
454  /// value.
455  HDX_API
456  void ResolveUnique(HdxPickHitVector* allHits) const;
457 
458 private:
459  bool _ResolveHit(int index, int x, int y, float z, HdxPickHit* hit) const;
460 
461  size_t _GetHash(int index) const;
462  bool _IsValidHit(int index) const;
463 
464  // Provide accessors for all of the ID buffers. Since all but _primIds
465  // are optional, if the buffer doesn't exist just return -1 (== no hit).
466  int _GetPrimId(int index) const {
467  return _primIds ? _primIds[index] : -1;
468  }
469  int _GetInstanceId(int index) const {
470  return _instanceIds ? _instanceIds[index] : -1;
471  }
472  int _GetElementId(int index) const {
473  return _elementIds ? _elementIds[index] : -1;
474  }
475  int _GetEdgeId(int index) const {
476  return _edgeIds ? _edgeIds[index] : -1;
477  }
478  int _GetPointId(int index) const {
479  return _pointIds ? _pointIds[index] : -1;
480  }
481 
482  // Provide an accessor for the normal buffer. If the normal buffer is
483  // provided, this function will unpack the normal. The fallback is
484  // GfVec3f(0.0f).
485  GfVec3f _GetNormal(int index) const;
486 
487  int const* _primIds;
488  int const* _instanceIds;
489  int const* _elementIds;
490  int const* _edgeIds;
491  int const* _pointIds;
492  int const* _neyes;
493  float const* _depths;
494  HdRenderIndex const *_index;
495  TfToken _pickTarget;
496  GfMatrix4d _ndcToWorld;
497  GfMatrix4d _eyeToWorld;
498  GfVec2f _depthRange;
499  GfVec2i _bufferSize;
500  GfVec4i _subRect;
501 };
502 
503 // For sorting, order hits by ndc depth.
504 HDX_API
505 bool operator<(HdxPickHit const& lhs, HdxPickHit const& rhs);
506 
507 // VtValue requirements
508 HDX_API
509 std::ostream& operator<<(std::ostream& out, const HdxPickHit& h);
510 HDX_API
511 bool operator==(const HdxPickHit& lhs,
512  const HdxPickHit& rhs);
513 HDX_API
514 bool operator!=(const HdxPickHit& lhs,
515  const HdxPickHit& rhs);
516 
517 HDX_API
518 std::ostream& operator<<(std::ostream& out, const HdxPickTaskParams& pv);
519 HDX_API
520 bool operator==(const HdxPickTaskParams& lhs,
521  const HdxPickTaskParams& rhs);
522 HDX_API
523 bool operator!=(const HdxPickTaskParams& lhs,
524  const HdxPickTaskParams& rhs);
525 
526 HDX_API
527 std::ostream& operator<<(std::ostream& out, const HdxPickTaskContextParams& pv);
528 HDX_API
529 bool operator==(const HdxPickTaskContextParams& lhs,
530  const HdxPickTaskContextParams& rhs);
531 HDX_API
532 bool operator!=(const HdxPickTaskContextParams& lhs,
533  const HdxPickTaskContextParams& rhs);
535 
536 #endif // PXR_IMAGING_HDX_PICK_TASK_H
bool enableSceneMaterials
Definition: pickTask.h:73
Definition: vec4i.h:43
HdCullStyle cullStyle
Definition: pickTask.h:72
std::shared_ptr< class HdRenderPassState > HdRenderPassStateSharedPtr
Definition: engine.h:25
GfVec3f worldSpaceHitNormal
Definition: pickTask.h:95
std::shared_ptr< class HdStShaderCode > HdStShaderCodeSharedPtr
HdCullStyle
Definition: enums.h:105
int instanceId
Index of the picked instance.
Definition: pickTask.h:142
HDX_API size_t GetHash() const
Definition: vec2i.h:43
std::shared_ptr< class HdRenderPass > HdRenderPassSharedPtr
Definition: engine.h:24
int edgeIndex
Definition: pickTask.h:92
SdfPath delegateId
Definition: pickTask.h:82
uint32_t HdDirtyBits
Definition: types.h:143
HDX_API void Execute(HdTaskContext *ctx) override
Execute the pick task.
SdfPath objectId
Definition: pickTask.h:86
int pointIndex
Definition: pickTask.h:93
std::vector< HdxPickHit > HdxPickHitVector
Definition: pickTask.h:108
GLdouble GLdouble GLdouble z
Definition: glcorearb.h:848
Definition: vec3f.h:45
HDX_API void ResolveUnique(HdxPickHitVector *allHits) const
bool IsEmpty() const noexcept
Returns true if this is the empty path (SdfPath::EmptyPath()).
Definition: path.h:398
GLint y
Definition: glcorearb.h:103
GfVec3d worldSpaceHitPoint
Definition: pickTask.h:94
#define HDX_API
Definition: api.h:23
SdfPath instancerId
Definition: pickTask.h:89
HdxPickHitVector * outHits
Definition: pickTask.h:272
#define HDX_PICK_TOKENS
Definition: pickTask.h:36
TF_DECLARE_PUBLIC_TOKENS(HdxPickTokens, HDX_API, HDX_PICK_TOKENS)
HDX_API HdInstancerContext ComputeInstancerContext(const TfToken &nameInPrimOrigin=HdPrimOriginSchemaTokens->scenePath) const
DepthMaskCallback depthMaskCallback
Definition: pickTask.h:269
std::vector< std::pair< SdfPath, int > > HdInstancerContext
Instancer context: a pair of instancer paths and instance indices.
Definition: sceneDelegate.h:44
HDX_API void ResolveNearestToCenter(HdxPickHitVector *allHits) const
GLfloat f
Definition: glcorearb.h:1926
Definition: token.h:70
HDX_API ~HdxPickTask() override
float normalizedDepth
Definition: pickTask.h:98
bool operator!=(const Mat3< T0 > &m0, const Mat3< T1 > &m1)
Inequality operator, does exact floating point comparisons.
Definition: Mat3.h:556
static HDX_API HdxPrimOriginInfo FromPickHit(HdRenderIndex *renderIndex, const HdxPickHit &hit)
HDX_API ~HdxPickResult()
HDX_API HdxPickResult & operator=(HdxPickResult &&)
std::vector< TfToken > TfTokenVector
Convenience types.
Definition: token.h:440
int instanceIndex
Definition: pickTask.h:90
HDX_API void ResolveAll(HdxPickHitVector *allHits) const
A utility class for resolving ID buffers into hits.
Definition: pickTask.h:388
HDX_API SdfPath GetFullPath(const TfToken &nameInPrimOrigin=HdPrimOriginSchemaTokens->scenePath) const
Definition: task.h:43
Definition: path.h:273
GLint GLenum GLint x
Definition: glcorearb.h:409
HDX_API const TfTokenVector & GetRenderTags() const override
HDX_API std::ostream & operator<<(std::ostream &out, const HdxPickHit &h)
std::unordered_map< TfToken, VtValue, TfToken::HashFunctor > HdTaskContext
Definition: renderIndex.h:61
HdContainerDataSourceHandle primOrigin
Definition: pickTask.h:207
GfMatrix4d projectionMatrix
Definition: pickTask.h:267
HDX_API void Sync(HdSceneDelegate *delegate, HdTaskContext *ctx, HdDirtyBits *dirtyBits) override
Sync the render pass resources.
Definition: hgi.h:93
HDX_API void Prepare(HdTaskContext *ctx, HdRenderIndex *renderIndex) override
Prepare the pick task.
GLfloat GLfloat GLfloat GLfloat h
Definition: glcorearb.h:2002
HDX_API bool IsValid() const
Return whether the result was given well-formed parameters.
static HDX_API std::vector< HdxPrimOriginInfo > FromPickHits(HdRenderIndex *renderIndex, const std::vector< HdxPickHit > &hits)
PXR_NAMESPACE_CLOSE_SCOPE PXR_NAMESPACE_OPEN_SCOPE
Definition: path.h:1425
HDX_API HdxPickResult(int const *primIds, int const *instanceIds, int const *elementIds, int const *edgeIds, int const *pointIds, int const *neyes, float const *depths, HdRenderIndex const *index, TfToken const &pickTarget, GfMatrix4d const &viewMatrix, GfMatrix4d const &projectionMatrix, GfVec2f const &depthRange, GfVec2i const &bufferSize, GfVec4i const &subRect)
Definition: vec2f.h:45
GLuint index
Definition: glcorearb.h:786
Definition: vec3d.h:45
static int DecodeIDRenderColor(unsigned char const idColor[4])
Utility: Given a UNorm8Vec4 pixel, unpack it into an int32 ID.
Definition: pickTask.h:317
HDX_API bool operator<(HdxPickHit const &lhs, HdxPickHit const &rhs)
HdContainerDataSourceHandle instancePrimOrigin
Definition: pickTask.h:140
#define PXR_NAMESPACE_CLOSE_SCOPE
Definition: pxr.h:74
std::shared_ptr< HdBufferArrayRange > HdBufferArrayRangeSharedPtr
Definition: bufferArray.h:27
SdfPath instancerSceneIndexPath
The path of the instancer in the scene index.
Definition: pickTask.h:115
std::vector< GfVec4d > clipPlanes
Definition: pickTask.h:268
int elementIndex
Definition: pickTask.h:91
std::vector< HdRenderPassAovBinding > HdRenderPassAovBindingVector
Definition: aov.h:137
bool IsValid() const
Definition: pickTask.h:100
std::vector< HdxInstancerContext > instancerContexts
Definition: pickTask.h:204
HdRprimCollection collection
Definition: pickTask.h:270
HDX_API void ResolveNearestToCamera(HdxPickHitVector *allHits) const
HdContainerDataSourceHandle instancerPrimOrigin
The prim origin data source of the instancer.
Definition: pickTask.h:117
bool operator==(const Mat3< T0 > &m0, const Mat3< T1 > &m1)
Equality operator, does exact floating point comparisons.
Definition: Mat3.h:542
SdfPath instanceSceneIndexPath
Definition: pickTask.h:121
std::function< void(void)> DepthMaskCallback
Definition: pickTask.h:244