Commit cfec8a23 authored by Nicholas Milef's avatar Nicholas Milef

ENH: Added documentation for the Vulkan renderer

parent 1c30b799
#----------------------------------------------------------------------------- #-----------------------------------------------------------------------------
# Vulkan renderer # Vulkan renderer
#----------------------------------------------------------------------------- #-----------------------------------------------------------------------------
message(STATUS "Superbuild - Vulkan SDK => ENABLING Vulkan renderer") if(NOT DEFINED VulkanSDK_ROOT_DIR OR NOT EXISTS ${VulkanSDK_ROOT_DIR})
if(NOT DEFINED VulkanSDK_ROOT_DIR)
set(VulkanSDK_ROOT_DIR "$ENV{VULKAN_SDK}" CACHE PATH "Path to Vulkan SDK install directory." FORCE) set(VulkanSDK_ROOT_DIR "$ENV{VULKAN_SDK}" CACHE PATH "Path to Vulkan SDK install directory." FORCE)
endif() endif()
if(NOT EXISTS ${VulkanSDK_ROOT_DIR}) if(NOT EXISTS ${VulkanSDK_ROOT_DIR})
...@@ -17,7 +16,7 @@ find_path(VulkanSDK_INCLUDE_DIR ...@@ -17,7 +16,7 @@ find_path(VulkanSDK_INCLUDE_DIR
vulkan/vulkan.h vulkan/vulkan.h
PATHS PATHS
${VulkanSDK_ROOT_DIR}/Include ${VulkanSDK_ROOT_DIR}/Include
) )
mark_as_advanced(VulkanSDK_INCLUDE_DIR) mark_as_advanced(VulkanSDK_INCLUDE_DIR)
#----------------------------------------------------------------------------- #-----------------------------------------------------------------------------
...@@ -26,6 +25,8 @@ mark_as_advanced(VulkanSDK_INCLUDE_DIR) ...@@ -26,6 +25,8 @@ mark_as_advanced(VulkanSDK_INCLUDE_DIR)
find_library(VulkanSDK_LIBRARY find_library(VulkanSDK_LIBRARY
NAMES NAMES
vulkan-1 vulkan-1
PATHS
${VulkanSDK_ROOT_DIR}/Lib
) )
mark_as_advanced(VulkanSDK_LIBRARY) mark_as_advanced(VulkanSDK_LIBRARY)
......
...@@ -91,6 +91,11 @@ To support the [Geomagic Touch (formerly Sensable Phantom Omni)](http://www.geom ...@@ -91,6 +91,11 @@ To support the [Geomagic Touch (formerly Sensable Phantom Omni)](http://www.geom
2. Configure your CMake project with the variable `iMSTK_USE_OMNI` set to `ON`. 2. Configure your CMake project with the variable `iMSTK_USE_OMNI` set to `ON`.
3. After configuration, the CMake variable `OPENHAPTICS_ROOT_DIR` should be set to the OpenHaptics path on your system. 3. After configuration, the CMake variable `OPENHAPTICS_ROOT_DIR` should be set to the OpenHaptics path on your system.
* ##### Vulkan Renderer
To use the Vulkan renderer, follow these steps:
* Download the [VulkanSDK](https://vulkan.lunarg.com/).
* Download your GPU vendor's latest drivers.
* Enable the `iMSTK_USE_Vulkan` option in CMake.
## Using iMSTK in your application ## Using iMSTK in your application
*Coming soon* *Coming soon*
......
...@@ -47,6 +47,8 @@ VulkanRenderer::initialize() ...@@ -47,6 +47,8 @@ VulkanRenderer::initialize()
m_creationInfo.enabledExtensionCount = (uint32_t)m_extensions.size(); m_creationInfo.enabledExtensionCount = (uint32_t)m_extensions.size();
m_creationInfo.ppEnabledExtensionNames = &m_extensions[0]; m_creationInfo.ppEnabledExtensionNames = &m_extensions[0];
std::cout << "\n" << "Vulkan Renderer Information:" << std::endl;
for (int i = 0; i < m_extensions.size(); i++) for (int i = 0; i < m_extensions.size(); i++)
{ {
std::cout << "Enabled extension: " << m_creationInfo.ppEnabledExtensionNames[i] << std::endl; std::cout << "Enabled extension: " << m_creationInfo.ppEnabledExtensionNames[i] << std::endl;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment