VulkanExamples
Open-Source Vulkan C++ API
VulkanExamples | Open-Source Vulkan C++ API | |
---|---|---|
5 | 36 | |
327 | 2,926 | |
- | 1.2% | |
2.6 | 9.1 | |
3 months ago | 7 days ago | |
C++ | C++ | |
MIT License | Apache License 2.0 |
Stars - the number of stars that a project has on GitHub. Growth - month over month growth in stars.
Activity is a relative number indicating how actively a project is being developed. Recent commits have higher weight than older ones.
For example, an activity of 9.0 indicates that a project is amongst the top 10% of the most actively developed projects that we are tracking.
VulkanExamples
-
Dependency management with Cmake FetchContent
cmake_minimum_required(VERSION 3.11) project(my_project LANGUAGES CXX VERSION 1.0 ) include(FetchContent) FetchContent_Declare( glfw GIT_REPOSITORY "https://github.com/glfw/glfw" GIT_TAG dd8a678a66f1967372e5a5e3deac41ebf65ee127 ) message("Fetching glfw...") FetchContent_MakeAvailable(glfw) FetchContent_Declare( vulkan GIT_REPOSITORY "https://github.com/KhronosGroup/Vulkan-Hpp" GIT_TAG 429c4c522c65d10ec6df4633a1b78fc28aca7dc3 ) message("Fetching vulkan") FetchContent_MakeAvailable(vulkan) add_executable(my_project src/main.cpp) target_link_libraries(my_project PRIVATE glfw) target_link_libraries(my_project PRIVATE vulkan)
-
Two new Vulkan samples from The Khronos Group! (Profiles and C++ bindings)
The second sample comes from NVIDIA. It shows a transcoded version of the API sample, High Dynamic Range, and illustrated the usage of the C++ binding of Vulkan provided by Vulkan.hpp. Sample - https://github.com/KhronosGroup/Vulkan-Samples/tree/master/samples/api/hpp_hdr Vulkan.hpp - https://github.com/KhronosGroup/Vulkan-Hpp
-
Thriving in a Crowded and Changing World: C++ 2006–2020 [pdf]
or https://github.com/KhronosGroup/Vulkan-Hpp which help quite a bit. Or https://github.com/VcDevel/std-simd.
If you want GUIs, same, you have at least (but not only) Qt or WxWidgets.
Want to interface scripting? Pybind11, Boost.Python, WrenBind17 for Wren, Sol2 for Lua... and all things that interface to C work also if you feel brave...
I really think that when it is about getting the job done... C++ goes a long way towards the task.
This is my 20 year experience of C++, almost 13 of those years professionally. Now, back to read the paper. :)
-
Practice project ideas
If you're not a complete beginner, the vulkan.hpp version of Sascha Willems' samples is out of date, you could contribute some updated examples. You'd get a decent overview of various Vulkan features and become familiar with both the C and C++ APIs.
-
Vulkan Hpp cheatsheet
I don't have a cheat sheet but I do have a repository with a bunch of examples that use the C++ api https://github.com/jherico/vulkan
Open-Source Vulkan C++ API
-
what math is required?
It might be useful to maybe look at the Vulkan.hpp examples since you can do the same in about 200 lines of code. https://github.com/KhronosGroup/Vulkan-Hpp/blob/main/samples/15_DrawCube/15_DrawCube.cpp
- Vulkan-Hpp now provides C++20 module interface file
-
How do you guys organize everything?
Wow that library looks amazing, I'll definitely be using it. Bonus that it's official from the Khronos Group. https://github.com/KhronosGroup/Vulkan-Hpp
-
An idea to ease wrapping C libraries in C++.
Even auto-generated c++ wrappers like vulkan-hpp require lots of manual maintenance.
-
Anybody know why V-EZ has not been updated in 5 years?
Ultimately I went with vulkan.hpp RAII bindings, even though that way also has some learning curve and I couldn't find any documentation other than the RAII programming guide. It's great for getting started, but could use a complementary auto-generated API doc. There are also decent programming samples, which really suck for getting started, but otherwise do a good job of presenting concepts they focus on. Putting the available resources together I was able to get a project going in two weekends.
-
Using enum classes as bitmasks
This is exactly how the official Vulkan C++ API, Vulkan-Hpp does it. For the precise example mentioned in the blog post:
-
Recommendations on how to start a small Vulkan project
Or the vulkan.hpp RAII samples would be a good place?
-
What's the most hilarious use of operator overloading you've seen?
For a real-life example: consider the vk::raii namespace of Vulkan-Hpp, where the developers have posted examples. The vk::raii::su namespace has a bunch of free functions that one might think are associated with a Vulkan instance/object (in fact, the Vulkan Tutorial does implement them as member functions), but they are much nicer when used as pure functions. It keeps the class/struct definition itself nice and clean.
-
Vulkan-HPP + Vulkan C API == Aliasing Bugs!
final c++17 draft (N4659) first post-publication draft after c++20 (N4868) vulkan-structs.hpp (containing the vk::ImageCreateInfo definition) VkImageCreateInfo struct
What are some alternatives?
conan-center-index - Recipes for the ConanCenter repository
Ogre 3D - scene-oriented, flexible 3D engine (C++, Python, C#, Java)
std-simd - std::experimental::simd for GCC [ISO/IEC TS 19570:2018]
GLFW - A multi-platform library for OpenGL, OpenGL ES, Vulkan, window and input
kompute - General purpose GPU compute framework built on Vulkan to support 1000s of cross vendor graphics cards (AMD, Qualcomm, NVIDIA & friends). Blazing fast, mobile-enabled, asynchronous and optimized for advanced GPU data processing usecases. Backed by the Linux Foundation.
Skia - Skia is a complete 2D graphic library for drawing Text, Geometries, and Images.
C++ REST SDK - The C++ REST SDK is a Microsoft project for cloud-based client-server communication in native code using a modern asynchronous C++ API design. This project aims to help C++ developers connect to and interact with services.
urho3d - Game engine
glbinding - A C++ binding for the OpenGL API, generated using the gl.xml specification.
Irrlicht - An automatically updated mirror of the Irrlicht SVN repository on sourceforge
VulkanHelper - A simple helper interface between Vulkan C API and C++ containers
OpenVDB - OpenVDB - Sparse volume data structure and tools