Skip to content

Commit dc7e615

Browse files
authored
Vrsaa (#10)
* Lots of changes, working towards cool things * UPdating a bunch of dependencies * Generating some profiles, gonna try and use them * Fixed lighting shader to do something reasonable heck yeah * Use the right primitve ID * Fixed some LPV things, it doens't look amazing but it's fine * Reworked voxelizer to emit colors, not SH * Adding ImGUI rendering, it doens't crash * FLycam is only active when the right mouse button is down. Also bulit an event queue * Adding ImGUI debug UI, it's not going well * Fixed ImGUI rendering, it was a dumb bug * Refactoring the render graph's subpass consideration * Un-did a bad refactor * Built new abstraction for descriptor, gonna try it out * Losts of refactors, but it's working better now * Bounding box display working well * Visualizing the voxels I think * Formatting and improvements * Added structs for dynamic rendering * Moved mesh_voxelizer to new API * Converting LPV to DR, calculate layerCount from render targets * Use the descriptor set abstractions for the global texture array * Convert RenderScene::generate_vpls_for_primitive to new API * Dealing with the fallout of making BufferHandle a real boy * Converted the rest of the renderer * Track buffers by index directly, this works for some reason * Convert depth_culling_phase to dynamic rendering * RenderBackend is a global now * Convert shadow pass to dynamic rendering * Converted propagate_lighting to new compute API * Converted lighting pass to dynamic rendering * Converted voxel_visualizaer to dynamic rendering * Converted UI pass to dynamic rendering * Fixed bug with BDA addresses * Fix GPU crash from compute dispatch * Add RenderDoc support, fix some bugs * Various fixes * Clear depth to 1 * Turn off the voxel subsystem * Try to enable the extension, read features from the device * Instance-rate ID buffer online * Creating preprocess buffer * About to embark on a magical shader journey * Actually no * Build BLASes * Fixed RTAS validation errors * Bind the AS to the lighting shader * Renamed sun_light to directional light * Build BLASes at the correct place * Trying to fix up the LPV * Fixed the shadows FINALLY * converting the texture pool to plf::colony, buffers coming soon * Finished converting textures to plf colony * Convert the buffer pool to plf::colony * Switched acceleration structure pool to plf::colony * Fixed the flicker! * Use a fixed size draw for VPL injection * Only add VPLs with non-zero contributions * Basic VPL visualization, revealed an issue * Fixed flicker * Fixed the LPV FINALLY * Beginning to add a sky * Prepare for optical flow motion vectors * Got the sky working and messed with the tonemapping a bit, it still sucks * Tweaked lighting a bit more, it's plausible * Adding CACAO * Continuing to struggle with CACAO * Generate contrast color image * Generating shading rate image * More work towards VRS * It works! * It works! * Switched VSRAA on * Turn VRS on by default * Fixed shadowmap recreation issue * Use the resource upload queue instaed of UB * Debugging, found some bugs, checkpoint before AABB culling * Switch everything to scalar layout, use a different BDA reference, no dice * Beginning slang compile script * Iterating on shader compilation * Fixesd some magic bugs * Upgrade gradle, replace absiel with std * Many fixes to get Android working again * Put the shaders in the correct directory * Smol windows fix * Fix some more crashes, debug some slang issues * Fix more validation errors, finally get slang to work * Removing BDAs
1 parent 6a13636 commit dc7e615

File tree

242 files changed

+126926
-4710
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

242 files changed

+126926
-4710
lines changed

Profiles/AndroidBaseline/VP_ANDROID_baseline_2022.json

Lines changed: 810 additions & 0 deletions
Large diffs are not rendered by default.
Lines changed: 179 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,179 @@
1+
2+
/*
3+
* Copyright (C) 2021-2023 Valve Corporation
4+
* Copyright (C) 2021-2023 LunarG, Inc.
5+
*
6+
* Licensed under the Apache License, Version 2.0 (the "License")
7+
* you may not use this file except in compliance with the License.
8+
* You may obtain a copy of the License at
9+
*
10+
* http://www.apache.org/licenses/LICENSE-2.0
11+
*
12+
* Unless required by applicable law or agreed to in writing, software
13+
* distributed under the License is distributed on an "AS IS" BASIS,
14+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
15+
* See the License for the specific language governing permissions and
16+
* limitations under the License.
17+
*
18+
* This file is ***GENERATED***. Do Not Edit.
19+
* See scripts/gen_profiles_solution.py for modifications.
20+
*/
21+
22+
#ifndef VULKAN_PROFILES_H_
23+
#define VULKAN_PROFILES_H_ 1
24+
25+
#define VPAPI_ATTR
26+
27+
#ifdef __cplusplus
28+
extern "C" {
29+
#endif
30+
31+
#include <vulkan/vulkan.h>
32+
33+
#if defined(VK_VERSION_1_1) && \
34+
defined(VK_ANDROID_external_memory_android_hardware_buffer) && \
35+
defined(VK_EXT_queue_family_foreign) && \
36+
defined(VK_EXT_swapchain_colorspace) && \
37+
defined(VK_GOOGLE_display_timing) && \
38+
defined(VK_KHR_android_surface) && \
39+
defined(VK_KHR_create_renderpass2) && \
40+
defined(VK_KHR_dedicated_allocation) && \
41+
defined(VK_KHR_descriptor_update_template) && \
42+
defined(VK_KHR_driver_properties) && \
43+
defined(VK_KHR_external_fence) && \
44+
defined(VK_KHR_external_fence_capabilities) && \
45+
defined(VK_KHR_external_fence_fd) && \
46+
defined(VK_KHR_external_memory) && \
47+
defined(VK_KHR_external_memory_capabilities) && \
48+
defined(VK_KHR_external_semaphore) && \
49+
defined(VK_KHR_external_semaphore_capabilities) && \
50+
defined(VK_KHR_external_semaphore_fd) && \
51+
defined(VK_KHR_get_memory_requirements2) && \
52+
defined(VK_KHR_get_physical_device_properties2) && \
53+
defined(VK_KHR_get_surface_capabilities2) && \
54+
defined(VK_KHR_incremental_present) && \
55+
defined(VK_KHR_maintenance1) && \
56+
defined(VK_KHR_sampler_mirror_clamp_to_edge) && \
57+
defined(VK_KHR_storage_buffer_storage_class) && \
58+
defined(VK_KHR_surface) && \
59+
defined(VK_KHR_swapchain) && \
60+
defined(VK_KHR_variable_pointers)
61+
#define VP_ANDROID_baseline_2022 1
62+
#define VP_ANDROID_BASELINE_2022_NAME "VP_ANDROID_baseline_2022"
63+
#define VP_ANDROID_BASELINE_2022_SPEC_VERSION 1
64+
#define VP_ANDROID_BASELINE_2022_MIN_API_VERSION VK_MAKE_VERSION(1, 1, 106)
65+
#endif
66+
67+
#define VP_HEADER_VERSION_COMPLETE VK_MAKE_API_VERSION(0, 2, 0, VK_HEADER_VERSION)
68+
69+
#define VP_MAX_PROFILE_NAME_SIZE 256U
70+
71+
typedef struct VpProfileProperties {
72+
char profileName[VP_MAX_PROFILE_NAME_SIZE];
73+
uint32_t specVersion;
74+
} VpProfileProperties;
75+
76+
typedef struct VpBlockProperties {
77+
VpProfileProperties profiles;
78+
uint32_t apiVersion;
79+
char blockName[VP_MAX_PROFILE_NAME_SIZE];
80+
} VpBlockProperties;
81+
82+
typedef enum VpInstanceCreateFlagBits {
83+
VP_INSTANCE_CREATE_FLAG_BITS_MAX_ENUM = 0x7FFFFFFF
84+
} VpInstanceCreateFlagBits;
85+
typedef VkFlags VpInstanceCreateFlags;
86+
87+
typedef struct VpInstanceCreateInfo {
88+
const VkInstanceCreateInfo* pCreateInfo;
89+
VpInstanceCreateFlags flags;
90+
uint32_t enabledFullProfileCount;
91+
const VpProfileProperties* pEnabledFullProfiles;
92+
uint32_t enabledProfileBlockCount;
93+
const VpBlockProperties* pEnabledProfileBlocks;
94+
} VpInstanceCreateInfo;
95+
96+
typedef enum VpDeviceCreateFlagBits {
97+
VP_DEVICE_CREATE_DISABLE_ROBUST_BUFFER_ACCESS_BIT = 0x0000001,
98+
VP_DEVICE_CREATE_DISABLE_ROBUST_IMAGE_ACCESS_BIT = 0x0000002,
99+
VP_DEVICE_CREATE_DISABLE_ROBUST_ACCESS =
100+
VP_DEVICE_CREATE_DISABLE_ROBUST_BUFFER_ACCESS_BIT | VP_DEVICE_CREATE_DISABLE_ROBUST_IMAGE_ACCESS_BIT,
101+
102+
VP_DEVICE_CREATE_FLAG_BITS_MAX_ENUM = 0x7FFFFFFF
103+
} VpDeviceCreateFlagBits;
104+
typedef VkFlags VpDeviceCreateFlags;
105+
106+
typedef struct VpDeviceCreateInfo {
107+
const VkDeviceCreateInfo* pCreateInfo;
108+
VpDeviceCreateFlags flags;
109+
uint32_t enabledFullProfileCount;
110+
const VpProfileProperties* pEnabledFullProfiles;
111+
uint32_t enabledProfileBlockCount;
112+
const VpBlockProperties* pEnabledProfileBlocks;
113+
} VpDeviceCreateInfo;
114+
115+
// Query the list of available profiles in the library
116+
VPAPI_ATTR VkResult vpGetProfiles(uint32_t *pPropertyCount, VpProfileProperties *pProperties);
117+
118+
// List the required profiles of a profile
119+
VPAPI_ATTR VkResult vpGetProfileRequiredProfiles(const VpProfileProperties* pProfile, uint32_t* pPropertyCount, VpProfileProperties* pProperties);
120+
121+
// Query the profile required Vulkan API version
122+
VPAPI_ATTR uint32_t vpGetProfileAPIVersion(const VpProfileProperties* pProfile);
123+
124+
// List the recommended fallback profiles of a profile
125+
VPAPI_ATTR VkResult vpGetProfileFallbacks(const VpProfileProperties *pProfile, uint32_t *pPropertyCount, VpProfileProperties *pProperties);
126+
127+
// Query whether the profile has multiple variants. Profiles with multiple variants can only use vpGetInstanceProfileSupport and vpGetPhysicalDeviceProfileSupport capabilities of the library. Other function will return a VK_ERROR_UNKNOWN error
128+
VPAPI_ATTR VkResult vpHasMultipleVariantsProfile(const VpProfileProperties *pProfile, VkBool32 *pHasMultipleVariants);
129+
130+
// Check whether a profile is supported at the instance level
131+
VPAPI_ATTR VkResult vpGetInstanceProfileSupport(const char *pLayerName, const VpProfileProperties *pProfile, VkBool32 *pSupported);
132+
133+
// Check whether a variant of a profile is supported at the instance level and report this list of blocks used to validate the profiles
134+
VPAPI_ATTR VkResult vpGetInstanceProfileVariantsSupport(const char *pLayerName, const VpProfileProperties *pProfile, VkBool32 *pSupported, uint32_t *pPropertyCount, VpBlockProperties* pProperties);
135+
136+
// Create a VkInstance with the profile instance extensions enabled
137+
VPAPI_ATTR VkResult vpCreateInstance(const VpInstanceCreateInfo *pCreateInfo, const VkAllocationCallbacks *pAllocator, VkInstance *pInstance);
138+
139+
// Check whether a profile is supported by the physical device
140+
VPAPI_ATTR VkResult vpGetPhysicalDeviceProfileSupport(VkInstance instance, VkPhysicalDevice physicalDevice, const VpProfileProperties *pProfile, VkBool32 *pSupported);
141+
142+
// Check whether a variant of a profile is supported by the physical device and report this list of blocks used to validate the profiles
143+
VPAPI_ATTR VkResult vpGetPhysicalDeviceProfileVariantsSupport(VkInstance instance, VkPhysicalDevice physicalDevice, const VpProfileProperties *pProfile, VkBool32 *pSupported, uint32_t *pPropertyCount, VpBlockProperties* pProperties);
144+
145+
// Create a VkDevice with the profile features and device extensions enabled
146+
VPAPI_ATTR VkResult vpCreateDevice(VkPhysicalDevice physicalDevice, const VpDeviceCreateInfo *pCreateInfo, const VkAllocationCallbacks *pAllocator, VkDevice *pDevice);
147+
148+
// Query the list of instance extensions of a profile
149+
VPAPI_ATTR VkResult vpGetProfileInstanceExtensionProperties(const VpProfileProperties *pProfile, const char* pBlockName, uint32_t *pPropertyCount, VkExtensionProperties *pProperties);
150+
151+
// Query the list of device extensions of a profile
152+
VPAPI_ATTR VkResult vpGetProfileDeviceExtensionProperties(const VpProfileProperties *pProfile, const char* pBlockName, uint32_t *pPropertyCount, VkExtensionProperties *pProperties);
153+
154+
// Fill the feature structures with the requirements of a profile
155+
VPAPI_ATTR VkResult vpGetProfileFeatures(const VpProfileProperties *pProfile, const char* pBlockName, void *pNext);
156+
157+
// Query the list of feature structure types specified by the profile
158+
VPAPI_ATTR VkResult vpGetProfileFeatureStructureTypes(const VpProfileProperties *pProfile, const char* pBlockName, uint32_t *pStructureTypeCount, VkStructureType *pStructureTypes);
159+
160+
// Fill the property structures with the requirements of a profile
161+
VPAPI_ATTR VkResult vpGetProfileProperties(const VpProfileProperties *pProfile, const char* pBlockName, void *pNext);
162+
163+
// Query the list of property structure types specified by the profile
164+
VPAPI_ATTR VkResult vpGetProfilePropertyStructureTypes(const VpProfileProperties *pProfile, const char* pBlockName, uint32_t *pStructureTypeCount, VkStructureType *pStructureTypes);
165+
166+
// Query the list of formats with specified requirements by a profile
167+
VPAPI_ATTR VkResult vpGetProfileFormats(const VpProfileProperties *pProfile, const char* pBlockName, uint32_t *pFormatCount, VkFormat *pFormats);
168+
169+
// Query the requirements of a format for a profile
170+
VPAPI_ATTR VkResult vpGetProfileFormatProperties(const VpProfileProperties *pProfile, const char* pBlockName, VkFormat format, void *pNext);
171+
172+
// Query the list of format structure types specified by the profile
173+
VPAPI_ATTR VkResult vpGetProfileFormatStructureTypes(const VpProfileProperties *pProfile, const char* pBlockName, uint32_t *pStructureTypeCount, VkStructureType *pStructureTypes);
174+
175+
#ifdef __cplusplus
176+
}
177+
#endif
178+
179+
#endif // VULKAN_PROFILES_H_

0 commit comments

Comments
 (0)