Fixed typos
This commit is contained in:
parent
5539991ca5
commit
78f9881ebf
18 changed files with 28 additions and 28 deletions
|
|
@ -278,7 +278,7 @@ public:
|
|||
bufferBarrier.size = compute.storageBuffer.descriptor.range;
|
||||
bufferBarrier.srcAccessMask = VK_ACCESS_SHADER_WRITE_BIT;
|
||||
bufferBarrier.dstAccessMask = VK_ACCESS_SHADER_READ_BIT;
|
||||
// Transfer ownership if compute and graphics queue familiy indices differ
|
||||
// Transfer ownership if compute and graphics queue family indices differ
|
||||
bufferBarrier.srcQueueFamilyIndex = VK_QUEUE_FAMILY_IGNORED;
|
||||
bufferBarrier.dstQueueFamilyIndex = VK_QUEUE_FAMILY_IGNORED;
|
||||
|
||||
|
|
|
|||
|
|
@ -86,7 +86,7 @@ public:
|
|||
struct Particle {
|
||||
glm::vec2 pos; // Particle position
|
||||
glm::vec2 vel; // Particle velocity
|
||||
glm::vec4 gradientPos; // Texture coordiantes for the gradient ramp map
|
||||
glm::vec4 gradientPos; // Texture coordinates for the gradient ramp map
|
||||
};
|
||||
|
||||
VulkanExample() : VulkanExampleBase(ENABLE_VALIDATION)
|
||||
|
|
|
|||
|
|
@ -8,7 +8,7 @@
|
|||
|
||||
/*
|
||||
* Note: This sample is deprecated!
|
||||
* An updated version using VK_EXT_debug_utils along with an in-depth tutorial is available in the pfficial Khronos Vulkan Samples repository at
|
||||
* An updated version using VK_EXT_debug_utils along with an in-depth tutorial is available in the official Khronos Vulkan Samples repository at
|
||||
* https://github.com/KhronosGroup/Vulkan-Samples/blob/master/samples/extensions/debug_utils.
|
||||
*/
|
||||
|
||||
|
|
@ -145,7 +145,7 @@ namespace DebugMarker
|
|||
// End the current debug marker region
|
||||
void endRegion(VkCommandBuffer cmdBuffer)
|
||||
{
|
||||
// Check for valid function (may not be present if not runnin in a debugging application)
|
||||
// Check for valid function (may not be present if not running in a debugging application)
|
||||
if (vkCmdDebugMarkerEnd)
|
||||
{
|
||||
vkCmdDebugMarkerEnd(cmdBuffer);
|
||||
|
|
@ -707,7 +707,7 @@ public:
|
|||
blendAttachmentState.dstAlphaBlendFactor = VK_BLEND_FACTOR_DST_ALPHA;
|
||||
VK_CHECK_RESULT(vkCreateGraphicsPipelines(device, pipelineCache, 1, &pipelineCI, nullptr, &pipelines.postprocess));
|
||||
|
||||
// Name shader moduels for debugging
|
||||
// Name shader modules for debugging
|
||||
// Shader module count starts at 2 when UI overlay in base class is enabled
|
||||
uint32_t moduleIndex = settings.overlay ? 2 : 0;
|
||||
DebugMarker::setObjectName(device, (uint64_t)shaderModules[moduleIndex + 0], VK_DEBUG_REPORT_OBJECT_TYPE_SHADER_MODULE_EXT, "Toon shading vertex shader");
|
||||
|
|
|
|||
|
|
@ -328,7 +328,7 @@ public:
|
|||
subpass.colorAttachmentCount = static_cast<uint32_t>(colorReferences.size());
|
||||
subpass.pDepthStencilAttachment = &depthReference;
|
||||
|
||||
// Use subpass dependencies for attachment layput transitions
|
||||
// Use subpass dependencies for attachment layout transitions
|
||||
std::array<VkSubpassDependency, 2> dependencies;
|
||||
|
||||
dependencies[0].srcSubpass = VK_SUBPASS_EXTERNAL;
|
||||
|
|
@ -405,7 +405,7 @@ public:
|
|||
|
||||
VkCommandBufferBeginInfo cmdBufInfo = vks::initializers::commandBufferBeginInfo();
|
||||
|
||||
// Clear values for all attachments written in the fragment sahder
|
||||
// Clear values for all attachments written in the fragment shader
|
||||
std::array<VkClearValue,4> clearValues;
|
||||
clearValues[0].color = { { 0.0f, 0.0f, 0.0f, 0.0f } };
|
||||
clearValues[1].color = { { 0.0f, 0.0f, 0.0f, 0.0f } };
|
||||
|
|
@ -784,7 +784,7 @@ public:
|
|||
|
||||
// Wait for offscreen semaphore
|
||||
submitInfo.pWaitSemaphores = &offscreenSemaphore;
|
||||
// Signal ready with render complete semaphpre
|
||||
// Signal ready with render complete semaphore
|
||||
submitInfo.pSignalSemaphores = &semaphores.renderComplete;
|
||||
|
||||
// Submit work
|
||||
|
|
|
|||
|
|
@ -225,7 +225,7 @@ public:
|
|||
|
||||
VkCommandBufferBeginInfo cmdBufInfo = vks::initializers::commandBufferBeginInfo();
|
||||
|
||||
// Clear values for all attachments written in the fragment sahder
|
||||
// Clear values for all attachments written in the fragment shader
|
||||
std::array<VkClearValue,4> clearValues;
|
||||
clearValues[0].color = clearValues[1].color = { { 0.0f, 0.0f, 0.0f, 0.0f } };
|
||||
clearValues[2].color = { { 0.0f, 0.0f, 0.0f, 0.0f } };
|
||||
|
|
@ -625,7 +625,7 @@ public:
|
|||
|
||||
// Wait for offscreen semaphore
|
||||
submitInfo.pWaitSemaphores = &offscreenSemaphore;
|
||||
// Signal ready with render complete semaphpre
|
||||
// Signal ready with render complete semaphore
|
||||
submitInfo.pSignalSemaphores = &semaphores.renderComplete;
|
||||
|
||||
// Submit work
|
||||
|
|
|
|||
|
|
@ -782,7 +782,7 @@ public:
|
|||
|
||||
// Wait for offscreen semaphore
|
||||
submitInfo.pWaitSemaphores = &offscreenSemaphore;
|
||||
// Signal ready with render complete semaphpre
|
||||
// Signal ready with render complete semaphore
|
||||
submitInfo.pSignalSemaphores = &semaphores.renderComplete;
|
||||
|
||||
// Submit work
|
||||
|
|
|
|||
|
|
@ -164,7 +164,7 @@ public:
|
|||
std::array<VkDescriptorSetLayoutBinding,2> setLayoutBindings{};
|
||||
|
||||
/*
|
||||
Binding 0: Uniform buffers (used to pass matrices matrices)
|
||||
Binding 0: Uniform buffers (used to pass matrices)
|
||||
*/
|
||||
setLayoutBindings[0].descriptorType = VK_DESCRIPTOR_TYPE_UNIFORM_BUFFER;
|
||||
// Shader binding point
|
||||
|
|
|
|||
|
|
@ -320,7 +320,7 @@ public:
|
|||
v.pos[1] -= 0.5f;
|
||||
}
|
||||
|
||||
// Generate host accesible buffers for the text vertices and indices and upload the data
|
||||
// Generate host accessible buffers for the text vertices and indices and upload the data
|
||||
|
||||
VK_CHECK_RESULT(vulkanDevice->createBuffer(
|
||||
VK_BUFFER_USAGE_VERTEX_BUFFER_BIT,
|
||||
|
|
@ -593,7 +593,7 @@ public:
|
|||
&uniformBuffers.vs,
|
||||
sizeof(uboVS)));
|
||||
|
||||
// Fragment sahder uniform buffer block (Contains font rendering parameters)
|
||||
// Fragment shader uniform buffer block (Contains font rendering parameters)
|
||||
VK_CHECK_RESULT(vulkanDevice->createBuffer(
|
||||
VK_BUFFER_USAGE_UNIFORM_BUFFER_BIT,
|
||||
VK_MEMORY_PROPERTY_HOST_VISIBLE_BIT | VK_MEMORY_PROPERTY_HOST_COHERENT_BIT,
|
||||
|
|
|
|||
|
|
@ -36,7 +36,7 @@ layout (binding = 1) uniform UboInstance {
|
|||
|
||||
***Note:*** When preparing the (host) memory to back up the dynamic uniform buffer object it's crucial to take the [minUniformBufferOffsetAlignment](http://vulkan.gpuinfo.org/listreports.php?limit=minUniformBufferOffsetAlignment) limit of the implementation into account.
|
||||
|
||||
Due to the implementation dependant alignment (different from our actual data size) we can't just use a vector and work with pointers instead:
|
||||
Due to the implementation dependent alignment (different from our actual data size) we can't just use a vector and work with pointers instead:
|
||||
|
||||
```cpp
|
||||
struct UboDataDynamic {
|
||||
|
|
|
|||
|
|
@ -346,7 +346,7 @@ public:
|
|||
void drawNode(VkCommandBuffer commandBuffer, VkPipelineLayout pipelineLayout, VulkanglTFModel::Node node)
|
||||
{
|
||||
if (node.mesh.primitives.size() > 0) {
|
||||
// Pass the node's matrix via push constanst
|
||||
// Pass the node's matrix via push constants
|
||||
// Traverse the node hierarchy to the top-most parent to get the final matrix of the current node
|
||||
glm::mat4 nodeMatrix = node.matrix;
|
||||
VulkanglTFModel::Node* currentParent = node.parent;
|
||||
|
|
|
|||
|
|
@ -49,7 +49,7 @@ void VulkanglTFScene::loadImages(tinygltf::Model& input)
|
|||
|
||||
### Materials
|
||||
|
||||
#### New Material poperties
|
||||
#### New Material properties
|
||||
|
||||
```cpp
|
||||
struct Material
|
||||
|
|
|
|||
|
|
@ -589,7 +589,7 @@ void VulkanglTFModel::drawNode(VkCommandBuffer commandBuffer, VkPipelineLayout p
|
|||
{
|
||||
if (node.mesh.primitives.size() > 0)
|
||||
{
|
||||
// Pass the node's matrix via push constanst
|
||||
// Pass the node's matrix via push constants
|
||||
// Traverse the node hierarchy to the top-most parent to get the final matrix of the current node
|
||||
glm::mat4 nodeMatrix = node.matrix;
|
||||
VulkanglTFModel::Node *currentParent = node.parent;
|
||||
|
|
|
|||
|
|
@ -385,7 +385,7 @@ public:
|
|||
// Depth attachment
|
||||
createAttachment(depthFormat, VK_IMAGE_USAGE_DEPTH_STENCIL_ATTACHMENT_BIT, &offscreen.depth);
|
||||
|
||||
// Set up separate renderpass with references to the colorand depth attachments
|
||||
// Set up separate renderpass with references to the color and depth attachments
|
||||
std::array<VkAttachmentDescription, 3> attachmentDescs = {};
|
||||
|
||||
// Init attachment properties
|
||||
|
|
@ -427,7 +427,7 @@ public:
|
|||
subpass.colorAttachmentCount = 2;
|
||||
subpass.pDepthStencilAttachment = &depthReference;
|
||||
|
||||
// Use subpass dependencies for attachment layput transitions
|
||||
// Use subpass dependencies for attachment layout transitions
|
||||
std::array<VkSubpassDependency, 2> dependencies;
|
||||
|
||||
dependencies[0].srcSubpass = VK_SUBPASS_EXTERNAL;
|
||||
|
|
@ -499,7 +499,7 @@ public:
|
|||
// Two floating point color buffers
|
||||
createAttachment(VK_FORMAT_R32G32B32A32_SFLOAT, VK_IMAGE_USAGE_COLOR_ATTACHMENT_BIT, &filterPass.color[0]);
|
||||
|
||||
// Set up separate renderpass with references to the colorand depth attachments
|
||||
// Set up separate renderpass with references to the color and depth attachments
|
||||
std::array<VkAttachmentDescription, 1> attachmentDescs = {};
|
||||
|
||||
// Init attachment properties
|
||||
|
|
@ -520,7 +520,7 @@ public:
|
|||
subpass.pColorAttachments = colorReferences.data();
|
||||
subpass.colorAttachmentCount = 1;
|
||||
|
||||
// Use subpass dependencies for attachment layput transitions
|
||||
// Use subpass dependencies for attachment layout transitions
|
||||
std::array<VkSubpassDependency, 2> dependencies;
|
||||
|
||||
dependencies[0].srcSubpass = VK_SUBPASS_EXTERNAL;
|
||||
|
|
|
|||
|
|
@ -308,7 +308,7 @@ public:
|
|||
// ...
|
||||
// layout (location = 4) in vec3 instancePos; Per-Instance
|
||||
attributeDescriptions = {
|
||||
// Per-vertex attributees
|
||||
// Per-vertex attributes
|
||||
// These are advanced for each vertex fetched by the vertex shader
|
||||
vks::initializers::vertexInputAttributeDescription(VERTEX_BUFFER_BIND_ID, 0, VK_FORMAT_R32G32B32_SFLOAT, 0), // Location 0: Position
|
||||
vks::initializers::vertexInputAttributeDescription(VERTEX_BUFFER_BIND_ID, 1, VK_FORMAT_R32G32B32_SFLOAT, sizeof(float) * 3), // Location 1: Normal
|
||||
|
|
|
|||
|
|
@ -118,7 +118,7 @@ public:
|
|||
camera.setRotationSpeed(0.5f);
|
||||
camera.setPerspective(60.0f, (float)width / (float)height, 0.1f, 256.0f);
|
||||
settings.overlay = true;
|
||||
// Get number of max. concurrrent threads
|
||||
// Get number of max. concurrent threads
|
||||
numThreads = std::thread::hardware_concurrency();
|
||||
assert(numThreads > 0);
|
||||
#if defined(__ANDROID__)
|
||||
|
|
|
|||
|
|
@ -110,7 +110,7 @@ public:
|
|||
"Input assembly primitives count ",
|
||||
"Vertex shader invocations ",
|
||||
"Clipping stage primitives processed",
|
||||
"Clipping stage primtives output ",
|
||||
"Clipping stage primitives output ",
|
||||
"Fragment shader invocations "
|
||||
};
|
||||
if (deviceFeatures.tessellationShader) {
|
||||
|
|
|
|||
|
|
@ -61,7 +61,7 @@ public:
|
|||
glm::mat4 projection;
|
||||
glm::mat4 view;
|
||||
} matrices;
|
||||
// Seperate data for each instance
|
||||
// Separate data for each instance
|
||||
UboInstanceData *instance;
|
||||
} uboVS;
|
||||
|
||||
|
|
|
|||
|
|
@ -187,7 +187,7 @@ void VulkanExample::prepareSparseTexture(uint32_t width, uint32_t height, uint32
|
|||
texture.layerCount = layerCount;
|
||||
texture.format = format;
|
||||
|
||||
// Get device properites for the requested texture format
|
||||
// Get device properties for the requested texture format
|
||||
VkFormatProperties formatProperties;
|
||||
vkGetPhysicalDeviceFormatProperties(physicalDevice, format, &formatProperties);
|
||||
|
||||
|
|
@ -251,7 +251,7 @@ void VulkanExample::prepareSparseTexture(uint32_t width, uint32_t height, uint32
|
|||
// Check requested image size against hardware sparse limit
|
||||
if (sparseImageMemoryReqs.size > vulkanDevice->properties.limits.sparseAddressSpaceSize)
|
||||
{
|
||||
std::cout << "Error: Requested sparse image size exceeds supportes sparse address space size!" << std::endl;
|
||||
std::cout << "Error: Requested sparse image size exceeds supports sparse address space size!" << std::endl;
|
||||
return;
|
||||
};
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue