Fixed compilation issue on clang 6.x

Bug:dawn:235
Change-Id: If96dbb9f70ee95a93fc1f14a9741903c3fd32b66
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/11942
Reviewed-by: Kai Ninomiya <kainino@chromium.org>
Commit-Queue: Kai Ninomiya <kainino@chromium.org>
This commit is contained in:
Mathieu-Andre Chiasson 2019-10-08 01:55:57 +00:00 committed by Commit Bot service account
parent 8eb8385e2e
commit 720988d878

View File

@ -670,8 +670,9 @@ namespace dawn_native { namespace vulkan {
VK_IMAGE_LAYOUT_TRANSFER_DST_OPTIMAL, VK_IMAGE_LAYOUT_TRANSFER_DST_OPTIMAL,
clearDepthStencilValue, 1, &range); clearDepthStencilValue, 1, &range);
} else { } else {
float fClearColor = static_cast<float>(clearColor);
VkClearColorValue clearColorValue = { VkClearColorValue clearColorValue = {
{clearColor, clearColor, clearColor, clearColor}}; {fClearColor, fClearColor, fClearColor, fClearColor}};
device->fn.CmdClearColorImage(recordingContext->commandBuffer, GetHandle(), device->fn.CmdClearColorImage(recordingContext->commandBuffer, GetHandle(),
VK_IMAGE_LAYOUT_TRANSFER_DST_OPTIMAL, VK_IMAGE_LAYOUT_TRANSFER_DST_OPTIMAL,
&clearColorValue, 1, &range); &clearColorValue, 1, &range);