mirror of
https://github.com/hrydgard/ppsspp.git
synced 2025-04-02 11:01:50 -04:00
Vulkan: Make sure to clear the pipeline key to avoid padding bytes causing us to allocate duplicate pipelines.
Also pack the struct better.
This commit is contained in:
parent
4a09289056
commit
5c7f7c1df6
2 changed files with 3 additions and 3 deletions
|
@ -299,7 +299,7 @@ static VulkanPipeline *CreateVulkanPipeline(VkDevice device, VkPipelineCache pip
|
|||
}
|
||||
|
||||
VulkanPipeline *PipelineManagerVulkan::GetOrCreatePipeline(VkPipelineLayout layout, VkRenderPass renderPass, const VulkanPipelineRasterStateKey &rasterKey, const DecVtxFormat *decFmt, VulkanVertexShader *vs, VulkanFragmentShader *fs, bool useHwTransform) {
|
||||
VulkanPipelineKey key;
|
||||
VulkanPipelineKey key{};
|
||||
if (!renderPass)
|
||||
Crash();
|
||||
|
||||
|
|
|
@ -40,10 +40,10 @@ enum class PspAttributeLocation {
|
|||
struct VulkanPipelineKey {
|
||||
VulkanPipelineRasterStateKey raster; // prim is included here
|
||||
VkRenderPass renderPass;
|
||||
bool useHWTransform;
|
||||
uint32_t vtxDecId;
|
||||
VkShaderModule vShader;
|
||||
VkShaderModule fShader;
|
||||
uint32_t vtxDecId;
|
||||
bool useHWTransform;
|
||||
|
||||
void ToString(std::string *str) const {
|
||||
str->resize(sizeof(*this));
|
||||
|
|
Loading…
Add table
Reference in a new issue