[{"data":1,"prerenderedAt":2149},["ShallowReactive",2],{"Pc37MYyLjI":3},{"title":4,"description":5,"parent":6,"type":7,"xrefs":8,"body":9,"_type":2148,"_id":4},"VkPhysicalDeviceMemoryProperties","Structure specifying physical device memory properties","VK_VERSION_1_0","structs",[],{"type":10,"children":11,"toc":2146},"root",[12,28,324,451,489,548,605,610,636,1201,1279,1320,1417,1478,1483,2140],{"type":13,"tag":14,"props":15,"children":16},"element","p",{},[17,20,26],{"type":18,"value":19},"text","The ",{"type":13,"tag":21,"props":22,"children":24},"code",{"className":23},[],[25],{"type":18,"value":4},{"type":18,"value":27}," structure is defined as:",{"type":13,"tag":29,"props":30,"children":31},"code-group",{},[32,142],{"type":13,"tag":33,"props":34,"children":40},"pre",{"className":35,"code":36,"filename":37,"language":38,"meta":39,"style":39},"language-c shiki shiki-themes github-light-default github-dark-default","typedef struct VkPhysicalDeviceMemoryProperties {\n uint32_t memoryTypeCount;\n VkMemoryType memoryTypes[VK_MAX_MEMORY_TYPES];\n uint32_t memoryHeapCount;\n VkMemoryHeap memoryHeaps[VK_MAX_MEMORY_HEAPS];\n} VkPhysicalDeviceMemoryProperties;\n","C","c","",[41],{"type":13,"tag":21,"props":42,"children":43},{"__ignoreMap":39},[44,67,81,101,114,133],{"type":13,"tag":45,"props":46,"children":49},"span",{"class":47,"line":48},"line",1,[50,56,61],{"type":13,"tag":45,"props":51,"children":53},{"style":52},"--shiki-default:#CF222E;--shiki-dark:#FF7B72",[54],{"type":18,"value":55},"typedef",{"type":13,"tag":45,"props":57,"children":58},{"style":52},[59],{"type":18,"value":60}," struct",{"type":13,"tag":45,"props":62,"children":64},{"style":63},"--shiki-default:#1F2328;--shiki-dark:#E6EDF3",[65],{"type":18,"value":66}," VkPhysicalDeviceMemoryProperties {\n",{"type":13,"tag":45,"props":68,"children":70},{"class":47,"line":69},2,[71,76],{"type":13,"tag":45,"props":72,"children":73},{"style":52},[74],{"type":18,"value":75}," uint32_t",{"type":13,"tag":45,"props":77,"children":78},{"style":63},[79],{"type":18,"value":80}," memoryTypeCount;\n",{"type":13,"tag":45,"props":82,"children":84},{"class":47,"line":83},3,[85,90,96],{"type":13,"tag":45,"props":86,"children":87},{"style":63},[88],{"type":18,"value":89}," VkMemoryType ",{"type":13,"tag":45,"props":91,"children":93},{"style":92},"--shiki-default:#953800;--shiki-dark:#FFA657",[94],{"type":18,"value":95},"memoryTypes",{"type":13,"tag":45,"props":97,"children":98},{"style":63},[99],{"type":18,"value":100},"[VK_MAX_MEMORY_TYPES];\n",{"type":13,"tag":45,"props":102,"children":104},{"class":47,"line":103},4,[105,109],{"type":13,"tag":45,"props":106,"children":107},{"style":52},[108],{"type":18,"value":75},{"type":13,"tag":45,"props":110,"children":111},{"style":63},[112],{"type":18,"value":113}," memoryHeapCount;\n",{"type":13,"tag":45,"props":115,"children":117},{"class":47,"line":116},5,[118,123,128],{"type":13,"tag":45,"props":119,"children":120},{"style":63},[121],{"type":18,"value":122}," VkMemoryHeap ",{"type":13,"tag":45,"props":124,"children":125},{"style":92},[126],{"type":18,"value":127},"memoryHeaps",{"type":13,"tag":45,"props":129,"children":130},{"style":63},[131],{"type":18,"value":132},"[VK_MAX_MEMORY_HEAPS];\n",{"type":13,"tag":45,"props":134,"children":136},{"class":47,"line":135},6,[137],{"type":13,"tag":45,"props":138,"children":139},{"style":63},[140],{"type":18,"value":141},"} VkPhysicalDeviceMemoryProperties;\n",{"type":13,"tag":33,"props":143,"children":148},{"className":144,"code":145,"filename":146,"language":147,"meta":39,"style":39},"language-rs shiki shiki-themes github-light-default github-dark-default","pub struct PhysicalDeviceMemoryProperties {\n memory_type_count: u32,\n memory_types: *const [vk::MemoryType ; MAX_MEMORY_TYPES],\n memory_heap_count: u32,\n memory_heaps: *const [vk::MemoryHeap ; MAX_MEMORY_HEAPS],\n}\n","Rust","rs",[149],{"type":13,"tag":21,"props":150,"children":151},{"__ignoreMap":39},[152,174,197,250,270,316],{"type":13,"tag":45,"props":153,"children":154},{"class":47,"line":48},[155,160,164,169],{"type":13,"tag":45,"props":156,"children":157},{"style":52},[158],{"type":18,"value":159},"pub",{"type":13,"tag":45,"props":161,"children":162},{"style":52},[163],{"type":18,"value":60},{"type":13,"tag":45,"props":165,"children":166},{"style":92},[167],{"type":18,"value":168}," PhysicalDeviceMemoryProperties",{"type":13,"tag":45,"props":170,"children":171},{"style":63},[172],{"type":18,"value":173}," {\n",{"type":13,"tag":45,"props":175,"children":176},{"class":47,"line":69},[177,182,187,192],{"type":13,"tag":45,"props":178,"children":179},{"style":63},[180],{"type":18,"value":181}," memory_type_count",{"type":13,"tag":45,"props":183,"children":184},{"style":52},[185],{"type":18,"value":186},":",{"type":13,"tag":45,"props":188,"children":189},{"style":92},[190],{"type":18,"value":191}," u32",{"type":13,"tag":45,"props":193,"children":194},{"style":63},[195],{"type":18,"value":196},",\n",{"type":13,"tag":45,"props":198,"children":199},{"class":47,"line":83},[200,205,209,214,219,224,229,234,239,245],{"type":13,"tag":45,"props":201,"children":202},{"style":63},[203],{"type":18,"value":204}," memory_types",{"type":13,"tag":45,"props":206,"children":207},{"style":52},[208],{"type":18,"value":186},{"type":13,"tag":45,"props":210,"children":211},{"style":52},[212],{"type":18,"value":213}," *const",{"type":13,"tag":45,"props":215,"children":216},{"style":63},[217],{"type":18,"value":218}," [",{"type":13,"tag":45,"props":220,"children":221},{"style":92},[222],{"type":18,"value":223},"vk",{"type":13,"tag":45,"props":225,"children":226},{"style":52},[227],{"type":18,"value":228},"::",{"type":13,"tag":45,"props":230,"children":231},{"style":92},[232],{"type":18,"value":233},"MemoryType",{"type":13,"tag":45,"props":235,"children":236},{"style":63},[237],{"type":18,"value":238}," ; ",{"type":13,"tag":45,"props":240,"children":242},{"style":241},"--shiki-default:#0550AE;--shiki-dark:#79C0FF",[243],{"type":18,"value":244},"MAX_MEMORY_TYPES",{"type":13,"tag":45,"props":246,"children":247},{"style":63},[248],{"type":18,"value":249},"],\n",{"type":13,"tag":45,"props":251,"children":252},{"class":47,"line":103},[253,258,262,266],{"type":13,"tag":45,"props":254,"children":255},{"style":63},[256],{"type":18,"value":257}," memory_heap_count",{"type":13,"tag":45,"props":259,"children":260},{"style":52},[261],{"type":18,"value":186},{"type":13,"tag":45,"props":263,"children":264},{"style":92},[265],{"type":18,"value":191},{"type":13,"tag":45,"props":267,"children":268},{"style":63},[269],{"type":18,"value":196},{"type":13,"tag":45,"props":271,"children":272},{"class":47,"line":116},[273,278,282,286,290,294,298,303,307,312],{"type":13,"tag":45,"props":274,"children":275},{"style":63},[276],{"type":18,"value":277}," memory_heaps",{"type":13,"tag":45,"props":279,"children":280},{"style":52},[281],{"type":18,"value":186},{"type":13,"tag":45,"props":283,"children":284},{"style":52},[285],{"type":18,"value":213},{"type":13,"tag":45,"props":287,"children":288},{"style":63},[289],{"type":18,"value":218},{"type":13,"tag":45,"props":291,"children":292},{"style":92},[293],{"type":18,"value":223},{"type":13,"tag":45,"props":295,"children":296},{"style":52},[297],{"type":18,"value":228},{"type":13,"tag":45,"props":299,"children":300},{"style":92},[301],{"type":18,"value":302},"MemoryHeap",{"type":13,"tag":45,"props":304,"children":305},{"style":63},[306],{"type":18,"value":238},{"type":13,"tag":45,"props":308,"children":309},{"style":241},[310],{"type":18,"value":311},"MAX_MEMORY_HEAPS",{"type":13,"tag":45,"props":313,"children":314},{"style":63},[315],{"type":18,"value":249},{"type":13,"tag":45,"props":317,"children":318},{"class":47,"line":135},[319],{"type":13,"tag":45,"props":320,"children":321},{"style":63},[322],{"type":18,"value":323},"}\n",{"type":13,"tag":325,"props":326,"children":327},"ul",{},[328,347,398,414],{"type":13,"tag":329,"props":330,"children":331},"li",{},[332,338,340,345],{"type":13,"tag":21,"props":333,"children":335},{"className":334},[],[336],{"type":18,"value":337},"memoryTypeCount",{"type":18,"value":339}," is the number of valid elements in the\n",{"type":13,"tag":21,"props":341,"children":343},{"className":342},[],[344],{"type":18,"value":95},{"type":18,"value":346}," array.",{"type":13,"tag":329,"props":348,"children":349},{},[350,355,357,363,367,374,376,382,384,389,391,396],{"type":13,"tag":21,"props":351,"children":353},{"className":352},[],[354],{"type":18,"value":95},{"type":18,"value":356}," is an array of ",{"type":13,"tag":21,"props":358,"children":360},{"className":359},[],[361],{"type":18,"value":362},"VK_MAX_MEMORY_TYPES",{"type":13,"tag":364,"props":365,"children":366},"br",{},[],{"type":13,"tag":368,"props":369,"children":371},"a",{"href":370},"/man/VkMemoryType",[372],{"type":18,"value":373},"VkMemoryType",{"type":18,"value":375}," structures describing the ",{"type":13,"tag":377,"props":378,"children":379},"em",{},[380],{"type":18,"value":381},"memory types",{"type":18,"value":383}," that ",{"type":13,"tag":385,"props":386,"children":388},"normative",{"type":387},"can",[],{"type":18,"value":390}," be\nused to access memory allocated from the heaps specified by\n",{"type":13,"tag":21,"props":392,"children":394},{"className":393},[],[395],{"type":18,"value":127},{"type":18,"value":397},".",{"type":13,"tag":329,"props":399,"children":400},{},[401,407,408,413],{"type":13,"tag":21,"props":402,"children":404},{"className":403},[],[405],{"type":18,"value":406},"memoryHeapCount",{"type":18,"value":339},{"type":13,"tag":21,"props":409,"children":411},{"className":410},[],[412],{"type":18,"value":127},{"type":18,"value":346},{"type":13,"tag":329,"props":415,"children":416},{},[417,422,423,429,432,438,439,444,446,449],{"type":13,"tag":21,"props":418,"children":420},{"className":419},[],[421],{"type":18,"value":127},{"type":18,"value":356},{"type":13,"tag":21,"props":424,"children":426},{"className":425},[],[427],{"type":18,"value":428},"VK_MAX_MEMORY_HEAPS",{"type":13,"tag":364,"props":430,"children":431},{},[],{"type":13,"tag":368,"props":433,"children":435},{"href":434},"/man/VkMemoryHeap",[436],{"type":18,"value":437},"VkMemoryHeap",{"type":18,"value":375},{"type":13,"tag":377,"props":440,"children":441},{},[442],{"type":18,"value":443},"memory heaps",{"type":18,"value":445}," from which\nmemory ",{"type":13,"tag":385,"props":447,"children":448},{"type":387},[],{"type":18,"value":450}," be allocated.",{"type":13,"tag":14,"props":452,"children":453},{},[454,455,460,462,466,468,472,473,476,478,481,483,487],{"type":18,"value":19},{"type":13,"tag":21,"props":456,"children":458},{"className":457},[],[459],{"type":18,"value":4},{"type":18,"value":461}," structure describes a number of\n",{"type":13,"tag":377,"props":463,"children":464},{},[465],{"type":18,"value":443},{"type":18,"value":467}," as well as a number of ",{"type":13,"tag":377,"props":469,"children":470},{},[471],{"type":18,"value":381},{"type":18,"value":383},{"type":13,"tag":385,"props":474,"children":475},{"type":387},[],{"type":18,"value":477}," be used to\naccess memory allocated in those heaps.\nEach heap describes a memory resource of a particular size, and each memory\ntype describes a set of memory properties (e.g. host cached vs. uncached)\nthat ",{"type":13,"tag":385,"props":479,"children":480},{"type":387},[],{"type":18,"value":482}," be used with a given memory heap.\nAllocations using a particular memory type will consume resources from the\nheap indicated by that memory type’s heap index.\nMore than one memory type ",{"type":13,"tag":385,"props":484,"children":486},{"type":485},"may",[],{"type":18,"value":488}," share each heap, and the heaps and memory\ntypes provide a mechanism to advertise an accurate size of the physical\nmemory resources while allowing the memory to be used with a variety of\ndifferent properties.",{"type":13,"tag":14,"props":490,"children":491},{},[492,494,499,501,506,508,513,515,519,521,526,528,533,535,540,542,546],{"type":18,"value":493},"The number of memory heaps is given by ",{"type":13,"tag":21,"props":495,"children":497},{"className":496},[],[498],{"type":18,"value":406},{"type":18,"value":500}," and is less\nthan or equal to ",{"type":13,"tag":21,"props":502,"children":504},{"className":503},[],[505],{"type":18,"value":428},{"type":18,"value":507},".\nEach heap is described by an element of the ",{"type":13,"tag":21,"props":509,"children":511},{"className":510},[],[512],{"type":18,"value":127},{"type":18,"value":514}," array as a\n",{"type":13,"tag":368,"props":516,"children":517},{"href":434},[518],{"type":18,"value":437},{"type":18,"value":520}," structure.\nThe number of memory types available across all memory heaps is given by\n",{"type":13,"tag":21,"props":522,"children":524},{"className":523},[],[525],{"type":18,"value":337},{"type":18,"value":527}," and is less than or equal to\n",{"type":13,"tag":21,"props":529,"children":531},{"className":530},[],[532],{"type":18,"value":362},{"type":18,"value":534},".\nEach memory type is described by an element of the ",{"type":13,"tag":21,"props":536,"children":538},{"className":537},[],[539],{"type":18,"value":95},{"type":18,"value":541}," array\nas a ",{"type":13,"tag":368,"props":543,"children":544},{"href":370},[545],{"type":18,"value":373},{"type":18,"value":547}," structure.",{"type":13,"tag":14,"props":549,"children":550},{},[551,553,557,559,565,567,571,572,578,580,583,585,590,592,598,600,603],{"type":18,"value":552},"At least one heap ",{"type":13,"tag":385,"props":554,"children":556},{"type":555},"must",[],{"type":18,"value":558}," include ",{"type":13,"tag":21,"props":560,"children":562},{"className":561},[],[563],{"type":18,"value":564},"VK_MEMORY_HEAP_DEVICE_LOCAL_BIT",{"type":18,"value":566}," in\n",{"type":13,"tag":368,"props":568,"children":569},{"href":434},[570],{"type":18,"value":437},{"type":18,"value":228},{"type":13,"tag":21,"props":573,"children":575},{"className":574},[],[576],{"type":18,"value":577},"flags",{"type":18,"value":579},".\nIf there are multiple heaps that all have similar performance\ncharacteristics, they ",{"type":13,"tag":385,"props":581,"children":582},{"type":485},[],{"type":18,"value":584}," all include\n",{"type":13,"tag":21,"props":586,"children":588},{"className":587},[],[589],{"type":18,"value":564},{"type":18,"value":591},".\nIn a unified memory architecture (UMA) system there is often only a single\nmemory heap which is considered to be equally ",{"type":13,"tag":21,"props":593,"children":595},{"className":594},[],[596],{"type":18,"value":597},"local",{"type":18,"value":599}," to the host and to\nthe device, and such an implementation ",{"type":13,"tag":385,"props":601,"children":602},{"type":555},[],{"type":18,"value":604}," advertise the heap as\ndevice-local.",{"type":13,"tag":606,"props":607,"children":609},"anchor",{"id":608},"memory-device-bitmask-list",[],{"type":13,"tag":14,"props":611,"children":612},{},[613,615,621,623,626,628,634],{"type":18,"value":614},"Each memory type returned by ",{"type":13,"tag":368,"props":616,"children":618},{"href":617},"/man/vkGetPhysicalDeviceMemoryProperties",[619],{"type":18,"value":620},"vkGetPhysicalDeviceMemoryProperties",{"type":18,"value":622}," ",{"type":13,"tag":385,"props":624,"children":625},{"type":555},[],{"type":18,"value":627},"\nhave its ",{"type":13,"tag":21,"props":629,"children":631},{"className":630},[],[632],{"type":18,"value":633},"propertyFlags",{"type":18,"value":635}," set to one of the following values:",{"type":13,"tag":325,"props":637,"children":638},{},[639,644,664,682,708,717,743,769,804,822,849,884,901,936,980,1016,1060,1086,1130,1183],{"type":13,"tag":329,"props":640,"children":641},{},[642],{"type":18,"value":643},"0",{"type":13,"tag":329,"props":645,"children":646},{},[647,653,655,658],{"type":13,"tag":21,"props":648,"children":650},{"className":649},[],[651],{"type":18,"value":652},"VK_MEMORY_PROPERTY_HOST_VISIBLE_BIT",{"type":18,"value":654}," |\\",{"type":13,"tag":364,"props":656,"children":657},{},[],{"type":13,"tag":21,"props":659,"children":661},{"className":660},[],[662],{"type":18,"value":663},"VK_MEMORY_PROPERTY_HOST_COHERENT_BIT",{"type":13,"tag":329,"props":665,"children":666},{},[667,672,673,676],{"type":13,"tag":21,"props":668,"children":670},{"className":669},[],[671],{"type":18,"value":652},{"type":18,"value":654},{"type":13,"tag":364,"props":674,"children":675},{},[],{"type":13,"tag":21,"props":677,"children":679},{"className":678},[],[680],{"type":18,"value":681},"VK_MEMORY_PROPERTY_HOST_CACHED_BIT",{"type":13,"tag":329,"props":683,"children":684},{},[685,690,691,694,699,700,703],{"type":13,"tag":21,"props":686,"children":688},{"className":687},[],[689],{"type":18,"value":652},{"type":18,"value":654},{"type":13,"tag":364,"props":692,"children":693},{},[],{"type":13,"tag":21,"props":695,"children":697},{"className":696},[],[698],{"type":18,"value":681},{"type":18,"value":654},{"type":13,"tag":364,"props":701,"children":702},{},[],{"type":13,"tag":21,"props":704,"children":706},{"className":705},[],[707],{"type":18,"value":663},{"type":13,"tag":329,"props":709,"children":710},{},[711],{"type":13,"tag":21,"props":712,"children":714},{"className":713},[],[715],{"type":18,"value":716},"VK_MEMORY_PROPERTY_DEVICE_LOCAL_BIT",{"type":13,"tag":329,"props":718,"children":719},{},[720,725,726,729,734,735,738],{"type":13,"tag":21,"props":721,"children":723},{"className":722},[],[724],{"type":18,"value":716},{"type":18,"value":654},{"type":13,"tag":364,"props":727,"children":728},{},[],{"type":13,"tag":21,"props":730,"children":732},{"className":731},[],[733],{"type":18,"value":652},{"type":18,"value":654},{"type":13,"tag":364,"props":736,"children":737},{},[],{"type":13,"tag":21,"props":739,"children":741},{"className":740},[],[742],{"type":18,"value":663},{"type":13,"tag":329,"props":744,"children":745},{},[746,751,752,755,760,761,764],{"type":13,"tag":21,"props":747,"children":749},{"className":748},[],[750],{"type":18,"value":716},{"type":18,"value":654},{"type":13,"tag":364,"props":753,"children":754},{},[],{"type":13,"tag":21,"props":756,"children":758},{"className":757},[],[759],{"type":18,"value":652},{"type":18,"value":654},{"type":13,"tag":364,"props":762,"children":763},{},[],{"type":13,"tag":21,"props":765,"children":767},{"className":766},[],[768],{"type":18,"value":681},{"type":13,"tag":329,"props":770,"children":771},{},[772,777,778,781,786,787,790,795,796,799],{"type":13,"tag":21,"props":773,"children":775},{"className":774},[],[776],{"type":18,"value":716},{"type":18,"value":654},{"type":13,"tag":364,"props":779,"children":780},{},[],{"type":13,"tag":21,"props":782,"children":784},{"className":783},[],[785],{"type":18,"value":652},{"type":18,"value":654},{"type":13,"tag":364,"props":788,"children":789},{},[],{"type":13,"tag":21,"props":791,"children":793},{"className":792},[],[794],{"type":18,"value":681},{"type":18,"value":654},{"type":13,"tag":364,"props":797,"children":798},{},[],{"type":13,"tag":21,"props":800,"children":802},{"className":801},[],[803],{"type":18,"value":663},{"type":13,"tag":329,"props":805,"children":806},{},[807,812,813,816],{"type":13,"tag":21,"props":808,"children":810},{"className":809},[],[811],{"type":18,"value":716},{"type":18,"value":654},{"type":13,"tag":364,"props":814,"children":815},{},[],{"type":13,"tag":21,"props":817,"children":819},{"className":818},[],[820],{"type":18,"value":821},"VK_MEMORY_PROPERTY_LAZILY_ALLOCATED_BIT",{"type":13,"tag":329,"props":823,"children":824},{},[825,830,831,834,839,840,843],{"type":13,"tag":21,"props":826,"children":828},{"className":827},[],[829],{"type":18,"value":652},{"type":18,"value":654},{"type":13,"tag":364,"props":832,"children":833},{},[],{"type":13,"tag":21,"props":835,"children":837},{"className":836},[],[838],{"type":18,"value":663},{"type":18,"value":654},{"type":13,"tag":364,"props":841,"children":842},{},[],{"type":13,"tag":21,"props":844,"children":846},{"className":845},[],[847],{"type":18,"value":848},"VK_MEMORY_PROPERTY_DEVICE_COHERENT_BIT_AMD",{"type":13,"tag":329,"props":850,"children":851},{},[852,857,858,861,866,867,870,875,876,879],{"type":13,"tag":21,"props":853,"children":855},{"className":854},[],[856],{"type":18,"value":652},{"type":18,"value":654},{"type":13,"tag":364,"props":859,"children":860},{},[],{"type":13,"tag":21,"props":862,"children":864},{"className":863},[],[865],{"type":18,"value":681},{"type":18,"value":654},{"type":13,"tag":364,"props":868,"children":869},{},[],{"type":13,"tag":21,"props":871,"children":873},{"className":872},[],[874],{"type":18,"value":663},{"type":18,"value":654},{"type":13,"tag":364,"props":877,"children":878},{},[],{"type":13,"tag":21,"props":880,"children":882},{"className":881},[],[883],{"type":18,"value":848},{"type":13,"tag":329,"props":885,"children":886},{},[887,892,893,896],{"type":13,"tag":21,"props":888,"children":890},{"className":889},[],[891],{"type":18,"value":716},{"type":18,"value":654},{"type":13,"tag":364,"props":894,"children":895},{},[],{"type":13,"tag":21,"props":897,"children":899},{"className":898},[],[900],{"type":18,"value":848},{"type":13,"tag":329,"props":902,"children":903},{},[904,909,910,913,918,919,922,927,928,931],{"type":13,"tag":21,"props":905,"children":907},{"className":906},[],[908],{"type":18,"value":716},{"type":18,"value":654},{"type":13,"tag":364,"props":911,"children":912},{},[],{"type":13,"tag":21,"props":914,"children":916},{"className":915},[],[917],{"type":18,"value":652},{"type":18,"value":654},{"type":13,"tag":364,"props":920,"children":921},{},[],{"type":13,"tag":21,"props":923,"children":925},{"className":924},[],[926],{"type":18,"value":663},{"type":18,"value":654},{"type":13,"tag":364,"props":929,"children":930},{},[],{"type":13,"tag":21,"props":932,"children":934},{"className":933},[],[935],{"type":18,"value":848},{"type":13,"tag":329,"props":937,"children":938},{},[939,944,945,948,953,954,957,962,963,966,971,972,975],{"type":13,"tag":21,"props":940,"children":942},{"className":941},[],[943],{"type":18,"value":716},{"type":18,"value":654},{"type":13,"tag":364,"props":946,"children":947},{},[],{"type":13,"tag":21,"props":949,"children":951},{"className":950},[],[952],{"type":18,"value":652},{"type":18,"value":654},{"type":13,"tag":364,"props":955,"children":956},{},[],{"type":13,"tag":21,"props":958,"children":960},{"className":959},[],[961],{"type":18,"value":681},{"type":18,"value":654},{"type":13,"tag":364,"props":964,"children":965},{},[],{"type":13,"tag":21,"props":967,"children":969},{"className":968},[],[970],{"type":18,"value":663},{"type":18,"value":654},{"type":13,"tag":364,"props":973,"children":974},{},[],{"type":13,"tag":21,"props":976,"children":978},{"className":977},[],[979],{"type":18,"value":848},{"type":13,"tag":329,"props":981,"children":982},{},[983,988,989,992,997,998,1001,1006,1007,1010],{"type":13,"tag":21,"props":984,"children":986},{"className":985},[],[987],{"type":18,"value":652},{"type":18,"value":654},{"type":13,"tag":364,"props":990,"children":991},{},[],{"type":13,"tag":21,"props":993,"children":995},{"className":994},[],[996],{"type":18,"value":663},{"type":18,"value":654},{"type":13,"tag":364,"props":999,"children":1000},{},[],{"type":13,"tag":21,"props":1002,"children":1004},{"className":1003},[],[1005],{"type":18,"value":848},{"type":18,"value":654},{"type":13,"tag":364,"props":1008,"children":1009},{},[],{"type":13,"tag":21,"props":1011,"children":1013},{"className":1012},[],[1014],{"type":18,"value":1015},"VK_MEMORY_PROPERTY_DEVICE_UNCACHED_BIT_AMD",{"type":13,"tag":329,"props":1017,"children":1018},{},[1019,1024,1025,1028,1033,1034,1037,1042,1043,1046,1051,1052,1055],{"type":13,"tag":21,"props":1020,"children":1022},{"className":1021},[],[1023],{"type":18,"value":652},{"type":18,"value":654},{"type":13,"tag":364,"props":1026,"children":1027},{},[],{"type":13,"tag":21,"props":1029,"children":1031},{"className":1030},[],[1032],{"type":18,"value":681},{"type":18,"value":654},{"type":13,"tag":364,"props":1035,"children":1036},{},[],{"type":13,"tag":21,"props":1038,"children":1040},{"className":1039},[],[1041],{"type":18,"value":663},{"type":18,"value":654},{"type":13,"tag":364,"props":1044,"children":1045},{},[],{"type":13,"tag":21,"props":1047,"children":1049},{"className":1048},[],[1050],{"type":18,"value":848},{"type":18,"value":654},{"type":13,"tag":364,"props":1053,"children":1054},{},[],{"type":13,"tag":21,"props":1056,"children":1058},{"className":1057},[],[1059],{"type":18,"value":1015},{"type":13,"tag":329,"props":1061,"children":1062},{},[1063,1068,1069,1072,1077,1078,1081],{"type":13,"tag":21,"props":1064,"children":1066},{"className":1065},[],[1067],{"type":18,"value":716},{"type":18,"value":654},{"type":13,"tag":364,"props":1070,"children":1071},{},[],{"type":13,"tag":21,"props":1073,"children":1075},{"className":1074},[],[1076],{"type":18,"value":848},{"type":18,"value":654},{"type":13,"tag":364,"props":1079,"children":1080},{},[],{"type":13,"tag":21,"props":1082,"children":1084},{"className":1083},[],[1085],{"type":18,"value":1015},{"type":13,"tag":329,"props":1087,"children":1088},{},[1089,1094,1095,1098,1103,1104,1107,1112,1113,1116,1121,1122,1125],{"type":13,"tag":21,"props":1090,"children":1092},{"className":1091},[],[1093],{"type":18,"value":716},{"type":18,"value":654},{"type":13,"tag":364,"props":1096,"children":1097},{},[],{"type":13,"tag":21,"props":1099,"children":1101},{"className":1100},[],[1102],{"type":18,"value":652},{"type":18,"value":654},{"type":13,"tag":364,"props":1105,"children":1106},{},[],{"type":13,"tag":21,"props":1108,"children":1110},{"className":1109},[],[1111],{"type":18,"value":663},{"type":18,"value":654},{"type":13,"tag":364,"props":1114,"children":1115},{},[],{"type":13,"tag":21,"props":1117,"children":1119},{"className":1118},[],[1120],{"type":18,"value":848},{"type":18,"value":654},{"type":13,"tag":364,"props":1123,"children":1124},{},[],{"type":13,"tag":21,"props":1126,"children":1128},{"className":1127},[],[1129],{"type":18,"value":1015},{"type":13,"tag":329,"props":1131,"children":1132},{},[1133,1138,1139,1142,1147,1148,1151,1156,1157,1160,1165,1166,1169,1174,1175,1178],{"type":13,"tag":21,"props":1134,"children":1136},{"className":1135},[],[1137],{"type":18,"value":716},{"type":18,"value":654},{"type":13,"tag":364,"props":1140,"children":1141},{},[],{"type":13,"tag":21,"props":1143,"children":1145},{"className":1144},[],[1146],{"type":18,"value":652},{"type":18,"value":654},{"type":13,"tag":364,"props":1149,"children":1150},{},[],{"type":13,"tag":21,"props":1152,"children":1154},{"className":1153},[],[1155],{"type":18,"value":681},{"type":18,"value":654},{"type":13,"tag":364,"props":1158,"children":1159},{},[],{"type":13,"tag":21,"props":1161,"children":1163},{"className":1162},[],[1164],{"type":18,"value":663},{"type":18,"value":654},{"type":13,"tag":364,"props":1167,"children":1168},{},[],{"type":13,"tag":21,"props":1170,"children":1172},{"className":1171},[],[1173],{"type":18,"value":848},{"type":18,"value":654},{"type":13,"tag":364,"props":1176,"children":1177},{},[],{"type":13,"tag":21,"props":1179,"children":1181},{"className":1180},[],[1182],{"type":18,"value":1015},{"type":13,"tag":329,"props":1184,"children":1185},{},[1186,1191,1192,1195],{"type":13,"tag":21,"props":1187,"children":1189},{"className":1188},[],[1190],{"type":18,"value":716},{"type":18,"value":654},{"type":13,"tag":364,"props":1193,"children":1194},{},[],{"type":13,"tag":21,"props":1196,"children":1198},{"className":1197},[],[1199],{"type":18,"value":1200},"VK_MEMORY_PROPERTY_RDMA_CAPABLE_BIT_NV",{"type":13,"tag":14,"props":1202,"children":1203},{},[1204,1206,1209,1211,1216,1218,1223,1225,1230,1232,1235,1237,1242,1244,1249,1251,1261,1263,1266,1267,1272,1273,1278],{"type":18,"value":1205},"There ",{"type":13,"tag":385,"props":1207,"children":1208},{"type":555},[],{"type":18,"value":1210}," be at least one memory type with both the\n",{"type":13,"tag":21,"props":1212,"children":1214},{"className":1213},[],[1215],{"type":18,"value":652},{"type":18,"value":1217}," and\n",{"type":13,"tag":21,"props":1219,"children":1221},{"className":1220},[],[1222],{"type":18,"value":663},{"type":18,"value":1224}," bits set in its\n",{"type":13,"tag":21,"props":1226,"children":1228},{"className":1227},[],[1229],{"type":18,"value":633},{"type":18,"value":1231},".\nThere ",{"type":13,"tag":385,"props":1233,"children":1234},{"type":555},[],{"type":18,"value":1236}," be at least one memory type with the\n",{"type":13,"tag":21,"props":1238,"children":1240},{"className":1239},[],[1241],{"type":18,"value":716},{"type":18,"value":1243}," bit set in its\n",{"type":13,"tag":21,"props":1245,"children":1247},{"className":1246},[],[1248],{"type":18,"value":633},{"type":18,"value":1250},".\nIf the ",{"type":13,"tag":368,"props":1252,"children":1254},{"href":1253},"/man/VkPhysicalDeviceCoherentMemoryFeaturesAMD#features-deviceCoherentMemory",[1255],{"type":13,"tag":21,"props":1256,"children":1258},{"className":1257},[],[1259],{"type":18,"value":1260},"deviceCoherentMemory",{"type":18,"value":1262}," feature\nis enabled, there ",{"type":13,"tag":385,"props":1264,"children":1265},{"type":555},[],{"type":18,"value":1236},{"type":13,"tag":21,"props":1268,"children":1270},{"className":1269},[],[1271],{"type":18,"value":848},{"type":18,"value":1243},{"type":13,"tag":21,"props":1274,"children":1276},{"className":1275},[],[1277],{"type":18,"value":633},{"type":18,"value":397},{"type":13,"tag":14,"props":1280,"children":1281},{},[1282,1284,1289,1291,1296,1298,1303,1305,1309,1312,1314,1318],{"type":18,"value":1283},"For each pair of elements ",{"type":13,"tag":377,"props":1285,"children":1286},{},[1287],{"type":18,"value":1288},"X",{"type":18,"value":1290}," and ",{"type":13,"tag":377,"props":1292,"children":1293},{},[1294],{"type":18,"value":1295},"Y",{"type":18,"value":1297}," returned in ",{"type":13,"tag":21,"props":1299,"children":1301},{"className":1300},[],[1302],{"type":18,"value":95},{"type":18,"value":1304},", ",{"type":13,"tag":377,"props":1306,"children":1307},{},[1308],{"type":18,"value":1288},{"type":13,"tag":385,"props":1310,"children":1311},{"type":555},[],{"type":18,"value":1313}," be placed at a lower index position than ",{"type":13,"tag":377,"props":1315,"children":1316},{},[1317],{"type":18,"value":1295},{"type":18,"value":1319}," if:",{"type":13,"tag":325,"props":1321,"children":1322},{},[1323,1353,1382],{"type":13,"tag":329,"props":1324,"children":1325},{},[1326,1328,1333,1335,1339,1341,1346,1347,1351],{"type":18,"value":1327},"the set of bit flags returned in the ",{"type":13,"tag":21,"props":1329,"children":1331},{"className":1330},[],[1332],{"type":18,"value":633},{"type":18,"value":1334}," member of ",{"type":13,"tag":377,"props":1336,"children":1337},{},[1338],{"type":18,"value":1288},{"type":18,"value":1340},"\nis a strict subset of the set of bit flags returned in the\n",{"type":13,"tag":21,"props":1342,"children":1344},{"className":1343},[],[1345],{"type":18,"value":633},{"type":18,"value":1334},{"type":13,"tag":377,"props":1348,"children":1349},{},[1350],{"type":18,"value":1295},{"type":18,"value":1352},"; or",{"type":13,"tag":329,"props":1354,"children":1355},{},[1356,1358,1363,1365,1369,1370,1374,1376,1380],{"type":18,"value":1357},"the ",{"type":13,"tag":21,"props":1359,"children":1361},{"className":1360},[],[1362],{"type":18,"value":633},{"type":18,"value":1364}," members of ",{"type":13,"tag":377,"props":1366,"children":1367},{},[1368],{"type":18,"value":1288},{"type":18,"value":1290},{"type":13,"tag":377,"props":1371,"children":1372},{},[1373],{"type":18,"value":1295},{"type":18,"value":1375}," are equal, and ",{"type":13,"tag":377,"props":1377,"children":1378},{},[1379],{"type":18,"value":1288},{"type":18,"value":1381},"\nbelongs to a memory heap with greater performance (as determined in an\nimplementation-specific manner)\n; or",{"type":13,"tag":329,"props":1383,"children":1384},{},[1385,1386,1391,1392,1396,1398,1403,1405,1410,1411,1415],{"type":18,"value":1357},{"type":13,"tag":21,"props":1387,"children":1389},{"className":1388},[],[1390],{"type":18,"value":633},{"type":18,"value":1364},{"type":13,"tag":377,"props":1393,"children":1394},{},[1395],{"type":18,"value":1295},{"type":18,"value":1397}," includes\n",{"type":13,"tag":21,"props":1399,"children":1401},{"className":1400},[],[1402],{"type":18,"value":848},{"type":18,"value":1404}," or\n",{"type":13,"tag":21,"props":1406,"children":1408},{"className":1407},[],[1409],{"type":18,"value":1015},{"type":18,"value":1290},{"type":13,"tag":377,"props":1412,"children":1413},{},[1414],{"type":18,"value":1288},{"type":18,"value":1416}," does not",{"type":13,"tag":1418,"props":1419,"children":1420},"note",{},[1421,1473],{"type":13,"tag":14,"props":1422,"children":1423},{},[1424,1426,1430,1431,1435,1437,1442,1444,1450,1452,1457,1459,1464,1466,1471],{"type":18,"value":1425},"There is no ordering requirement between ",{"type":13,"tag":377,"props":1427,"children":1428},{},[1429],{"type":18,"value":1288},{"type":18,"value":1290},{"type":13,"tag":377,"props":1432,"children":1433},{},[1434],{"type":18,"value":1295},{"type":18,"value":1436}," elements for the case\ntheir ",{"type":13,"tag":21,"props":1438,"children":1440},{"className":1439},[],[1441],{"type":18,"value":633},{"type":18,"value":1443}," members are not in a subset relation.\nThat potentially allows more than one possible way to order the same set of\nmemory types.\nNotice that the ",{"type":13,"tag":368,"props":1445,"children":1447},{"href":1446},"/man/VkPhysicalDeviceMemoryProperties#memory-device-bitmask-list",[1448],{"type":18,"value":1449},"list of all allowed memory\nproperty flag combinations",{"type":18,"value":1451}," is written in a valid order.\nBut if instead ",{"type":13,"tag":21,"props":1453,"children":1455},{"className":1454},[],[1456],{"type":18,"value":716},{"type":18,"value":1458}," was before\n",{"type":13,"tag":21,"props":1460,"children":1462},{"className":1461},[],[1463],{"type":18,"value":652},{"type":18,"value":1465}," |\n",{"type":13,"tag":21,"props":1467,"children":1469},{"className":1468},[],[1470],{"type":18,"value":663},{"type":18,"value":1472},", the list would still be in a\nvalid order.",{"type":13,"tag":14,"props":1474,"children":1475},{},[1476],{"type":18,"value":1477},"There may be a performance penalty for using device coherent or uncached\ndevice memory types, and using these accidentally is undesirable.\nIn order to avoid this, memory types with these properties always appear at\nthe end of the list; but are subject to the same rules otherwise.",{"type":13,"tag":14,"props":1479,"children":1480},{},[1481],{"type":18,"value":1482},"This ordering requirement enables applications to use a simple search loop\nto select the desired memory type along the lines of:",{"type":13,"tag":33,"props":1484,"children":1488},{"className":1485,"code":1486,"language":1487,"meta":39,"style":39},"language-c++ shiki shiki-themes github-light-default github-dark-default","// Find a memory in `memoryTypeBitsRequirement` that includes all of `requiredProperties`\nint32_t findProperties(const VkPhysicalDeviceMemoryProperties* pMemoryProperties,\n uint32_t memoryTypeBitsRequirement,\n VkMemoryPropertyFlags requiredProperties) {\n const uint32_t memoryCount = pMemoryProperties->memoryTypeCount;\n for (uint32_t memoryIndex = 0; memoryIndex \u003C memoryCount; ++memoryIndex) {\n const uint32_t memoryTypeBits = (1 \u003C\u003C memoryIndex);\n const bool isRequiredMemoryType = memoryTypeBitsRequirement & memoryTypeBits;\n\n const VkMemoryPropertyFlags properties =\n pMemoryProperties->memoryTypes[memoryIndex].propertyFlags;\n const bool hasRequiredProperties =\n (properties & requiredProperties) == requiredProperties;\n\n if (isRequiredMemoryType && hasRequiredProperties)\n return static_cast\u003Cint32_t>(memoryIndex);\n }\n\n // failed to find memory type\n return -1;\n}\n\n// Try to find an optimal memory type, or if it does not exist try fallback memory type\n// `device` is the VkDevice\n// `image` is the VkImage that requires memory to be bound\n// `memoryProperties` properties as returned by vkGetPhysicalDeviceMemoryProperties\n// `requiredProperties` are the property flags that must be present\n// `optimalProperties` are the property flags that are preferred by the application\nVkMemoryRequirements memoryRequirements;\nvkGetImageMemoryRequirements(device, image, &memoryRequirements);\nint32_t memoryType =\n findProperties(&memoryProperties, memoryRequirements.memoryTypeBits, optimalProperties);\nif (memoryType == -1) // not found; try fallback properties\n memoryType =\n findProperties(&memoryProperties, memoryRequirements.memoryTypeBits, requiredProperties);\n","c++",[1489],{"type":13,"tag":21,"props":1490,"children":1491},{"__ignoreMap":39},[1492,1501,1544,1561,1579,1607,1664,1705,1742,1752,1770,1779,1800,1828,1836,1860,1879,1888,1896,1905,1928,1936,1944,1953,1962,1971,1980,1989,1998,2007,2030,2047,2069,2105,2118],{"type":13,"tag":45,"props":1493,"children":1494},{"class":47,"line":48},[1495],{"type":13,"tag":45,"props":1496,"children":1498},{"style":1497},"--shiki-default:#6E7781;--shiki-dark:#8B949E",[1499],{"type":18,"value":1500},"// Find a memory in `memoryTypeBitsRequirement` that includes all of `requiredProperties`\n",{"type":13,"tag":45,"props":1502,"children":1503},{"class":47,"line":69},[1504,1509,1515,1520,1525,1530,1535,1540],{"type":13,"tag":45,"props":1505,"children":1506},{"style":52},[1507],{"type":18,"value":1508},"int32_t",{"type":13,"tag":45,"props":1510,"children":1512},{"style":1511},"--shiki-default:#8250DF;--shiki-dark:#D2A8FF",[1513],{"type":18,"value":1514}," findProperties",{"type":13,"tag":45,"props":1516,"children":1517},{"style":63},[1518],{"type":18,"value":1519},"(",{"type":13,"tag":45,"props":1521,"children":1522},{"style":52},[1523],{"type":18,"value":1524},"const",{"type":13,"tag":45,"props":1526,"children":1527},{"style":92},[1528],{"type":18,"value":1529}," VkPhysicalDeviceMemoryProperties",{"type":13,"tag":45,"props":1531,"children":1532},{"style":52},[1533],{"type":18,"value":1534},"*",{"type":13,"tag":45,"props":1536,"children":1537},{"style":92},[1538],{"type":18,"value":1539}," pMemoryProperties",{"type":13,"tag":45,"props":1541,"children":1542},{"style":63},[1543],{"type":18,"value":196},{"type":13,"tag":45,"props":1545,"children":1546},{"class":47,"line":83},[1547,1552,1557],{"type":13,"tag":45,"props":1548,"children":1549},{"style":52},[1550],{"type":18,"value":1551}," uint32_t",{"type":13,"tag":45,"props":1553,"children":1554},{"style":92},[1555],{"type":18,"value":1556}," memoryTypeBitsRequirement",{"type":13,"tag":45,"props":1558,"children":1559},{"style":63},[1560],{"type":18,"value":196},{"type":13,"tag":45,"props":1562,"children":1563},{"class":47,"line":103},[1564,1569,1574],{"type":13,"tag":45,"props":1565,"children":1566},{"style":92},[1567],{"type":18,"value":1568}," VkMemoryPropertyFlags",{"type":13,"tag":45,"props":1570,"children":1571},{"style":92},[1572],{"type":18,"value":1573}," requiredProperties",{"type":13,"tag":45,"props":1575,"children":1576},{"style":63},[1577],{"type":18,"value":1578},") {\n",{"type":13,"tag":45,"props":1580,"children":1581},{"class":47,"line":116},[1582,1587,1592,1597,1602],{"type":13,"tag":45,"props":1583,"children":1584},{"style":52},[1585],{"type":18,"value":1586}," const",{"type":13,"tag":45,"props":1588,"children":1589},{"style":52},[1590],{"type":18,"value":1591}," uint32_t",{"type":13,"tag":45,"props":1593,"children":1594},{"style":63},[1595],{"type":18,"value":1596}," memoryCount ",{"type":13,"tag":45,"props":1598,"children":1599},{"style":52},[1600],{"type":18,"value":1601},"=",{"type":13,"tag":45,"props":1603,"children":1604},{"style":63},[1605],{"type":18,"value":1606}," pMemoryProperties->memoryTypeCount;\n",{"type":13,"tag":45,"props":1608,"children":1609},{"class":47,"line":135},[1610,1615,1620,1625,1630,1634,1639,1644,1649,1654,1659],{"type":13,"tag":45,"props":1611,"children":1612},{"style":52},[1613],{"type":18,"value":1614}," for",{"type":13,"tag":45,"props":1616,"children":1617},{"style":63},[1618],{"type":18,"value":1619}," (",{"type":13,"tag":45,"props":1621,"children":1622},{"style":52},[1623],{"type":18,"value":1624},"uint32_t",{"type":13,"tag":45,"props":1626,"children":1627},{"style":63},[1628],{"type":18,"value":1629}," memoryIndex ",{"type":13,"tag":45,"props":1631,"children":1632},{"style":52},[1633],{"type":18,"value":1601},{"type":13,"tag":45,"props":1635,"children":1636},{"style":241},[1637],{"type":18,"value":1638}," 0",{"type":13,"tag":45,"props":1640,"children":1641},{"style":63},[1642],{"type":18,"value":1643},"; memoryIndex ",{"type":13,"tag":45,"props":1645,"children":1646},{"style":52},[1647],{"type":18,"value":1648},"\u003C",{"type":13,"tag":45,"props":1650,"children":1651},{"style":63},[1652],{"type":18,"value":1653}," memoryCount; ",{"type":13,"tag":45,"props":1655,"children":1656},{"style":52},[1657],{"type":18,"value":1658},"++",{"type":13,"tag":45,"props":1660,"children":1661},{"style":63},[1662],{"type":18,"value":1663},"memoryIndex) {\n",{"type":13,"tag":45,"props":1665,"children":1667},{"class":47,"line":1666},7,[1668,1673,1677,1682,1686,1690,1695,1700],{"type":13,"tag":45,"props":1669,"children":1670},{"style":52},[1671],{"type":18,"value":1672}," const",{"type":13,"tag":45,"props":1674,"children":1675},{"style":52},[1676],{"type":18,"value":1591},{"type":13,"tag":45,"props":1678,"children":1679},{"style":63},[1680],{"type":18,"value":1681}," memoryTypeBits ",{"type":13,"tag":45,"props":1683,"children":1684},{"style":52},[1685],{"type":18,"value":1601},{"type":13,"tag":45,"props":1687,"children":1688},{"style":63},[1689],{"type":18,"value":1619},{"type":13,"tag":45,"props":1691,"children":1692},{"style":241},[1693],{"type":18,"value":1694},"1",{"type":13,"tag":45,"props":1696,"children":1697},{"style":52},[1698],{"type":18,"value":1699}," \u003C\u003C",{"type":13,"tag":45,"props":1701,"children":1702},{"style":63},[1703],{"type":18,"value":1704}," memoryIndex);\n",{"type":13,"tag":45,"props":1706,"children":1708},{"class":47,"line":1707},8,[1709,1713,1718,1723,1727,1732,1737],{"type":13,"tag":45,"props":1710,"children":1711},{"style":52},[1712],{"type":18,"value":1672},{"type":13,"tag":45,"props":1714,"children":1715},{"style":52},[1716],{"type":18,"value":1717}," bool",{"type":13,"tag":45,"props":1719,"children":1720},{"style":63},[1721],{"type":18,"value":1722}," isRequiredMemoryType ",{"type":13,"tag":45,"props":1724,"children":1725},{"style":52},[1726],{"type":18,"value":1601},{"type":13,"tag":45,"props":1728,"children":1729},{"style":63},[1730],{"type":18,"value":1731}," memoryTypeBitsRequirement ",{"type":13,"tag":45,"props":1733,"children":1734},{"style":52},[1735],{"type":18,"value":1736},"&",{"type":13,"tag":45,"props":1738,"children":1739},{"style":63},[1740],{"type":18,"value":1741}," memoryTypeBits;\n",{"type":13,"tag":45,"props":1743,"children":1745},{"class":47,"line":1744},9,[1746],{"type":13,"tag":45,"props":1747,"children":1749},{"emptyLinePlaceholder":1748},true,[1750],{"type":18,"value":1751},"\n",{"type":13,"tag":45,"props":1753,"children":1755},{"class":47,"line":1754},10,[1756,1760,1765],{"type":13,"tag":45,"props":1757,"children":1758},{"style":52},[1759],{"type":18,"value":1672},{"type":13,"tag":45,"props":1761,"children":1762},{"style":63},[1763],{"type":18,"value":1764}," VkMemoryPropertyFlags properties ",{"type":13,"tag":45,"props":1766,"children":1767},{"style":52},[1768],{"type":18,"value":1769},"=\n",{"type":13,"tag":45,"props":1771,"children":1773},{"class":47,"line":1772},11,[1774],{"type":13,"tag":45,"props":1775,"children":1776},{"style":63},[1777],{"type":18,"value":1778}," pMemoryProperties->memoryTypes[memoryIndex].propertyFlags;\n",{"type":13,"tag":45,"props":1780,"children":1782},{"class":47,"line":1781},12,[1783,1787,1791,1796],{"type":13,"tag":45,"props":1784,"children":1785},{"style":52},[1786],{"type":18,"value":1672},{"type":13,"tag":45,"props":1788,"children":1789},{"style":52},[1790],{"type":18,"value":1717},{"type":13,"tag":45,"props":1792,"children":1793},{"style":63},[1794],{"type":18,"value":1795}," hasRequiredProperties ",{"type":13,"tag":45,"props":1797,"children":1798},{"style":52},[1799],{"type":18,"value":1769},{"type":13,"tag":45,"props":1801,"children":1803},{"class":47,"line":1802},13,[1804,1809,1813,1818,1823],{"type":13,"tag":45,"props":1805,"children":1806},{"style":63},[1807],{"type":18,"value":1808}," (properties ",{"type":13,"tag":45,"props":1810,"children":1811},{"style":52},[1812],{"type":18,"value":1736},{"type":13,"tag":45,"props":1814,"children":1815},{"style":63},[1816],{"type":18,"value":1817}," requiredProperties) ",{"type":13,"tag":45,"props":1819,"children":1820},{"style":52},[1821],{"type":18,"value":1822},"==",{"type":13,"tag":45,"props":1824,"children":1825},{"style":63},[1826],{"type":18,"value":1827}," requiredProperties;\n",{"type":13,"tag":45,"props":1829,"children":1831},{"class":47,"line":1830},14,[1832],{"type":13,"tag":45,"props":1833,"children":1834},{"emptyLinePlaceholder":1748},[1835],{"type":18,"value":1751},{"type":13,"tag":45,"props":1837,"children":1839},{"class":47,"line":1838},15,[1840,1845,1850,1855],{"type":13,"tag":45,"props":1841,"children":1842},{"style":52},[1843],{"type":18,"value":1844}," if",{"type":13,"tag":45,"props":1846,"children":1847},{"style":63},[1848],{"type":18,"value":1849}," (isRequiredMemoryType ",{"type":13,"tag":45,"props":1851,"children":1852},{"style":52},[1853],{"type":18,"value":1854},"&&",{"type":13,"tag":45,"props":1856,"children":1857},{"style":63},[1858],{"type":18,"value":1859}," hasRequiredProperties)\n",{"type":13,"tag":45,"props":1861,"children":1863},{"class":47,"line":1862},16,[1864,1869,1874],{"type":13,"tag":45,"props":1865,"children":1866},{"style":52},[1867],{"type":18,"value":1868}," return",{"type":13,"tag":45,"props":1870,"children":1871},{"style":52},[1872],{"type":18,"value":1873}," static_cast\u003Cint32_t>",{"type":13,"tag":45,"props":1875,"children":1876},{"style":63},[1877],{"type":18,"value":1878},"(memoryIndex);\n",{"type":13,"tag":45,"props":1880,"children":1882},{"class":47,"line":1881},17,[1883],{"type":13,"tag":45,"props":1884,"children":1885},{"style":63},[1886],{"type":18,"value":1887}," }\n",{"type":13,"tag":45,"props":1889,"children":1891},{"class":47,"line":1890},18,[1892],{"type":13,"tag":45,"props":1893,"children":1894},{"emptyLinePlaceholder":1748},[1895],{"type":18,"value":1751},{"type":13,"tag":45,"props":1897,"children":1899},{"class":47,"line":1898},19,[1900],{"type":13,"tag":45,"props":1901,"children":1902},{"style":1497},[1903],{"type":18,"value":1904}," // failed to find memory type\n",{"type":13,"tag":45,"props":1906,"children":1908},{"class":47,"line":1907},20,[1909,1914,1919,1923],{"type":13,"tag":45,"props":1910,"children":1911},{"style":52},[1912],{"type":18,"value":1913}," return",{"type":13,"tag":45,"props":1915,"children":1916},{"style":52},[1917],{"type":18,"value":1918}," -",{"type":13,"tag":45,"props":1920,"children":1921},{"style":241},[1922],{"type":18,"value":1694},{"type":13,"tag":45,"props":1924,"children":1925},{"style":63},[1926],{"type":18,"value":1927},";\n",{"type":13,"tag":45,"props":1929,"children":1931},{"class":47,"line":1930},21,[1932],{"type":13,"tag":45,"props":1933,"children":1934},{"style":63},[1935],{"type":18,"value":323},{"type":13,"tag":45,"props":1937,"children":1939},{"class":47,"line":1938},22,[1940],{"type":13,"tag":45,"props":1941,"children":1942},{"emptyLinePlaceholder":1748},[1943],{"type":18,"value":1751},{"type":13,"tag":45,"props":1945,"children":1947},{"class":47,"line":1946},23,[1948],{"type":13,"tag":45,"props":1949,"children":1950},{"style":1497},[1951],{"type":18,"value":1952},"// Try to find an optimal memory type, or if it does not exist try fallback memory type\n",{"type":13,"tag":45,"props":1954,"children":1956},{"class":47,"line":1955},24,[1957],{"type":13,"tag":45,"props":1958,"children":1959},{"style":1497},[1960],{"type":18,"value":1961},"// `device` is the VkDevice\n",{"type":13,"tag":45,"props":1963,"children":1965},{"class":47,"line":1964},25,[1966],{"type":13,"tag":45,"props":1967,"children":1968},{"style":1497},[1969],{"type":18,"value":1970},"// `image` is the VkImage that requires memory to be bound\n",{"type":13,"tag":45,"props":1972,"children":1974},{"class":47,"line":1973},26,[1975],{"type":13,"tag":45,"props":1976,"children":1977},{"style":1497},[1978],{"type":18,"value":1979},"// `memoryProperties` properties as returned by vkGetPhysicalDeviceMemoryProperties\n",{"type":13,"tag":45,"props":1981,"children":1983},{"class":47,"line":1982},27,[1984],{"type":13,"tag":45,"props":1985,"children":1986},{"style":1497},[1987],{"type":18,"value":1988},"// `requiredProperties` are the property flags that must be present\n",{"type":13,"tag":45,"props":1990,"children":1992},{"class":47,"line":1991},28,[1993],{"type":13,"tag":45,"props":1994,"children":1995},{"style":1497},[1996],{"type":18,"value":1997},"// `optimalProperties` are the property flags that are preferred by the application\n",{"type":13,"tag":45,"props":1999,"children":2001},{"class":47,"line":2000},29,[2002],{"type":13,"tag":45,"props":2003,"children":2004},{"style":63},[2005],{"type":18,"value":2006},"VkMemoryRequirements memoryRequirements;\n",{"type":13,"tag":45,"props":2008,"children":2010},{"class":47,"line":2009},30,[2011,2016,2021,2025],{"type":13,"tag":45,"props":2012,"children":2013},{"style":1511},[2014],{"type":18,"value":2015},"vkGetImageMemoryRequirements",{"type":13,"tag":45,"props":2017,"children":2018},{"style":63},[2019],{"type":18,"value":2020},"(device, image, ",{"type":13,"tag":45,"props":2022,"children":2023},{"style":52},[2024],{"type":18,"value":1736},{"type":13,"tag":45,"props":2026,"children":2027},{"style":63},[2028],{"type":18,"value":2029},"memoryRequirements);\n",{"type":13,"tag":45,"props":2031,"children":2033},{"class":47,"line":2032},31,[2034,2038,2043],{"type":13,"tag":45,"props":2035,"children":2036},{"style":52},[2037],{"type":18,"value":1508},{"type":13,"tag":45,"props":2039,"children":2040},{"style":63},[2041],{"type":18,"value":2042}," memoryType ",{"type":13,"tag":45,"props":2044,"children":2045},{"style":52},[2046],{"type":18,"value":1769},{"type":13,"tag":45,"props":2048,"children":2050},{"class":47,"line":2049},32,[2051,2056,2060,2064],{"type":13,"tag":45,"props":2052,"children":2053},{"style":1511},[2054],{"type":18,"value":2055}," findProperties",{"type":13,"tag":45,"props":2057,"children":2058},{"style":63},[2059],{"type":18,"value":1519},{"type":13,"tag":45,"props":2061,"children":2062},{"style":52},[2063],{"type":18,"value":1736},{"type":13,"tag":45,"props":2065,"children":2066},{"style":63},[2067],{"type":18,"value":2068},"memoryProperties, memoryRequirements.memoryTypeBits, optimalProperties);\n",{"type":13,"tag":45,"props":2070,"children":2072},{"class":47,"line":2071},33,[2073,2078,2083,2087,2091,2095,2100],{"type":13,"tag":45,"props":2074,"children":2075},{"style":52},[2076],{"type":18,"value":2077},"if",{"type":13,"tag":45,"props":2079,"children":2080},{"style":63},[2081],{"type":18,"value":2082}," (memoryType ",{"type":13,"tag":45,"props":2084,"children":2085},{"style":52},[2086],{"type":18,"value":1822},{"type":13,"tag":45,"props":2088,"children":2089},{"style":52},[2090],{"type":18,"value":1918},{"type":13,"tag":45,"props":2092,"children":2093},{"style":241},[2094],{"type":18,"value":1694},{"type":13,"tag":45,"props":2096,"children":2097},{"style":63},[2098],{"type":18,"value":2099},")",{"type":13,"tag":45,"props":2101,"children":2102},{"style":1497},[2103],{"type":18,"value":2104}," // not found; try fallback properties\n",{"type":13,"tag":45,"props":2106,"children":2108},{"class":47,"line":2107},34,[2109,2114],{"type":13,"tag":45,"props":2110,"children":2111},{"style":63},[2112],{"type":18,"value":2113}," memoryType ",{"type":13,"tag":45,"props":2115,"children":2116},{"style":52},[2117],{"type":18,"value":1769},{"type":13,"tag":45,"props":2119,"children":2121},{"class":47,"line":2120},35,[2122,2127,2131,2135],{"type":13,"tag":45,"props":2123,"children":2124},{"style":1511},[2125],{"type":18,"value":2126}," findProperties",{"type":13,"tag":45,"props":2128,"children":2129},{"style":63},[2130],{"type":18,"value":1519},{"type":13,"tag":45,"props":2132,"children":2133},{"style":52},[2134],{"type":18,"value":1736},{"type":13,"tag":45,"props":2136,"children":2137},{"style":63},[2138],{"type":18,"value":2139},"memoryProperties, memoryRequirements.memoryTypeBits, requiredProperties);\n",{"type":13,"tag":2141,"props":2142,"children":2143},"style",{},[2144],{"type":18,"value":2145},"html .default .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}html.dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}",{"title":39,"searchDepth":69,"depth":69,"links":2147},[],"markdown",1725732570917]