Switch to PPSSPP's assert functions (don't use the system's)

This commit is contained in:
Henrik Rydgård committed 2020-08-16 10:01:10 +02:00
1 parent c5147c01a0
commit 5d64fc5ff1
49 files changed
+142 -180

No files matched your search

+4 -6
View File
@@ -15,8 +15,6 @@
// Official git repository and contact information can be found at
// https://github.com/hrydgard/ppsspp and http://www.ppsspp.org/.
#include <cassert>
#include "math/dataconv.h"
#include "profiler/profiler.h"
#include "thin3d/VulkanRenderManager.h"
@@ -142,7 +140,7 @@ void DrawEngineVulkan::InitDeviceObjects() {
dsl.bindingCount = ARRAY_SIZE(bindings);
dsl.pBindings = bindings;
VkResult res = vkCreateDescriptorSetLayout(device, &dsl, nullptr, &descriptorSetLayout_);
assert(VK_SUCCESS == res);
_dbg_assert_(VK_SUCCESS == res);
// We are going to use one-shot descriptors in the initial implementation. Might look into caching them
// if creating and updating them turns out to be expensive.
@@ -164,7 +162,7 @@ void DrawEngineVulkan::InitDeviceObjects() {
pl.pSetLayouts = &descriptorSetLayout_;
pl.flags = 0;
res = vkCreatePipelineLayout(device, &pl, nullptr, &pipelineLayout_);
assert(VK_SUCCESS == res);
_dbg_assert_(VK_SUCCESS == res);
VkSamplerCreateInfo samp{ VK_STRUCTURE_TYPE_SAMPLER_CREATE_INFO };
samp.addressModeU = VK_SAMPLER_ADDRESS_MODE_CLAMP_TO_EDGE;
@@ -176,7 +174,7 @@ void DrawEngineVulkan::InitDeviceObjects() {
samp.minFilter = VK_FILTER_NEAREST;
res = vkCreateSampler(device, &samp, nullptr, &samplerSecondary_);
res = vkCreateSampler(device, &samp, nullptr, &nullSampler_);
assert(VK_SUCCESS == res);
_dbg_assert_(VK_SUCCESS == res);
vertexCache_ = new VulkanPushBuffer(vulkan_, VERTEX_CACHE_SIZE, VK_BUFFER_USAGE_INDEX_BUFFER_BIT | VK_BUFFER_USAGE_VERTEX_BUFFER_BIT);
@@ -407,7 +405,7 @@ VkDescriptorSet DrawEngineVulkan::GetOrCreateDescriptorSet(VkImageView imageView
if (!frame.descPool || frame.descPoolSize < frame.descCount + 1) {
VkResult res = RecreateDescriptorPool(frame, frame.descPoolSize * 2);
assert(res == VK_SUCCESS);
_dbg_assert_(res == VK_SUCCESS);
}
// Didn't find one in the frame descriptor set cache, let's make a new one.