17ec681f3Smrg/* 27ec681f3Smrg * Copyright 2019 Google LLC 37ec681f3Smrg * SPDX-License-Identifier: MIT 47ec681f3Smrg * 57ec681f3Smrg * based in part on anv and radv which are: 67ec681f3Smrg * Copyright © 2015 Intel Corporation 77ec681f3Smrg * Copyright © 2016 Red Hat. 87ec681f3Smrg * Copyright © 2016 Bas Nieuwenhuizen 97ec681f3Smrg */ 107ec681f3Smrg 117ec681f3Smrg#ifndef VN_BUFFER_H 127ec681f3Smrg#define VN_BUFFER_H 137ec681f3Smrg 147ec681f3Smrg#include "vn_common.h" 157ec681f3Smrg 167ec681f3Smrgstruct vn_buffer { 177ec681f3Smrg struct vn_object_base base; 187ec681f3Smrg 197ec681f3Smrg VkMemoryRequirements2 memory_requirements; 207ec681f3Smrg VkMemoryDedicatedRequirements dedicated_requirements; 217ec681f3Smrg}; 227ec681f3SmrgVK_DEFINE_NONDISP_HANDLE_CASTS(vn_buffer, 237ec681f3Smrg base.base, 247ec681f3Smrg VkBuffer, 257ec681f3Smrg VK_OBJECT_TYPE_BUFFER) 267ec681f3Smrg 277ec681f3Smrgstruct vn_buffer_view { 287ec681f3Smrg struct vn_object_base base; 297ec681f3Smrg}; 307ec681f3SmrgVK_DEFINE_NONDISP_HANDLE_CASTS(vn_buffer_view, 317ec681f3Smrg base.base, 327ec681f3Smrg VkBufferView, 337ec681f3Smrg VK_OBJECT_TYPE_BUFFER_VIEW) 347ec681f3Smrg 357ec681f3SmrgVkResult 367ec681f3Smrgvn_buffer_create(struct vn_device *dev, 377ec681f3Smrg const VkBufferCreateInfo *create_info, 387ec681f3Smrg const VkAllocationCallbacks *alloc, 397ec681f3Smrg struct vn_buffer **out_buf); 407ec681f3Smrg 417ec681f3Smrg#endif /* VN_BUFFER_H */ 42