Function Prototype

vkGetBufferCollectionPropertiesFUCHSIA

Retrieve properties from a buffer collection

After constraints have been set on the buffer collection by calling vkSetBufferCollectionImageConstraintsFUCHSIA or vkSetBufferCollectionBufferConstraintsFUCHSIA, call vkGetBufferCollectionPropertiesFUCHSIA to retrieve the negotiated and finalized properties of the buffer collection.

The call to vkGetBufferCollectionPropertiesFUCHSIA is synchronous. It waits for the Sysmem format negotiation and buffer collection allocation to complete before returning.

VkResult vkGetBufferCollectionPropertiesFUCHSIA(
    VkDevice device,
    VkBufferCollectionFUCHSIA collection,
    VkBufferCollectionPropertiesFUCHSIA* pProperties);

For image-based buffer collections, upon calling vkGetBufferCollectionPropertiesFUCHSIA, Sysmem will choose an element of the VkImageConstraintsInfoFUCHSIA::pImageCreateInfos established by the preceding call to vkSetBufferCollectionImageConstraintsFUCHSIA. The index of the element chosen is stored in and can be retrieved from VkBufferCollectionPropertiesFUCHSIA::createInfoIndex.

For buffer-based buffer collections, a single VkBufferCreateInfo is specified as VkBufferConstraintsInfoFUCHSIA::createInfo. VkBufferCollectionPropertiesFUCHSIA::createInfoIndex will therefore always be zero.

vkGetBufferCollectionPropertiesFUCHSIA may fail if Sysmem is unable to resolve the constraints of all of the participants in the buffer collection. If that occurs, vkGetBufferCollectionPropertiesFUCHSIA will return VK_ERROR_INITIALIZATION_FAILED.