vulkanprog.c 686 B

1234567891011121314151617181920212223242526
  1. #include <vulkan/vulkan.h>
  2. #include <stdio.h>
  3. int main()
  4. {
  5. VkInstanceCreateInfo instance_create_info = {
  6. VK_STRUCTURE_TYPE_INSTANCE_CREATE_INFO,
  7. NULL,
  8. 0,
  9. NULL,
  10. 0,
  11. NULL,
  12. 0,
  13. NULL,
  14. };
  15. // we don't actually require instance creation to succeed since
  16. // we cannot expect test environments to have a vulkan driver installed.
  17. // As long as this does not produce as segmentation fault or similar,
  18. // everything's alright.
  19. VkInstance instance;
  20. if(vkCreateInstance(&instance_create_info, NULL, &instance) == VK_SUCCESS)
  21. vkDestroyInstance(instance, NULL);
  22. return 0;
  23. }