Skip to content

Commit

Permalink
post-merge fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
goeiecool9999 committed Dec 16, 2024
1 parent 234a013 commit 40219e2
Show file tree
Hide file tree
Showing 5 changed files with 1 addition and 19 deletions.
2 changes: 1 addition & 1 deletion src/Cafe/HW/Latte/Renderer/RendererOuputShader.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -146,7 +146,7 @@ void RendererOutputShader::SetUniformParameters(const LatteTextureView& texture_
{
sint32 effectiveWidth, effectiveHeight;
texture_view.baseTexture->GetEffectiveSize(effectiveWidth, effectiveHeight, 0);
auto setUniforms = [&](RendererShader* shader, const UniformLocations& locations){
auto setUniforms = [&](const std::unique_ptr<RendererShader>& shader, const UniformLocations& locations){
float res[2];
if (locations.m_loc_textureSrcResolution != -1)
{
Expand Down
7 changes: 0 additions & 7 deletions src/Cafe/HW/Latte/Renderer/Vulkan/VKRBase.h
Original file line number Diff line number Diff line change
Expand Up @@ -235,11 +235,4 @@ class VKRObjectDescriptorSet : public VKRDestructibleObject
~VKRObjectDescriptorSet() override;

VkDescriptorSet descriptorSet{ VK_NULL_HANDLE };
};

class VKRObjectSampler : public VKRDestructibleObject
{
public:
~VKRObjectSampler() override;
VkSampler sampler { VK_NULL_HANDLE };
};
8 changes: 0 additions & 8 deletions src/Cafe/HW/Latte/Renderer/Vulkan/VulkanRenderer.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3229,8 +3229,6 @@ VkDescriptorSetInfo::~VkDescriptorSetInfo()

auto renderer = VulkanRenderer::GetInstance();
renderer->ReleaseDestructibleObject(m_vkObjDescriptorSet);
for(auto& sampler : m_vkObjSamplers)
renderer->ReleaseDestructibleObject(sampler);
m_vkObjDescriptorSet = nullptr;
}

Expand Down Expand Up @@ -4147,9 +4145,3 @@ VKRObjectDescriptorSet::~VKRObjectDescriptorSet()
vkFreeDescriptorSets(vkr->GetLogicalDevice(), vkr->GetDescriptorPool(), 1, &descriptorSet);
performanceMonitor.vk.numDescriptorSets.decrement();
}

VKRObjectSampler::~VKRObjectSampler()
{
auto vkr = VulkanRenderer::GetInstance();
vkDestroySampler(vkr->GetLogicalDevice(), sampler, nullptr);
}
1 change: 0 additions & 1 deletion src/Cafe/HW/Latte/Renderer/Vulkan/VulkanRenderer.h
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,6 @@ struct VkSupportedFormatInfo_t
struct VkDescriptorSetInfo
{
VKRObjectDescriptorSet* m_vkObjDescriptorSet{};
std::vector<VKRObjectSampler*> m_vkObjSamplers{};

~VkDescriptorSetInfo();

Expand Down
2 changes: 0 additions & 2 deletions src/Cafe/HW/Latte/Renderer/Vulkan/VulkanRendererCore.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1167,8 +1167,6 @@ void VulkanRenderer::draw_prepareDescriptorSets(PipelineInfo* pipeline_info, VkD
return nullptr;
auto descriptorSetInfo = draw_getOrCreateDescriptorSet(pipeline_info, shader);
descriptorSetInfo->m_vkObjDescriptorSet->flagForCurrentCommandBuffer();
for (auto& sampler : descriptorSetInfo->m_vkObjSamplers)
sampler->flagForCurrentCommandBuffer();
return descriptorSetInfo;
};

Expand Down

0 comments on commit 40219e2

Please sign in to comment.