7#ifndef HDX_VISUALIZE_AOV_TASK_H
8#define HDX_VISUALIZE_AOV_TASK_H
12#include "pxr/imaging/hdx/api.h"
13#include "pxr/imaging/hdx/task.h"
14#include "pxr/imaging/hdx/tokens.h"
15#include "pxr/imaging/hgi/attachmentDesc.h"
16#include "pxr/imaging/hgi/buffer.h"
17#include "pxr/imaging/hgi/graphicsPipeline.h"
18#include "pxr/imaging/hgi/resourceBindings.h"
19#include "pxr/imaging/hgi/shaderProgram.h"
20#include "pxr/imaging/hgi/texture.h"
21#include "pxr/usd/sdf/path.h"
23PXR_NAMESPACE_OPEN_SCOPE
61 void Execute(HdTaskContext* ctx)
override;
67 HdDirtyBits* dirtyBits)
override;
85 bool _UpdateVizKernel(
TfToken const &aovName);
88 TfToken const& _GetTextureIdentifierForShader()
const;
91 TfToken const& _GetFragmentMixin()
const;
95 bool _CreateShaderResources(
HgiTextureDesc const& inputAovTextureDesc);
98 bool _CreateBufferResources();
110 bool _CreateOutputTexture(
GfVec3i const &dimensions);
113 void _DestroyShaderProgram();
116 void _PrintCompileErrors();
127 GfVec3i _outputTextureDimensions;
138 float _screenSize[2];
139 float _minMaxDepth[2];
140 VizKernel _vizKernel;
171PXR_NAMESPACE_CLOSE_SCOPE
Basic type for a vector of 3 int components.
The Hydra render index is a flattened representation of the client scene graph, which may be composed...
Adapter class providing data exchange with the client scene graph.
Base class for (some) tasks in Hdx that provides common progressive rendering and Hgi functionality.
A task for visualizing non-color AOVs such as depth, normals, primId.
HDX_API void Prepare(HdTaskContext *ctx, HdRenderIndex *renderIndex) override
Prepare Phase: Resolve bindings and manage resources.
HDX_API void Execute(HdTaskContext *ctx) override
Execute Phase: Runs the task.
A path value used to locate objects in layers or scenegraphs.
Token for efficient comparison, assignment, and hashing of known strings.
GF_API std::ostream & operator<<(std::ostream &, const GfBBox3d &)
Output a GfBBox3d using the format [(range) matrix zeroArea].
aovName: The name of the aov to visualize.
Describes the properties of a framebuffer attachment.
Describes the properties needed to create a GPU texture.