24 #ifndef HDX_BOUNDINGBOX_TASK_H 25 #define HDX_BOUNDINGBOX_TASK_H 31 #include "pxr/imaging/hdx/api.h" 32 #include "pxr/imaging/hdx/task.h" 33 #include "pxr/imaging/hdx/tokens.h" 35 #include "pxr/imaging/hd/camera.h" 37 #include "pxr/imaging/hgi/attachmentDesc.h" 38 #include "pxr/imaging/hgi/buffer.h" 39 #include "pxr/imaging/hgi/graphicsCmds.h" 40 #include "pxr/imaging/hgi/graphicsPipeline.h" 41 #include "pxr/imaging/hgi/resourceBindings.h" 42 #include "pxr/imaging/hgi/shaderProgram.h" 43 #include "pxr/imaging/hgi/texture.h" 45 #include "pxr/usd/sdf/path.h" 47 PXR_NAMESPACE_OPEN_SCOPE
57 using BBoxVector = std::vector<GfBBox3d>;
90 void Prepare(HdTaskContext* ctx,
95 void Execute(HdTaskContext* ctx)
override;
102 HdDirtyBits* dirtyBits)
override;
110 bool _CreateShaderResources();
113 bool _CreateBufferResources();
116 bool _CreateResourceBindings();
119 bool _CreatePipeline(
120 const HgiTextureHandle& colorTexture,
121 const HgiTextureHandle& depthTexture);
128 void _UpdateShaderConstants(
135 const HgiTextureHandle& colorTexture,
136 const HgiTextureHandle& depthTexture,
140 void _DestroyShaderProgram();
143 void _PrintCompileErrors();
149 size_t _maxTransforms;
168 PXR_NAMESPACE_CLOSE_SCOPE
Basic type for a vector of 4 int components.
HDX_API void Execute(HdTaskContext *ctx) override
Execute the bounding box task.
The Hydra render index is a flattened representation of the client scene graph, which may be composed...
A graphics API independent abstraction of graphics commands.
Describes the properties of a framebuffer attachment.
AR_API bool operator!=(const ArAssetInfo &lhs, const ArAssetInfo &rhs)
A set of rendering parameters used among render passes.
AR_API bool operator==(const ArAssetInfo &lhs, const ArAssetInfo &rhs)
Token for efficient comparison, assignment, and hashing of known strings.
Stores a 4x4 matrix of double elements.
Adapter class providing data exchange with the client scene graph.
A task for rendering bounding boxes.
A path value used to locate objects in layers or scenegraphs.
Basic type for a vector of 4 float components.
Base class for (some) tasks in Hdx that provides common progressive rendering and Hgi functionality.
GF_API std::ostream & operator<<(std::ostream &, const GfBBox3d &)
Output a GfBBox3d using the format [(range) matrix zeroArea].
HDX_API void _Sync(HdSceneDelegate *delegate, HdTaskContext *ctx, HdDirtyBits *dirtyBits) override
Sync the render pass resources.
HDX_API void Prepare(HdTaskContext *ctx, HdRenderIndex *renderIndex) override
Prepare the bounding box task resources.
BoundingBoxTask parameters.