Lines Matching defs:device
82 std::unique_ptr<vk::BufferWithMemory> makeBufferForImage (const vk::DeviceInterface& vkd, const vk::VkDevice device, vk::Allocator& allocator, tcu::TextureFormat tcuFormat, vk::VkExtent2D imageExtent)
87 auto outBuffer = std::unique_ptr<vk::BufferWithMemory>(new vk::BufferWithMemory(vkd, device, allocator, outBufferInfo, vk::MemoryRequirement::HostVisible));
115 void copyAndFlush(const vk::DeviceInterface& vkd, vk::VkDevice device, vk::BufferWithMemory& buffer, size_t offset, const void* src, size_t size)
121 vk::flushAlloc(vkd, device, alloc);
207 // We are creating a custom device with a potentially large amount of extensions and features enabled, using the default device
208 // as a reference. Some implementations may only enable certain device extensions if some instance extensions are enabled, so in
209 // this case it's important to reuse the context instance when creating the device.
263 const vk::VkDevice device = m_context.getDevice();
287 const vk::Move<vk::VkImage> colorImage (makeImage(vk, device, makeImageCreateInfo(extent, vk::VK_FORMAT_R32G32B32A32_SFLOAT, vk::VK_IMAGE_USAGE_COLOR_ATTACHMENT_BIT | vk::VK_IMAGE_USAGE_TRANSFER_SRC_BIT)));
288 const de::MovePtr<vk::Allocation> colorImageAlloc (bindImage(vk, device, allocator, *colorImage, vk::MemoryRequirement::Any));
289 const vk::Move<vk::VkImageView> colorImageView (makeImageView(vk, device, *colorImage, vk::VK_IMAGE_VIEW_TYPE_2D, vk::VK_FORMAT_R32G32B32A32_SFLOAT, colorSubresourceRange));
291 const vk::PipelineLayoutWrapper pipelineLayout (m_pipelineConstructionType, vk, device, &pipelineLayoutInfo);
292 vk::RenderPassWrapper renderPass (m_pipelineConstructionType, vk, device, vk::VK_FORMAT_R32G32B32A32_SFLOAT);
293 renderPass.createFramebuffer(vk, device, *colorImage, *colorImageView, extent.width, extent.height);
294 const vk::ShaderWrapper vertShaderModule = vk::ShaderWrapper(vk, device, m_context.getBinaryCollection().get("vert"));
295 const vk::ShaderWrapper fragShaderModule = vk::ShaderWrapper(vk, device, m_context.getBinaryCollection().get("frag"));
298 auto outBuffer = makeBufferForImage(vk, device, allocator, mapVkFormat(vk::VK_FORMAT_R32G32B32A32_SFLOAT), extent);
379 vk::GraphicsPipelineWrapper graphicsPipelineWrapper { vki, vk, physicalDevice, device, deviceExtensions, m_pipelineConstructionType };
400 const vk::Move<vk::VkCommandPool> cmdPool (createCommandPool(vk, device, vk::VK_COMMAND_POOL_CREATE_RESET_COMMAND_BUFFER_BIT, queueFamilyIndex));
401 const vk::Move<vk::VkCommandBuffer> cmdBuffer (allocateCommandBuffer(vk, device, *cmdPool, vk::VK_COMMAND_BUFFER_LEVEL_PRIMARY));
459 de::MovePtr<vk::BufferWithMemory> colorBuffer = de::MovePtr<vk::BufferWithMemory>(new vk::BufferWithMemory(vk, device, allocator, colorCreateInfo, vk::MemoryRequirement::HostVisible));
460 de::MovePtr<vk::BufferWithMemory> vertexBuffer = de::MovePtr<vk::BufferWithMemory>(new vk::BufferWithMemory(vk, device, allocator, vertexCreateInfo, vk::MemoryRequirement::HostVisible));
461 copyAndFlush(vk, device, *colorBuffer, 0, colorData.data(), colorData.size() * sizeof(float));
462 copyAndFlush(vk, device, *vertexBuffer, 0, vertexData.data(), vertexData.size() * sizeof(float));
529 submitCommandsAndWait(vk, device, queue, *cmdBuffer);
531 invalidateAlloc(vk, device, outBufferAlloc);
573 DevicePtr device,
582 , m_device(device)
743 const vk::VkDevice device = getDevice();
862 de::SharedPtr<vk::BufferWithMemory> clrBuffer(new vk::BufferWithMemory(vk, device, allocator, clrCreateInfo, vk::MemoryRequirement::HostVisible));
863 copyAndFlush(vk, device, *clrBuffer, 0, colors.data(), deUint32(colors.size() * sizeof(float)));
921 de::SharedPtr<vk::BufferWithMemory> buffer(new vk::BufferWithMemory(vk, device, allocator, createInfo, vk::MemoryRequirement::HostVisible));
922 copyAndFlush(vk, device, *buffer, 0, points.data(), deUint32(points.size() * sizeof(float)));
941 const vk::VkDevice device = getDevice();
950 const vk::Move<vk::VkImage> colorImage = makeImage(vk, device, makeImageCreateInfo(extent, colorFormat, vk::VK_IMAGE_USAGE_COLOR_ATTACHMENT_BIT | vk::VK_IMAGE_USAGE_TRANSFER_SRC_BIT));
951 const de::MovePtr<vk::Allocation> colorImageAlloc = bindImage(vk, device, allocator, *colorImage, vk::MemoryRequirement::Any);
952 const vk::Move<vk::VkImageView> colorImageView = makeImageView(vk, device, *colorImage, vk::VK_IMAGE_VIEW_TYPE_2D, colorFormat, colorSubresRange);
953 vk::RenderPassWrapper renderPass (m_pipelineConstructionType, vk, device, colorFormat);
954 renderPass.createFramebuffer(vk, device, colorImage.get(), colorImageView.get(), extent.width, extent.height);
956 const vk::PipelineLayoutWrapper pipelineLayout(m_pipelineConstructionType, vk, device, &pipelineLayoutInfo, nullptr);
959 const vk::Move<vk::VkCommandPool> cmdPool = createCommandPool(vk, device, vk::VK_COMMAND_POOL_CREATE_RESET_COMMAND_BUFFER_BIT, queueFamilyIndex);
960 const vk::Move<vk::VkCommandBuffer> cmdBuffer = allocateCommandBuffer(vk, device, *cmdPool, vk::VK_COMMAND_BUFFER_LEVEL_PRIMARY);
982 std::unique_ptr<vk::BufferWithMemory> outBuffer = makeBufferForImage(vk, device, allocator, mapVkFormat(colorFormat), extent);
1000 submitCommandsAndWait(vk, device, queue, *cmdBuffer);
1002 invalidateAlloc(vk, device, outBufferAlloc);
1291 DevicePtr device;
1325 device = createRobustBufferAccessDevice(context, &features2);
1328 DeviceDriverPtr(new vk::DeviceDriver(context.getPlatformInterface(), context.getInstance(), *device, context.getUsedApiVersion()));
1330 DeviceDriverPtr(new DeviceDriverSC(context.getPlatformInterface(), context.getInstance(), *device, context.getTestContext().getCommandLine(),
1332 vk::DeinitDeviceDeleter(context.getResourceInterface().get(), *device));
1336 return (new BindVertexBuffers2Instance(context, driver, device, m_pipelineConstructionType, m_params, m_robustness2));