||1 year ago|
|OLD||2 years ago|
|external||2 years ago|
|inc||2 years ago|
|media||2 years ago|
|src||1 year ago|
|.gitignore||2 years ago|
|LICENSE||2 years ago|
|Makefile||2 years ago|
|README.md||2 years ago|
|app.init||2 years ago|
Vulkan tests in FreeBSD/Debian
Personal development workshop to learn vulkan before implementing in serious projects
As part of a learning path, this project is aiming the creation of a coding environment (software) to interact with graphics. Please take note that this is an ongoing project I'm doing in my spare time along with the unixworks project. I try to keep it as updated as possible.
I don't like the idea of increasing the repository size by including media progress in here (it only supports gif animations) but if you're interested in the progress of the project I usually post information and video demos at my personal channel.
To try and reproduce what I have in my machine, install the following depending in your os:
sudo apt-get install vulkan-validationlayers-dev libvulkan-dev mesa-vulkan-drivers vulkan-tools vulkan-utils libglfw3-dev glslang-tools glslang-dev spirv-tools
Important note: There's a bug with validation layers running with XCB. A temporary patch may be found here. I'd recommend you to build vulkan dependencies from source.
doas pkg install vulkan-validation-layers vulkan-tools vulkan-loader vulkan-headers glfw glslang spirv-tools shaderc
Most of the open source repositories doing vulkan development are using the LunarG SDK, C++ and CMAKE which is perfectly fine but I want to go in other direction.
This is why this repo is focused on BSD and Linux operating systems and being written in close-to-metal C, using plain makefiles and no IDE dependency to build it and try to avoid any extra code bloat.
A scripting implementation will come when development grows, most probably the implementation will be using Lua.
- Learn to use complex Makefiles.
- Learn in depth C.
- Learn Vulkan.
- Create a basic graphics sandbox development engine.
- Make it portable being multiplatform and multi-arch.
- Avoid bloat.
Organize and clean main modules.
Select best device based on family queues.
Select device features automatically.
Implement VMA from AMD.
Simple Vertex Buffers.
Abstracted buffer pipeline.
Uniform buffer object.
Basic PBR render (deferred or forward light).
Better have this list empty. 🍃
- A semaphore cannot be signaled. Happens when resizing the window for the first time.
UNASSIGNED-CoreValidation-DrawState-QueueForwardProgress(ERROR / SPEC): msgNum: 0 - VkQueue 0x627000028738 is waiting on VkSemaphore 0x160000000016 that has no way to be signaled. Objects: 1  0x160000000016, type: 5, name: NULL
- Second image in swapchain hasn't been acquired. Happens when resizing the window for the first time.
UNASSIGNED-CoreValidation-DrawState-SwapchainImageNotAcquired(ERROR / SPEC): msgNum: 0 - vkQueuePresentKHR: Swapchain image index 2 has not been acquired. Objects: 1  0x20000000002, type: 1000001000, name: NULL
- Apparently the oldswapchain doesn't reference a valid VkSwapchainKHR. Happens each time we recreate the swapchain.
VUID-VkSwapchainCreateInfoKHR-oldSwapchain-parameter(ERROR / SPEC): msgNum: 0 - Invalid VkSwapchainKHR Object 0x20000000002. The Vulkan spec states: If oldSwapchain is not VK_NULL_HANDLE, oldSwapchain must be a valid VkSwapchainKHR handle (https://www.khronos.org/registry/vulkan/specs/1.1-extensions/html/vkspec.html#VUID-VkSwapchainCreateInfoKHR-oldSwapchain-parameter) Objects: 1  0x20000000002, type: 1000001000, name: NULL
- No idea what is this exactly
UNASSIGNED-Threading-Info(ERROR / SPEC): msgNum: 0 - Couldn't find VkDescriptorUpdateTemplate Object 0x20000000002. This should not happen and may indicate a bug in the application. Objects: 1  0x20000000002, type: 1000001000, name: NULL
- Segmentation fault happens when we press ESC KEY (managed by GFLW in main loop)
UNASSIGNED-ObjectTracker-ObjectLeak(ERROR / SPEC): msgNum: 0 - OBJ ERROR : VK_DEBUG_REPORT_OBJECT_TYPE_DEVICE_EXT object VkDevice 0x55a89903fe30 has not been destroyed. Objects: 1  0x55a89903fe30, type: 3, name: NULL Segmentation fault
- Telegram channel
This project is GPL v2.0 licensed. This means you can borrow the code and do whatever you want with it, but any changes you make have to be documented and the product you make has to use the same license. Check the LICENSE file for details.
Hey! Thanks for checking this out.
I'm running low on coffee, if you think the project is useful or want to look a faster development, consider buying me a coffee or becoming a patron. That way I can spend more time working on it (:
No coffee? Don't worry, check out the Telegram channel (it works from the web, no accounts required), star the repo and share it!