Refactor the CMakeLists for all the samples; use vulkan.hpp/vulkan_raii.hpp as precompiled header.
This commit is contained in:
@@ -15,9 +15,8 @@
|
||||
// VulkanHpp Samples : ArrayProxy
|
||||
// Compile test on using vk::ArrayProxy
|
||||
|
||||
#include "vulkan/vulkan.hpp"
|
||||
|
||||
#include <iostream>
|
||||
#include <vulkan/vulkan.hpp>
|
||||
#if ( 20 <= VULKAN_HPP_CPP_VERSION )
|
||||
# include <span>
|
||||
#endif
|
||||
|
||||
@@ -25,9 +25,8 @@
|
||||
// unknow compiler... just ignore the warnings for yourselves ;)
|
||||
#endif
|
||||
|
||||
#include "vulkan/vulkan.hpp"
|
||||
|
||||
#include <iostream>
|
||||
#include <vulkan/vulkan.hpp>
|
||||
|
||||
void fct( vk::ArrayProxyNoTemporaries<int> /*ap*/ ) {}
|
||||
|
||||
@@ -270,7 +269,7 @@ int main( int /*argc*/, char ** /*argv*/ )
|
||||
vk::ArrayProxyNoTemporaries<const int> ap24 = {};
|
||||
assert( ap24.size() == 0 );
|
||||
|
||||
//vk::ArrayProxyNoTemporaries<const int> ap25 = { 0, 1 }; // not supported
|
||||
// vk::ArrayProxyNoTemporaries<const int> ap25 = { 0, 1 }; // not supported
|
||||
|
||||
vk::ArrayProxyNoTemporaries<const int> ap26 = il1;
|
||||
assert( ap26.size() == 2 );
|
||||
|
||||
@@ -17,9 +17,8 @@
|
||||
|
||||
#define VULKAN_HPP_NO_STRUCT_CONSTRUCTORS
|
||||
|
||||
#include "vulkan/vulkan.hpp"
|
||||
|
||||
#include <iostream>
|
||||
#include <vulkan/vulkan.hpp>
|
||||
|
||||
#if defined( __clang__ ) || defined( __GNUC__ )
|
||||
# pragma GCC diagnostic ignored "-Wunused-variable"
|
||||
|
||||
@@ -36,5 +36,5 @@ if (NOT TESTS_BUILD_ONLY_DYNAMIC)
|
||||
)
|
||||
|
||||
set_target_properties(DeviceFunctions PROPERTIES FOLDER "Tests")
|
||||
target_link_libraries(DeviceFunctions PRIVATE utils "${Vulkan_LIBRARIES}")
|
||||
target_link_libraries(DeviceFunctions PRIVATE utils ${Vulkan_LIBRARIES})
|
||||
endif()
|
||||
@@ -27,9 +27,8 @@
|
||||
#undef VULKAN_HPP_DISPATCH_LOADER_DYNAMIC
|
||||
#define VULKAN_HPP_DISPATCH_LOADER_DYNAMIC 0
|
||||
|
||||
#include "vulkan/vulkan.hpp"
|
||||
|
||||
#include <iostream>
|
||||
#include <vulkan/vulkan.hpp>
|
||||
|
||||
static char const * AppName = "DeviceFunctions";
|
||||
static char const * EngineName = "Vulkan.hpp";
|
||||
|
||||
@@ -17,11 +17,9 @@
|
||||
|
||||
#define VULKAN_HPP_DISPATCH_LOADER_DYNAMIC 1
|
||||
|
||||
#include "vulkan/vulkan.hpp"
|
||||
|
||||
#include <iostream>
|
||||
#include <map>
|
||||
#include <vulkan/vulkan.h>
|
||||
#include <vulkan/vulkan.hpp>
|
||||
|
||||
VULKAN_HPP_DEFAULT_DISPATCH_LOADER_DYNAMIC_STORAGE
|
||||
|
||||
|
||||
@@ -15,6 +15,6 @@
|
||||
// VulkanHpp Samples : DispatchLoaderDynamic
|
||||
// Compile test on DispatchLoaderDynamic functions
|
||||
|
||||
#include "vulkan/vulkan.hpp"
|
||||
#include <vulkan/vulkan.hpp>
|
||||
|
||||
VULKAN_HPP_DEFAULT_DISPATCH_LOADER_DYNAMIC_STORAGE
|
||||
|
||||
@@ -15,11 +15,9 @@
|
||||
// VulkanHpp Samples : DispatchLoaderDynamic
|
||||
// Compile test on DispatchLoaderDynamic functions
|
||||
|
||||
#include "vulkan/vulkan.hpp"
|
||||
|
||||
#include <iostream>
|
||||
#include <map>
|
||||
#include <vulkan/vulkan.h>
|
||||
#include <vulkan/vulkan.hpp>
|
||||
|
||||
int main( int /*argc*/, char ** /*argv*/ )
|
||||
{
|
||||
|
||||
@@ -40,6 +40,6 @@ if (NOT TESTS_BUILD_ONLY_DYNAMIC)
|
||||
endif()
|
||||
|
||||
set_target_properties(DispatchLoaderStatic PROPERTIES FOLDER "Tests")
|
||||
target_link_libraries(DispatchLoaderStatic PRIVATE utils "${Vulkan_LIBRARIES}")
|
||||
target_link_libraries(DispatchLoaderStatic PRIVATE utils ${Vulkan_LIBRARIES})
|
||||
|
||||
endif()
|
||||
@@ -18,10 +18,9 @@
|
||||
#undef VULKAN_HPP_DISPATCH_LOADER_DYNAMIC
|
||||
#define VULKAN_HPP_DISPATCH_LOADER_DYNAMIC 0
|
||||
|
||||
#include "vulkan/vulkan.hpp"
|
||||
|
||||
#include <iostream>
|
||||
#include <map>
|
||||
#include <vulkan/vulkan.hpp>
|
||||
|
||||
int main( int /*argc*/, char ** /*argv*/ )
|
||||
{
|
||||
|
||||
@@ -19,9 +19,8 @@
|
||||
#define VULKAN_HPP_NO_EXCEPTIONS
|
||||
#define VULKAN_HPP_DISPATCH_LOADER_DYNAMIC 1
|
||||
|
||||
#include "vulkan/vulkan.hpp"
|
||||
|
||||
#include <iostream>
|
||||
#include <vulkan/vulkan.hpp>
|
||||
|
||||
static char const * AppName = "NoExceptions";
|
||||
static char const * EngineName = "Vulkan.hpp";
|
||||
|
||||
@@ -26,9 +26,8 @@
|
||||
|
||||
#define VULKAN_HPP_DISPATCH_LOADER_DYNAMIC 1
|
||||
|
||||
#include "vulkan/vulkan.hpp"
|
||||
|
||||
#include <iostream>
|
||||
#include <vulkan/vulkan.hpp>
|
||||
|
||||
static char const * AppName = "StructureChain";
|
||||
static char const * EngineName = "Vulkan.hpp";
|
||||
@@ -37,7 +36,8 @@ VULKAN_HPP_DEFAULT_DISPATCH_LOADER_DYNAMIC_STORAGE
|
||||
|
||||
template <typename T>
|
||||
void unused( T const & )
|
||||
{}
|
||||
{
|
||||
}
|
||||
|
||||
int main( int /*argc*/, char ** /*argv*/ )
|
||||
{
|
||||
|
||||
@@ -18,7 +18,6 @@
|
||||
#include "../../samples/utils/shaders.hpp"
|
||||
#include "../../samples/utils/utils.hpp"
|
||||
#include "SPIRV/GlslangToSpv.h"
|
||||
#include "vulkan/vulkan.hpp"
|
||||
|
||||
#include <iostream>
|
||||
|
||||
|
||||
@@ -17,7 +17,7 @@
|
||||
#define VULKAN_HPP_NO_EXCEPTIONS
|
||||
#define VULKAN_HPP_DISPATCH_LOADER_DYNAMIC 1
|
||||
|
||||
#include "vulkan/vulkan.hpp"
|
||||
#include <vulkan/vulkan.hpp>
|
||||
|
||||
VULKAN_HPP_DEFAULT_DISPATCH_LOADER_DYNAMIC_STORAGE
|
||||
|
||||
|
||||
Reference in New Issue
Block a user