13 #ifndef RV_VKPipeline_h
14 #define RV_VKPipeline_h
62 {(uint32_t)rect.
width(),
101 UT_ASSERT(
false &&
"Unrecognized Topology Type used for Pipeline");
182 myRenderPassInfo = info;
206 bool myIsVertexInputDynamic =
false;
213 bool myIsTopologyDynamic =
false;
216 bool myIsPrimRestartDynamic =
false;
217 bool myPrimitiveRestartEnable =
false;
220 bool myHasTesselation =
false;
221 bool myIsControlPointsDynamic =
false;
222 uint32_t myTessControlPoints = 4;
229 bool myIsViewportDynamic =
false;
233 bool myIsScissorDynamic =
false;
241 bool myDepthClamp =
false;
244 bool myIsRasterDiscardDynamic =
false;
245 bool myRasterDiscard =
false;
247 bool myIsCullModeDynamic =
false;
250 bool myIsFrontFaceDynamic=
false;
253 bool myIsBiasDynamic =
false;
254 bool myDepthBiasEnable =
false;
256 bool myIsBiasParamDynamic=
false;
257 float myBiasConst = 0.f;
258 float myBiasClamp = 0.f;
259 float myBiasSlope = 0.f;
261 bool myIslineWidthDynamic =
false;
262 float myLineWidth = 1.f;
265 int mySampleCount = -1;
273 bool myIsDepthTestDynamic =
false;
274 bool myDepthTest =
true;
276 bool myIsDepthWriteDynamic =
false;
277 bool myDepthWrite =
true;
279 bool myIsDepthOpDynamic =
false;
282 bool myIsDepthBoundsEnableDynamic =
false;
283 bool myDepthBoundsTest =
false;
285 bool myIsDepthBoundsDynamic =
false;
286 float myMinDepth = 0.f;
287 float myMaxDepth = 1.f;
289 bool myIsStencilTestDynamic =
false;
290 bool myStencilTest =
false;
292 bool myIsStencilOpDynamic =
false;
293 bool myIsStencilWriteMaskDynamic =
false;
294 bool myIsStencilCompMaskDynamic =
false;
295 bool myIsStencilRefDynamic =
false;
322 bool myLogicOpEnable =
false;
339 bool myIsBlendConstDynamic =
false;
340 float myBlendConst[4] = {0.f, 0.f, 0.f, 0.f};
393 { binding,
stride, input_rate};
404 used_bindings.insert(attr.binding);
408 for (uint32_t binding : used_bindings)
458 : myInst(inst), myVkPipeline(vk_pipeline)
467 : myInst(other.myInst), myVkPipeline(other.myVkPipeline)
469 other.myInst =
nullptr;
497 const char* filenames,
RV_VKPipeline & operator=(RV_VKPipeline &)=delete
VKAPI_ATTR void VKAPI_CALL vkDestroyPipeline(VkDevice device, VkPipeline pipeline, const VkAllocationCallbacks *pAllocator)
static RV_VKPipelinePtr createCompute(RV_Instance *inst, const RV_VKPipelineLayout &layout)
static RV_VKPipelinePtr create(RV_Instance *inst, const RV_VKPipelineLayout &layout_info, const RV_VKPipelineStateInfo &state_info, const RV_VKPipelineInputInfo &input_info)
RV_VKPipeline(RV_VKPipeline &&other) noexcept
void setCapacity(exint new_capacity)
std::pair< float, float > RV_DepthRange
void setSize(exint newsize)
bool operator==(const BaseDimensions< T > &a, const BaseDimensions< Y > &b)
IMATH_NAMESPACE::V2f float
void setRenderRegion(const UT_DimRect ®ion)
RAII wrapper class for VkPipeline.
GLint GLint GLsizei GLint GLenum format
GLint GLenum GLboolean GLsizei stride
void setRenderPassInfo(const RV_RenderPassFormatInfo &info)
int x() const
Get lower-left corner.
exint removeIf(IsEqual is_equal)
Handle to the main interface of Vulkan.
int width() const
Get width/height dimensions.
VkPipeline getVkPipeline()
RV_RenderPassFormatInfo myRenderPassInfo
RV_VKPipeline(RV_Instance *inst, VkPipeline vk_pipeline)
RV_TopologyClass RVgetTopologyClass(VkPrimitiveTopology t)
LeafData & operator=(const LeafData &)=delete
VkRect2D RVmakeVkRect(const UT_DimRect &rect)
int y() const
Get lower-left corner.
RV_API void RVloadSpirvFiles(RV_Instance *inst, const UT_StringArray &filenames, UT_Array< RV_VKShaderModulePtr > &shader_modules)
VkDevice getDevice()
Get the raw vulkan device assocated with this instance.
int height() const
Get width/height dimensions.
UT_UniquePtr< RV_VKPipeline > RV_VKPipelinePtr
bool RVisSameTopologyClass(VkPrimitiveTopology lhs, VkPrimitiveTopology rhs)
void clear()
Resets list to an empty list.
VkViewport RVmakeViewport(const UT_DimRect &view_rect, RV_DepthRange depth_range={0.f, 1.f})