From 02ba99a09a6138b0c7e8735e405a608b0a24df14 Mon Sep 17 00:00:00 2001 From: Courtney Goeltzenleuchter Date: Wed, 25 Feb 2015 11:48:28 -0700 Subject: demos: Be sure to request correct memory type --- demos/cube.c | 1 + demos/tri.c | 1 + 2 files changed, 2 insertions(+) diff --git a/demos/cube.c b/demos/cube.c index 5ea5b248..37db0de9 100644 --- a/demos/cube.c +++ b/demos/cube.c @@ -788,6 +788,7 @@ static void demo_prepare_texture_image(struct demo *demo, mem_alloc.memProps = XGL_MEMORY_PROPERTY_CPU_VISIBLE_BIT; for (uint32_t j = 0; j < num_allocations; j ++) { mem_alloc.allocationSize = mem_reqs[j].size; + mem_alloc.memType = mem_reqs[j].memType; /* allocate memory */ err = xglAllocMemory(demo->device, &mem_alloc, diff --git a/demos/tri.c b/demos/tri.c index e497c670..b10037ac 100644 --- a/demos/tri.c +++ b/demos/tri.c @@ -458,6 +458,7 @@ static void demo_prepare_texture_image(struct demo *demo, mem_alloc.memProps = XGL_MEMORY_PROPERTY_CPU_VISIBLE_BIT; for (uint32_t j = 0; j < num_allocations; j ++) { mem_alloc.allocationSize = mem_reqs[j].size; + mem_alloc.memType = mem_reqs[j].memType; /* allocate memory */ err = xglAllocMemory(demo->device, &mem_alloc, -- cgit v1.2.3