| 1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253 |
- //********************************** Banshee Engine (www.banshee3d.com) **************************************************//
- //**************** Copyright (c) 2016 Marko Pintera ([email protected]). All rights reserved. **********************//
- #pragma once
- #include "BsVulkanPrerequisites.h"
- #include "BsGpuPipelineParamInfo.h"
- namespace BansheeEngine
- {
- /** @addtogroup Vulkan
- * @{
- */
- /** Holds meta-data about a set of GPU parameters used by a single pipeline state. */
- class VulkanGpuPipelineParamInfo : public GpuPipelineParamInfoCore
- {
- public:
- VulkanGpuPipelineParamInfo(const GPU_PIPELINE_PARAMS_DESC& desc, GpuDeviceFlags deviceMask);
- ~VulkanGpuPipelineParamInfo();
- /** Returns the number of bindings present at the layout at the specified index. */
- UINT32 getNumBindings(UINT32 layoutIdx) const { return mLayoutInfos[layoutIdx].numBindings; }
- /** Returns a pointer to an array of bindings for the layout at the specified index. */
- VkDescriptorSetLayoutBinding* getBindings(UINT32 layoutIdx) const { return mLayoutInfos[layoutIdx].bindings; }
- /**
- * Returns a layout for the specified device, at the specified index. Returns null if no layout for the specified
- * device index.
- */
- VulkanDescriptorLayout* getLayout(UINT32 deviceIdx, UINT32 layoutIdx) const;
- private:
- /** @copydoc GpuPipelineParamInfoCore::initialize */
- void initialize() override;
- /** Data related to a single descriptor set layout. */
- struct LayoutInfo
- {
- VkDescriptorSetLayoutBinding* bindings;
- UINT32 numBindings;
- };
- GpuDeviceFlags mDeviceMask;
- VulkanDescriptorLayout** mLayouts[BS_MAX_DEVICES];
- LayoutInfo* mLayoutInfos;
- UINT8* mData;
- };
- /** @} */
- }
|