GithubHelp home page GithubHelp logo

vk-module's People

Contributors

cdgiessen avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

vk-module's Issues

Make optional handles default constructed with nullptr

This way you don't have to specify an argument manually.
QueueSubmit() requires a Fence() to be provided currently, which is cumbersome.
Making it a pointer would allow actual nullptr values, but it may be simpler to have Fence fence = Fence() so the .get() function doesn't have to be conditional.

Note, there must be logic to guarantee the = default() only occurs if its the last argument in a function. Allocator Callbacks are in the middle, thus can't be defaulted.

Create helpers for functions which create multiple objects

vkCreateGraphicsPipelines and vkCreateComputePipelines take an array of pipeline create info's and should return a vector of pipelines. This is the last create/query function category but needs special consideration wrt how the len attributes are handled.

Add vk::Result to_string to main headers/module instead of in separate header

The ability to print vk::Result is the most useful to_string function, it only makes sense to include it in the main headers and not be separate.
Only difficulty is that now it must be documented that the vk::Result to string is inside the main header.

C++20 module shouldn't have such a reason to split them in the first place.

Properly #if-def guard for all types from extensions

Currently, structs & unions do not properly guard against the vulkan headers not containing newer extensions.

For example, PhysicalDevice4444FormatsFeaturesEXT will fail to compile if the header version isn't new enough to contain it.

Add Mock Library for Vulkan C api

Create a library that implements all C api entry points, allow mocking of an application without needing a vulkan driver or loader.

Needs to allow specifying the return values of Vulkan functions.

Also might make more sense to be in a separate repository.

Similar to Mock-ICD but before the loader, not after.

Extension functions promoted to core do not have non core version.

Extension functions which are aliases to now core functions do not have the alias version present.
This is a tricky issue, as the internal function in the loader may not be distinct (todo: double check that).

For example vkGetPhysicalDeviceImageFormatProperties2KHR doesn't exist, only vkGetPhysicalDeviceImageFormatProperties2. If the KHR version was added what should happen if the KHR version is called on a 1.0 driver that doesn't support the extension?

Add ASAN support

It would be really nice if the bindings did the necessary grunt work to disable asan checking inside the drivers, eliminating any driver or layer related false positives from application output.

Setup CI with github actions

Requires using the Mock Vulkan API library.
Will make tests run every time, ensuring changes don't break code.

Promote the Result enum to a Struct

There are many capabilities that would be very convenient. conversion to bool, allowing to be ignored (by an explicit function call that does nothing, for use in functions which [[nodiscard]], and more flexibility for interaction with the expected type.

Only downside would be that the enum values would have to be made class constants to preserve the current syntax. vk::Result::Success and vk::Result::EventSet` would need to continue to work.

Add builder pattern for creation functions

Create structs to hold all intermediate data and have .setXXX() member functions.
Anything that is passed by counter+pointer pairs will have a vector to store the data.
Return type is an expected like type, eg expected<NewValue, Error>.

Need to decide how to handle functions which can create multiple objects, and functions which aren't 'creation' but allocation (descriptor sets & command buffers).

Add version information into the headers directly.

Vulkan.h has macro defines to specify the major, minor, and patch version of the headers.
The bindings need to have similar functionality.

Also, the VK_MAKE_VERSION() macro needs to be made accessible.

Add std::span<T> overloads for C++20 module

Make overloads for any function which takes count+pointer argument pairs into functions with std::span. This allows for easy interoperation with std::vector & std::array.

investigate: natvis & debug_utils set object name integration

It would be nice to see the debug utils handle in the debugger.
This could be accomplished by creating a hash map that the debug utils calls know about and modify.
Then natvis can call into that with the handle, then get the string from the hash map, and thus you get nice strings to go with your uint64_t values.

Low priority, but would be really cool!

Add Enumeration functions helpers

EnumerateInstanceExtensionProperties
EnumerateInstanceLayerProperties
EnumerateInstanceVersion
pfn_EnumeratePhysicalDevices
pfn_EnumerateDeviceExtensionProperties
pfn_EnumeratePhysicalDeviceGroups
pfn_EnumeratePhysicalDeviceQueueFamilyPerformanceQueryCountersKHR

Do not do EnumerateInstanceDeviceProperties - deprecated

Improve CMake file

Current CMakeLists.txt is geared to work on my system and my system only.
It should be rewritten so optional parts (like generation python script) properly check for python or download the other dependencies as necessary.
It should also be tested against using system vulkan-headers, and getting the vk.xml from the SDK/packages/manually downloaded headers.

Replace std::span with custom span

Reason are:
Allows C++17 users to use span - unify interface - really the only reason to do it. Having this be different between the two is silly.
span can be 'customized' to be better suited for vulkan, eg uint32_t size in most places. Make it a template argument which defaults to uint32_t.
Make an implicit conversion operator from std::span in C++20 mode for seamless interop.

Downsides:
Need to have vk::Span be as fleshed out as is reasonably possible. It can't have major deficiencies compared to std::span, lest it be a worse replacement.
More code = more tests needed

Create proper C++20 Module version of bindings

Currently, there are C++17 headers but no module.

The interim step is to create C++20 headers for feature testing (std::span, default operator==).

This will require build system support to make it usable for many projects.

Manually download vk.xml directly

The project requires the vk.xml and nothing else from the Vulkan-Headers repo.
It speeds up build time of the repo if the entire vulkan-headers repo isn't downloaded.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.