The CPU image state tracking does not know about state changes from a future command list which is submitted before the current list.
This leads to incorrect state transition when copying pixel data and getting incorrect data in the pixel history
* Previously we treated dynamic state as valid in a temporary state (when e.g.
pushing and popping state) only if it was valid for the currently bound
pipeline. However it's possible for an application to have a static pipeline
bound, set some dynamic state, then set the pipeline needing that dynamic
state before the draw. The state is temporarily invalid for a period of time
but eventually becomes valid, and if we're restoring that state we need to
restore the dynamically set state assuming it will become valid.
This behavior is correctly applied on Windows but on posix systems would fail to apply duplicate
entries that should be additive, such as multiple prepends. Previously only the last modification
would win.
* This prevents a potential deadlock/failed readback situation if the queue
we're submitting on at the time memory needs to be read is currently blocked
by a pending wait and can't execute more code.
* On Android the end-to-end latency of a single call is large enough that doing
a call per-instance in a draw with a high number of instances is a real
problem
* This can be a problem since copying by pitch * count can slightly over-read if
the pitch is larger than a row or slice, potentially reading into unmapped
pages.
* DecodeFormattedComponents converted everything to floats which were
then reinterpreted as int or uint via the unioned fields of PixelValue,
resulting in erroneous value display in PixelHistoryView.
* I've made a pixel history specific version of the format conversion
which treats the values the way the viewer expects.
Fixes validation error related to dependencies:
VUID-vkCmdDraw-renderPass-02684] Validation Error: [ VUID-vkCmdDraw-renderPass-02684 ] Object 0: handle = 0x61ee4f000000021b, type = VK_OBJECT_TYPE_RENDER_PASS; Object 1: handle = 0x1c2336000000021a, type = VK_OBJECT_TYPE_RENDER_PASS; | MessageID = 0x50685725 | vkCmdDraw: RenderPasses incompatible between active render pass w/ VkRenderPass 0x61ee4f000000021b[] with a dependencyCount of 0 and pipeline state object w/ VkRenderPass 0x1c2336000000021a[] with a dependencyCount of 2. The Vulkan spec states: The current render pass must be compatible with the renderPass member of the VkGraphicsPipelineCreateInfo structure specified when creating the VkPipeline bound to VK_PIPELINE_BIND_POINT_GRAPHICS (https://vulkan.lunarg.com/doc/view/1.3.261.1/windows/1.3-extensions/vkspec.html#VUID-vkCmdDraw-renderPass-02684)
The implementation usage of m_BufferAddresses assumes the container is sorted and requires the use of lower_bound() API
Added rdcsortedflatmap subclass of rdcflatmap
Only expose upper_bound(), lower_bound() APIs in rdcsortedflatmap
The upper/lower bound APIs require a sorted container
* We handle support for trivially supported exts like KHR_index_type_uint8 and
KHR_calibrated_timestamps as it would be more churn and work to temporarily
make them unsupported, given how they are almost entirely just aliased.
* Cache indirect parameters pre-callback so they can be used for replay.
* Move ReplayDraw implementation to device so it can be re-used.
* Non-callback support left as a TODO + Assert.
* For capture resources, use the actual resource state at the time of
the event rather than a hardcoded state.
* When hardcoded RT source state was used, on UAV events attempting to
transition a texture which was not created with the RTV flag from that
state caused a device removal.
* Includes a fix provided by Jake to ApplyBarriers that caused an
incorrect state to be returned in this usage.
The state tracking will not be complete during loading and can cause a crash trying to rebind the current pipeline after filling the image with the discard pattern
Do not use the "VkGraphicsPipelineCreateInfo" because this does not include the dynamic state.
Fixes Mesh Output being incorrect when dynamic state for vertex input is used.
D3D12 ERROR: ID3D12CommandList::CopyTextureRegion: D3D12_SUBRESOURCE_FOOTPRINT::RowPitch must be a multiple of 256 (aka. D3D12_TEXTURE_DATA_PITCH_ALIGNMENT) and greater or equal to the pitch implied by the width.[ RESOURCE_MANIPULATION ERROR #855: COPYTEXTUREREGION_INVALIDDSTROWPITCH]