New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[WIP] Bootstrapping Vulkan support #234

wants to merge 10 commits into
base: master


2 participants

mosra commented Mar 2, 2018

This currently depends on #233, so I'm setting base branch to that instead of master so the changes are visible clearer. I'm also working on both at the same time. #233 is merged now.

Things to do:

  • Initial library bootstrap (WITH_VK)
  • Find module updates
    • Require CMake 3.7
    • Require C++14 for dependencies of this lib
  • TARGET_VK variable
  • @fn_vk etc Doxygen aliases, update Coding Style for them
  • Extension list and support state
  • Command and type mapping page
  • High-level overview page
  • Header generation using flextGL
    • some types are parsed with trailing whitespace, remove that
    • the global enums have a different order every time they are generated
    • the vk.xml file is not sorted in type dependency order, submit patch upstream (or hotfix in flextGL?)
    • don't export the flextVkInitInstance() function (done just because there's no Instance/Device wrapper yet)
    • avoid global function pointers, fill a struct with them instead
    • add another flextVkInitDevice() for populating device-dependent pointers into another struct
    • clean up and submit the patches upstream (mosra/flextgl#15)
    • update the Developers Guide with generating Vulkan headers
  • Initial Instance wrapper
  • Initial Device wrapper
  • Initial magnum-vk-info utility
  • Initial Vulkan function / limit mapping page
  • Initial Vulkan extension support page
  • Initial Vulkan wrapping docs, focusing on interoperability with raw code
  • Vulkan-specific projection matrix creation. Would need to be moved out from Math::Matrix[34]::*Projection() to some API-specific header.
  • Initial base class for Vk tests, BUILD_VK_TESTS option
    • Decide what to set up in the Vulkan tester and what to leave up to the tests (will probably become clearer once we implement a few)
    • Setting up debug layers? Leak detection?
    • Setting up queues?
    • Ability to override the chosen device on command-line?
  • Building on Travis CI against a minimal stub (can't be bothered to build some random driver there just yet)
    • Why is it looking for OpenGL even though everything else is disabled? -- not anymore since 89d9883
  • Building on AppVeyor the same way -- d578d4d
  • Integrating an initial Vulkan Triangle example -- mosra/magnum-examples@41c78ef
  • Basic translation of Magnum enums to raw Vulkan enums (will get deprecated/removed later once we have our own types there) -- b0a1719

Cc: @Squareys

@mosra mosra added this to the 2018.0b milestone Mar 2, 2018

@mosra mosra self-assigned this Mar 2, 2018

@mosra mosra added this to TODO in Vulkan via automation Mar 2, 2018

@mosra mosra moved this from TODO to In Progress in Vulkan Mar 2, 2018


This comment has been minimized.

codecov-io commented Mar 2, 2018

Codecov Report

Merging #234 into master will decrease coverage by 4.08%.
The diff coverage is n/a.

Impacted file tree graph

@@            Coverage Diff             @@
##           master     #234      +/-   ##
- Coverage   50.93%   46.84%   -4.09%     
  Files         365      345      -20     
  Lines       16580    14202    -2378     
- Hits         8445     6653    -1792     
+ Misses       8135     7549     -586
Impacted Files Coverage Δ
src/Magnum/GL/Extensions.h 0% <0%> (-100%) ⬇️
src/Magnum/Trade/AbstractImporter.cpp 15.05% <0%> (-84.95%) ⬇️
src/Magnum/GL/MeshView.h 0% <0%> (-50%) ⬇️
...agnumPlugins/AnyImageImporter/AnyImageImporter.cpp 52.94% <0%> (-38.57%) ⬇️
src/Magnum/Trade/AbstractImageConverter.cpp 63.46% <0%> (-36.54%) ⬇️
src/Magnum/GL/Version.cpp 66.66% <0%> (-33.34%) ⬇️
src/Magnum/GL/Buffer.h 8.33% <0%> (-26.15%) ⬇️
src/Magnum/Shaders/Flat.h 18.18% <0%> (-17.54%) ⬇️
src/Magnum/GL/Attribute.h 53.84% <0%> (-15.39%) ⬇️
src/Magnum/Shaders/DistanceFieldVector.h 16.66% <0%> (-14.37%) ⬇️
... and 219 more

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 2948953...6ad0d75. Read the comment docs.

@mosra mosra referenced this pull request Mar 2, 2018


Vulkan / GL split #147

27 of 27 tasks complete

@mosra mosra modified the milestones: 2018.0b, 2018.0c Apr 29, 2018

@mosra mosra changed the base branch from split to master May 4, 2018

mosra added some commits Mar 2, 2018

package/ci: enable Vulkan building on Travis CI.
Currently a separate job with everything that depends on GL disabled.
And against a minimal Vulkan driver that has just four symbols, because
I can't run the stuff there anyway.
Vk: require at least CMake 3.7.
Older versions don't have FindVulkan and I can't be bothered.
[wip] Vk: WIP magnum-vk-info utility.
TODO: documentation
TODO: FindMagnum entry
TODO: consistency with magnum-info
TODO: rename magnum-info to magnum-gl-info
[wip] Vk: require C++14 for this library.
Maybe not needed in the end?

This comment has been minimized.


mosra commented May 14, 2018

Initial Vulkan flextGL headers were merged into master in b137703.


This comment has been minimized.


mosra commented Sep 15, 2018

Initial Vulkan Triangle example is integrated in mosra/magnum-examples@41c78ef.

@mosra mosra referenced this pull request Oct 15, 2018


2018.10 release #265

56 of 56 tasks complete

This comment has been minimized.


mosra commented Oct 21, 2018

Translation of Magnum pixel format / mesh primitive / mesh index type / sampler state enums to Vulkan-specific values is done in b0a1719. This is an important step allowing Magnum to be used as an asset management pipeline for Vulkan renderers and that also wraps up everything Vulkan-related for 2018.0c. Further work will happen once I push the release out :)

@mosra mosra modified the milestones: 2018.0c, 2018.0d Oct 21, 2018

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment