aboutsummaryrefslogtreecommitdiff
path: root/layers/mem_tracker.cpp
diff options
context:
space:
mode:
authorCourtney Goeltzenleuchter <courtney@LunarG.com>2015-04-03 16:35:32 -0600
committerChia-I Wu <olv@lunarg.com>2015-04-16 17:33:25 +0800
commit374553cbc2d26d8a523cef7dd5b11150a09129d0 (patch)
tree8224bda78e841a6d280de342c9ee4b72f9f21a29 /layers/mem_tracker.cpp
parent49ffd3f1ecf0d6e034ae6d5ebdc147563b7124e8 (diff)
downloadusermoji-374553cbc2d26d8a523cef7dd5b11150a09129d0.tar.xz
xgl: combine xglCmdClearColor* into one function
combined the two xglCmdClearColorImage* functions into one, with the XGL_CLEAR_COLOR struct bug # 13172 alpha header: r29626
Diffstat (limited to 'layers/mem_tracker.cpp')
-rw-r--r--layers/mem_tracker.cpp23
1 files changed, 2 insertions, 21 deletions
diff --git a/layers/mem_tracker.cpp b/layers/mem_tracker.cpp
index 9b75d503..3c2dec09 100644
--- a/layers/mem_tracker.cpp
+++ b/layers/mem_tracker.cpp
@@ -1563,8 +1563,7 @@ XGL_LAYER_EXPORT void XGLAPI xglCmdFillBuffer(XGL_CMD_BUFFER cmdBuffer, XGL_BUFF
nextTable.CmdFillBuffer(cmdBuffer, destBuffer, destOffset, fillSize, data);
}
-XGL_LAYER_EXPORT void XGLAPI xglCmdClearColorImage(XGL_CMD_BUFFER cmdBuffer, XGL_IMAGE image, const float color[4],
- uint32_t rangeCount, const XGL_IMAGE_SUBRESOURCE_RANGE* pRanges)
+XGL_LAYER_EXPORT void XGLAPI xglCmdClearColorImage(XGL_CMD_BUFFER cmdBuffer, XGL_IMAGE image, XGL_CLEAR_COLOR color, uint32_t rangeCount, const XGL_IMAGE_SUBRESOURCE_RANGE* pRanges)
{
// TODO : Verify memory is in XGL_IMAGE_STATE_CLEAR state
loader_platform_thread_lock_mutex(&globalLock);
@@ -1578,23 +1577,7 @@ XGL_LAYER_EXPORT void XGLAPI xglCmdClearColorImage(XGL_CMD_BUFFER cmdBuffer, XGL
nextTable.CmdClearColorImage(cmdBuffer, image, color, rangeCount, pRanges);
}
-XGL_LAYER_EXPORT void XGLAPI xglCmdClearColorImageRaw(XGL_CMD_BUFFER cmdBuffer, XGL_IMAGE image, const uint32_t color[4],
- uint32_t rangeCount, const XGL_IMAGE_SUBRESOURCE_RANGE* pRanges)
-{
- // TODO : Verify memory is in XGL_IMAGE_STATE_CLEAR state
- loader_platform_thread_lock_mutex(&globalLock);
- XGL_GPU_MEMORY mem = getMemBindingFromObject(image);
- if (XGL_FALSE == updateCBBinding(cmdBuffer, mem)) {
- char str[1024];
- sprintf(str, "In xglCmdClearColorImageRaw() call unable to update binding of image buffer %p to cmdBuffer %p", image, cmdBuffer);
- layerCbMsg(XGL_DBG_MSG_ERROR, XGL_VALIDATION_LEVEL_0, cmdBuffer, 0, MEMTRACK_MEMORY_BINDING_ERROR, "MEM", str);
- }
- loader_platform_thread_unlock_mutex(&globalLock);
- nextTable.CmdClearColorImageRaw(cmdBuffer, image, color, rangeCount, pRanges);
-}
-
-XGL_LAYER_EXPORT void XGLAPI xglCmdClearDepthStencil(XGL_CMD_BUFFER cmdBuffer, XGL_IMAGE image, float depth,
- uint32_t stencil, uint32_t rangeCount, const XGL_IMAGE_SUBRESOURCE_RANGE* pRanges)
+XGL_LAYER_EXPORT void XGLAPI xglCmdClearDepthStencil(XGL_CMD_BUFFER cmdBuffer, XGL_IMAGE image, float depth, uint32_t stencil, uint32_t rangeCount, const XGL_IMAGE_SUBRESOURCE_RANGE* pRanges)
{
// TODO : Verify memory is in XGL_IMAGE_STATE_CLEAR state
loader_platform_thread_lock_mutex(&globalLock);
@@ -1874,8 +1857,6 @@ XGL_LAYER_EXPORT void* XGLAPI xglGetProcAddr(XGL_PHYSICAL_GPU gpu, const char* f
return (void*) xglCmdFillBuffer;
if (!strcmp(funcName, "xglCmdClearColorImage"))
return (void*) xglCmdClearColorImage;
- if (!strcmp(funcName, "xglCmdClearColorImageRaw"))
- return (void*) xglCmdClearColorImageRaw;
if (!strcmp(funcName, "xglCmdClearDepthStencil"))
return (void*) xglCmdClearDepthStencil;
if (!strcmp(funcName, "xglCmdResolveImage"))