Commit graph

25 commits

Author SHA1 Message Date
Sascha Willems
570ba6da47 Only apply stencil flag if selected format has a stencil part
Refs #947
2022-05-14 11:44:57 +02:00
Witold Baryluk
be24a9c583
Add VK_PHYSICAL_DEVICE_TYPE_CPU to string 2021-01-07 19:54:33 +00:00
Sascha Willems
a369e6ed96 Apply shader group handle alignment where required
Fixes #787
2020-12-12 08:20:33 +01:00
Sascha Willems
d32663d569 Merged #729 2020-08-23 18:05:39 +02:00
Hanif Ariffin
8b521e2cd9
Don't perform unecessary copy (#727) 2020-08-22 09:21:12 +02:00
Alejandro Piñeiro
d33bc6c75e shadowmappping: check if depth format supports LINEAR filtering
The test uses the format VK_FORMAT_D16_UNORM for the shadow map, and
it sets unconditionally VK_FILTER_LINEAR when using it.

But by spec, it is not mandatory that format to support
filtering. Explained here:

https://www.khronos.org/registry/vulkan/specs/1.2/html/chap32.html

table 51, VK_FORMAT_FEATURE_SAMPLED_IMAGE_FILTER_LINEAR_BIT.

This commit checks if that flag is present with that format to decide
between LINEAR (the default value) or NEAREST (if LINEAR is not
supported). Adds a auxiliar method on VulkanTools just in case it
could be useful for other demos.

This is not detected by the Validation Layers, but raise an assertion
with one of the development tools we use to implement the Mesa v3dv
driver (rpi4 vulkan driver).
2020-06-20 00:08:13 +02:00
Ben Clayton
301e8abf12 Add command flag for picking between shaders
The new `-s`, `--shaders` command line flag allows you to specify whether you want to load the glsl or hlsl shaders.
Defaults to glsl.

Issue: #723
2020-06-01 12:22:28 +01:00
Ben Clayton
ca884587a4 Move shaders into glsl and hlsl directories
Move `data/shaders` to `data/shaders/glsl`
Move `data/hlsl` to `data/shaders/hlsl`

Fix up shader paths in the cpp files to point to the new glsl location.

`data/shaders/hlsl/compile.py` still overwrites the glsl .spv files (for
now).

Issue: #723
2020-06-01 12:22:28 +01:00
Sascha Willems
4b9f10d644 Code cleanup 2020-04-20 21:39:30 +02:00
Sascha Willems
662d2b3464 Centralize asset path handling
Refs #470
Refs #627
2020-02-17 21:09:27 +01:00
Sascha Willems
eb39c1b8ac Removed deprecated function
Refs #576
2019-05-05 14:18:35 +02:00
saschawillems
5fe9f91529 Code cleanup, return and exit conditions for Android 2018-05-01 11:23:36 +02:00
saschawillems
5056563f5d Android alert display functionality using JNI 2018-04-30 22:24:45 +02:00
saschawillems
df223f5b9b Result (exit) codes for fatal terminations 2018-01-21 18:28:17 +01:00
saschawillems
4b0bb1a454 Silent error mode as global toggle 2018-01-21 10:58:30 +01:00
saschawillems
d271098464 Silent error mode 2017-08-26 15:05:59 +02:00
saschawillems
ba0cc82e50 Removed unused parameters for image layout transitions and shader loading (Refs #103) 2017-04-23 11:51:31 +02:00
saschawillems
549f49ff77 Default route for image layout switch statements (fixes gcc compiler warnings, refs #103) 2017-04-22 20:39:16 +02:00
saschawillems
486a6a94c0 image memory barrier access masks (validation) [skip ci] 2017-04-20 21:16:48 +02:00
saschawillems
b399fed33b Check if file to load texture from exists, display error if not 2017-04-13 22:11:00 +02:00
saschawillems
03b671562b Output fatal errors to logcat (Android) [skip ci] 2017-03-07 20:51:48 +01:00
saschawillems
373f005d9a Added function for explicit image memory barrier 2017-02-23 19:56:24 +01:00
Tomek Bury
c32a131788 Use VK_NULL_HANDLE for null shader module.
The VkShaderModule is defined in vulkan.h as:
VK_DEFINE_NON_DISPATCHABLE_HANDLE(VkShaderModule)
2017-02-15 10:43:59 +00:00
saschawillems
1309ee0ef9 Moved tool functions to vks namespace (Refs #260) 2017-02-12 13:10:05 +01:00
saschawillems
a105dfdece File name case [skip ci] 2017-02-12 13:08:17 +01:00
Renamed from base/vulkantools.cpp (Browse further)