Tring to fix things
Some checks failed
Build VulkanEngine / nix (push) Has been cancelled
Build VulkanEngine / release (BUNDLE) (push) Has been cancelled
Build VulkanEngine / release (PORTABLE) (push) Has been cancelled
Build VulkanEngine / notify (push) Has been cancelled

This commit is contained in:
Alexandre 2026-10-09 23:17:15 +02:00
parent 4874a49aaa
commit e2a2833aae
5 changed files with 21 additions and 12 deletions

View File

@ -85,6 +85,7 @@ endif()
# Same in every mode: no link-time dependency on libvulkan, all Vulkan
# functions come from volk (otherwise vk*KHR aliases are undefined at link).
set(ENGINE_EXTRA_DEFINITIONS
GLFW_INCLUDE_NONE
VK_NO_PROTOTYPES
VMA_STATIC_VULKAN_FUNCTIONS=0
VMA_DYNAMIC_VULKAN_FUNCTIONS=1

17
flake.lock generated
View File

@ -20,18 +20,15 @@
},
"nixpkgs": {
"locked": {
"lastModified": 1790689126,
"narHash": "sha256-ilerN1WLSvF+HMjziC/Wv99J5y02maDH+6hZPwsORKg=",
"owner": "NixOS",
"repo": "nixpkgs",
"rev": "b4fd65b198c599cbe814fcb9f42d25d021595ec9",
"type": "github"
"lastModified": 1791366222,
"narHash": "sha256-/4ezBOv6aldGab7qTb6ls3SDpgzG8kuuSqEAA9zEZ8E=",
"rev": "39ad350a0602fa0a58a544344e3e9187526ea45c",
"type": "tarball",
"url": "https://releases.nixos.org/nixpkgs/nixpkgs-26.11pre1087089.39ad350a0602/nixexprs.tar.zst"
},
"original": {
"owner": "NixOS",
"ref": "nixos-unstable",
"repo": "nixpkgs",
"type": "github"
"id": "nixpkgs",
"type": "indirect"
}
},
"root": {

View File

@ -2,7 +2,7 @@
description = "VulkanEngine development environment";
inputs = {
nixpkgs.url = "github:NixOS/nixpkgs/nixos-unstable";
nixpkgs.url = "nixpkgs";
flake-utils.url = "github:numtide/flake-utils";
};
@ -88,6 +88,11 @@
"${pkgs.vulkan-validation-layers}";
shellHook = ''
export LD_LIBRARY_PATH="${pkgs.lib.makeLibraryPath [
pkgs.vulkan-loader
pkgs.wayland
pkgs.libxkbcommon
]}"
echo "VulkanEngine development environment"
echo "CMake: $(cmake --version | head -n1)"
echo "Ninja: $(ninja --version)"

View File

@ -22,7 +22,7 @@
#include <vulkan/vk_enum_string_helper.h>
#include <vk_mem_alloc.h>
#define GLFW_INCLUDE_NONE
//#define GLFW_INCLUDE_NONE
#include <GLFW/glfw3.h>
#define GLM_ENABLE_EXPERIMENTAL

View File

@ -774,10 +774,16 @@ void Engine::initVulkan() {
volkLoadDevice(_device);
VmaVulkanFunctions vmaFuncs{
.vkGetInstanceProcAddr = vkGetInstanceProcAddr, // Volk pointers
.vkGetDeviceProcAddr = vkGetDeviceProcAddr
};
VmaAllocatorCreateInfo allocatorInfo = {
.flags = VMA_ALLOCATOR_CREATE_BUFFER_DEVICE_ADDRESS_BIT,
.physicalDevice = _choosenGPU,
.device = _device,
.pVulkanFunctions = &vmaFuncs,
.instance = _instance
};