24 #ifndef PXR_USD_IMAGING_USD_IMAGING_GL_DRAW_MODE_ADAPTER_H
25 #define PXR_USD_IMAGING_USD_IMAGING_GL_DRAW_MODE_ADAPTER_H
28 #include "pxr/usdImaging/usdImagingGL/api.h"
31 PXR_NAMESPACE_OPEN_SCOPE
47 ~UsdImagingGLDrawModeAdapter()
override;
59 bool ShouldCullChildren()
const override;
67 bool CanPopulateUsdInstance()
const override;
76 HdDirtyBits* timeVaryingBits,
78 instancerContext = NULL)
const override;
84 HdDirtyBits requestedBits,
86 instancerContext = NULL)
const override;
95 TfToken const& property)
override;
98 void MarkDirty(
UsdPrim const& prim,
104 void MarkTransformDirty(
UsdPrim const& prim,
109 void MarkVisibilityDirty(
UsdPrim const& prim,
114 void MarkMaterialDirty(
UsdPrim const& prim,
127 VtIntArray *outIndices)
const override;
153 bool ignoreRootTransform =
false)
const override;
167 void _RemovePrim(
SdfPath const& cachePath,
173 void _SanityCheckFaceSizes(
SdfPath const& cachePath,
174 GfRange3d const& extents, uint8_t axes_mask)
177 void _ComputeGeometryData(
UsdPrim const& prim,
188 bool _IsMaterialPath(
SdfPath const& path)
const;
191 bool _IsTexturePath(
SdfPath const& path)
const;
194 bool _HasVaryingExtent(
UsdPrim const& prim)
const;
197 void _CheckForTextureVariability(
UsdPrim const& prim,
198 HdDirtyBits dirtyBits,
199 HdDirtyBits *timeVaryingBits)
const;
216 GfRange3d const& extents, uint8_t axes_mask)
const;
220 GfRange3d const& extents, uint8_t axes_mask)
const;
223 void _GenerateCardsFromTextureGeometry(
VtValue* topo,
VtValue* points,
234 uint8_t axes_mask)
const;
237 using _DrawModeMap = TfHashMap<SdfPath, TfToken, SdfPath::Hash>;
238 _DrawModeMap _drawModeMap;
246 PXR_NAMESPACE_CLOSE_SCOPE
248 #endif // PXR_USD_IMAGING_USD_IMAGING_GL_DRAW_MODE_ADAPTER_H
Basic type: 3-dimensional floating point range.
USDIMAGINGGL_API HdCullStyle GetCullStyle(UsdPrim const &prim, SdfPath const &cachePath, UsdTimeCode time) const override
Gets the cullstyle of a specific path in the scene graph.
USDIMAGINGGL_API void TrackVariability(UsdPrim const &prim, SdfPath const &cachePath, HdDirtyBits *timeVaryingBits, UsdImagingInstancerContext const *instancerContext=NULL) const override
For the given prim, variability is detected and stored in timeVaryingBits.
SdfPath Populate(UsdPrim const &prim, UsdImagingIndexProxy *index, UsdImagingInstancerContext const *instancerContext=NULL) override
Called to populate the RenderIndex for this UsdPrim.
bool IsSupported(UsdImagingIndexProxy const *index) const override
Returns true if the adapter can be populated into the target index.
Basic type for a vector of 3 float components.
USDIMAGINGGL_API bool GetDoubleSided(UsdPrim const &prim, SdfPath const &cachePath, UsdTimeCode time) const override
Reads double-sided from the given prim. If not authored, returns false.
This proxy class exposes a subset of the private Delegate API to PrimAdapters.
Scenegraph object for authoring and retrieving numeric, string, and array valued data, sampled over time.
USDIMAGINGGL_API VtValue GetTopology(UsdPrim const &prim, SdfPath const &cachePath, UsdTimeCode time) const override
Gets the topology object of a specific Usd prim.
Token for efficient comparison, assignment, and hashing of known strings.
Stores a 4x4 matrix of double elements.
Represent a time value, which may be either numeric, holding a double value, or a sentinel value UsdT...
Base class for all PrimAdapters.
UsdPrim is the sole persistent scenegraph object on a UsdStage, and is the embodiment of a "Prim" as ...
USDIMAGINGGL_API void UpdateForTime(UsdPrim const &prim, SdfPath const &cachePath, UsdTimeCode time, HdDirtyBits requestedBits, UsdImagingInstancerContext const *instancerContext=NULL) const override
Populates the cache for the given prim, time and requestedBits.
A path value used to locate objects in layers or scenegraphs.
USDIMAGINGGL_API GfMatrix4d GetTransform(UsdPrim const &prim, SdfPath const &cachePath, UsdTimeCode time, bool ignoreRootTransform=false) const override
Fetches the transform for the given prim at the given time from a pre-computed cache of prim transfor...
USDIMAGINGGL_API GfRange3d GetExtent(UsdPrim const &prim, SdfPath const &cachePath, UsdTimeCode time) const override
Reads the extent from the given prim.
Object used by instancer prim adapters to pass along context about the instancer and instance prim to...
USDIMAGINGGL_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...
USDIMAGINGGL_API HdDirtyBits ProcessPropertyChange(UsdPrim const &prim, SdfPath const &cachePath, TfToken const &property) override
Returns a bit mask of attributes to be updated, or HdChangeTracker::AllDirty if the entire prim must ...
Provides a container which may hold any type, and provides introspection and iteration over array typ...
Delegate support for the drawMode attribute on UsdGeomModelAPI.