Merge branch 'jbreton-buffer-test-heap-limit' into 'vulkan-cts-1.0'
authorPyry Haulos <phaulos@google.com>
Mon, 21 Mar 2016 17:28:07 +0000 (10:28 -0700)
committerPyry Haulos <phaulos@google.com>
Mon, 21 Mar 2016 17:28:07 +0000 (10:28 -0700)
Fix createBuffer tests to clamp the buffer size based on the size of the selected heap

Right now, those tests clamp the allocation size based on the size of heap 0.
This is incorrect if the allocation is not done on heap 0.
In order to get the first compatible heap, we need to create the buffer and then call getBufferMemoryRequirements to query the requirement.

Then if we detect if the size need to be clamped we will recreate another buffer with the clamped size.

Fixes #326

See merge request !464


Trivial merge