2016-02-16 09:53:44 +00:00
// Copyright (c) 2015-2016 The Khronos Group Inc.
// Copyright notice at https://www.khronos.org/registry/speccopyright.html
[[copies]]
= Copy Commands
An application can: copy buffer and image data using several methods
depending on the type of data transfer. Data can: be copied between buffer
objects with fname:vkCmdCopyBuffer and a portion of an image can: be copied
to another image with fname:vkCmdCopyImage. Image data can: also be
copied to and from buffer memory using fname:vkCmdCopyImageToBuffer and
fname:vkCmdCopyBufferToImage. Image data can: be blitted (with or without
scaling and filtering) with fname:vkCmdBlitImage. Multisampled images can:
be resolved to a non-multisampled image with fname:vkCmdResolveImage.
== Common Operation
Some rules for valid operation are common to all copy commands:
* Copy commands must: be recorded outside of a render pass instance.
* For non-sparse resources, the union of the source regions in a given
buffer or image must: not overlap the union of the destination regions
in the same buffer or image.
* For sparse resources, the set of bytes used by all the source regions
must: not intersect the set of bytes used by all the destination
regions.
* Copy regions must: be non-empty.
* Regions must: not extend outside the bounds of the buffer or image
level, except that regions of compressed images can: extend as far as
Change log for March 25, 2016 Vulkan 1.0.7 spec update:
* Bump API patch number and header version number to 7 for this
update.
Github Issues:
* Fix slink:VkSpecializationMapEntry example to avoid C/C++ strict
aliasing issues (public issue 14).
* Clarify the meaning of "matching" in flink:vkCmdBindDescriptorSets
validity language (public issue 33).
* Add stub reference pages so xrefs to not-yet-written pages don't
generate 404 errors. However, the actual content of these pages
still needs to be filled in as time allows (public issue 44, but
does not close that issue out).
* Remove incorrect validity statement for
flink:vkGetImageSparseMemoryRequirements (public issue 85).
* Reword the
<<features-limits-bufferImageGranularity,bufferImageGranularity>>
feature in terms of "aliasing", and clarify that it applies to
bindings in the same memory object (public issue 90).
* Clarify the relationship of the slink:VkPhysicalDeviceLimits
pname:maxViewportDimensions and pname:viewportBoundsRange limits
(public issue 92).
* Specify sparse unbound texture replacement in the
<<textures-texel-replacement,Texel Replacement>> section
independently of robust buffer access language (public issue 100).
* Add the <<fundamentals-architecture-model,Architecture Model>>
section to explain architecture constraints Vulkan has chosen to
accept in order to enable portable and performant code (public issue
122).
* State that an object must not be destroyed until *all* (not *any*)
uses of that object have completed (public issue 123).
* Minor editorial cleanup (public issues 129, 134, 146, 148).
* Add validity language for layer and extension names to
slink:VkDeviceCreateInfo matching that used for
slink:VkInstanceCreateInfo (public issue 130).
* Clean up terminology for the case when the bits set in one bitmask
are a subset of the bits set in another bitmask (public issue 138).
* Document that input attachments are UniformConstant not Input, in
the <<interfaces-inputattachment,Fragment Input Attachment
Interface>> section (public glslang bug 169).
Internal Issues:
* Add max enum values to "flag bits" enums (internal issue #136).
* Clarify language around the various uses of the term "block" in the
<<appendix-compressedtex-bc,Block Compressed Image Formats>> section
(internal issue #202).
* Removed "expand" dependency from <enums> groups in vk.xml and added
auto-generation code in the scripts to infer it instead, to ensure
consistency. This caused renaming of sname:VkColorSpaceKHR and
sname:VkPresentModeKHR etext:BEGIN_RANGE (etc.) tokens, but those
tokens are metadata, not part of the API, and the Vulkan WG is OK
with this change. This change adds ranges to two additional enums
that were missing them due to not defining the "expand" attribute
(internal issue 217).
* Tweak makefile to generate ref page nroff (.3) files in the right
output directory, working around an a2x limitation (internal issue
223).
Other Commits:
* Add validity requirements for flink:vkCmdCopyQueryPoolResults
pname:dstBuffer parameter.
* Fix ref page build to generate .3 targets in the right output
directory.
2016-03-25 09:25:04 +00:00
the dimension of the image level rounded up to a complete compressed
texel block.
2016-02-16 09:53:44 +00:00
* Source image subresources must: be in either the
ename:VK_IMAGE_LAYOUT_GENERAL or
ename:VK_IMAGE_LAYOUT_TRANSFER_SRC_OPTIMAL layout. Destination image
subresources must: be in either the ename:VK_IMAGE_LAYOUT_GENERAL or
ename:VK_IMAGE_LAYOUT_TRANSFER_DST_OPTIMAL layout. As a consequence, if
an image subresource is used as both source and destination of a copy,
it must: be in the ename:VK_IMAGE_LAYOUT_GENERAL layout.
* Source images must: have been created with the
ename:VK_IMAGE_USAGE_TRANSFER_SRC_BIT usage bit enabled and destination
images must: have been created with the
ename:VK_IMAGE_USAGE_TRANSFER_DST_BIT usage bit enabled.
* Source buffers must: have been created with the
ename:VK_BUFFER_USAGE_TRANSFER_SRC_BIT usage bit enabled and destination
buffers must: have been created with the
ename:VK_BUFFER_USAGE_TRANSFER_DST_BIT usage bit enabled.
All copy commands are treated as ``transfer'' operations for the purposes of
synchronization barriers.
[[copies-buffers]]
== Copying Data Between Buffers
2016-09-17 04:22:17 +00:00
// refBegin vkCmdCopyBuffer Copy data between buffer regions
2016-07-11 01:13:41 +00:00
2016-02-16 09:53:44 +00:00
To copy data between buffer objects, call:
Change log for July 22, 2016 Vulkan 1.0.22 spec update:
* Bump API patch number and header version number to 22 for this update.
Github Issues:
* Translate the subpass self-dependency language into concrete
validity statements, and added a validity statement about the
restrictions on layout parameters (public issue 267).
* Add validity requirement that
slink:VkAttachmentDescription::pname:finalLayout and
slink:VkAttachmentReference::pname:layout must not be
ename:VK_IMAGE_LAYOUT_UNDEFINED or
ename:VK_IMAGE_LAYOUT_PREINITIALIZED (public issue 268).
* Clarify that slink:VkSubpassDescription::pname:pResolveAttachments
layouts are used. Make language consistent with other attachment
arrays (public issue 270).
* Changed 64-bit definition for
dname:VK_DEFINE_NON_DISPATCHABLE_HANDLE to work for x32 platform in
+vk.xml+ and the resulting +vulkan.h+ (public issue 282).
* Add missing error return code for
flink:vkEnumerateInstanceExtensionProperties and
flink:vkEnumerateDeviceExtensionProperties (public issue 285)
* Fix several cases of stext::VkStructName.memberName markup to
stext::VkStructName::pname:memberName, to match other usage in the
spec, and describe this markup in the style guide (public issue
286).
* Modified validity language generation script to avoid redundant
common ancestor language if covered by generic parent language, and
used `Both' instead of `Each' when appropriate (public issue 288).
Internal Issues:
* Add language about behavior of flink:vkAllocateDescriptorSets when
allocation fails due to fragmentation, a new error
ename:VK_ERROR_FRAGMENTED_POOL, and a Note explaining the situation
(internal issue 309).
* For the features of code:PointSize, code:ClipDistance, and
code:CullDistance, the SPIR-V capability is required to be declared
on use (read or write) rather than on decoration (internal issue
359).
* Have desktop versions of GLSL respect precision qualification
(code:mediump and code:lowp) when compiling for Vulkan. These will
get translated to SPIR-V's code:RelaxedPrecision decoration as they
do with OpenGL ES versions of GLSL (ESSL). The default precision of
all types is code:highp when using a desktop version (internal issue
360).
* Add validity statement for slink:VkImageCreateInfo specifying that
multisampled images must be two-dimensional, optimally tiled, and
with a single mipmap level (internal issue 369).
* Add validity statements to slink:VkImageViewCreateInfo disallowing
creation of images or image views with no supported features. Made
some slink:VkImageViewCreateInfo validity statements more precise
and consistent. Added a Note to the <<features,features>> chapter
about formats with no features (internal issue 371).
* Remove +manpages+ from default build targets. Nroff outputs
containing imbedded latexmath will not render properly. Fixing this
is a lot of work for limited use cases (internal issue 401).
Other Commits:
* Fix flink:vkRenderPassBeginInfo::pname:clearValueCount validity
statement to be based on attachment indices rather than the number
of cleared attachments
(Vulkan-LoaderAndValidationLayers/issues/601).
* Convert registry documentation from LaTeX to asciidoc source and
rename from +src/spec/readme.tex+ to +src/spec/registry.txt+.
* Fix lack of Oxford commas in validity language.
* Lots of cleanup of generator scripts and Makefiles to move extension
list for generator into the script arguments instead of the body of
genvk.py, and express better dependencies between XML, scripts, and
generated files.
2016-07-23 10:15:48 +00:00
include::../api/protos/vkCmdCopyBuffer.txt[]
2016-02-16 09:53:44 +00:00
* pname:commandBuffer is the command buffer into which the command will be
recorded.
* pname:srcBuffer is the source buffer.
* pname:dstBuffer is the destination buffer.
* pname:regionCount is the number of regions to copy.
* pname:pRegions is a pointer to an array of slink:VkBufferCopy structures
specifying the regions to copy.
Each region in pname:pRegions is copied from the source buffer to the same
region of the destination buffer. pname:srcBuffer and pname:dstBuffer can:
be the same buffer or alias the same memory, but the result is undefined if
the copy regions overlap in memory.
include::../validity/protos/vkCmdCopyBuffer.txt[]
2016-09-17 04:22:17 +00:00
// refBegin VkBufferCopy Structure specifying a buffer copy operation
2016-07-11 01:13:41 +00:00
2016-04-21 08:08:38 +00:00
The sname:VkBufferCopy structure is defined as:
2016-02-16 09:53:44 +00:00
Change log for July 22, 2016 Vulkan 1.0.22 spec update:
* Bump API patch number and header version number to 22 for this update.
Github Issues:
* Translate the subpass self-dependency language into concrete
validity statements, and added a validity statement about the
restrictions on layout parameters (public issue 267).
* Add validity requirement that
slink:VkAttachmentDescription::pname:finalLayout and
slink:VkAttachmentReference::pname:layout must not be
ename:VK_IMAGE_LAYOUT_UNDEFINED or
ename:VK_IMAGE_LAYOUT_PREINITIALIZED (public issue 268).
* Clarify that slink:VkSubpassDescription::pname:pResolveAttachments
layouts are used. Make language consistent with other attachment
arrays (public issue 270).
* Changed 64-bit definition for
dname:VK_DEFINE_NON_DISPATCHABLE_HANDLE to work for x32 platform in
+vk.xml+ and the resulting +vulkan.h+ (public issue 282).
* Add missing error return code for
flink:vkEnumerateInstanceExtensionProperties and
flink:vkEnumerateDeviceExtensionProperties (public issue 285)
* Fix several cases of stext::VkStructName.memberName markup to
stext::VkStructName::pname:memberName, to match other usage in the
spec, and describe this markup in the style guide (public issue
286).
* Modified validity language generation script to avoid redundant
common ancestor language if covered by generic parent language, and
used `Both' instead of `Each' when appropriate (public issue 288).
Internal Issues:
* Add language about behavior of flink:vkAllocateDescriptorSets when
allocation fails due to fragmentation, a new error
ename:VK_ERROR_FRAGMENTED_POOL, and a Note explaining the situation
(internal issue 309).
* For the features of code:PointSize, code:ClipDistance, and
code:CullDistance, the SPIR-V capability is required to be declared
on use (read or write) rather than on decoration (internal issue
359).
* Have desktop versions of GLSL respect precision qualification
(code:mediump and code:lowp) when compiling for Vulkan. These will
get translated to SPIR-V's code:RelaxedPrecision decoration as they
do with OpenGL ES versions of GLSL (ESSL). The default precision of
all types is code:highp when using a desktop version (internal issue
360).
* Add validity statement for slink:VkImageCreateInfo specifying that
multisampled images must be two-dimensional, optimally tiled, and
with a single mipmap level (internal issue 369).
* Add validity statements to slink:VkImageViewCreateInfo disallowing
creation of images or image views with no supported features. Made
some slink:VkImageViewCreateInfo validity statements more precise
and consistent. Added a Note to the <<features,features>> chapter
about formats with no features (internal issue 371).
* Remove +manpages+ from default build targets. Nroff outputs
containing imbedded latexmath will not render properly. Fixing this
is a lot of work for limited use cases (internal issue 401).
Other Commits:
* Fix flink:vkRenderPassBeginInfo::pname:clearValueCount validity
statement to be based on attachment indices rather than the number
of cleared attachments
(Vulkan-LoaderAndValidationLayers/issues/601).
* Convert registry documentation from LaTeX to asciidoc source and
rename from +src/spec/readme.tex+ to +src/spec/registry.txt+.
* Fix lack of Oxford commas in validity language.
* Lots of cleanup of generator scripts and Makefiles to move extension
list for generator into the script arguments instead of the body of
genvk.py, and express better dependencies between XML, scripts, and
generated files.
2016-07-23 10:15:48 +00:00
include::../api/structs/VkBufferCopy.txt[]
2016-02-16 09:53:44 +00:00
* pname:srcOffset is the starting offset in bytes from the start of
pname:srcBuffer.
* pname:dstOffset is the starting offset in bytes from the start of
pname:dstBuffer.
* pname:size is the number of bytes to copy.
include::../validity/structs/VkBufferCopy.txt[]
[[copies-images]]
== Copying Data Between Images
fname:vkCmdCopyImage performs image copies in a similar manner to a host
memcpy. It does not perform general-purpose conversions such as scaling,
resizing, blending, color-space conversion, or format conversions.
Rather, it simply copies raw image data. fname:vkCmdCopyImage can: copy
between images with different formats, provided the formats are compatible
as defined below.
2016-09-17 04:22:17 +00:00
// refBegin vkCmdCopyImage Copy data between images
2016-07-11 01:13:41 +00:00
2016-02-16 09:53:44 +00:00
To copy data between image objects, call:
Change log for July 22, 2016 Vulkan 1.0.22 spec update:
* Bump API patch number and header version number to 22 for this update.
Github Issues:
* Translate the subpass self-dependency language into concrete
validity statements, and added a validity statement about the
restrictions on layout parameters (public issue 267).
* Add validity requirement that
slink:VkAttachmentDescription::pname:finalLayout and
slink:VkAttachmentReference::pname:layout must not be
ename:VK_IMAGE_LAYOUT_UNDEFINED or
ename:VK_IMAGE_LAYOUT_PREINITIALIZED (public issue 268).
* Clarify that slink:VkSubpassDescription::pname:pResolveAttachments
layouts are used. Make language consistent with other attachment
arrays (public issue 270).
* Changed 64-bit definition for
dname:VK_DEFINE_NON_DISPATCHABLE_HANDLE to work for x32 platform in
+vk.xml+ and the resulting +vulkan.h+ (public issue 282).
* Add missing error return code for
flink:vkEnumerateInstanceExtensionProperties and
flink:vkEnumerateDeviceExtensionProperties (public issue 285)
* Fix several cases of stext::VkStructName.memberName markup to
stext::VkStructName::pname:memberName, to match other usage in the
spec, and describe this markup in the style guide (public issue
286).
* Modified validity language generation script to avoid redundant
common ancestor language if covered by generic parent language, and
used `Both' instead of `Each' when appropriate (public issue 288).
Internal Issues:
* Add language about behavior of flink:vkAllocateDescriptorSets when
allocation fails due to fragmentation, a new error
ename:VK_ERROR_FRAGMENTED_POOL, and a Note explaining the situation
(internal issue 309).
* For the features of code:PointSize, code:ClipDistance, and
code:CullDistance, the SPIR-V capability is required to be declared
on use (read or write) rather than on decoration (internal issue
359).
* Have desktop versions of GLSL respect precision qualification
(code:mediump and code:lowp) when compiling for Vulkan. These will
get translated to SPIR-V's code:RelaxedPrecision decoration as they
do with OpenGL ES versions of GLSL (ESSL). The default precision of
all types is code:highp when using a desktop version (internal issue
360).
* Add validity statement for slink:VkImageCreateInfo specifying that
multisampled images must be two-dimensional, optimally tiled, and
with a single mipmap level (internal issue 369).
* Add validity statements to slink:VkImageViewCreateInfo disallowing
creation of images or image views with no supported features. Made
some slink:VkImageViewCreateInfo validity statements more precise
and consistent. Added a Note to the <<features,features>> chapter
about formats with no features (internal issue 371).
* Remove +manpages+ from default build targets. Nroff outputs
containing imbedded latexmath will not render properly. Fixing this
is a lot of work for limited use cases (internal issue 401).
Other Commits:
* Fix flink:vkRenderPassBeginInfo::pname:clearValueCount validity
statement to be based on attachment indices rather than the number
of cleared attachments
(Vulkan-LoaderAndValidationLayers/issues/601).
* Convert registry documentation from LaTeX to asciidoc source and
rename from +src/spec/readme.tex+ to +src/spec/registry.txt+.
* Fix lack of Oxford commas in validity language.
* Lots of cleanup of generator scripts and Makefiles to move extension
list for generator into the script arguments instead of the body of
genvk.py, and express better dependencies between XML, scripts, and
generated files.
2016-07-23 10:15:48 +00:00
include::../api/protos/vkCmdCopyImage.txt[]
2016-02-16 09:53:44 +00:00
* pname:commandBuffer is the command buffer into which the command will be
recorded.
* pname:srcImage is the source image.
* pname:srcImageLayout is the current layout of the source image
subresource.
* pname:dstImage is the destination image.
* pname:dstImageLayout is the current layout of the destination image
subresource.
* pname:regionCount is the number of regions to copy.
* pname:pRegions is a pointer to an array of slink:VkImageCopy structures
specifying the regions to copy.
Each region in pname:pRegions is copied from the source image to the same
region of the destination image. pname:srcImage and pname:dstImage can: be
the same image or alias the same memory.
Copies are done layer by layer starting with pname:baseArrayLayer member of
pname:srcSubresource for the source and pname:dstSubresource for the
destination. pname:layerCount layers are copied to the destination image.
[[copies-images-format-compatibility]]
The formats of pname:srcImage and pname:dstImage must: be compatible.
Formats are considered compatible if their texel size in bytes is the same
between both formats. For example, ename:VK_FORMAT_R8G8B8A8_UNORM is
Change log for March 25, 2016 Vulkan 1.0.7 spec update:
* Bump API patch number and header version number to 7 for this
update.
Github Issues:
* Fix slink:VkSpecializationMapEntry example to avoid C/C++ strict
aliasing issues (public issue 14).
* Clarify the meaning of "matching" in flink:vkCmdBindDescriptorSets
validity language (public issue 33).
* Add stub reference pages so xrefs to not-yet-written pages don't
generate 404 errors. However, the actual content of these pages
still needs to be filled in as time allows (public issue 44, but
does not close that issue out).
* Remove incorrect validity statement for
flink:vkGetImageSparseMemoryRequirements (public issue 85).
* Reword the
<<features-limits-bufferImageGranularity,bufferImageGranularity>>
feature in terms of "aliasing", and clarify that it applies to
bindings in the same memory object (public issue 90).
* Clarify the relationship of the slink:VkPhysicalDeviceLimits
pname:maxViewportDimensions and pname:viewportBoundsRange limits
(public issue 92).
* Specify sparse unbound texture replacement in the
<<textures-texel-replacement,Texel Replacement>> section
independently of robust buffer access language (public issue 100).
* Add the <<fundamentals-architecture-model,Architecture Model>>
section to explain architecture constraints Vulkan has chosen to
accept in order to enable portable and performant code (public issue
122).
* State that an object must not be destroyed until *all* (not *any*)
uses of that object have completed (public issue 123).
* Minor editorial cleanup (public issues 129, 134, 146, 148).
* Add validity language for layer and extension names to
slink:VkDeviceCreateInfo matching that used for
slink:VkInstanceCreateInfo (public issue 130).
* Clean up terminology for the case when the bits set in one bitmask
are a subset of the bits set in another bitmask (public issue 138).
* Document that input attachments are UniformConstant not Input, in
the <<interfaces-inputattachment,Fragment Input Attachment
Interface>> section (public glslang bug 169).
Internal Issues:
* Add max enum values to "flag bits" enums (internal issue #136).
* Clarify language around the various uses of the term "block" in the
<<appendix-compressedtex-bc,Block Compressed Image Formats>> section
(internal issue #202).
* Removed "expand" dependency from <enums> groups in vk.xml and added
auto-generation code in the scripts to infer it instead, to ensure
consistency. This caused renaming of sname:VkColorSpaceKHR and
sname:VkPresentModeKHR etext:BEGIN_RANGE (etc.) tokens, but those
tokens are metadata, not part of the API, and the Vulkan WG is OK
with this change. This change adds ranges to two additional enums
that were missing them due to not defining the "expand" attribute
(internal issue 217).
* Tweak makefile to generate ref page nroff (.3) files in the right
output directory, working around an a2x limitation (internal issue
223).
Other Commits:
* Add validity requirements for flink:vkCmdCopyQueryPoolResults
pname:dstBuffer parameter.
* Fix ref page build to generate .3 targets in the right output
directory.
2016-03-25 09:25:04 +00:00
compatible with ename:VK_FORMAT_R32_UINT because both texels are 4
2016-02-16 09:53:44 +00:00
bytes in size. Depth/stencil formats must: match exactly.
fname:vkCmdCopyImage allows copying between size-compatible compressed
and uncompressed internal formats. Formats are size-compatible if the texel
Change log for March 25, 2016 Vulkan 1.0.7 spec update:
* Bump API patch number and header version number to 7 for this
update.
Github Issues:
* Fix slink:VkSpecializationMapEntry example to avoid C/C++ strict
aliasing issues (public issue 14).
* Clarify the meaning of "matching" in flink:vkCmdBindDescriptorSets
validity language (public issue 33).
* Add stub reference pages so xrefs to not-yet-written pages don't
generate 404 errors. However, the actual content of these pages
still needs to be filled in as time allows (public issue 44, but
does not close that issue out).
* Remove incorrect validity statement for
flink:vkGetImageSparseMemoryRequirements (public issue 85).
* Reword the
<<features-limits-bufferImageGranularity,bufferImageGranularity>>
feature in terms of "aliasing", and clarify that it applies to
bindings in the same memory object (public issue 90).
* Clarify the relationship of the slink:VkPhysicalDeviceLimits
pname:maxViewportDimensions and pname:viewportBoundsRange limits
(public issue 92).
* Specify sparse unbound texture replacement in the
<<textures-texel-replacement,Texel Replacement>> section
independently of robust buffer access language (public issue 100).
* Add the <<fundamentals-architecture-model,Architecture Model>>
section to explain architecture constraints Vulkan has chosen to
accept in order to enable portable and performant code (public issue
122).
* State that an object must not be destroyed until *all* (not *any*)
uses of that object have completed (public issue 123).
* Minor editorial cleanup (public issues 129, 134, 146, 148).
* Add validity language for layer and extension names to
slink:VkDeviceCreateInfo matching that used for
slink:VkInstanceCreateInfo (public issue 130).
* Clean up terminology for the case when the bits set in one bitmask
are a subset of the bits set in another bitmask (public issue 138).
* Document that input attachments are UniformConstant not Input, in
the <<interfaces-inputattachment,Fragment Input Attachment
Interface>> section (public glslang bug 169).
Internal Issues:
* Add max enum values to "flag bits" enums (internal issue #136).
* Clarify language around the various uses of the term "block" in the
<<appendix-compressedtex-bc,Block Compressed Image Formats>> section
(internal issue #202).
* Removed "expand" dependency from <enums> groups in vk.xml and added
auto-generation code in the scripts to infer it instead, to ensure
consistency. This caused renaming of sname:VkColorSpaceKHR and
sname:VkPresentModeKHR etext:BEGIN_RANGE (etc.) tokens, but those
tokens are metadata, not part of the API, and the Vulkan WG is OK
with this change. This change adds ranges to two additional enums
that were missing them due to not defining the "expand" attribute
(internal issue 217).
* Tweak makefile to generate ref page nroff (.3) files in the right
output directory, working around an a2x limitation (internal issue
223).
Other Commits:
* Add validity requirements for flink:vkCmdCopyQueryPoolResults
pname:dstBuffer parameter.
* Fix ref page build to generate .3 targets in the right output
directory.
2016-03-25 09:25:04 +00:00
size of the uncompressed format is equal to the compressed texel block size in
bytes of the compressed format. Such a copy does not perform on-the-fly
compression or decompression. When copying from an uncompressed format to a
compressed format, each texel of uncompressed data of the source image is
copied as a raw value to the corresponding compressed texel block of the
destination image. When copying from a compressed format to an uncompressed
format, each compressed texel block of the source image is copied as a raw
value to the corresponding texel of uncompressed data in the destination
image. Thus, for example, it is legal to copy between a 128-bit uncompressed
format and a compressed format which has a 128-bit sized compressed texel
block representing 4x4 texels (using 8 bits per texel), or between a 64-bit
uncompressed format and a compressed format which has a 64-bit sized
compressed texel block representing 4x4 texels (using 4 bits per texel).
2016-02-16 09:53:44 +00:00
When copying between compressed and uncompressed formats the pname:extent
members represent the texel dimensions of the source image and not the
destination. When copying from a compressed image to an uncompressed image
the image texel dimensions written to the uncompressed image will be source
Change log for March 25, 2016 Vulkan 1.0.7 spec update:
* Bump API patch number and header version number to 7 for this
update.
Github Issues:
* Fix slink:VkSpecializationMapEntry example to avoid C/C++ strict
aliasing issues (public issue 14).
* Clarify the meaning of "matching" in flink:vkCmdBindDescriptorSets
validity language (public issue 33).
* Add stub reference pages so xrefs to not-yet-written pages don't
generate 404 errors. However, the actual content of these pages
still needs to be filled in as time allows (public issue 44, but
does not close that issue out).
* Remove incorrect validity statement for
flink:vkGetImageSparseMemoryRequirements (public issue 85).
* Reword the
<<features-limits-bufferImageGranularity,bufferImageGranularity>>
feature in terms of "aliasing", and clarify that it applies to
bindings in the same memory object (public issue 90).
* Clarify the relationship of the slink:VkPhysicalDeviceLimits
pname:maxViewportDimensions and pname:viewportBoundsRange limits
(public issue 92).
* Specify sparse unbound texture replacement in the
<<textures-texel-replacement,Texel Replacement>> section
independently of robust buffer access language (public issue 100).
* Add the <<fundamentals-architecture-model,Architecture Model>>
section to explain architecture constraints Vulkan has chosen to
accept in order to enable portable and performant code (public issue
122).
* State that an object must not be destroyed until *all* (not *any*)
uses of that object have completed (public issue 123).
* Minor editorial cleanup (public issues 129, 134, 146, 148).
* Add validity language for layer and extension names to
slink:VkDeviceCreateInfo matching that used for
slink:VkInstanceCreateInfo (public issue 130).
* Clean up terminology for the case when the bits set in one bitmask
are a subset of the bits set in another bitmask (public issue 138).
* Document that input attachments are UniformConstant not Input, in
the <<interfaces-inputattachment,Fragment Input Attachment
Interface>> section (public glslang bug 169).
Internal Issues:
* Add max enum values to "flag bits" enums (internal issue #136).
* Clarify language around the various uses of the term "block" in the
<<appendix-compressedtex-bc,Block Compressed Image Formats>> section
(internal issue #202).
* Removed "expand" dependency from <enums> groups in vk.xml and added
auto-generation code in the scripts to infer it instead, to ensure
consistency. This caused renaming of sname:VkColorSpaceKHR and
sname:VkPresentModeKHR etext:BEGIN_RANGE (etc.) tokens, but those
tokens are metadata, not part of the API, and the Vulkan WG is OK
with this change. This change adds ranges to two additional enums
that were missing them due to not defining the "expand" attribute
(internal issue 217).
* Tweak makefile to generate ref page nroff (.3) files in the right
output directory, working around an a2x limitation (internal issue
223).
Other Commits:
* Add validity requirements for flink:vkCmdCopyQueryPoolResults
pname:dstBuffer parameter.
* Fix ref page build to generate .3 targets in the right output
directory.
2016-03-25 09:25:04 +00:00
extent divided by the compressed texel block dimensions. When copying from an
uncompressed image to a compressed image the image texel dimensions written
to the compressed image will be the source extent multiplied by the
compressed texel block dimensions. In both cases the number of bytes read and
the number of bytes written will be identical.
2016-02-16 09:53:44 +00:00
Copying to or from block-compressed images is typically done in multiples of
Change log for March 25, 2016 Vulkan 1.0.7 spec update:
* Bump API patch number and header version number to 7 for this
update.
Github Issues:
* Fix slink:VkSpecializationMapEntry example to avoid C/C++ strict
aliasing issues (public issue 14).
* Clarify the meaning of "matching" in flink:vkCmdBindDescriptorSets
validity language (public issue 33).
* Add stub reference pages so xrefs to not-yet-written pages don't
generate 404 errors. However, the actual content of these pages
still needs to be filled in as time allows (public issue 44, but
does not close that issue out).
* Remove incorrect validity statement for
flink:vkGetImageSparseMemoryRequirements (public issue 85).
* Reword the
<<features-limits-bufferImageGranularity,bufferImageGranularity>>
feature in terms of "aliasing", and clarify that it applies to
bindings in the same memory object (public issue 90).
* Clarify the relationship of the slink:VkPhysicalDeviceLimits
pname:maxViewportDimensions and pname:viewportBoundsRange limits
(public issue 92).
* Specify sparse unbound texture replacement in the
<<textures-texel-replacement,Texel Replacement>> section
independently of robust buffer access language (public issue 100).
* Add the <<fundamentals-architecture-model,Architecture Model>>
section to explain architecture constraints Vulkan has chosen to
accept in order to enable portable and performant code (public issue
122).
* State that an object must not be destroyed until *all* (not *any*)
uses of that object have completed (public issue 123).
* Minor editorial cleanup (public issues 129, 134, 146, 148).
* Add validity language for layer and extension names to
slink:VkDeviceCreateInfo matching that used for
slink:VkInstanceCreateInfo (public issue 130).
* Clean up terminology for the case when the bits set in one bitmask
are a subset of the bits set in another bitmask (public issue 138).
* Document that input attachments are UniformConstant not Input, in
the <<interfaces-inputattachment,Fragment Input Attachment
Interface>> section (public glslang bug 169).
Internal Issues:
* Add max enum values to "flag bits" enums (internal issue #136).
* Clarify language around the various uses of the term "block" in the
<<appendix-compressedtex-bc,Block Compressed Image Formats>> section
(internal issue #202).
* Removed "expand" dependency from <enums> groups in vk.xml and added
auto-generation code in the scripts to infer it instead, to ensure
consistency. This caused renaming of sname:VkColorSpaceKHR and
sname:VkPresentModeKHR etext:BEGIN_RANGE (etc.) tokens, but those
tokens are metadata, not part of the API, and the Vulkan WG is OK
with this change. This change adds ranges to two additional enums
that were missing them due to not defining the "expand" attribute
(internal issue 217).
* Tweak makefile to generate ref page nroff (.3) files in the right
output directory, working around an a2x limitation (internal issue
223).
Other Commits:
* Add validity requirements for flink:vkCmdCopyQueryPoolResults
pname:dstBuffer parameter.
* Fix ref page build to generate .3 targets in the right output
directory.
2016-03-25 09:25:04 +00:00
the compressed texel block. For this reason the pname:extent must: be a
multiple of the compressed texel block dimension. There is one exception to
this rule which is required: to handle compressed images created with
dimensions that are not a multiple of the compressed texel block dimensions.
If the pname:srcImage is compressed and if pname:extent.width is not a
multiple of the compressed texel block width then (pname:extent.width +
Change log for April 15, 2016 Vulkan 1.0.10 spec update:
* Bump API patch number and header version number to 10 for this
update.
Github Issues:
* Slightly tweak the <<memory-allocation,Host Memory>> allocator language
so that an application wrapping the standard C alloc/free/realloc
functions is still correct - the previous language was too strong with
regards to freeing memory. Also made certain scenarios clearer - an
implementation may now continue without error if an allocation failed
and it is able to continue correctly (public issue 21).
* Require that etext:VK_*_CREATE_SPARSE_BINDING_BIT is set when the
corresponding etext:VK_*_CREATE_SPARSE_RESIDENCY_BIT is used, in the
<<sparsememory-miptail,Mip Tail Regions>> section and related commands
flink:vkCreateBuffer and flink:vkCreateImage (public issue 84).
* Update the <<features,Features, Limits, and Formats>> chapter to clarify
interactions between optional features and dynamic state for the
pname:depthBiasClamp and pname:wideLines features (public issue 89).
* Describe the code:WorkgroupSize builtin in the
<<interfaces-builtin-variables,Built-In Variables>> section, and update
the <<compute-shaders,Compute Shaders>> section to further clarify how
to set the number of workgroups to execute in a compute shader (public
issue 145).
* Use the term *image subresource* everywhere instead of *subresource*,
except for the special case of *host-accessible subresource*, which may
be either an image subresource or buffer range (public issue 120)
* Add a note to the <<features,Features, Limits, and Formats>> section
about extensibility of structures (Public issue 165).
* Fix return code flink:vkAcquireNextImageKHR when the timeout parameter
is 0 to ename:VK_NOT_READY instead of ename:VK_TIMEOUT (public issue
170).
* Fix typo in slink:VkLayerProperties::pname:apiVersion field (public
issue 172).
Internal Issues:
* Fix a few minor internally-detected typos.
* Minor formatting tweaks to pseudocode in the <<resources,Resource
Creation>> chapter (internal issue 179).
* Fix typo in the definition of point sampling for
elink:VkCullModeFlagBits (internal issue 268).
2016-04-14 08:58:49 +00:00
pname:srcOffset.x) must: equal the image subresource width, if
Change log for March 25, 2016 Vulkan 1.0.7 spec update:
* Bump API patch number and header version number to 7 for this
update.
Github Issues:
* Fix slink:VkSpecializationMapEntry example to avoid C/C++ strict
aliasing issues (public issue 14).
* Clarify the meaning of "matching" in flink:vkCmdBindDescriptorSets
validity language (public issue 33).
* Add stub reference pages so xrefs to not-yet-written pages don't
generate 404 errors. However, the actual content of these pages
still needs to be filled in as time allows (public issue 44, but
does not close that issue out).
* Remove incorrect validity statement for
flink:vkGetImageSparseMemoryRequirements (public issue 85).
* Reword the
<<features-limits-bufferImageGranularity,bufferImageGranularity>>
feature in terms of "aliasing", and clarify that it applies to
bindings in the same memory object (public issue 90).
* Clarify the relationship of the slink:VkPhysicalDeviceLimits
pname:maxViewportDimensions and pname:viewportBoundsRange limits
(public issue 92).
* Specify sparse unbound texture replacement in the
<<textures-texel-replacement,Texel Replacement>> section
independently of robust buffer access language (public issue 100).
* Add the <<fundamentals-architecture-model,Architecture Model>>
section to explain architecture constraints Vulkan has chosen to
accept in order to enable portable and performant code (public issue
122).
* State that an object must not be destroyed until *all* (not *any*)
uses of that object have completed (public issue 123).
* Minor editorial cleanup (public issues 129, 134, 146, 148).
* Add validity language for layer and extension names to
slink:VkDeviceCreateInfo matching that used for
slink:VkInstanceCreateInfo (public issue 130).
* Clean up terminology for the case when the bits set in one bitmask
are a subset of the bits set in another bitmask (public issue 138).
* Document that input attachments are UniformConstant not Input, in
the <<interfaces-inputattachment,Fragment Input Attachment
Interface>> section (public glslang bug 169).
Internal Issues:
* Add max enum values to "flag bits" enums (internal issue #136).
* Clarify language around the various uses of the term "block" in the
<<appendix-compressedtex-bc,Block Compressed Image Formats>> section
(internal issue #202).
* Removed "expand" dependency from <enums> groups in vk.xml and added
auto-generation code in the scripts to infer it instead, to ensure
consistency. This caused renaming of sname:VkColorSpaceKHR and
sname:VkPresentModeKHR etext:BEGIN_RANGE (etc.) tokens, but those
tokens are metadata, not part of the API, and the Vulkan WG is OK
with this change. This change adds ranges to two additional enums
that were missing them due to not defining the "expand" attribute
(internal issue 217).
* Tweak makefile to generate ref page nroff (.3) files in the right
output directory, working around an a2x limitation (internal issue
223).
Other Commits:
* Add validity requirements for flink:vkCmdCopyQueryPoolResults
pname:dstBuffer parameter.
* Fix ref page build to generate .3 targets in the right output
directory.
2016-03-25 09:25:04 +00:00
pname:extent.height is not a multiple of the compressed texel block height
Change log for April 15, 2016 Vulkan 1.0.10 spec update:
* Bump API patch number and header version number to 10 for this
update.
Github Issues:
* Slightly tweak the <<memory-allocation,Host Memory>> allocator language
so that an application wrapping the standard C alloc/free/realloc
functions is still correct - the previous language was too strong with
regards to freeing memory. Also made certain scenarios clearer - an
implementation may now continue without error if an allocation failed
and it is able to continue correctly (public issue 21).
* Require that etext:VK_*_CREATE_SPARSE_BINDING_BIT is set when the
corresponding etext:VK_*_CREATE_SPARSE_RESIDENCY_BIT is used, in the
<<sparsememory-miptail,Mip Tail Regions>> section and related commands
flink:vkCreateBuffer and flink:vkCreateImage (public issue 84).
* Update the <<features,Features, Limits, and Formats>> chapter to clarify
interactions between optional features and dynamic state for the
pname:depthBiasClamp and pname:wideLines features (public issue 89).
* Describe the code:WorkgroupSize builtin in the
<<interfaces-builtin-variables,Built-In Variables>> section, and update
the <<compute-shaders,Compute Shaders>> section to further clarify how
to set the number of workgroups to execute in a compute shader (public
issue 145).
* Use the term *image subresource* everywhere instead of *subresource*,
except for the special case of *host-accessible subresource*, which may
be either an image subresource or buffer range (public issue 120)
* Add a note to the <<features,Features, Limits, and Formats>> section
about extensibility of structures (Public issue 165).
* Fix return code flink:vkAcquireNextImageKHR when the timeout parameter
is 0 to ename:VK_NOT_READY instead of ename:VK_TIMEOUT (public issue
170).
* Fix typo in slink:VkLayerProperties::pname:apiVersion field (public
issue 172).
Internal Issues:
* Fix a few minor internally-detected typos.
* Minor formatting tweaks to pseudocode in the <<resources,Resource
Creation>> chapter (internal issue 179).
* Fix typo in the definition of point sampling for
elink:VkCullModeFlagBits (internal issue 268).
2016-04-14 08:58:49 +00:00
then (pname:extent.height + pname:srcOffset.y) must: equal the image
subresource height and if pname:extent.depth is not a multiple of the
compressed texel block depth then (pname:extent.depth + pname:srcOffset.z)
Change log for April 29, 2016 Vulkan 1.0.12 spec update:
* Bump API patch number and header version number to 12 for this
update.
Github Issues:
* Change valid usage statements intended to be "sub-points" to
be actual sub-points (public issue 66).
* Replace double negation in description of
slink:VkRenderPassBeginInfo::pname:pClearValues (based on public
merge 142).
* Cleanup minor typos in spec, ref pages and XML, including those
proposed in public pull requests 144, 150, 151, 167, 168, 181, and
186.
* Use *strict subset* in describing the partial order of memory
property types for slink:VkMemoryType, and update the style guide
accordingly (public issue 190).
* Fix various "a image" -> "an image" typos (public issue 191).
* Note in the <<fundamentals-validusage,Valid Usage>> and
<<extensions-interactions,Extension Interactions>> sections that
structures defined by extensions which may be passed in structure
chains using the ptext:pNext member must: include initial
ptext:sType and ptext:pNext members (public issue 192).
Internal Issues:
* Remove duplicate language from the description of the pname:fence
parameter to flink:vkQueueSubmit and improve validity language
(internal issue 91).
* Added documentation for "optional" attribute to XML readme.tex/pdf
(internal issue 149).
* Clarify the host-side data validity rules and behavior of
flink:vkFlushMappedMemoryRanges and
flink:vkInvalidateMappedMemoryRanges (internal issue 266).
Other Commits:
* Added clarification to flink:vkCmdFillBuffer regarding the use of
ename:VK_WHOLE_SIZE.
* Fixed and documented implementation of "validextensionstructs"
attribute. in XML processing scripts and readme.tex/pdf.
* Add missing validity statements to flink:vkResetEvent and
flink:vkCmdResetEvent.
* Fix validity for the
ename:VK_FORMAT_FEATURE_SAMPLED_IMAGE_FILTER_LINEAR_BIT flag.
Correct all the draw/dispatch commands to mention optimally tiled
images as well as linear tiled images, and say image VIEWS instead
of images. Add validity statement to flink:vkCmdBlitImage
* Replace the {apiname} macro with hardcoded "Vulkan", now that we've
committed to that name.
* Add the VK_AMD_rasterization_order extension to vk.xml.
2016-04-29 12:53:46 +00:00
must: equal the image subresource depth. Similarly, if the pname:dstImage is
Change log for April 15, 2016 Vulkan 1.0.10 spec update:
* Bump API patch number and header version number to 10 for this
update.
Github Issues:
* Slightly tweak the <<memory-allocation,Host Memory>> allocator language
so that an application wrapping the standard C alloc/free/realloc
functions is still correct - the previous language was too strong with
regards to freeing memory. Also made certain scenarios clearer - an
implementation may now continue without error if an allocation failed
and it is able to continue correctly (public issue 21).
* Require that etext:VK_*_CREATE_SPARSE_BINDING_BIT is set when the
corresponding etext:VK_*_CREATE_SPARSE_RESIDENCY_BIT is used, in the
<<sparsememory-miptail,Mip Tail Regions>> section and related commands
flink:vkCreateBuffer and flink:vkCreateImage (public issue 84).
* Update the <<features,Features, Limits, and Formats>> chapter to clarify
interactions between optional features and dynamic state for the
pname:depthBiasClamp and pname:wideLines features (public issue 89).
* Describe the code:WorkgroupSize builtin in the
<<interfaces-builtin-variables,Built-In Variables>> section, and update
the <<compute-shaders,Compute Shaders>> section to further clarify how
to set the number of workgroups to execute in a compute shader (public
issue 145).
* Use the term *image subresource* everywhere instead of *subresource*,
except for the special case of *host-accessible subresource*, which may
be either an image subresource or buffer range (public issue 120)
* Add a note to the <<features,Features, Limits, and Formats>> section
about extensibility of structures (Public issue 165).
* Fix return code flink:vkAcquireNextImageKHR when the timeout parameter
is 0 to ename:VK_NOT_READY instead of ename:VK_TIMEOUT (public issue
170).
* Fix typo in slink:VkLayerProperties::pname:apiVersion field (public
issue 172).
Internal Issues:
* Fix a few minor internally-detected typos.
* Minor formatting tweaks to pseudocode in the <<resources,Resource
Creation>> chapter (internal issue 179).
* Fix typo in the definition of point sampling for
elink:VkCullModeFlagBits (internal issue 268).
2016-04-14 08:58:49 +00:00
compressed and if pname:extent.width is not a multiple of the compressed
texel block width then (pname:extent.width + pname:dstOffset.x) must: equal
the image subresource width, if pname:extent.height is not a multiple of the
compressed texel block height then (pname:extent.height + pname:dstOffset.y)
must: equal the image subresource height and if pname:extent.depth is not a
multiple of the compressed texel block depth then (pname:extent.depth +
pname:dstOffset.z) must: equal the image subresource depth. This allows the
last compressed texel block of the image in each non-multiple dimension to
be included as a source or destination of the copy.
2016-02-16 09:53:44 +00:00
fname:vkCmdCopyImage can: be used to copy image data between multisample
images, but both images must: have the same number of samples.
2016-07-11 01:13:41 +00:00
include::../validity/protos/vkCmdCopyImage.txt[]
2016-09-17 04:22:17 +00:00
// refBegin VkImageCopy Structure specifying an image copy operation
2016-07-11 01:13:41 +00:00
The sname:VkImageCopy structure is defined as:
Change log for July 22, 2016 Vulkan 1.0.22 spec update:
* Bump API patch number and header version number to 22 for this update.
Github Issues:
* Translate the subpass self-dependency language into concrete
validity statements, and added a validity statement about the
restrictions on layout parameters (public issue 267).
* Add validity requirement that
slink:VkAttachmentDescription::pname:finalLayout and
slink:VkAttachmentReference::pname:layout must not be
ename:VK_IMAGE_LAYOUT_UNDEFINED or
ename:VK_IMAGE_LAYOUT_PREINITIALIZED (public issue 268).
* Clarify that slink:VkSubpassDescription::pname:pResolveAttachments
layouts are used. Make language consistent with other attachment
arrays (public issue 270).
* Changed 64-bit definition for
dname:VK_DEFINE_NON_DISPATCHABLE_HANDLE to work for x32 platform in
+vk.xml+ and the resulting +vulkan.h+ (public issue 282).
* Add missing error return code for
flink:vkEnumerateInstanceExtensionProperties and
flink:vkEnumerateDeviceExtensionProperties (public issue 285)
* Fix several cases of stext::VkStructName.memberName markup to
stext::VkStructName::pname:memberName, to match other usage in the
spec, and describe this markup in the style guide (public issue
286).
* Modified validity language generation script to avoid redundant
common ancestor language if covered by generic parent language, and
used `Both' instead of `Each' when appropriate (public issue 288).
Internal Issues:
* Add language about behavior of flink:vkAllocateDescriptorSets when
allocation fails due to fragmentation, a new error
ename:VK_ERROR_FRAGMENTED_POOL, and a Note explaining the situation
(internal issue 309).
* For the features of code:PointSize, code:ClipDistance, and
code:CullDistance, the SPIR-V capability is required to be declared
on use (read or write) rather than on decoration (internal issue
359).
* Have desktop versions of GLSL respect precision qualification
(code:mediump and code:lowp) when compiling for Vulkan. These will
get translated to SPIR-V's code:RelaxedPrecision decoration as they
do with OpenGL ES versions of GLSL (ESSL). The default precision of
all types is code:highp when using a desktop version (internal issue
360).
* Add validity statement for slink:VkImageCreateInfo specifying that
multisampled images must be two-dimensional, optimally tiled, and
with a single mipmap level (internal issue 369).
* Add validity statements to slink:VkImageViewCreateInfo disallowing
creation of images or image views with no supported features. Made
some slink:VkImageViewCreateInfo validity statements more precise
and consistent. Added a Note to the <<features,features>> chapter
about formats with no features (internal issue 371).
* Remove +manpages+ from default build targets. Nroff outputs
containing imbedded latexmath will not render properly. Fixing this
is a lot of work for limited use cases (internal issue 401).
Other Commits:
* Fix flink:vkRenderPassBeginInfo::pname:clearValueCount validity
statement to be based on attachment indices rather than the number
of cleared attachments
(Vulkan-LoaderAndValidationLayers/issues/601).
* Convert registry documentation from LaTeX to asciidoc source and
rename from +src/spec/readme.tex+ to +src/spec/registry.txt+.
* Fix lack of Oxford commas in validity language.
* Lots of cleanup of generator scripts and Makefiles to move extension
list for generator into the script arguments instead of the body of
genvk.py, and express better dependencies between XML, scripts, and
generated files.
2016-07-23 10:15:48 +00:00
include::../api/structs/VkImageCopy.txt[]
2016-07-11 01:13:41 +00:00
* pname:srcSubresource and pname:dstSubresource are
slink:VkImageSubresourceLayers structures specifying the image
subresources of the images used for the source and destination image
data, respectively.
* pname:srcOffset and pname:dstOffset select the initial x, y, and z
offsets in texels of the sub-regions of the source and destination image
data.
* pname:extent is the size in texels of the source image to copy in
pname:width, pname:height and pname:depth. 1D images use only pname:x
and pname:width. 2D images use pname:x, pname:y, pname:width and
pname:height. 3D images use pname:x, pname:y, pname:z, pname:width,
pname:height and pname:depth.
include::../validity/structs/VkImageCopy.txt[]
2016-09-17 04:22:17 +00:00
// refBegin VkImageSubresourceLayers Structure specifying a image subresource layers
2016-07-11 01:13:41 +00:00
The sname:VkImageSubresourceLayers structure is defined as:
Change log for July 22, 2016 Vulkan 1.0.22 spec update:
* Bump API patch number and header version number to 22 for this update.
Github Issues:
* Translate the subpass self-dependency language into concrete
validity statements, and added a validity statement about the
restrictions on layout parameters (public issue 267).
* Add validity requirement that
slink:VkAttachmentDescription::pname:finalLayout and
slink:VkAttachmentReference::pname:layout must not be
ename:VK_IMAGE_LAYOUT_UNDEFINED or
ename:VK_IMAGE_LAYOUT_PREINITIALIZED (public issue 268).
* Clarify that slink:VkSubpassDescription::pname:pResolveAttachments
layouts are used. Make language consistent with other attachment
arrays (public issue 270).
* Changed 64-bit definition for
dname:VK_DEFINE_NON_DISPATCHABLE_HANDLE to work for x32 platform in
+vk.xml+ and the resulting +vulkan.h+ (public issue 282).
* Add missing error return code for
flink:vkEnumerateInstanceExtensionProperties and
flink:vkEnumerateDeviceExtensionProperties (public issue 285)
* Fix several cases of stext::VkStructName.memberName markup to
stext::VkStructName::pname:memberName, to match other usage in the
spec, and describe this markup in the style guide (public issue
286).
* Modified validity language generation script to avoid redundant
common ancestor language if covered by generic parent language, and
used `Both' instead of `Each' when appropriate (public issue 288).
Internal Issues:
* Add language about behavior of flink:vkAllocateDescriptorSets when
allocation fails due to fragmentation, a new error
ename:VK_ERROR_FRAGMENTED_POOL, and a Note explaining the situation
(internal issue 309).
* For the features of code:PointSize, code:ClipDistance, and
code:CullDistance, the SPIR-V capability is required to be declared
on use (read or write) rather than on decoration (internal issue
359).
* Have desktop versions of GLSL respect precision qualification
(code:mediump and code:lowp) when compiling for Vulkan. These will
get translated to SPIR-V's code:RelaxedPrecision decoration as they
do with OpenGL ES versions of GLSL (ESSL). The default precision of
all types is code:highp when using a desktop version (internal issue
360).
* Add validity statement for slink:VkImageCreateInfo specifying that
multisampled images must be two-dimensional, optimally tiled, and
with a single mipmap level (internal issue 369).
* Add validity statements to slink:VkImageViewCreateInfo disallowing
creation of images or image views with no supported features. Made
some slink:VkImageViewCreateInfo validity statements more precise
and consistent. Added a Note to the <<features,features>> chapter
about formats with no features (internal issue 371).
* Remove +manpages+ from default build targets. Nroff outputs
containing imbedded latexmath will not render properly. Fixing this
is a lot of work for limited use cases (internal issue 401).
Other Commits:
* Fix flink:vkRenderPassBeginInfo::pname:clearValueCount validity
statement to be based on attachment indices rather than the number
of cleared attachments
(Vulkan-LoaderAndValidationLayers/issues/601).
* Convert registry documentation from LaTeX to asciidoc source and
rename from +src/spec/readme.tex+ to +src/spec/registry.txt+.
* Fix lack of Oxford commas in validity language.
* Lots of cleanup of generator scripts and Makefiles to move extension
list for generator into the script arguments instead of the body of
genvk.py, and express better dependencies between XML, scripts, and
generated files.
2016-07-23 10:15:48 +00:00
include::../api/structs/VkImageSubresourceLayers.txt[]
2016-07-11 01:13:41 +00:00
* pname:aspectMask is a combination of elink:VkImageAspectFlagBits,
selecting the color, depth and/or stencil aspects to be copied.
* pname:mipLevel is the mipmap level to copy from.
* pname:baseArrayLayer and pname:layerCount are the starting layer and
number of layers to copy.
include::../validity/structs/VkImageSubresourceLayers.txt[]
2016-02-16 09:53:44 +00:00
[[copies-buffers-images]]
== Copying Data Between Buffers and Images
2016-09-17 04:22:17 +00:00
// refBegin vkCmdCopyBufferToImage Copy data from a buffer into an image
2016-07-11 01:13:41 +00:00
2016-02-16 09:53:44 +00:00
To copy data from a buffer object to an image object, call:
Change log for July 22, 2016 Vulkan 1.0.22 spec update:
* Bump API patch number and header version number to 22 for this update.
Github Issues:
* Translate the subpass self-dependency language into concrete
validity statements, and added a validity statement about the
restrictions on layout parameters (public issue 267).
* Add validity requirement that
slink:VkAttachmentDescription::pname:finalLayout and
slink:VkAttachmentReference::pname:layout must not be
ename:VK_IMAGE_LAYOUT_UNDEFINED or
ename:VK_IMAGE_LAYOUT_PREINITIALIZED (public issue 268).
* Clarify that slink:VkSubpassDescription::pname:pResolveAttachments
layouts are used. Make language consistent with other attachment
arrays (public issue 270).
* Changed 64-bit definition for
dname:VK_DEFINE_NON_DISPATCHABLE_HANDLE to work for x32 platform in
+vk.xml+ and the resulting +vulkan.h+ (public issue 282).
* Add missing error return code for
flink:vkEnumerateInstanceExtensionProperties and
flink:vkEnumerateDeviceExtensionProperties (public issue 285)
* Fix several cases of stext::VkStructName.memberName markup to
stext::VkStructName::pname:memberName, to match other usage in the
spec, and describe this markup in the style guide (public issue
286).
* Modified validity language generation script to avoid redundant
common ancestor language if covered by generic parent language, and
used `Both' instead of `Each' when appropriate (public issue 288).
Internal Issues:
* Add language about behavior of flink:vkAllocateDescriptorSets when
allocation fails due to fragmentation, a new error
ename:VK_ERROR_FRAGMENTED_POOL, and a Note explaining the situation
(internal issue 309).
* For the features of code:PointSize, code:ClipDistance, and
code:CullDistance, the SPIR-V capability is required to be declared
on use (read or write) rather than on decoration (internal issue
359).
* Have desktop versions of GLSL respect precision qualification
(code:mediump and code:lowp) when compiling for Vulkan. These will
get translated to SPIR-V's code:RelaxedPrecision decoration as they
do with OpenGL ES versions of GLSL (ESSL). The default precision of
all types is code:highp when using a desktop version (internal issue
360).
* Add validity statement for slink:VkImageCreateInfo specifying that
multisampled images must be two-dimensional, optimally tiled, and
with a single mipmap level (internal issue 369).
* Add validity statements to slink:VkImageViewCreateInfo disallowing
creation of images or image views with no supported features. Made
some slink:VkImageViewCreateInfo validity statements more precise
and consistent. Added a Note to the <<features,features>> chapter
about formats with no features (internal issue 371).
* Remove +manpages+ from default build targets. Nroff outputs
containing imbedded latexmath will not render properly. Fixing this
is a lot of work for limited use cases (internal issue 401).
Other Commits:
* Fix flink:vkRenderPassBeginInfo::pname:clearValueCount validity
statement to be based on attachment indices rather than the number
of cleared attachments
(Vulkan-LoaderAndValidationLayers/issues/601).
* Convert registry documentation from LaTeX to asciidoc source and
rename from +src/spec/readme.tex+ to +src/spec/registry.txt+.
* Fix lack of Oxford commas in validity language.
* Lots of cleanup of generator scripts and Makefiles to move extension
list for generator into the script arguments instead of the body of
genvk.py, and express better dependencies between XML, scripts, and
generated files.
2016-07-23 10:15:48 +00:00
include::../api/protos/vkCmdCopyBufferToImage.txt[]
2016-02-16 09:53:44 +00:00
* pname:commandBuffer is the command buffer into which the command will be
recorded.
* pname:srcBuffer is the source buffer.
* pname:dstImage is the destination image.
* pname:dstImageLayout is the layout of the destination image subresources
for the copy.
* pname:regionCount is the number of regions to copy.
* pname:pRegions is a pointer to an array of slink:VkBufferImageCopy
structures specifying the regions to copy.
Each region in pname:pRegions is copied from the specified region of the
source buffer to the specified region of the destination image.
include::../validity/protos/vkCmdCopyBufferToImage.txt[]
2016-09-17 04:22:17 +00:00
// refBegin vkCmdCopyImageToBuffer Copy image data into a buffer
2016-07-11 01:13:41 +00:00
2016-02-16 09:53:44 +00:00
To copy data from an image object to a buffer object, call:
Change log for July 22, 2016 Vulkan 1.0.22 spec update:
* Bump API patch number and header version number to 22 for this update.
Github Issues:
* Translate the subpass self-dependency language into concrete
validity statements, and added a validity statement about the
restrictions on layout parameters (public issue 267).
* Add validity requirement that
slink:VkAttachmentDescription::pname:finalLayout and
slink:VkAttachmentReference::pname:layout must not be
ename:VK_IMAGE_LAYOUT_UNDEFINED or
ename:VK_IMAGE_LAYOUT_PREINITIALIZED (public issue 268).
* Clarify that slink:VkSubpassDescription::pname:pResolveAttachments
layouts are used. Make language consistent with other attachment
arrays (public issue 270).
* Changed 64-bit definition for
dname:VK_DEFINE_NON_DISPATCHABLE_HANDLE to work for x32 platform in
+vk.xml+ and the resulting +vulkan.h+ (public issue 282).
* Add missing error return code for
flink:vkEnumerateInstanceExtensionProperties and
flink:vkEnumerateDeviceExtensionProperties (public issue 285)
* Fix several cases of stext::VkStructName.memberName markup to
stext::VkStructName::pname:memberName, to match other usage in the
spec, and describe this markup in the style guide (public issue
286).
* Modified validity language generation script to avoid redundant
common ancestor language if covered by generic parent language, and
used `Both' instead of `Each' when appropriate (public issue 288).
Internal Issues:
* Add language about behavior of flink:vkAllocateDescriptorSets when
allocation fails due to fragmentation, a new error
ename:VK_ERROR_FRAGMENTED_POOL, and a Note explaining the situation
(internal issue 309).
* For the features of code:PointSize, code:ClipDistance, and
code:CullDistance, the SPIR-V capability is required to be declared
on use (read or write) rather than on decoration (internal issue
359).
* Have desktop versions of GLSL respect precision qualification
(code:mediump and code:lowp) when compiling for Vulkan. These will
get translated to SPIR-V's code:RelaxedPrecision decoration as they
do with OpenGL ES versions of GLSL (ESSL). The default precision of
all types is code:highp when using a desktop version (internal issue
360).
* Add validity statement for slink:VkImageCreateInfo specifying that
multisampled images must be two-dimensional, optimally tiled, and
with a single mipmap level (internal issue 369).
* Add validity statements to slink:VkImageViewCreateInfo disallowing
creation of images or image views with no supported features. Made
some slink:VkImageViewCreateInfo validity statements more precise
and consistent. Added a Note to the <<features,features>> chapter
about formats with no features (internal issue 371).
* Remove +manpages+ from default build targets. Nroff outputs
containing imbedded latexmath will not render properly. Fixing this
is a lot of work for limited use cases (internal issue 401).
Other Commits:
* Fix flink:vkRenderPassBeginInfo::pname:clearValueCount validity
statement to be based on attachment indices rather than the number
of cleared attachments
(Vulkan-LoaderAndValidationLayers/issues/601).
* Convert registry documentation from LaTeX to asciidoc source and
rename from +src/spec/readme.tex+ to +src/spec/registry.txt+.
* Fix lack of Oxford commas in validity language.
* Lots of cleanup of generator scripts and Makefiles to move extension
list for generator into the script arguments instead of the body of
genvk.py, and express better dependencies between XML, scripts, and
generated files.
2016-07-23 10:15:48 +00:00
include::../api/protos/vkCmdCopyImageToBuffer.txt[]
2016-02-16 09:53:44 +00:00
* pname:commandBuffer is the command buffer into which the command will be
recorded.
* pname:srcImage is the source image.
* pname:srcImageLayout is the layout of the source image subresources for
the copy.
* pname:dstBuffer is the destination buffer.
* pname:regionCount is the number of regions to copy.
* pname:pRegions is a pointer to an array of slink:VkBufferImageCopy
structures specifying the regions to copy.
Each region in pname:pRegions is copied from the specified region of the
2016-02-22 22:01:34 +00:00
source image to the specified region of the destination buffer.
2016-02-16 09:53:44 +00:00
include::../validity/protos/vkCmdCopyImageToBuffer.txt[]
2016-09-17 04:22:17 +00:00
// refBegin VkBufferImageCopy Structure specifying a buffer image copy operation
2016-07-11 01:13:41 +00:00
2016-02-16 09:53:44 +00:00
For both flink:vkCmdCopyBufferToImage and flink:vkCmdCopyImageToBuffer, each
element of pname:pRegions is a structure defined as:
Change log for July 22, 2016 Vulkan 1.0.22 spec update:
* Bump API patch number and header version number to 22 for this update.
Github Issues:
* Translate the subpass self-dependency language into concrete
validity statements, and added a validity statement about the
restrictions on layout parameters (public issue 267).
* Add validity requirement that
slink:VkAttachmentDescription::pname:finalLayout and
slink:VkAttachmentReference::pname:layout must not be
ename:VK_IMAGE_LAYOUT_UNDEFINED or
ename:VK_IMAGE_LAYOUT_PREINITIALIZED (public issue 268).
* Clarify that slink:VkSubpassDescription::pname:pResolveAttachments
layouts are used. Make language consistent with other attachment
arrays (public issue 270).
* Changed 64-bit definition for
dname:VK_DEFINE_NON_DISPATCHABLE_HANDLE to work for x32 platform in
+vk.xml+ and the resulting +vulkan.h+ (public issue 282).
* Add missing error return code for
flink:vkEnumerateInstanceExtensionProperties and
flink:vkEnumerateDeviceExtensionProperties (public issue 285)
* Fix several cases of stext::VkStructName.memberName markup to
stext::VkStructName::pname:memberName, to match other usage in the
spec, and describe this markup in the style guide (public issue
286).
* Modified validity language generation script to avoid redundant
common ancestor language if covered by generic parent language, and
used `Both' instead of `Each' when appropriate (public issue 288).
Internal Issues:
* Add language about behavior of flink:vkAllocateDescriptorSets when
allocation fails due to fragmentation, a new error
ename:VK_ERROR_FRAGMENTED_POOL, and a Note explaining the situation
(internal issue 309).
* For the features of code:PointSize, code:ClipDistance, and
code:CullDistance, the SPIR-V capability is required to be declared
on use (read or write) rather than on decoration (internal issue
359).
* Have desktop versions of GLSL respect precision qualification
(code:mediump and code:lowp) when compiling for Vulkan. These will
get translated to SPIR-V's code:RelaxedPrecision decoration as they
do with OpenGL ES versions of GLSL (ESSL). The default precision of
all types is code:highp when using a desktop version (internal issue
360).
* Add validity statement for slink:VkImageCreateInfo specifying that
multisampled images must be two-dimensional, optimally tiled, and
with a single mipmap level (internal issue 369).
* Add validity statements to slink:VkImageViewCreateInfo disallowing
creation of images or image views with no supported features. Made
some slink:VkImageViewCreateInfo validity statements more precise
and consistent. Added a Note to the <<features,features>> chapter
about formats with no features (internal issue 371).
* Remove +manpages+ from default build targets. Nroff outputs
containing imbedded latexmath will not render properly. Fixing this
is a lot of work for limited use cases (internal issue 401).
Other Commits:
* Fix flink:vkRenderPassBeginInfo::pname:clearValueCount validity
statement to be based on attachment indices rather than the number
of cleared attachments
(Vulkan-LoaderAndValidationLayers/issues/601).
* Convert registry documentation from LaTeX to asciidoc source and
rename from +src/spec/readme.tex+ to +src/spec/registry.txt+.
* Fix lack of Oxford commas in validity language.
* Lots of cleanup of generator scripts and Makefiles to move extension
list for generator into the script arguments instead of the body of
genvk.py, and express better dependencies between XML, scripts, and
generated files.
2016-07-23 10:15:48 +00:00
include::../api/structs/VkBufferImageCopy.txt[]
2016-02-16 09:53:44 +00:00
* pname:bufferOffset is the offset in bytes from the start of the
buffer object where the image data is copied from or to.
* pname:bufferRowLength and pname:bufferImageHeight specify the
data in buffer memory as a subregion of a larger two- or
three-dimensional image, and control the addressing calculations of data
in buffer memory. If either of these values is zero, that aspect of the
buffer memory is considered to be tightly packed according to the
pname:imageExtent.
Change log for August 5, 2016 Vulkan 1.0.23 spec update:
* Bump API patch number and header version number to 23 for this update.
Github Issues:
* Add explicit valid value attributes to pname:sType members in vk.xml
(public issue 34).
* Clarify usage of flink:vkGetInstanceProcAddr and
flink:vkGetDeviceProcAddr (public issue 225).
* Fix a copy-and-paste error in the description of
pname:pSwapchainImageCount saying that it was the count of ``format
pairs'' instead of ``swapchain images'' (public issue 292).
* flink:vkCmdExecuteCommandBuffers requires all command buffers to be
allocated from command pools created for the same queue family (public
issue 296).
* Remove bogus +optional+ attribute for
flink:vkEnumerateDeviceLayerProperties::pname:physicalDevice from vk.xml
(public issue 301).
* Clean up the <<resources-image-views-compatibility,image and image view
compatibility table>> reference and contents. Use full enumerant names.
Refer to pname:layerCount in the ``view parameters'' column instead of
pname:arrayLayers. Require N >= 1 for the cube array subview row, not
just arrayLayers >= 6 N (public issue 304).
* Modify description of <<resources-memory-aliasing,memory aliasing>> to
be consistent with the description of
<<resources-bufferimagegranularity,buffer image granularity>> (public
issue 307).
Internal Issues:
* Describe remaining +vk_platform.h+ macros in the <<boilerplate,API
Boilerplate>> appendix (internal issue 6).
* Clarify
<<features-features-robustBufferAccess,pname:robustBufferAccess>>
feature behavior; what memory can be accessed, how bounds checking is
performed, and allowing for vectorization (internal issue 332).
* Document markup for automatic extraction of reference pages from the
spec sources in the style guide (internal issue 395).
* Allow flink:vkCreateDisplayModeKHR to return
ename:VK_ERROR_INITIALIZAION_FAILED_KHR if the user requests mode
parameters that the specified display does not support (internal issue
411).
* Remove atomic counters (atomic_uint style) from KHR_vulkan_glsl, and
more clearly remove the subroutine keyword alongside it (internal issue
421).
* Clarify behavior of flink:vkCmdBindDescriptorSets for descriptor sets
not contained in the layout (internal issue 427).
Other Commits:
* Change the order in which members of sname:VkAttachmentDescription and
sname:VkPipelineInputAssemblyStateCreateInfo are described to match
their order in the structures.
2016-08-05 12:11:02 +00:00
* pname:imageSubresource is a slink:VkImageSubresourceLayers used to
Change log for April 15, 2016 Vulkan 1.0.10 spec update:
* Bump API patch number and header version number to 10 for this
update.
Github Issues:
* Slightly tweak the <<memory-allocation,Host Memory>> allocator language
so that an application wrapping the standard C alloc/free/realloc
functions is still correct - the previous language was too strong with
regards to freeing memory. Also made certain scenarios clearer - an
implementation may now continue without error if an allocation failed
and it is able to continue correctly (public issue 21).
* Require that etext:VK_*_CREATE_SPARSE_BINDING_BIT is set when the
corresponding etext:VK_*_CREATE_SPARSE_RESIDENCY_BIT is used, in the
<<sparsememory-miptail,Mip Tail Regions>> section and related commands
flink:vkCreateBuffer and flink:vkCreateImage (public issue 84).
* Update the <<features,Features, Limits, and Formats>> chapter to clarify
interactions between optional features and dynamic state for the
pname:depthBiasClamp and pname:wideLines features (public issue 89).
* Describe the code:WorkgroupSize builtin in the
<<interfaces-builtin-variables,Built-In Variables>> section, and update
the <<compute-shaders,Compute Shaders>> section to further clarify how
to set the number of workgroups to execute in a compute shader (public
issue 145).
* Use the term *image subresource* everywhere instead of *subresource*,
except for the special case of *host-accessible subresource*, which may
be either an image subresource or buffer range (public issue 120)
* Add a note to the <<features,Features, Limits, and Formats>> section
about extensibility of structures (Public issue 165).
* Fix return code flink:vkAcquireNextImageKHR when the timeout parameter
is 0 to ename:VK_NOT_READY instead of ename:VK_TIMEOUT (public issue
170).
* Fix typo in slink:VkLayerProperties::pname:apiVersion field (public
issue 172).
Internal Issues:
* Fix a few minor internally-detected typos.
* Minor formatting tweaks to pseudocode in the <<resources,Resource
Creation>> chapter (internal issue 179).
* Fix typo in the definition of point sampling for
elink:VkCullModeFlagBits (internal issue 268).
2016-04-14 08:58:49 +00:00
specify the specific image subresources of the image used for the source
or destination image data.
2016-02-16 09:53:44 +00:00
* pname:imageOffset selects the initial x, y, z offsets in texels of the
sub-region of the source or destination image data.
* pname:imageExtent is the size in texels of the image to copy in
pname:width, pname:height and pname:depth. 1D images use only pname:x
and pname:width. 2D images use pname:x, pname:y, pname:width and
pname:height. 3D images use pname:x, pname:y, pname:z, pname:width,
pname:height and pname:depth.
When copying to or from a depth or stencil aspect, the data in buffer
memory uses a layout that is a (mostly) tightly packed representation of
the depth or stencil data. Specifically:
2016-04-21 08:08:38 +00:00
* data copied to or from the stencil aspect of any depth/stencil format
is tightly packed with one ename:VK_FORMAT_S8_UINT value per texel.
* data copied to or from the depth aspect of a ename:VK_FORMAT_D16_UNORM
or ename:VK_FORMAT_D16_UNORM_S8_UINT format is tightly packed with one
ename:VK_FORMAT_D16_UNORM value per texel.
* data copied to or from the depth aspect of a ename:VK_FORMAT_D32_SFLOAT
or ename:VK_FORMAT_D32_SFLOAT_S8_UINT format is tightly packed with
one ename:VK_FORMAT_D32_SFLOAT value per texel.
* data copied to or from the depth aspect of a
ename:VK_FORMAT_X8_D24_UNORM_PACK32 or
ename:VK_FORMAT_D24_UNORM_S8_UINT format is packed with one 32-bit word
per texel with the D24 value in the LSBs of the word, and undefined
values in the eight MSBs.
2016-02-16 09:53:44 +00:00
[NOTE]
.Note
====
To copy both the depth and stencil aspects of a depth/stencil format, two
entries in pname:pRegions can: be used, where one specifies the depth
aspect in pname:imageSubresource, and the other specifies the stencil
aspect.
====
Because depth or stencil aspect buffer to image copies may: require format
conversions on some implementations, they are not supported on queues
2016-09-17 04:22:17 +00:00
that do not support graphics. When copying to a depth aspect, the data in
buffer memory must: be in the the range latexmath:[$[0,1\]$] or undefined
results occur.
2016-02-16 09:53:44 +00:00
Copies are done layer by layer starting with image layer
pname:baseArrayLayer member of pname:imageSubresource. pname:layerCount
layers are copied from the source image or to the destination image.
include::../validity/structs/VkBufferImageCopy.txt[]
Pseudocode for image/buffer addressing is:
[source,c]
---------------------------------------------------
rowLength = region->bufferRowLength;
if (rowLength == 0)
rowLength = region->imageExtent.width;
imageHeight = region->bufferImageHeight;
if (imageHeight == 0)
imageHeight = region->imageExtent.height;
texelSize = <texel size taken from the src/dstImage>;
address of (x,y,z) = region->bufferOffset + (((z * imageHeight) + y) * rowLength + x) * texelSize;
where x,y,z range from (0,0,0) to region->imageExtent.{width,height,depth}.
---------------------------------------------------
Note that pname:imageOffset does not affect addressing calculations for
buffer memory. Instead, pname:bufferOffset can: be used to
select the starting address in buffer memory.
For block-compression formats, all parameters are still specified in texels
Change log for March 25, 2016 Vulkan 1.0.7 spec update:
* Bump API patch number and header version number to 7 for this
update.
Github Issues:
* Fix slink:VkSpecializationMapEntry example to avoid C/C++ strict
aliasing issues (public issue 14).
* Clarify the meaning of "matching" in flink:vkCmdBindDescriptorSets
validity language (public issue 33).
* Add stub reference pages so xrefs to not-yet-written pages don't
generate 404 errors. However, the actual content of these pages
still needs to be filled in as time allows (public issue 44, but
does not close that issue out).
* Remove incorrect validity statement for
flink:vkGetImageSparseMemoryRequirements (public issue 85).
* Reword the
<<features-limits-bufferImageGranularity,bufferImageGranularity>>
feature in terms of "aliasing", and clarify that it applies to
bindings in the same memory object (public issue 90).
* Clarify the relationship of the slink:VkPhysicalDeviceLimits
pname:maxViewportDimensions and pname:viewportBoundsRange limits
(public issue 92).
* Specify sparse unbound texture replacement in the
<<textures-texel-replacement,Texel Replacement>> section
independently of robust buffer access language (public issue 100).
* Add the <<fundamentals-architecture-model,Architecture Model>>
section to explain architecture constraints Vulkan has chosen to
accept in order to enable portable and performant code (public issue
122).
* State that an object must not be destroyed until *all* (not *any*)
uses of that object have completed (public issue 123).
* Minor editorial cleanup (public issues 129, 134, 146, 148).
* Add validity language for layer and extension names to
slink:VkDeviceCreateInfo matching that used for
slink:VkInstanceCreateInfo (public issue 130).
* Clean up terminology for the case when the bits set in one bitmask
are a subset of the bits set in another bitmask (public issue 138).
* Document that input attachments are UniformConstant not Input, in
the <<interfaces-inputattachment,Fragment Input Attachment
Interface>> section (public glslang bug 169).
Internal Issues:
* Add max enum values to "flag bits" enums (internal issue #136).
* Clarify language around the various uses of the term "block" in the
<<appendix-compressedtex-bc,Block Compressed Image Formats>> section
(internal issue #202).
* Removed "expand" dependency from <enums> groups in vk.xml and added
auto-generation code in the scripts to infer it instead, to ensure
consistency. This caused renaming of sname:VkColorSpaceKHR and
sname:VkPresentModeKHR etext:BEGIN_RANGE (etc.) tokens, but those
tokens are metadata, not part of the API, and the Vulkan WG is OK
with this change. This change adds ranges to two additional enums
that were missing them due to not defining the "expand" attribute
(internal issue 217).
* Tweak makefile to generate ref page nroff (.3) files in the right
output directory, working around an a2x limitation (internal issue
223).
Other Commits:
* Add validity requirements for flink:vkCmdCopyQueryPoolResults
pname:dstBuffer parameter.
* Fix ref page build to generate .3 targets in the right output
directory.
2016-03-25 09:25:04 +00:00
rather than compressed texel blocks, but the addressing math operates on
whole compressed texel blocks. Pseudocode for compressed copy addressing is:
2016-02-16 09:53:44 +00:00
[source,c]
---------------------------------------------------
rowLength = region->bufferRowLength;
if (rowLength == 0)
rowLength = region->imageExtent.width;
imageHeight = region->bufferImageHeight;
if (imageHeight == 0)
imageHeight = region->imageExtent.height;
Change log for March 25, 2016 Vulkan 1.0.7 spec update:
* Bump API patch number and header version number to 7 for this
update.
Github Issues:
* Fix slink:VkSpecializationMapEntry example to avoid C/C++ strict
aliasing issues (public issue 14).
* Clarify the meaning of "matching" in flink:vkCmdBindDescriptorSets
validity language (public issue 33).
* Add stub reference pages so xrefs to not-yet-written pages don't
generate 404 errors. However, the actual content of these pages
still needs to be filled in as time allows (public issue 44, but
does not close that issue out).
* Remove incorrect validity statement for
flink:vkGetImageSparseMemoryRequirements (public issue 85).
* Reword the
<<features-limits-bufferImageGranularity,bufferImageGranularity>>
feature in terms of "aliasing", and clarify that it applies to
bindings in the same memory object (public issue 90).
* Clarify the relationship of the slink:VkPhysicalDeviceLimits
pname:maxViewportDimensions and pname:viewportBoundsRange limits
(public issue 92).
* Specify sparse unbound texture replacement in the
<<textures-texel-replacement,Texel Replacement>> section
independently of robust buffer access language (public issue 100).
* Add the <<fundamentals-architecture-model,Architecture Model>>
section to explain architecture constraints Vulkan has chosen to
accept in order to enable portable and performant code (public issue
122).
* State that an object must not be destroyed until *all* (not *any*)
uses of that object have completed (public issue 123).
* Minor editorial cleanup (public issues 129, 134, 146, 148).
* Add validity language for layer and extension names to
slink:VkDeviceCreateInfo matching that used for
slink:VkInstanceCreateInfo (public issue 130).
* Clean up terminology for the case when the bits set in one bitmask
are a subset of the bits set in another bitmask (public issue 138).
* Document that input attachments are UniformConstant not Input, in
the <<interfaces-inputattachment,Fragment Input Attachment
Interface>> section (public glslang bug 169).
Internal Issues:
* Add max enum values to "flag bits" enums (internal issue #136).
* Clarify language around the various uses of the term "block" in the
<<appendix-compressedtex-bc,Block Compressed Image Formats>> section
(internal issue #202).
* Removed "expand" dependency from <enums> groups in vk.xml and added
auto-generation code in the scripts to infer it instead, to ensure
consistency. This caused renaming of sname:VkColorSpaceKHR and
sname:VkPresentModeKHR etext:BEGIN_RANGE (etc.) tokens, but those
tokens are metadata, not part of the API, and the Vulkan WG is OK
with this change. This change adds ranges to two additional enums
that were missing them due to not defining the "expand" attribute
(internal issue 217).
* Tweak makefile to generate ref page nroff (.3) files in the right
output directory, working around an a2x limitation (internal issue
223).
Other Commits:
* Add validity requirements for flink:vkCmdCopyQueryPoolResults
pname:dstBuffer parameter.
* Fix ref page build to generate .3 targets in the right output
directory.
2016-03-25 09:25:04 +00:00
compressedTexelBlockSizeInBytes = <compressed texel block size taken from the src/dstImage>;
rowLength /= compressedTexelBlockWidth;
imageHeight /= compressedTexelBlockHeight;
2016-02-16 09:53:44 +00:00
Change log for March 25, 2016 Vulkan 1.0.7 spec update:
* Bump API patch number and header version number to 7 for this
update.
Github Issues:
* Fix slink:VkSpecializationMapEntry example to avoid C/C++ strict
aliasing issues (public issue 14).
* Clarify the meaning of "matching" in flink:vkCmdBindDescriptorSets
validity language (public issue 33).
* Add stub reference pages so xrefs to not-yet-written pages don't
generate 404 errors. However, the actual content of these pages
still needs to be filled in as time allows (public issue 44, but
does not close that issue out).
* Remove incorrect validity statement for
flink:vkGetImageSparseMemoryRequirements (public issue 85).
* Reword the
<<features-limits-bufferImageGranularity,bufferImageGranularity>>
feature in terms of "aliasing", and clarify that it applies to
bindings in the same memory object (public issue 90).
* Clarify the relationship of the slink:VkPhysicalDeviceLimits
pname:maxViewportDimensions and pname:viewportBoundsRange limits
(public issue 92).
* Specify sparse unbound texture replacement in the
<<textures-texel-replacement,Texel Replacement>> section
independently of robust buffer access language (public issue 100).
* Add the <<fundamentals-architecture-model,Architecture Model>>
section to explain architecture constraints Vulkan has chosen to
accept in order to enable portable and performant code (public issue
122).
* State that an object must not be destroyed until *all* (not *any*)
uses of that object have completed (public issue 123).
* Minor editorial cleanup (public issues 129, 134, 146, 148).
* Add validity language for layer and extension names to
slink:VkDeviceCreateInfo matching that used for
slink:VkInstanceCreateInfo (public issue 130).
* Clean up terminology for the case when the bits set in one bitmask
are a subset of the bits set in another bitmask (public issue 138).
* Document that input attachments are UniformConstant not Input, in
the <<interfaces-inputattachment,Fragment Input Attachment
Interface>> section (public glslang bug 169).
Internal Issues:
* Add max enum values to "flag bits" enums (internal issue #136).
* Clarify language around the various uses of the term "block" in the
<<appendix-compressedtex-bc,Block Compressed Image Formats>> section
(internal issue #202).
* Removed "expand" dependency from <enums> groups in vk.xml and added
auto-generation code in the scripts to infer it instead, to ensure
consistency. This caused renaming of sname:VkColorSpaceKHR and
sname:VkPresentModeKHR etext:BEGIN_RANGE (etc.) tokens, but those
tokens are metadata, not part of the API, and the Vulkan WG is OK
with this change. This change adds ranges to two additional enums
that were missing them due to not defining the "expand" attribute
(internal issue 217).
* Tweak makefile to generate ref page nroff (.3) files in the right
output directory, working around an a2x limitation (internal issue
223).
Other Commits:
* Add validity requirements for flink:vkCmdCopyQueryPoolResults
pname:dstBuffer parameter.
* Fix ref page build to generate .3 targets in the right output
directory.
2016-03-25 09:25:04 +00:00
address of (x,y,z) = region->bufferOffset + (((z * imageHeight) + y) * rowLength + x) * compressedTexelBlockSizeInBytes;
2016-02-16 09:53:44 +00:00
Change log for March 25, 2016 Vulkan 1.0.7 spec update:
* Bump API patch number and header version number to 7 for this
update.
Github Issues:
* Fix slink:VkSpecializationMapEntry example to avoid C/C++ strict
aliasing issues (public issue 14).
* Clarify the meaning of "matching" in flink:vkCmdBindDescriptorSets
validity language (public issue 33).
* Add stub reference pages so xrefs to not-yet-written pages don't
generate 404 errors. However, the actual content of these pages
still needs to be filled in as time allows (public issue 44, but
does not close that issue out).
* Remove incorrect validity statement for
flink:vkGetImageSparseMemoryRequirements (public issue 85).
* Reword the
<<features-limits-bufferImageGranularity,bufferImageGranularity>>
feature in terms of "aliasing", and clarify that it applies to
bindings in the same memory object (public issue 90).
* Clarify the relationship of the slink:VkPhysicalDeviceLimits
pname:maxViewportDimensions and pname:viewportBoundsRange limits
(public issue 92).
* Specify sparse unbound texture replacement in the
<<textures-texel-replacement,Texel Replacement>> section
independently of robust buffer access language (public issue 100).
* Add the <<fundamentals-architecture-model,Architecture Model>>
section to explain architecture constraints Vulkan has chosen to
accept in order to enable portable and performant code (public issue
122).
* State that an object must not be destroyed until *all* (not *any*)
uses of that object have completed (public issue 123).
* Minor editorial cleanup (public issues 129, 134, 146, 148).
* Add validity language for layer and extension names to
slink:VkDeviceCreateInfo matching that used for
slink:VkInstanceCreateInfo (public issue 130).
* Clean up terminology for the case when the bits set in one bitmask
are a subset of the bits set in another bitmask (public issue 138).
* Document that input attachments are UniformConstant not Input, in
the <<interfaces-inputattachment,Fragment Input Attachment
Interface>> section (public glslang bug 169).
Internal Issues:
* Add max enum values to "flag bits" enums (internal issue #136).
* Clarify language around the various uses of the term "block" in the
<<appendix-compressedtex-bc,Block Compressed Image Formats>> section
(internal issue #202).
* Removed "expand" dependency from <enums> groups in vk.xml and added
auto-generation code in the scripts to infer it instead, to ensure
consistency. This caused renaming of sname:VkColorSpaceKHR and
sname:VkPresentModeKHR etext:BEGIN_RANGE (etc.) tokens, but those
tokens are metadata, not part of the API, and the Vulkan WG is OK
with this change. This change adds ranges to two additional enums
that were missing them due to not defining the "expand" attribute
(internal issue 217).
* Tweak makefile to generate ref page nroff (.3) files in the right
output directory, working around an a2x limitation (internal issue
223).
Other Commits:
* Add validity requirements for flink:vkCmdCopyQueryPoolResults
pname:dstBuffer parameter.
* Fix ref page build to generate .3 targets in the right output
directory.
2016-03-25 09:25:04 +00:00
where x,y,z range from (0,0,0) to region->imageExtent.{width/compressedTexelBlockWidth,height/compressedTexelBlockHeight,depth/compressedTexelBlockDepth}.
2016-02-16 09:53:44 +00:00
---------------------------------------------------
Copying to or from block-compressed images is typically done in multiples of
Change log for March 25, 2016 Vulkan 1.0.7 spec update:
* Bump API patch number and header version number to 7 for this
update.
Github Issues:
* Fix slink:VkSpecializationMapEntry example to avoid C/C++ strict
aliasing issues (public issue 14).
* Clarify the meaning of "matching" in flink:vkCmdBindDescriptorSets
validity language (public issue 33).
* Add stub reference pages so xrefs to not-yet-written pages don't
generate 404 errors. However, the actual content of these pages
still needs to be filled in as time allows (public issue 44, but
does not close that issue out).
* Remove incorrect validity statement for
flink:vkGetImageSparseMemoryRequirements (public issue 85).
* Reword the
<<features-limits-bufferImageGranularity,bufferImageGranularity>>
feature in terms of "aliasing", and clarify that it applies to
bindings in the same memory object (public issue 90).
* Clarify the relationship of the slink:VkPhysicalDeviceLimits
pname:maxViewportDimensions and pname:viewportBoundsRange limits
(public issue 92).
* Specify sparse unbound texture replacement in the
<<textures-texel-replacement,Texel Replacement>> section
independently of robust buffer access language (public issue 100).
* Add the <<fundamentals-architecture-model,Architecture Model>>
section to explain architecture constraints Vulkan has chosen to
accept in order to enable portable and performant code (public issue
122).
* State that an object must not be destroyed until *all* (not *any*)
uses of that object have completed (public issue 123).
* Minor editorial cleanup (public issues 129, 134, 146, 148).
* Add validity language for layer and extension names to
slink:VkDeviceCreateInfo matching that used for
slink:VkInstanceCreateInfo (public issue 130).
* Clean up terminology for the case when the bits set in one bitmask
are a subset of the bits set in another bitmask (public issue 138).
* Document that input attachments are UniformConstant not Input, in
the <<interfaces-inputattachment,Fragment Input Attachment
Interface>> section (public glslang bug 169).
Internal Issues:
* Add max enum values to "flag bits" enums (internal issue #136).
* Clarify language around the various uses of the term "block" in the
<<appendix-compressedtex-bc,Block Compressed Image Formats>> section
(internal issue #202).
* Removed "expand" dependency from <enums> groups in vk.xml and added
auto-generation code in the scripts to infer it instead, to ensure
consistency. This caused renaming of sname:VkColorSpaceKHR and
sname:VkPresentModeKHR etext:BEGIN_RANGE (etc.) tokens, but those
tokens are metadata, not part of the API, and the Vulkan WG is OK
with this change. This change adds ranges to two additional enums
that were missing them due to not defining the "expand" attribute
(internal issue 217).
* Tweak makefile to generate ref page nroff (.3) files in the right
output directory, working around an a2x limitation (internal issue
223).
Other Commits:
* Add validity requirements for flink:vkCmdCopyQueryPoolResults
pname:dstBuffer parameter.
* Fix ref page build to generate .3 targets in the right output
directory.
2016-03-25 09:25:04 +00:00
the compressed texel block. For this reason the pname:imageExtent must: be a
multiple of the compressed texel block dimension. There is one exception to
this rule which is required: to handle compressed images created with
dimensions that are not a multiple of the compressed texel block dimensions.
If pname:imageExtent.width is not a multiple of the compressed texel block
width then (pname:imageExtent.width + pname:imageOffset.x) must: equal the
Change log for April 15, 2016 Vulkan 1.0.10 spec update:
* Bump API patch number and header version number to 10 for this
update.
Github Issues:
* Slightly tweak the <<memory-allocation,Host Memory>> allocator language
so that an application wrapping the standard C alloc/free/realloc
functions is still correct - the previous language was too strong with
regards to freeing memory. Also made certain scenarios clearer - an
implementation may now continue without error if an allocation failed
and it is able to continue correctly (public issue 21).
* Require that etext:VK_*_CREATE_SPARSE_BINDING_BIT is set when the
corresponding etext:VK_*_CREATE_SPARSE_RESIDENCY_BIT is used, in the
<<sparsememory-miptail,Mip Tail Regions>> section and related commands
flink:vkCreateBuffer and flink:vkCreateImage (public issue 84).
* Update the <<features,Features, Limits, and Formats>> chapter to clarify
interactions between optional features and dynamic state for the
pname:depthBiasClamp and pname:wideLines features (public issue 89).
* Describe the code:WorkgroupSize builtin in the
<<interfaces-builtin-variables,Built-In Variables>> section, and update
the <<compute-shaders,Compute Shaders>> section to further clarify how
to set the number of workgroups to execute in a compute shader (public
issue 145).
* Use the term *image subresource* everywhere instead of *subresource*,
except for the special case of *host-accessible subresource*, which may
be either an image subresource or buffer range (public issue 120)
* Add a note to the <<features,Features, Limits, and Formats>> section
about extensibility of structures (Public issue 165).
* Fix return code flink:vkAcquireNextImageKHR when the timeout parameter
is 0 to ename:VK_NOT_READY instead of ename:VK_TIMEOUT (public issue
170).
* Fix typo in slink:VkLayerProperties::pname:apiVersion field (public
issue 172).
Internal Issues:
* Fix a few minor internally-detected typos.
* Minor formatting tweaks to pseudocode in the <<resources,Resource
Creation>> chapter (internal issue 179).
* Fix typo in the definition of point sampling for
elink:VkCullModeFlagBits (internal issue 268).
2016-04-14 08:58:49 +00:00
image subresource width, if pname:imageExtent.height is not a multiple of
the compressed texel block height then (pname:imageExtent.height +
pname:imageOffset.y) must: equal the image subresource height and if
pname:imageExtent.depth is not a multiple of the compressed texel block
depth then (pname:imageExtent.depth + pname:imageOffset.z) must: equal the
image subresource depth. This allows the last compressed texel block of the
image in each non-multiple dimension to be included as a source or
destination of the copy.
2016-02-16 09:53:44 +00:00
[[copies-imagescaling]]
== Image Copies with Scaling
2016-09-17 04:22:17 +00:00
// refBegin vkCmdBlitImage Copy regions of an image, potentially performing format conversion,
2016-07-11 01:13:41 +00:00
2016-02-16 09:53:44 +00:00
To copy regions of a source image into a destination image, potentially
performing format conversion, arbitrary scaling, and filtering, call:
Change log for July 22, 2016 Vulkan 1.0.22 spec update:
* Bump API patch number and header version number to 22 for this update.
Github Issues:
* Translate the subpass self-dependency language into concrete
validity statements, and added a validity statement about the
restrictions on layout parameters (public issue 267).
* Add validity requirement that
slink:VkAttachmentDescription::pname:finalLayout and
slink:VkAttachmentReference::pname:layout must not be
ename:VK_IMAGE_LAYOUT_UNDEFINED or
ename:VK_IMAGE_LAYOUT_PREINITIALIZED (public issue 268).
* Clarify that slink:VkSubpassDescription::pname:pResolveAttachments
layouts are used. Make language consistent with other attachment
arrays (public issue 270).
* Changed 64-bit definition for
dname:VK_DEFINE_NON_DISPATCHABLE_HANDLE to work for x32 platform in
+vk.xml+ and the resulting +vulkan.h+ (public issue 282).
* Add missing error return code for
flink:vkEnumerateInstanceExtensionProperties and
flink:vkEnumerateDeviceExtensionProperties (public issue 285)
* Fix several cases of stext::VkStructName.memberName markup to
stext::VkStructName::pname:memberName, to match other usage in the
spec, and describe this markup in the style guide (public issue
286).
* Modified validity language generation script to avoid redundant
common ancestor language if covered by generic parent language, and
used `Both' instead of `Each' when appropriate (public issue 288).
Internal Issues:
* Add language about behavior of flink:vkAllocateDescriptorSets when
allocation fails due to fragmentation, a new error
ename:VK_ERROR_FRAGMENTED_POOL, and a Note explaining the situation
(internal issue 309).
* For the features of code:PointSize, code:ClipDistance, and
code:CullDistance, the SPIR-V capability is required to be declared
on use (read or write) rather than on decoration (internal issue
359).
* Have desktop versions of GLSL respect precision qualification
(code:mediump and code:lowp) when compiling for Vulkan. These will
get translated to SPIR-V's code:RelaxedPrecision decoration as they
do with OpenGL ES versions of GLSL (ESSL). The default precision of
all types is code:highp when using a desktop version (internal issue
360).
* Add validity statement for slink:VkImageCreateInfo specifying that
multisampled images must be two-dimensional, optimally tiled, and
with a single mipmap level (internal issue 369).
* Add validity statements to slink:VkImageViewCreateInfo disallowing
creation of images or image views with no supported features. Made
some slink:VkImageViewCreateInfo validity statements more precise
and consistent. Added a Note to the <<features,features>> chapter
about formats with no features (internal issue 371).
* Remove +manpages+ from default build targets. Nroff outputs
containing imbedded latexmath will not render properly. Fixing this
is a lot of work for limited use cases (internal issue 401).
Other Commits:
* Fix flink:vkRenderPassBeginInfo::pname:clearValueCount validity
statement to be based on attachment indices rather than the number
of cleared attachments
(Vulkan-LoaderAndValidationLayers/issues/601).
* Convert registry documentation from LaTeX to asciidoc source and
rename from +src/spec/readme.tex+ to +src/spec/registry.txt+.
* Fix lack of Oxford commas in validity language.
* Lots of cleanup of generator scripts and Makefiles to move extension
list for generator into the script arguments instead of the body of
genvk.py, and express better dependencies between XML, scripts, and
generated files.
2016-07-23 10:15:48 +00:00
include::../api/protos/vkCmdBlitImage.txt[]
2016-02-16 09:53:44 +00:00
* pname:commandBuffer is the command buffer into which the command will be
recorded.
* pname:srcImage is the source image.
* pname:srcImageLayout is the layout of the source image subresources for
the blit.
* pname:dstImage is the destination image.
* pname:dstImageLayout is the layout of the destination image subresources
for the blit.
* pname:regionCount is the number of regions to blit.
* pname:pRegions is a pointer to an array of slink:VkImageBlit structures
specifying the regions to blit.
* pname:filter is a elink:VkFilter specifying the filter to apply if the
blits require scaling.
Change log for September 6, 2016 Vulkan 1.0.26 spec update:
* Bump API patch number and header version number to 26 for this update.
Github Issues:
* Bring sample code in the +VK_KHR_surface+ and +VK_KHR_swapchain+
extension summary appendices up to date, and note they will be replaced
with pointers to the LunarG SDK examples in the future (public issue
279).
* Add a new <<fundamentals-commandsyntax-results-lifetime,Lifetime of
Retrieved Results>> section specifying that ftext:vkGet* and
ftext:VkEnumerate* results are invariant unless otherwise specified, and
specify behavior for individual commands which are not invariant (public
issue 280).
* Remove conflicting definition of
slink:VkDisplayPlaneCapabilitiesKHR::pname:maxSrcPosition and clean up
language of the remaining definition (public issue 351).
* Fix many minor spelling errors and add rules to the style guide to
prevent recurrences (public issue 352).
Internal Issues:
* Remove redundant descriptions of the etext:VK_USE_PLATFORM_* macros from
the <<wsi,Window System Integration>> chapter in favor of the
description in the <<boilerplate-wsi-header,Window System-Specific
Header Control>> appendix (internal issue 6).
* Replace misleading 'can: be destroyed when not X' with more correct
'must: not be destroyed while X' in the
<<fundamentals-objectmodel-lifetime,Object Lifetime>> section. Disallow
destroying a pipeline layout while a command buffer using it is
recording (internal issue 241).
* Clarify that ename:VK_IMAGE_USAGE_TRANSIENT_ATTACHMENT_BIT is valid for
all images used as attachments in elink:VkImageUsageFlagBits and the
slink:VkImageLayout validity language (internal issue 320).
* Note that <<extended-functionality-layers,Layers>> may wrap object
handles, but that this is a generally discouraged. A link to additional
information in the documentation for layer authors is provided (issue
398)
* Replace the mustnot: and shouldnot: macros with equivalent must: not and
should: not to get rid of non-English words while still highlighting
normative language (internal issue 407).
* Disallow creating multisampled images with
ename:VK_IMAGE_CREATE_CUBE_COMPATIBLE_BIT in the slink:VkImageLayout
validity language and the <<features-supported-sample-counts,Supported
Sample Counts>> section (internal issue 445).
* Fix typo so that flink:vkCmdDrawIndexedIndirect is defined in terms of
flink:vkCmdDrawIndexed rather than flink:vkCmdDrawIndirect (internal
issue 446).
* Reorganize the per-extension information sections to all be in the
<<extensions,Layers & Extensions>> appendix. Also fix a typo in
+VK_IMG_filter_cubic+ which incorrectly identified it as a +KHR+
extension (internal issue 461).
Other Issues:
* Use asciidoc markup instead of latexmath to simplify diagrams in the
<<features-formats-non-packed,byte mapping tables>> for color formats.
* Fix a markup problem with the wildcarded enumerant names in a NOTE in
the <<textures-texel-replacement,Texel Replacement>> section.
* Fix missing attributes in the XML interface for
elink:VkExternalMemoryHandleTypeFlagBitsNV and
elink:VkExternalMemoryFeatureFlagBitsNV (KhronosGroup/Vulkan-Hpp issue
#25)
* Cleanup reference page builds so only core pages are built for releases.
2016-09-06 13:17:27 +00:00
fname:vkCmdBlitImage must: not be used for multisampled source or destination
Change log for July 15, 2016 Vulkan 1.0.21 spec update:
* Bump API patch number and header version number to 21 for this update.
Github Issues:
* Clarify how <<features-supported-sample-counts,sample count queries>>
relate to the limits in slink:VkPhysicalDeviceLimits. (public issue
185).
* Clarify in the <<interfaces-iointerfaces,Shader Input and Output
Interfaces>> section that shader output variables have undefined values
until the shader writes to them (public issue 240).
* Specify the implicit value of image parameters that cannot be set in
slink:VkSwapchainCreateInfo::pname:flags, pname:imageType,
pname:mipLevels, pname:samples, pname:tiling, and pname:initialLayout
(public issue 243).
* Make use of code:NULL and code:VK_NULL_HANDLE consistent in the
VK_KHR_swapchain extension (public issue 276).
Internal Issues:
* Clarify that presenting an image to a display surface swapchain applies
the display surface's mode, and that destroying a display surface
swapchain may reset the display's mode, in the VK_KHR_display_swapchain
extension (internal issue 247).
* Better describe what a slink:VkSurfaceKHR is, and that creating one does
not set a mode, in the VK_KHR_display extension. This is a round-about
way of pointing out that mode setting is not covered by the extension,
but rather is performed as a side effect of presentation (internal issue
247).
* Add more valid usage statements to flink:vkQueuePresentKHR command when
the VK_KHR_display_swapchain extension is present (internal issue
247).
* Add more includes to the VK_KHR_swapchain extension to better document
interactions with VK_KHR_display_swapchain (internal issue 247).
* Clarify restrictions on location aliasing in the
<<fxvertex,Fixed-Function Vertex Processing>> section (internal issue
370).
* Add mathematical description of blitting to flink:vkCmdBlitImage, and
link it to the <<textures,Image Operations>> chapter. Use mathematical
notation for ranges of texel coordinates in the <<textures,Image
Operations>> chapter. Fixed miscellaneous validity statements for
flink:vkCmdBlit and slink:VkImageBlit (internal issue 382).
Other Commits:
* Added a valid usage rule to flink:VkGraphicsPipelineCreateInfo that the
ename:VK_PRIMITIVE_TOPOLOGY_PATCH_LIST topology must only be used when
tessellation shaders are used.
* Expand the style guide into a formal "Procedures and Conventions"
document. Add a API Naming Conventions section, move most of the API
Specification Appendix C (Layers and Extensions) content into the new
document, and define the resulting procedures as mandatory (where
relevant). This more clearly separates use vs. specification of Vulkan
APIs.
* Update vk_platform.h to handle 32-bit ARMv8 binaries.
* Various minor cleanups to the Makefile and build process.
2016-07-16 02:05:43 +00:00
images.
Use flink:vkCmdResolveImage for this purpose.
As the sizes of the source and destination extents can: differ in any
dimension, texels in the source extent are scaled and filtered to the
destination extent.
Scaling occurs via the following operations:
* For each destination texel, the integer coordinate of that texel is
converted to an unnormalized texture coordinate, using the effective
inverse of the equations described in
<<textures-unnormalized-to-integer, unnormalized to integer
conversion>>:
[latexmath]
++++++++++++++++++++++++
\begin{align*}
u_{base} & = i + \frac{1}{2}\\
v_{base} & = j + \frac{1}{2}\\
w_{base} & = k + \frac{1}{2}\\
\end{align*}
++++++++++++++++++++++++
* These base coordinates are then offset by the first destination offset:
[latexmath]
++++++++++++++++++++++++
\begin{align*}
u_{offset} & = u_{base} - x_{dst_0}\\
v_{offset} & = v_{base} - y_{dst_0}\\
w_{offset} & = w_{base} - z_{dst_0}\\
a_{offset} & = a - baseArrayCount_{dst}
\end{align*}
++++++++++++++++++++++++
* The scale is determined from the source and destination regions, and
applied to the offset coordinates:
[latexmath]
++++++++++++++++++++++++
\begin{align*}
scale_u & = \frac{x_{src_1} - x_{src_0}}{x_{dst_1} - x_{dst_0}}\\
scale_v & = \frac{y_{src_1} - y_{src_0}}{y_{dst_1} - y_{dst_0}}\\
scale_w & = \frac{z_{src_1} - z_{src_0}}{z_{dst_1} - z_{dst_0}}\\
\\
u_{scaled} & = u_{offset} * scale_u\\
v_{scaled} & = v_{offset} * scale_v\\
w_{scaled} & = w_{offset} * scale_w
\end{align*}
++++++++++++++++++++++++
* Finally the source offset is added to the scaled coordinates, to
determine the final unnormalized coordinates used to sample from
pname:srcImage:
[latexmath]
++++++++++++++++++++++++
\begin{align*}
u & = u_{scaled} + x_{src_0}\\
v & = v_{scaled} + y_{src_0}\\
w & = w_{scaled} + z_{src_0}\\
q & = mipLevel\\
a & = a_{offset} + baseArrayCount_{src}
\end{align*}
++++++++++++++++++++++++
These coordinates are used to sample from the source image, as described in
<<textures, Image Operations chapter>>, with the filter mode equal to that
of pname:filter, a mipmap mode of ename:VK_SAMPLER_MIPMAP_MODE_NEAREST and
an address mode of ename:VK_SAMPLER_ADDRESS_MODE_CLAMP_TO_EDGE.
Implementations must: clamp at the edge of the source image, and may:
additionally clamp to the edge of the source region.
[NOTE]
.Note
====
Due to allowable rounding errors in the generation of the source texture
coordinates, it is not always possible to guarantee exactly which source
texels will be sampled for a given blit.
As rounding errors are implementation dependent, the exact results of a
blitting operation are also implementation dependent.
====
2016-02-16 09:53:44 +00:00
Blits are done layer by layer starting with the pname:baseArrayLayer member
of pname:srcSubresource for the source and pname:dstSubresource for the
Change log for July 15, 2016 Vulkan 1.0.21 spec update:
* Bump API patch number and header version number to 21 for this update.
Github Issues:
* Clarify how <<features-supported-sample-counts,sample count queries>>
relate to the limits in slink:VkPhysicalDeviceLimits. (public issue
185).
* Clarify in the <<interfaces-iointerfaces,Shader Input and Output
Interfaces>> section that shader output variables have undefined values
until the shader writes to them (public issue 240).
* Specify the implicit value of image parameters that cannot be set in
slink:VkSwapchainCreateInfo::pname:flags, pname:imageType,
pname:mipLevels, pname:samples, pname:tiling, and pname:initialLayout
(public issue 243).
* Make use of code:NULL and code:VK_NULL_HANDLE consistent in the
VK_KHR_swapchain extension (public issue 276).
Internal Issues:
* Clarify that presenting an image to a display surface swapchain applies
the display surface's mode, and that destroying a display surface
swapchain may reset the display's mode, in the VK_KHR_display_swapchain
extension (internal issue 247).
* Better describe what a slink:VkSurfaceKHR is, and that creating one does
not set a mode, in the VK_KHR_display extension. This is a round-about
way of pointing out that mode setting is not covered by the extension,
but rather is performed as a side effect of presentation (internal issue
247).
* Add more valid usage statements to flink:vkQueuePresentKHR command when
the VK_KHR_display_swapchain extension is present (internal issue
247).
* Add more includes to the VK_KHR_swapchain extension to better document
interactions with VK_KHR_display_swapchain (internal issue 247).
* Clarify restrictions on location aliasing in the
<<fxvertex,Fixed-Function Vertex Processing>> section (internal issue
370).
* Add mathematical description of blitting to flink:vkCmdBlitImage, and
link it to the <<textures,Image Operations>> chapter. Use mathematical
notation for ranges of texel coordinates in the <<textures,Image
Operations>> chapter. Fixed miscellaneous validity statements for
flink:vkCmdBlit and slink:VkImageBlit (internal issue 382).
Other Commits:
* Added a valid usage rule to flink:VkGraphicsPipelineCreateInfo that the
ename:VK_PRIMITIVE_TOPOLOGY_PATCH_LIST topology must only be used when
tessellation shaders are used.
* Expand the style guide into a formal "Procedures and Conventions"
document. Add a API Naming Conventions section, move most of the API
Specification Appendix C (Layers and Extensions) content into the new
document, and define the resulting procedures as mandatory (where
relevant). This more clearly separates use vs. specification of Vulkan
APIs.
* Update vk_platform.h to handle 32-bit ARMv8 binaries.
* Various minor cleanups to the Makefile and build process.
2016-07-16 02:05:43 +00:00
destination.
pname:layerCount layers are blitted to the destination image.
2016-02-16 09:53:44 +00:00
3D textures are blitted slice by slice. Slices in the source region bounded
by pname:srcOffsets[0].z and pname:srcOffsets[1].z are copied to slices in
the destination region bounded by pname:dstOffsets[0].z and
pname:dstOffsets[1].z. For each destination slice, a source z coordinate is
linearly interpolated between pname:srcOffsets[0].z and
pname:srcOffsets[1].z. If the pname:filter parameter is
ename:VK_FILTER_LINEAR then the value sampled from the source image is taken
by doing linear filtering using the interpolated z coordinate. If
pname:filter parameter is ename:VK_FILTER_NEAREST then value sampled from
the source image is taken from the single nearest slice (with undefined
rounding mode).
2016-07-01 02:34:54 +00:00
The following filtering and conversion rules apply:
2016-02-16 09:53:44 +00:00
* Integer formats can: only be converted to other integer formats with the
same signedness.
* No format conversion is supported between depth/stencil images - the
formats must: match.
* Format conversions on unorm, snorm, unscaled and packed float formats of
the copied aspect of the image are performed by first converting the
pixels to float values.
Change log for March 10, 2016 Vulkan 1.0.6 spec update:
* Bump API patch number and header version number to 6 for this
update.
Github Issues:
* Define 'invocation group' for compute and graphics shaders. Cleanup
definition and use of 'workgroup', and add glossary entries (public
issue 1).
* Various minor editorial fixes (public issue 33).
* Clarify locations for block members in the
<<interfaces-iointerfaces-locations,Location Assignment>>
section (public issue 45).
* Editorial fixes for <<commandbuffer-allocation,Command Buffer
Allocation>> section (public issues 54, 59).
* Clarify behavior of depth test in the <<fragops-depth,Depth
Test>> section (public issues 80, 81).
* Remove discussion of return codes from
flink:vkGetPhysicalDeviceSparseImageFormatProperties and
flink:vkGetImageSparseMemoryRequirements, which don't return values
(public issue 82).
* Allow flink:vkCmdDrawIndirect and flink:vkCmdDrawIndexedIndirect
pname:drawCount of 0, as well as 1, when the multiDrawIndirect
feature is not supported (public issue 88).
* Remove confusing wording in the <<features-limits,Limits>>
section describing the slink:VkPhysicalDeviceLimits
pname:minTexelBufferOffsetAlignment,
pname:minUniformBufferOffsetAlignment, and
pname:minStorageBufferOffsetAlignment members as both minimums and
maximums (public issue 91).
* Clarified that only the RGB components should be affected in places
where sRGB is referred to in the spec, such as ASTC formats. Minor
re-wording to avoid "color space" when actively incorrect, now that
we refer to the Data Format Spec which actually makes a distinction
between color space and transfer function (public issue 94).
* Treat pname:pPropertyCount == 0 consistently in
flink:vkEnumerateInstanceLayerProperties and
flink:vkEnumerateDeviceLayerProperties (public issue 99)
* Cleanup minor editorial issues in chapters 14-17 (public issue 100).
* Clarify definition of flink:vkEnumerateInstanceExtensionProperties
and flink:vkEnumerateDeviceExtensionProperties (public issue 101).
* Define the flink:vkEnumerateInstanceExtensionProperties and
flink:vkEnumerateDeviceExtensionProperties pname:pLayerName
parameter to be a pointer to a null-terminated UTF-8 string (public
issue 101).
* Rearrange "Missing information" references in mandatory format
tables (public issue 101).
* Clarify that the enumerated extensions returned by
flink:vkEnumerateInstanceExtensionProperties and
flink:vkEnumerateDeviceExtensionProperties will only include
extensions provided by the platform or extensions implemented in
implicitly enabled layers (public issue 101).
* Miscellaneous editorial fixes. Include the Vulkan spec patch number
in the PDF title. Fix label on <<fig-non-strict-lines,Non
strict lines>> diagram. Use more easily distinguished symbols in
tables in the <<features-required-format-support,Required
Format Support>> section. Don't require FQDNs used as layer names be
encoded in lower case if not possible, in the
<<extensions-naming-conventions, Extension and Layer Naming
Conventions>> section (public issues 101, 119, 121).
Internal Issues:
* Fixed excessive spacing in tables in XHTML (internal issue 18).
* Clarify that ename:VK_COMMAND_BUFFER_USAGE_ONE_TIME_SUBMIT_BIT
applies to secondary command buffers. Previously spec only referred
to the members of pname:pCommandBuffers being affected by this bit.
Added a separate slink:VkSubmitInfo Valid Usage restriction
specifying that ename:VK_COMMAND_BUFFER_USAGE_ONE_TIME_SUBMIT_BIT
also applies to any secondary command buffers that are recorded into
the primary command buffers in pname:pCommandBuffers (internal issue
106).
* Clarify that slink:VkDeviceCreateInfo::pname:pEnabledFeatures can be
NULL (internal issue 117).
* Remove "the value of" where it is redundant (e.g. speaking of an API
parameter, struct member, or SPIR-V variable, but not when speaking
of color components) (internal issue 175).
* Forced patch version to always be 0 in the header. Add a
"VK_API_VERSION_<major>_<minor>" macro for people to use to do the
right thing. Add a VK_HEADER_VERSION which captures the header
release number independent of the spec patch number (internal issue
176).
* Correct description of
slink:VkPipelineShaderStageCreateInfo::pname:pName to "a pointer to
a null-terminated UTF-8 string" (internal issue #197).
Other Commits:
* Updated DataFormat spec reference to the new date for revision 5 of
that spec.
* Fixed KEEP option (to retain LaTeX intermediate files) in the
Makefile to be included when edited there, as well as set on the
command line.
* Reserve and add "VK_IMG_filter_cubic" to the registry, and implement
script functionality to add and remove validity from existing
functions. Includes schema and readme changes.
* Update GL_KHR_vulkan_glsl so push_constants do not have descriptor
sets.
2016-03-11 01:33:02 +00:00
* In case of sRGB source format, nonlinear RGB values are converted to
linear representation prior to filtering.
2016-02-16 09:53:44 +00:00
* After filtering, the float values are first clamped and then cast to the
Change log for March 10, 2016 Vulkan 1.0.6 spec update:
* Bump API patch number and header version number to 6 for this
update.
Github Issues:
* Define 'invocation group' for compute and graphics shaders. Cleanup
definition and use of 'workgroup', and add glossary entries (public
issue 1).
* Various minor editorial fixes (public issue 33).
* Clarify locations for block members in the
<<interfaces-iointerfaces-locations,Location Assignment>>
section (public issue 45).
* Editorial fixes for <<commandbuffer-allocation,Command Buffer
Allocation>> section (public issues 54, 59).
* Clarify behavior of depth test in the <<fragops-depth,Depth
Test>> section (public issues 80, 81).
* Remove discussion of return codes from
flink:vkGetPhysicalDeviceSparseImageFormatProperties and
flink:vkGetImageSparseMemoryRequirements, which don't return values
(public issue 82).
* Allow flink:vkCmdDrawIndirect and flink:vkCmdDrawIndexedIndirect
pname:drawCount of 0, as well as 1, when the multiDrawIndirect
feature is not supported (public issue 88).
* Remove confusing wording in the <<features-limits,Limits>>
section describing the slink:VkPhysicalDeviceLimits
pname:minTexelBufferOffsetAlignment,
pname:minUniformBufferOffsetAlignment, and
pname:minStorageBufferOffsetAlignment members as both minimums and
maximums (public issue 91).
* Clarified that only the RGB components should be affected in places
where sRGB is referred to in the spec, such as ASTC formats. Minor
re-wording to avoid "color space" when actively incorrect, now that
we refer to the Data Format Spec which actually makes a distinction
between color space and transfer function (public issue 94).
* Treat pname:pPropertyCount == 0 consistently in
flink:vkEnumerateInstanceLayerProperties and
flink:vkEnumerateDeviceLayerProperties (public issue 99)
* Cleanup minor editorial issues in chapters 14-17 (public issue 100).
* Clarify definition of flink:vkEnumerateInstanceExtensionProperties
and flink:vkEnumerateDeviceExtensionProperties (public issue 101).
* Define the flink:vkEnumerateInstanceExtensionProperties and
flink:vkEnumerateDeviceExtensionProperties pname:pLayerName
parameter to be a pointer to a null-terminated UTF-8 string (public
issue 101).
* Rearrange "Missing information" references in mandatory format
tables (public issue 101).
* Clarify that the enumerated extensions returned by
flink:vkEnumerateInstanceExtensionProperties and
flink:vkEnumerateDeviceExtensionProperties will only include
extensions provided by the platform or extensions implemented in
implicitly enabled layers (public issue 101).
* Miscellaneous editorial fixes. Include the Vulkan spec patch number
in the PDF title. Fix label on <<fig-non-strict-lines,Non
strict lines>> diagram. Use more easily distinguished symbols in
tables in the <<features-required-format-support,Required
Format Support>> section. Don't require FQDNs used as layer names be
encoded in lower case if not possible, in the
<<extensions-naming-conventions, Extension and Layer Naming
Conventions>> section (public issues 101, 119, 121).
Internal Issues:
* Fixed excessive spacing in tables in XHTML (internal issue 18).
* Clarify that ename:VK_COMMAND_BUFFER_USAGE_ONE_TIME_SUBMIT_BIT
applies to secondary command buffers. Previously spec only referred
to the members of pname:pCommandBuffers being affected by this bit.
Added a separate slink:VkSubmitInfo Valid Usage restriction
specifying that ename:VK_COMMAND_BUFFER_USAGE_ONE_TIME_SUBMIT_BIT
also applies to any secondary command buffers that are recorded into
the primary command buffers in pname:pCommandBuffers (internal issue
106).
* Clarify that slink:VkDeviceCreateInfo::pname:pEnabledFeatures can be
NULL (internal issue 117).
* Remove "the value of" where it is redundant (e.g. speaking of an API
parameter, struct member, or SPIR-V variable, but not when speaking
of color components) (internal issue 175).
* Forced patch version to always be 0 in the header. Add a
"VK_API_VERSION_<major>_<minor>" macro for people to use to do the
right thing. Add a VK_HEADER_VERSION which captures the header
release number independent of the spec patch number (internal issue
176).
* Correct description of
slink:VkPipelineShaderStageCreateInfo::pname:pName to "a pointer to
a null-terminated UTF-8 string" (internal issue #197).
Other Commits:
* Updated DataFormat spec reference to the new date for revision 5 of
that spec.
* Fixed KEEP option (to retain LaTeX intermediate files) in the
Makefile to be included when edited there, as well as set on the
command line.
* Reserve and add "VK_IMG_filter_cubic" to the registry, and implement
script functionality to add and remove validity from existing
functions. Includes schema and readme changes.
* Update GL_KHR_vulkan_glsl so push_constants do not have descriptor
sets.
2016-03-11 01:33:02 +00:00
destination image format. In case of sRGB destination format, linear RGB
values are converted to nonlinear representation before writing the
pixel to the image.
2016-02-16 09:53:44 +00:00
Signed and unsigned integers are converted by first clamping to the
2016-02-27 15:44:21 +00:00
representable range of the destination format, then casting the value.
2016-02-16 09:53:44 +00:00
2016-07-11 01:13:41 +00:00
include::../validity/protos/vkCmdBlitImage.txt[]
2016-09-17 04:22:17 +00:00
// refBegin VkImageBlit Structure specifying an image blit operation
2016-07-11 01:13:41 +00:00
The sname:VkImageBlit structure is defined as:
Change log for July 22, 2016 Vulkan 1.0.22 spec update:
* Bump API patch number and header version number to 22 for this update.
Github Issues:
* Translate the subpass self-dependency language into concrete
validity statements, and added a validity statement about the
restrictions on layout parameters (public issue 267).
* Add validity requirement that
slink:VkAttachmentDescription::pname:finalLayout and
slink:VkAttachmentReference::pname:layout must not be
ename:VK_IMAGE_LAYOUT_UNDEFINED or
ename:VK_IMAGE_LAYOUT_PREINITIALIZED (public issue 268).
* Clarify that slink:VkSubpassDescription::pname:pResolveAttachments
layouts are used. Make language consistent with other attachment
arrays (public issue 270).
* Changed 64-bit definition for
dname:VK_DEFINE_NON_DISPATCHABLE_HANDLE to work for x32 platform in
+vk.xml+ and the resulting +vulkan.h+ (public issue 282).
* Add missing error return code for
flink:vkEnumerateInstanceExtensionProperties and
flink:vkEnumerateDeviceExtensionProperties (public issue 285)
* Fix several cases of stext::VkStructName.memberName markup to
stext::VkStructName::pname:memberName, to match other usage in the
spec, and describe this markup in the style guide (public issue
286).
* Modified validity language generation script to avoid redundant
common ancestor language if covered by generic parent language, and
used `Both' instead of `Each' when appropriate (public issue 288).
Internal Issues:
* Add language about behavior of flink:vkAllocateDescriptorSets when
allocation fails due to fragmentation, a new error
ename:VK_ERROR_FRAGMENTED_POOL, and a Note explaining the situation
(internal issue 309).
* For the features of code:PointSize, code:ClipDistance, and
code:CullDistance, the SPIR-V capability is required to be declared
on use (read or write) rather than on decoration (internal issue
359).
* Have desktop versions of GLSL respect precision qualification
(code:mediump and code:lowp) when compiling for Vulkan. These will
get translated to SPIR-V's code:RelaxedPrecision decoration as they
do with OpenGL ES versions of GLSL (ESSL). The default precision of
all types is code:highp when using a desktop version (internal issue
360).
* Add validity statement for slink:VkImageCreateInfo specifying that
multisampled images must be two-dimensional, optimally tiled, and
with a single mipmap level (internal issue 369).
* Add validity statements to slink:VkImageViewCreateInfo disallowing
creation of images or image views with no supported features. Made
some slink:VkImageViewCreateInfo validity statements more precise
and consistent. Added a Note to the <<features,features>> chapter
about formats with no features (internal issue 371).
* Remove +manpages+ from default build targets. Nroff outputs
containing imbedded latexmath will not render properly. Fixing this
is a lot of work for limited use cases (internal issue 401).
Other Commits:
* Fix flink:vkRenderPassBeginInfo::pname:clearValueCount validity
statement to be based on attachment indices rather than the number
of cleared attachments
(Vulkan-LoaderAndValidationLayers/issues/601).
* Convert registry documentation from LaTeX to asciidoc source and
rename from +src/spec/readme.tex+ to +src/spec/registry.txt+.
* Fix lack of Oxford commas in validity language.
* Lots of cleanup of generator scripts and Makefiles to move extension
list for generator into the script arguments instead of the body of
genvk.py, and express better dependencies between XML, scripts, and
generated files.
2016-07-23 10:15:48 +00:00
include::../api/structs/VkImageBlit.txt[]
2016-07-11 01:13:41 +00:00
* pname:srcSubresource is the subresource to blit from.
* pname:srcOffsets is an array of two slink:VkOffset3D structures
specifying the bounds of the source region within pname:srcSubresource.
* pname:dstSubresource is the subresource to blit into.
* pname:dstOffsets is an array of two slink:VkOffset3D structures
specifying the bounds of the destination region within
pname:dstSubresource.
For each element of the pname:pRegions array, a blit operation is performed
the specified source and destination regions.
include::../validity/structs/VkImageBlit.txt[]
2016-02-16 09:53:44 +00:00
[[copies-resolve]]
== Resolving Multisample Images
2016-09-17 04:22:17 +00:00
// refBegin vkCmdResolveImage Resolve regions of an image
2016-07-11 01:13:41 +00:00
2016-02-16 09:53:44 +00:00
To resolve a multisample image to a non-multisample image, call:
Change log for July 22, 2016 Vulkan 1.0.22 spec update:
* Bump API patch number and header version number to 22 for this update.
Github Issues:
* Translate the subpass self-dependency language into concrete
validity statements, and added a validity statement about the
restrictions on layout parameters (public issue 267).
* Add validity requirement that
slink:VkAttachmentDescription::pname:finalLayout and
slink:VkAttachmentReference::pname:layout must not be
ename:VK_IMAGE_LAYOUT_UNDEFINED or
ename:VK_IMAGE_LAYOUT_PREINITIALIZED (public issue 268).
* Clarify that slink:VkSubpassDescription::pname:pResolveAttachments
layouts are used. Make language consistent with other attachment
arrays (public issue 270).
* Changed 64-bit definition for
dname:VK_DEFINE_NON_DISPATCHABLE_HANDLE to work for x32 platform in
+vk.xml+ and the resulting +vulkan.h+ (public issue 282).
* Add missing error return code for
flink:vkEnumerateInstanceExtensionProperties and
flink:vkEnumerateDeviceExtensionProperties (public issue 285)
* Fix several cases of stext::VkStructName.memberName markup to
stext::VkStructName::pname:memberName, to match other usage in the
spec, and describe this markup in the style guide (public issue
286).
* Modified validity language generation script to avoid redundant
common ancestor language if covered by generic parent language, and
used `Both' instead of `Each' when appropriate (public issue 288).
Internal Issues:
* Add language about behavior of flink:vkAllocateDescriptorSets when
allocation fails due to fragmentation, a new error
ename:VK_ERROR_FRAGMENTED_POOL, and a Note explaining the situation
(internal issue 309).
* For the features of code:PointSize, code:ClipDistance, and
code:CullDistance, the SPIR-V capability is required to be declared
on use (read or write) rather than on decoration (internal issue
359).
* Have desktop versions of GLSL respect precision qualification
(code:mediump and code:lowp) when compiling for Vulkan. These will
get translated to SPIR-V's code:RelaxedPrecision decoration as they
do with OpenGL ES versions of GLSL (ESSL). The default precision of
all types is code:highp when using a desktop version (internal issue
360).
* Add validity statement for slink:VkImageCreateInfo specifying that
multisampled images must be two-dimensional, optimally tiled, and
with a single mipmap level (internal issue 369).
* Add validity statements to slink:VkImageViewCreateInfo disallowing
creation of images or image views with no supported features. Made
some slink:VkImageViewCreateInfo validity statements more precise
and consistent. Added a Note to the <<features,features>> chapter
about formats with no features (internal issue 371).
* Remove +manpages+ from default build targets. Nroff outputs
containing imbedded latexmath will not render properly. Fixing this
is a lot of work for limited use cases (internal issue 401).
Other Commits:
* Fix flink:vkRenderPassBeginInfo::pname:clearValueCount validity
statement to be based on attachment indices rather than the number
of cleared attachments
(Vulkan-LoaderAndValidationLayers/issues/601).
* Convert registry documentation from LaTeX to asciidoc source and
rename from +src/spec/readme.tex+ to +src/spec/registry.txt+.
* Fix lack of Oxford commas in validity language.
* Lots of cleanup of generator scripts and Makefiles to move extension
list for generator into the script arguments instead of the body of
genvk.py, and express better dependencies between XML, scripts, and
generated files.
2016-07-23 10:15:48 +00:00
include::../api/protos/vkCmdResolveImage.txt[]
2016-02-16 09:53:44 +00:00
* pname:commandBuffer is the command buffer into which the command will be
recorded.
* pname:srcImage is the source image.
* pname:srcImageLayout is the layout of the source image subresources for
2016-02-22 22:03:31 +00:00
the resolve.
2016-02-16 09:53:44 +00:00
* pname:dstImage is the destination image.
* pname:dstImageLayout is the layout of the destination image subresources
2016-02-22 22:03:31 +00:00
for the resolve.
* pname:regionCount is the number of regions to resolve.
2016-02-16 09:53:44 +00:00
* pname:pRegions is a pointer to an array of slink:VkImageResolve
structures specifying the regions to resolve.
2016-07-11 01:13:41 +00:00
During the resolve the samples corresponding to each pixel location in the
source are converted to a single sample before being written to the
destination. If the source formats are floating-point or normalized types,
the sample values for each pixel are resolved in an implementation-dependent
manner. If the source formats are integer types, a single sample's value is
selected for each pixel.
pname:srcOffset and pname:dstOffset select the initial x, y, and z
offsets in texels of the sub-regions of the source and destination image
data. pname:extent is the size in texels of the source
image to resolve in pname:width, pname:height and pname:depth. 1D images use
only pname:x and pname:width. 2D images use pname:x, pname:y, pname:width
and pname:height. 3D images use pname:x, pname:y, pname:z, pname:width,
pname:height and pname:depth.
Resolves are done layer by layer starting with pname:baseArrayLayer member
of pname:srcSubresource for the source and pname:dstSubresource for the
destination. pname:layerCount layers are resolved to the destination image.
2016-02-16 09:53:44 +00:00
include::../validity/protos/vkCmdResolveImage.txt[]
2016-09-17 04:22:17 +00:00
// refBegin VkImageResolve Structure specifying an image resolve operation
2016-07-11 01:13:41 +00:00
2016-04-21 08:08:38 +00:00
The sname:VkImageResolve structure is defined as:
2016-02-16 09:53:44 +00:00
Change log for July 22, 2016 Vulkan 1.0.22 spec update:
* Bump API patch number and header version number to 22 for this update.
Github Issues:
* Translate the subpass self-dependency language into concrete
validity statements, and added a validity statement about the
restrictions on layout parameters (public issue 267).
* Add validity requirement that
slink:VkAttachmentDescription::pname:finalLayout and
slink:VkAttachmentReference::pname:layout must not be
ename:VK_IMAGE_LAYOUT_UNDEFINED or
ename:VK_IMAGE_LAYOUT_PREINITIALIZED (public issue 268).
* Clarify that slink:VkSubpassDescription::pname:pResolveAttachments
layouts are used. Make language consistent with other attachment
arrays (public issue 270).
* Changed 64-bit definition for
dname:VK_DEFINE_NON_DISPATCHABLE_HANDLE to work for x32 platform in
+vk.xml+ and the resulting +vulkan.h+ (public issue 282).
* Add missing error return code for
flink:vkEnumerateInstanceExtensionProperties and
flink:vkEnumerateDeviceExtensionProperties (public issue 285)
* Fix several cases of stext::VkStructName.memberName markup to
stext::VkStructName::pname:memberName, to match other usage in the
spec, and describe this markup in the style guide (public issue
286).
* Modified validity language generation script to avoid redundant
common ancestor language if covered by generic parent language, and
used `Both' instead of `Each' when appropriate (public issue 288).
Internal Issues:
* Add language about behavior of flink:vkAllocateDescriptorSets when
allocation fails due to fragmentation, a new error
ename:VK_ERROR_FRAGMENTED_POOL, and a Note explaining the situation
(internal issue 309).
* For the features of code:PointSize, code:ClipDistance, and
code:CullDistance, the SPIR-V capability is required to be declared
on use (read or write) rather than on decoration (internal issue
359).
* Have desktop versions of GLSL respect precision qualification
(code:mediump and code:lowp) when compiling for Vulkan. These will
get translated to SPIR-V's code:RelaxedPrecision decoration as they
do with OpenGL ES versions of GLSL (ESSL). The default precision of
all types is code:highp when using a desktop version (internal issue
360).
* Add validity statement for slink:VkImageCreateInfo specifying that
multisampled images must be two-dimensional, optimally tiled, and
with a single mipmap level (internal issue 369).
* Add validity statements to slink:VkImageViewCreateInfo disallowing
creation of images or image views with no supported features. Made
some slink:VkImageViewCreateInfo validity statements more precise
and consistent. Added a Note to the <<features,features>> chapter
about formats with no features (internal issue 371).
* Remove +manpages+ from default build targets. Nroff outputs
containing imbedded latexmath will not render properly. Fixing this
is a lot of work for limited use cases (internal issue 401).
Other Commits:
* Fix flink:vkRenderPassBeginInfo::pname:clearValueCount validity
statement to be based on attachment indices rather than the number
of cleared attachments
(Vulkan-LoaderAndValidationLayers/issues/601).
* Convert registry documentation from LaTeX to asciidoc source and
rename from +src/spec/readme.tex+ to +src/spec/registry.txt+.
* Fix lack of Oxford commas in validity language.
* Lots of cleanup of generator scripts and Makefiles to move extension
list for generator into the script arguments instead of the body of
genvk.py, and express better dependencies between XML, scripts, and
generated files.
2016-07-23 10:15:48 +00:00
include::../api/structs/VkImageResolve.txt[]
2016-02-16 09:53:44 +00:00
* pname:srcSubresource and pname:dstSubresource are
Change log for April 15, 2016 Vulkan 1.0.10 spec update:
* Bump API patch number and header version number to 10 for this
update.
Github Issues:
* Slightly tweak the <<memory-allocation,Host Memory>> allocator language
so that an application wrapping the standard C alloc/free/realloc
functions is still correct - the previous language was too strong with
regards to freeing memory. Also made certain scenarios clearer - an
implementation may now continue without error if an allocation failed
and it is able to continue correctly (public issue 21).
* Require that etext:VK_*_CREATE_SPARSE_BINDING_BIT is set when the
corresponding etext:VK_*_CREATE_SPARSE_RESIDENCY_BIT is used, in the
<<sparsememory-miptail,Mip Tail Regions>> section and related commands
flink:vkCreateBuffer and flink:vkCreateImage (public issue 84).
* Update the <<features,Features, Limits, and Formats>> chapter to clarify
interactions between optional features and dynamic state for the
pname:depthBiasClamp and pname:wideLines features (public issue 89).
* Describe the code:WorkgroupSize builtin in the
<<interfaces-builtin-variables,Built-In Variables>> section, and update
the <<compute-shaders,Compute Shaders>> section to further clarify how
to set the number of workgroups to execute in a compute shader (public
issue 145).
* Use the term *image subresource* everywhere instead of *subresource*,
except for the special case of *host-accessible subresource*, which may
be either an image subresource or buffer range (public issue 120)
* Add a note to the <<features,Features, Limits, and Formats>> section
about extensibility of structures (Public issue 165).
* Fix return code flink:vkAcquireNextImageKHR when the timeout parameter
is 0 to ename:VK_NOT_READY instead of ename:VK_TIMEOUT (public issue
170).
* Fix typo in slink:VkLayerProperties::pname:apiVersion field (public
issue 172).
Internal Issues:
* Fix a few minor internally-detected typos.
* Minor formatting tweaks to pseudocode in the <<resources,Resource
Creation>> chapter (internal issue 179).
* Fix typo in the definition of point sampling for
elink:VkCullModeFlagBits (internal issue 268).
2016-04-14 08:58:49 +00:00
slink:VkImageSubresourceLayers structures specifying the image
subresources of the images used for the source and destination image
data, respectively. Resolve of depth/stencil images is not supported.
2016-02-16 09:53:44 +00:00
* pname:srcOffset and pname:dstOffset select the initial x, y, and z
offsets in texels of the sub-regions of the source and destination image
data.
* pname:extent is the size in texels of the source image to resolve in
pname:width, pname:height and pname:depth. 1D images use only pname:x
and pname:width. 2D images use pname:x, pname:y, pname:width and
pname:height. 3D images use pname:x, pname:y, pname:z, pname:width,
pname:height and pname:depth.
include::../validity/structs/VkImageResolve.txt[]