assert(!err);
/* bind memory */
- err = xglBindObjectMemory(demo->depth.image,
+ err = xglBindObjectMemory(demo->depth.image, 0,
demo->depth.mem, 0);
assert(!err);
assert(!err);
/* bind memory */
- err = xglBindObjectMemory(demo->textures[i].image,
+ err = xglBindObjectMemory(demo->textures[i].image, 0,
demo->textures[i].mem, 0);
assert(!err);
err = xglUnmapMemory(demo->uniform_data.mem);
assert(!err);
- err = xglBindObjectMemory(demo->uniform_data.buf,
+ err = xglBindObjectMemory(demo->uniform_data.buf, 0,
demo->uniform_data.mem, 0);
assert(!err);
assert(!err);
/* bind memory */
- err = xglBindObjectMemory(demo->depth.image,
+ err = xglBindObjectMemory(demo->depth.image, 0,
demo->depth.mem, 0);
assert(!err);
assert(!err);
/* bind memory */
- err = xglBindObjectMemory(demo->textures[i].image,
+ err = xglBindObjectMemory(demo->textures[i].image, 0,
demo->textures[i].mem, 0);
assert(!err);
err = xglUnmapMemory(demo->vertices.mem);
assert(!err);
- err = xglBindObjectMemory(demo->vertices.buf, demo->vertices.mem, 0);
+ err = xglBindObjectMemory(demo->vertices.buf, 0, demo->vertices.mem, 0);
assert(!err);
demo->vertices.vi.sType = XGL_STRUCTURE_TYPE_PIPELINE_VERTEX_INPUT_CREATE_INFO;
xglDestroyObject(demo->pipeline);
xglDestroyObject(demo->desc_layout);
- xglBindObjectMemory(demo->vertices.buf, XGL_NULL_HANDLE, 0);
+ xglBindObjectMemory(demo->vertices.buf, 0, XGL_NULL_HANDLE, 0);
xglDestroyObject(demo->vertices.buf);
xglFreeMemory(demo->vertices.mem);
for (i = 0; i < DEMO_TEXTURE_COUNT; i++) {
xglDestroyObject(demo->textures[i].view);
- xglBindObjectMemory(demo->textures[i].image, XGL_NULL_HANDLE, 0);
+ xglBindObjectMemory(demo->textures[i].image, 0, XGL_NULL_HANDLE, 0);
xglDestroyObject(demo->textures[i].image);
xglFreeMemory(demo->textures[i].mem);
xglDestroyObject(demo->textures[i].sampler);
}
xglDestroyObject(demo->depth.view);
- xglBindObjectMemory(demo->depth.image, XGL_NULL_HANDLE, 0);
+ xglBindObjectMemory(demo->depth.image, 0, XGL_NULL_HANDLE, 0);
xglDestroyObject(demo->depth.image);
xglFreeMemory(demo->depth.mem);
typedef XGL_RESULT (XGLAPI *xglOpenPeerImageType)(XGL_DEVICE device, const XGL_PEER_IMAGE_OPEN_INFO* pOpenInfo, XGL_IMAGE* pImage, XGL_GPU_MEMORY* pMem);
typedef XGL_RESULT (XGLAPI *xglDestroyObjectType)(XGL_OBJECT object);
typedef XGL_RESULT (XGLAPI *xglGetObjectInfoType)(XGL_BASE_OBJECT object, XGL_OBJECT_INFO_TYPE infoType, XGL_SIZE* pDataSize, XGL_VOID* pData);
-typedef XGL_RESULT (XGLAPI *xglBindObjectMemoryType)(XGL_OBJECT object, XGL_GPU_MEMORY mem, XGL_GPU_SIZE memOffset);
-typedef XGL_RESULT (XGLAPI *xglBindObjectMemoryRangeType)(XGL_OBJECT object, XGL_GPU_SIZE rangeOffset, XGL_GPU_SIZE rangeSize, XGL_GPU_MEMORY mem, XGL_GPU_SIZE memOffset);
-typedef XGL_RESULT (XGLAPI *xglBindImageMemoryRangeType)(XGL_IMAGE image, const XGL_IMAGE_MEMORY_BIND_INFO* bindInfo, XGL_GPU_MEMORY mem, XGL_GPU_SIZE memOffset);
+typedef XGL_RESULT (XGLAPI *xglBindObjectMemoryType)(XGL_OBJECT object, XGL_UINT allocationIdx, XGL_GPU_MEMORY mem, XGL_GPU_SIZE memOffset);
+typedef XGL_RESULT (XGLAPI *xglBindObjectMemoryRangeType)(XGL_OBJECT object, XGL_UINT allocationIdx, XGL_GPU_SIZE rangeOffset, XGL_GPU_SIZE rangeSize, XGL_GPU_MEMORY mem, XGL_GPU_SIZE memOffset);
+typedef XGL_RESULT (XGLAPI *xglBindImageMemoryRangeType)(XGL_IMAGE image, XGL_UINT allocationIdx, const XGL_IMAGE_MEMORY_BIND_INFO* bindInfo, XGL_GPU_MEMORY mem, XGL_GPU_SIZE memOffset);
typedef XGL_RESULT (XGLAPI *xglCreateFenceType)(XGL_DEVICE device, const XGL_FENCE_CREATE_INFO* pCreateInfo, XGL_FENCE* pFence);
typedef XGL_RESULT (XGLAPI *xglGetFenceStatusType)(XGL_FENCE fence);
typedef XGL_RESULT (XGLAPI *xglWaitForFencesType)(XGL_DEVICE device, XGL_UINT fenceCount, const XGL_FENCE* pFences, XGL_BOOL waitAll, XGL_UINT64 timeout);
XGL_RESULT XGLAPI xglBindObjectMemory(
XGL_OBJECT object,
+ XGL_UINT allocationIdx,
XGL_GPU_MEMORY mem,
XGL_GPU_SIZE memOffset);
XGL_RESULT XGLAPI xglBindObjectMemoryRange(
XGL_OBJECT object,
+ XGL_UINT allocationIdx,
XGL_GPU_SIZE rangeOffset,
XGL_GPU_SIZE rangeSize,
XGL_GPU_MEMORY mem,
XGL_RESULT XGLAPI xglBindImageMemoryRange(
XGL_IMAGE image,
+ XGL_UINT allocationIdx,
const XGL_IMAGE_MEMORY_BIND_INFO* bindInfo,
XGL_GPU_MEMORY mem,
XGL_GPU_SIZE memOffset);
return result;
}
-XGL_LAYER_EXPORT XGL_RESULT XGLAPI xglBindObjectMemory(XGL_OBJECT object, XGL_GPU_MEMORY mem, XGL_GPU_SIZE offset)
+XGL_LAYER_EXPORT XGL_RESULT XGLAPI xglBindObjectMemory(XGL_OBJECT object, XGL_UINT allocationIdx, XGL_GPU_MEMORY mem, XGL_GPU_SIZE offset)
{
- XGL_RESULT result = nextTable.BindObjectMemory(object, mem, offset);
+ XGL_RESULT result = nextTable.BindObjectMemory(object, allocationIdx, mem, offset);
return result;
}
return result;
}
-XGL_LAYER_EXPORT XGL_RESULT XGLAPI xglBindObjectMemory(XGL_OBJECT object, XGL_GPU_MEMORY mem, XGL_GPU_SIZE offset)
+XGL_LAYER_EXPORT XGL_RESULT XGLAPI xglBindObjectMemory(XGL_OBJECT object, XGL_UINT allocationIdx, XGL_GPU_MEMORY mem, XGL_GPU_SIZE offset)
{
- XGL_RESULT result = nextTable.BindObjectMemory(object, mem, offset);
+ XGL_RESULT result = nextTable.BindObjectMemory(object, allocationIdx, mem, offset);
// Track objects tied to memory
if (XGL_FALSE == updateObjectBinding(object, mem)) {
char str[1024];
Proto("XGL_RESULT", "BindObjectMemory",
[Param("XGL_OBJECT", "object"),
+ Param("XGL_UINT", "allocationIdx"),
Param("XGL_GPU_MEMORY", "mem"),
Param("XGL_GPU_SIZE", "memOffset")]),
Proto("XGL_RESULT", "BindObjectMemoryRange",
[Param("XGL_OBJECT", "object"),
+ Param("XGL_UINT", "allocationIdx"),
Param("XGL_GPU_SIZE", "rangeOffset"),
Param("XGL_GPU_SIZE", "rangeSize"),
Param("XGL_GPU_MEMORY", "mem"),
Proto("XGL_RESULT", "BindImageMemoryRange",
[Param("XGL_IMAGE", "image"),
+ Param("XGL_UINT", "allocationIdx"),
Param("const XGL_IMAGE_MEMORY_BIND_INFO*", "bindInfo"),
Param("XGL_GPU_MEMORY", "mem"),
Param("XGL_GPU_SIZE", "memOffset")]),