computePipeline.h
1 //
2 // Copyright 2020 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_HGI_COMPUTE_PIPELINE_H
8 #define PXR_IMAGING_HGI_COMPUTE_PIPELINE_H
9 
10 #include "pxr/pxr.h"
11 #include "pxr/imaging/hgi/api.h"
12 #include "pxr/imaging/hgi/attachmentDesc.h"
13 #include "pxr/imaging/hgi/enums.h"
14 #include "pxr/imaging/hgi/handle.h"
15 #include "pxr/imaging/hgi/resourceBindings.h"
16 #include "pxr/imaging/hgi/shaderProgram.h"
17 #include "pxr/imaging/hgi/types.h"
18 
19 #include <string>
20 #include <vector>
21 
22 PXR_NAMESPACE_OPEN_SCOPE
23 
24 
35  HGI_API
37 
38  uint32_t byteSize;
39 };
40 
41 HGI_API
42 bool operator==(
45 
46 HGI_API
47 bool operator!=(
50 
63 {
64  HGI_API
66 
67  std::string debugName;
68  HgiShaderProgramHandle shaderProgram;
69  HgiComputeShaderConstantsDesc shaderConstantsDesc;
70 };
71 
72 HGI_API
73 bool operator==(
74  const HgiComputePipelineDesc& lhs,
75  const HgiComputePipelineDesc& rhs);
76 
77 HGI_API
78 bool operator!=(
79  const HgiComputePipelineDesc& lhs,
80  const HgiComputePipelineDesc& rhs);
81 
82 
93 {
94 public:
95  HGI_API
96  virtual ~HgiComputePipeline();
97 
99  HGI_API
100  HgiComputePipelineDesc const& GetDescriptor() const;
101 
102 protected:
103  HGI_API
105 
106  HgiComputePipelineDesc _descriptor;
107 
108 private:
109  HgiComputePipeline() = delete;
110  HgiComputePipeline & operator=(const HgiComputePipeline&) = delete;
111  HgiComputePipeline(const HgiComputePipeline&) = delete;
112 };
113 
115 using HgiComputePipelineHandleVector = std::vector<HgiComputePipelineHandle>;
116 
117 
118 PXR_NAMESPACE_CLOSE_SCOPE
119 
120 #endif
AR_API bool operator!=(const ArAssetInfo &lhs, const ArAssetInfo &rhs)
AR_API bool operator==(const ArAssetInfo &lhs, const ArAssetInfo &rhs)
Describes the properties needed to create a GPU compute pipeline.
Represents a graphics platform independent GPU compute pipeline resource.
A small, but fast buffer of uniform data for shaders.
HGI_API HgiComputePipelineDesc const & GetDescriptor() const
The descriptor describes the object.