update some stuff so i dont get a ton of useless warnings

This commit is contained in:
Mars 2024-09-30 17:52:49 -04:00
parent 2735eb5807
commit 134b43c1d4
Signed by untrusted user: pupbrained
GPG key ID: 874E22DF2F9DFCB5
4 changed files with 11 additions and 1664 deletions

View file

@ -35,14 +35,15 @@ foreach file : source_file_names
endforeach endforeach
deps = [ deps = [
dependency('fmt', static: true), dependency('fmt', include_type: 'system'),
dependency('glfw3'), dependency('glfw3', include_type: 'system'),
dependency('glm'), dependency('glm', include_type: 'system'),
dependency('vulkan'), dependency('vulkan', include_type: 'system'),
] ]
executable( executable(
'graphics-test', 'graphics-test',
sources, sources,
include_directories: include_directories('include', is_system: true),
dependencies: deps, dependencies: deps,
) )

View file

@ -11,14 +11,14 @@
#include <vulkan/vulkan.hpp> #include <vulkan/vulkan.hpp>
#include "util/types.h" #include "util/types.h"
#include "util/vkfw.hpp" #include "vkfw.hpp"
namespace vk { namespace vk {
using DebugUtilsMessengerUnique = vk::UniqueHandle<vk::DebugUtilsMessengerEXT, vk::DispatchLoaderDynamic>; using DebugUtilsMessengerUnique = vk::UniqueHandle<vk::DebugUtilsMessengerEXT, vk::DispatchLoaderDynamic>;
} }
constexpr int WIDTH = 800; constexpr i32 WIDTH = 800;
constexpr int HEIGHT = 600; constexpr i32 HEIGHT = 600;
constexpr std::array<const char*, 1> validationLayers = { "VK_LAYER_KHRONOS_validation" }; constexpr std::array<const char*, 1> validationLayers = { "VK_LAYER_KHRONOS_validation" };
@ -103,9 +103,9 @@ class VulkanApp {
vk::InstanceCreateInfo createInfo { vk::InstanceCreateInfo createInfo {
.flags = vk::InstanceCreateFlagBits::eEnumeratePortabilityKHR, .flags = vk::InstanceCreateFlagBits::eEnumeratePortabilityKHR,
.pApplicationInfo = &appInfo, .pApplicationInfo = &appInfo,
.enabledLayerCount = enableValidationLayers ? static_cast<uint32_t>(validationLayers.size()) : 0, .enabledLayerCount = enableValidationLayers ? static_cast<u32>(validationLayers.size()) : 0,
.ppEnabledLayerNames = enableValidationLayers ? validationLayers.data() : nullptr, .ppEnabledLayerNames = enableValidationLayers ? validationLayers.data() : nullptr,
.enabledExtensionCount = static_cast<uint32_t>(extensions.size()), .enabledExtensionCount = static_cast<u32>(extensions.size()),
.ppEnabledExtensionNames = extensions.data() .ppEnabledExtensionNames = extensions.data()
}; };

File diff suppressed because it is too large Load diff