Commit Graph
33 Commits
Author SHA1 Message Date
baldurk 26ce9fcc0f Don't serialise size_t directly in VkDescriptorUpdateTemplateEntry
* This caused an incompatibility between 32-bit and 64-bit capture and replay.
2018-07-26 17:24:30 +01:00
baldurk ba78e08394 Fix crash if VkImportMemoryWin32HandleInfoKHR::name is NULL 2018-07-12 15:33:51 +01:00
baldurk 83a0066f00 Add support for VK_KHR_image_format_list 2018-06-21 17:46:15 +01:00
baldurk ea3e2c8610 Add multiqueue support for Vulkan. Closes #373 2018-06-13 09:17:03 +01:00
baldurk 1569a6f0dd Serialise all structs in pNext and discard at replay time
* Rather than not serialising structs that we aren't interested in, we serialise
  them (as best as we can in some cases) so that the information is available to
  the user. Also if in future we decide to replay them they are available.
* We also now replay dedicated allocation extension use.
2018-05-25 18:32:31 +01:00
baldurk 2efce90591 [Coverity] Fix incorrect logic identified by deref-before-NULL-check 2018-05-08 12:47:28 +01:00
baldurk 8b50413bf4 Report support for Vulkan 1.1. Closes #909
* We handle non-suffixed promoted functions but assume that calling
  forward to either the promoted function or the old KHR extension is
  equivalent.
* By this nature we won't record which function the user called, be that
  extension or promoted, it will just be reported as the core function.
* Remove KHR suffixes from function names, enums, etc for promoted
  extensions when serialising/stringising.
2018-05-01 12:36:05 +01:00
baldurk b7ab28a2c4 Add stringification for new bits in vulkan flag enums that had no bits 2018-04-30 19:07:40 +01:00
baldurk deab822e30 Add support for protected memory, new in Vulkan 1.1 2018-04-30 19:07:07 +01:00
baldurk 7961b25e80 Add support for VK_KHR_multiview extension 2018-04-30 18:37:12 +01:00
baldurk d03df4d1a9 Add support for VK_device_group & VK_device_group_creation 2018-04-30 18:31:47 +01:00
baldurk bfe021cf73 Add (mostly disabled) support for VK_KHR_sampler_ycbcr_conversion
* We report no support for Ycbcr conversions by snooping the physical
  device feature query.
* Just to be safe, we support pass-through/ignore implementations of
  most of the functions and pNext structs.
2018-04-30 16:41:46 +01:00
baldurk 49ea4dd8e3 Add support for VK_EXT_debug_utils extension 2018-04-30 13:52:17 +01:00
baldurk 7182e0af3a Add support for VK_EXT_sampler_filter_minmax extension 2018-04-30 10:50:46 +01:00
baldurk f87338dc0e Add support for VK_EXT_vertex_attribute_divisor 2018-04-25 19:11:04 +01:00
baldurk 1bbb99d649 Add support for VK_EXT_global_priority just ignoring for now
* In future we could serialise (but perhaps not apply?) the global
  priority pNext struct
2018-04-25 19:10:54 +01:00
baldurk cbc01342a8 Expose VK_KHR_external_fence* extensions. Closes #742 2018-04-24 19:24:17 +01:00
baldurk a1f5dbdaa6 Implement extension VK_KHR_maintenance2. Closes #818 2018-04-24 19:24:09 +01:00
baldurk bbc0581e7e Implement support VK_EXT_conservative_rasterization. Closes #898 2018-04-24 19:23:51 +01:00
baldurk e9a47112d4 Prepare for actually serialising pNext pointers in structs
* Any struct with a pNext pointer gets a Deserialise function, to clean
  up any dynamically allocated chains.
* The mechanism is as follows:
  - On writing, walk the pNext chain (assuming there is one) and skip
    any structs we don't care to serialise.
  - When we reach a struct we do want to serialise, save a nullable (i.e
    optional) VkStructureType* for it, then recurse and serialise the
    nullable casted struct.
  - If there is no pNext (or none we care about) we serialise a NULL
    VkStructureType*
  - On reading, we serialise the VkStructureType*. If it's NULL, rename
    it to look like a void *pNext = NULL.
  - If it's not NULL, use the structure type to serialise a nullable
    struct of the right type, and recurse.
* The pNext chain is dynamically allocated, which is why it gets cleaned
  up in the Deserialise() function.
2018-04-24 19:23:32 +01:00
baldurk 0fbeace478 Implement VK_KHR_bind_memory2 2018-04-24 15:57:44 +01:00
baldurk 4879f6da6e Mark which members of VkDescriptorImageInfo are valid to serialise
* We need to pass flags down from the parent struct to know, since it
  depends on the type of descriptor. This could happen in any case, but
  is most likely for templated descriptor updates where the memory that
  is referenced could be garbage.
2018-04-24 14:45:42 +01:00
baldurk 0442c46aff Implement VK_KHR_descriptor_update_template. Closes #934 2018-04-24 14:42:05 +01:00
baldurk b88d6eaf86 Print resource ID with missing reference message.
* This makes it easier to track down after the fact.
2018-04-09 17:11:26 +01:00
baldurk e5350505c0 Serialise all union members in vulkan structs and add Union SDTypeFlag 2018-02-28 11:51:08 +00:00
baldurk a1c104f6f8 Serialise VkMemoryHeap::flags as typed enum 2018-02-15 10:09:38 +00:00
baldurk 1ee01e1f82 Apply a normalisation pass over the serialised data
* This is a backwards-incompatible change, so it's done here before v1.0
  so that we can freely break compatibility and not need to define a lot
  of ugly compatibility code.
* The primary motivation is to make the serialised data more uniform
  and have fewer special cases where the serialised form is naturally
  defined from the functions/structs in question.
* There are still some special cases or variances but they should be
  more isolated and only where really necessary.
* Remove some cases in the D3D12 struct serialising where we were
  directly serialising child struct members in the parent struct.
* We now try to match argument/struct member order as closely as
  possible.
* Serialising an array with a count no longer reads the count back out
  into that variable, counts must be serialised separately. This means
  all members/arguments are explicitly present in the structured data
  and also eliminates the awkward case where a count needed to be
  serialised separately after an array if we want to have the count be
  a valid number even if the array could be NULL. It also means we don't
  need the FIXED_COUNT() macro since array lengths can be plain values
  and don't have to be a reference type.
2018-02-14 15:57:53 +00:00
baldurk ef12af50b4 Fix some issues when exporting vulkan structured data. 2018-02-14 00:41:04 +00:00
baldurk e305029ddd Update copyright years to 2018 2018-01-01 17:55:29 +00:00
baldurk 2651ef3185 Serialise memory requirements in vulkan with vkCreateBuffer/CreateImage 2017-11-24 18:14:24 +00:00
baldurk 13de20612b Use typed enum for serialising VkMemoryType::propertyFlags 2017-11-17 16:33:05 +00:00
baldurk 401705ec15 Mark barriers as containing optional resources 2017-11-09 15:09:51 +00:00
baldurk 651ba25919 Update Vulkan common struct serialisation & split it into separate file
* This also includes serialising vulkan handles as Ids by type instead
  of using a macro as before.
* In contrast to the old code, we serialise handles as the wrapped type
  since e.g. when serialising a command buffer in a vkCmd* function we
  want to get back the wrapped type. This means some structs need to be
  unwrapped on replay when before they were "pre-unwrapped" after the
  serialisation, but this isn't a big deal.
2017-11-08 18:24:08 +00:00