Loading...
Searching...
No Matches
particleFieldAdapter.h
1//
2// Copyright 2025 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_USD_IMAGING_USD_VOL_IMAGING_PARTICLE_FIELD_ADAPTER_H
8#define PXR_USD_IMAGING_USD_VOL_IMAGING_PARTICLE_FIELD_ADAPTER_H
9
10#include "pxr/pxr.h"
11#include "pxr/usdImaging/usdVolImaging/api.h"
14
15PXR_NAMESPACE_OPEN_SCOPE
16
21 public:
23
24 // ---------------------------------------------------------------------- //
26 // ---------------------------------------------------------------------- //
27
28 USDVOLIMAGING_API
30 const UsdImagingInstancerContext* instancerContext = nullptr) override;
31
32 USDVOLIMAGING_API
33 bool IsSupported(const UsdImagingIndexProxy* index) const override;
34
35 // ---------------------------------------------------------------------- //
37 // ---------------------------------------------------------------------- //
38
39 USDVOLIMAGING_API
40 void TrackVariability(const UsdPrim& usdPrim, const SdfPath& cachePath,
41 HdDirtyBits* timeVaryingBits,
42 const UsdImagingInstancerContext* i_instancerContext = nullptr)
43 const override;
44
46 USDVOLIMAGING_API
47 void UpdateForTime(UsdPrim const& prim, SdfPath const& cachePath,
48 UsdTimeCode time, HdDirtyBits requestedBits,
49 UsdImagingInstancerContext const* instancerContext = nullptr)
50 const override;
51
52 // ---------------------------------------------------------------------- //
54 // ---------------------------------------------------------------------- //
55
56 USDVOLIMAGING_API
57 HdDirtyBits ProcessPropertyChange(const UsdPrim& usdPrim,
58 const SdfPath& cachePath, const TfToken& propertyName) override;
59
60 // ---------------------------------------------------------------------- //
62 // ---------------------------------------------------------------------- //
63
64 USDVOLIMAGING_API
65 VtValue Get(UsdPrim const& prim, SdfPath const& cachePath,
66 TfToken const& key, UsdTimeCode time,
67 VtIntArray* outIndices) const override;
68
70
71 USDVOLIMAGING_API
73
74 // ---------------------------------------------------------------------- //
76 // ---------------------------------------------------------------------- //
77
78 USDVOLIMAGING_API
79 TfTokenVector GetImagingSubprims(UsdPrim const& prim) override;
80
81 USDVOLIMAGING_API
82 TfToken GetImagingSubprimType(
83 UsdPrim const& prim, TfToken const& subprim) override;
84
85 USDVOLIMAGING_API
86 HdContainerDataSourceHandle GetImagingSubprimData(
87 UsdPrim const& prim, TfToken const& subprim,
88 const UsdImagingDataSourceStageGlobals& stageGlobals) override;
89
90 USDVOLIMAGING_API
91 HdDataSourceLocatorSet InvalidateImagingSubprim(
92 UsdPrim const& prim, TfToken const& subprim,
93 TfTokenVector const& properties,
94 UsdImagingPropertyInvalidationType invalidationType) override;
95};
96
97PXR_NAMESPACE_CLOSE_SCOPE
98
99#endif // HDPARTICLEFIELD_PARTICLEFIELD_ADAPTER_H
Represents a set of data source locators closed under descendancy.
A path value used to locate objects in layers or scenegraphs.
Definition: path.h:281
Token for efficient comparison, assignment, and hashing of known strings.
Definition: token.h:71
This class is used as a context object with global stage information, that gets passed down to dataso...
Delegate support for UsdGeomGrims.
Definition: gprimAdapter.h:32
This proxy class exposes a subset of the private Delegate API to PrimAdapters.
Definition: indexProxy.h:30
Adapter class for prims of type ParticleField.
USDVOLIMAGING_API void UpdateForTime(UsdPrim const &prim, SdfPath const &cachePath, UsdTimeCode time, HdDirtyBits requestedBits, UsdImagingInstancerContext const *instancerContext=nullptr) const override
Thread Safe.
USDVOLIMAGING_API HdDirtyBits ProcessPropertyChange(const UsdPrim &usdPrim, const SdfPath &cachePath, const TfToken &propertyName) override
Returns a bit mask of attributes to be updated, or HdChangeTracker::AllDirty if the entire prim must ...
USDVOLIMAGING_API void TrackVariability(const UsdPrim &usdPrim, const SdfPath &cachePath, HdDirtyBits *timeVaryingBits, const UsdImagingInstancerContext *i_instancerContext=nullptr) const override
Thread Safe.
USDVOLIMAGING_API bool IsSupported(const UsdImagingIndexProxy *index) const override
Returns true if the adapter can be populated into the target index.
USDVOLIMAGING_API SdfPath Populate(const UsdPrim &usdPrim, UsdImagingIndexProxy *index, const UsdImagingInstancerContext *instancerContext=nullptr) override
Called to populate the RenderIndex for this UsdPrim.
USDVOLIMAGING_API VtValue Get(UsdPrim const &prim, SdfPath const &cachePath, TfToken const &key, UsdTimeCode time, VtIntArray *outIndices) const override
Gets the value of the parameter named key for the given prim (which has the given cache path) and giv...
UsdPrim is the sole persistent scenegraph object on a UsdStage, and is the embodiment of a "Prim" as ...
Definition: prim.h:117
Represent a time value, which may be either numeric, holding a double value, or a sentinel value UsdT...
Definition: timeCode.h:72
Provides a container which may hold any type, and provides introspection and iteration over array typ...
Definition: value.h:90
Object used by instancer prim adapters to pass along context about the instancer and instance prim to...
std::vector< TfToken > TfTokenVector
Convenience types.
Definition: token.h:440