| <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "https://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> |
| <html xmlns="http://www.w3.org/1999/xhtml"> |
| <head> |
| <meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/> |
| <meta http-equiv="X-UA-Compatible" content="IE=11"/> |
| <meta name="generator" content="Doxygen 1.9.3"/> |
| <meta name="viewport" content="width=device-width, initial-scale=1"/> |
| <title>Direct3D 12 Memory Allocator: D3D12MA::ALLOCATION_DESC Struct Reference</title> |
| <link href="tabs.css" rel="stylesheet" type="text/css"/> |
| <script type="text/javascript" src="jquery.js"></script> |
| <script type="text/javascript" src="dynsections.js"></script> |
| <link href="search/search.css" rel="stylesheet" type="text/css"/> |
| <script type="text/javascript" src="search/searchdata.js"></script> |
| <script type="text/javascript" src="search/search.js"></script> |
| <link href="doxygen.css" rel="stylesheet" type="text/css" /> |
| </head> |
| <body> |
| <div id="top"><!-- do not remove this div, it is closed by doxygen! --> |
| <div id="titlearea"> |
| <table cellspacing="0" cellpadding="0"> |
| <tbody> |
| <tr id="projectrow"> |
| <td id="projectalign"> |
| <div id="projectname">Direct3D 12 Memory Allocator |
| </div> |
| </td> |
| </tr> |
| </tbody> |
| </table> |
| </div> |
| <!-- end header part --> |
| <!-- Generated by Doxygen 1.9.3 --> |
| <script type="text/javascript"> |
| /* @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699&dn=expat.txt MIT */ |
| var searchBox = new SearchBox("searchBox", "search",'Search','.html'); |
| /* @license-end */ |
| </script> |
| <script type="text/javascript" src="menudata.js"></script> |
| <script type="text/javascript" src="menu.js"></script> |
| <script type="text/javascript"> |
| /* @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699&dn=expat.txt MIT */ |
| $(function() { |
| initMenu('',true,false,'search.php','Search'); |
| $(document).ready(function() { init_search(); }); |
| }); |
| /* @license-end */ |
| </script> |
| <div id="main-nav"></div> |
| <!-- window showing the filter options --> |
| <div id="MSearchSelectWindow" |
| onmouseover="return searchBox.OnSearchSelectShow()" |
| onmouseout="return searchBox.OnSearchSelectHide()" |
| onkeydown="return searchBox.OnSearchSelectKey(event)"> |
| </div> |
| |
| <!-- iframe showing the search results (closed by default) --> |
| <div id="MSearchResultsWindow"> |
| <iframe src="javascript:void(0)" frameborder="0" |
| name="MSearchResults" id="MSearchResults"> |
| </iframe> |
| </div> |
| |
| <div id="nav-path" class="navpath"> |
| <ul> |
| <li class="navelem"><a class="el" href="namespace_d3_d12_m_a.html">D3D12MA</a></li><li class="navelem"><a class="el" href="struct_d3_d12_m_a_1_1_a_l_l_o_c_a_t_i_o_n___d_e_s_c.html">ALLOCATION_DESC</a></li> </ul> |
| </div> |
| </div><!-- top --> |
| <div class="header"> |
| <div class="summary"> |
| <a href="#pub-attribs">Public Attributes</a> | |
| <a href="struct_d3_d12_m_a_1_1_a_l_l_o_c_a_t_i_o_n___d_e_s_c-members.html">List of all members</a> </div> |
| <div class="headertitle"><div class="title">D3D12MA::ALLOCATION_DESC Struct Reference</div></div> |
| </div><!--header--> |
| <div class="contents"> |
| |
| <p>Parameters of created <a class="el" href="class_d3_d12_m_a_1_1_allocation.html" title="Represents single memory allocation.">D3D12MA::Allocation</a> object. To be used with <a class="el" href="class_d3_d12_m_a_1_1_allocator.html#aa37d6b9fe8ea0864f7a35b9d68e8345a" title="Allocates memory and creates a D3D12 resource (buffer or texture). This is the main allocation functi...">Allocator::CreateResource</a>. |
| <a href="struct_d3_d12_m_a_1_1_a_l_l_o_c_a_t_i_o_n___d_e_s_c.html#details">More...</a></p> |
| |
| <p><code>#include <D3D12MemAlloc.h></code></p> |
| <table class="memberdecls"> |
| <tr class="heading"><td colspan="2"><h2 class="groupheader"><a id="pub-attribs" name="pub-attribs"></a> |
| Public Attributes</h2></td></tr> |
| <tr class="memitem:a92dec49b788a334fc91c55340dfbace6"><td class="memItemLeft" align="right" valign="top"><a class="el" href="namespace_d3_d12_m_a.html#abbad31a7e0b3d09d77f3fb704b77645e">ALLOCATION_FLAGS</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="struct_d3_d12_m_a_1_1_a_l_l_o_c_a_t_i_o_n___d_e_s_c.html#a92dec49b788a334fc91c55340dfbace6">Flags</a></td></tr> |
| <tr class="memdesc:a92dec49b788a334fc91c55340dfbace6"><td class="mdescLeft"> </td><td class="mdescRight">Flags. <a href="struct_d3_d12_m_a_1_1_a_l_l_o_c_a_t_i_o_n___d_e_s_c.html#a92dec49b788a334fc91c55340dfbace6">More...</a><br /></td></tr> |
| <tr class="separator:a92dec49b788a334fc91c55340dfbace6"><td class="memSeparator" colspan="2"> </td></tr> |
| <tr class="memitem:aa46b3c0456e5a23edef3328607ebf4d7"><td class="memItemLeft" align="right" valign="top">D3D12_HEAP_TYPE </td><td class="memItemRight" valign="bottom"><a class="el" href="struct_d3_d12_m_a_1_1_a_l_l_o_c_a_t_i_o_n___d_e_s_c.html#aa46b3c0456e5a23edef3328607ebf4d7">HeapType</a></td></tr> |
| <tr class="memdesc:aa46b3c0456e5a23edef3328607ebf4d7"><td class="mdescLeft"> </td><td class="mdescRight">The type of memory heap where the new allocation should be placed. <a href="struct_d3_d12_m_a_1_1_a_l_l_o_c_a_t_i_o_n___d_e_s_c.html#aa46b3c0456e5a23edef3328607ebf4d7">More...</a><br /></td></tr> |
| <tr class="separator:aa46b3c0456e5a23edef3328607ebf4d7"><td class="memSeparator" colspan="2"> </td></tr> |
| <tr class="memitem:a97878838f976b2d1e6b1a76881035690"><td class="memItemLeft" align="right" valign="top">D3D12_HEAP_FLAGS </td><td class="memItemRight" valign="bottom"><a class="el" href="struct_d3_d12_m_a_1_1_a_l_l_o_c_a_t_i_o_n___d_e_s_c.html#a97878838f976b2d1e6b1a76881035690">ExtraHeapFlags</a></td></tr> |
| <tr class="memdesc:a97878838f976b2d1e6b1a76881035690"><td class="mdescLeft"> </td><td class="mdescRight">Additional heap flags to be used when allocating memory. <a href="struct_d3_d12_m_a_1_1_a_l_l_o_c_a_t_i_o_n___d_e_s_c.html#a97878838f976b2d1e6b1a76881035690">More...</a><br /></td></tr> |
| <tr class="separator:a97878838f976b2d1e6b1a76881035690"><td class="memSeparator" colspan="2"> </td></tr> |
| <tr class="memitem:ab06b85f3cf3254f855b29264477e3934"><td class="memItemLeft" align="right" valign="top"><a class="el" href="class_d3_d12_m_a_1_1_pool.html">Pool</a> * </td><td class="memItemRight" valign="bottom"><a class="el" href="struct_d3_d12_m_a_1_1_a_l_l_o_c_a_t_i_o_n___d_e_s_c.html#ab06b85f3cf3254f855b29264477e3934">CustomPool</a></td></tr> |
| <tr class="memdesc:ab06b85f3cf3254f855b29264477e3934"><td class="mdescLeft"> </td><td class="mdescRight">Custom pool to place the new resource in. Optional. <a href="struct_d3_d12_m_a_1_1_a_l_l_o_c_a_t_i_o_n___d_e_s_c.html#ab06b85f3cf3254f855b29264477e3934">More...</a><br /></td></tr> |
| <tr class="separator:ab06b85f3cf3254f855b29264477e3934"><td class="memSeparator" colspan="2"> </td></tr> |
| <tr class="memitem:ac638dd987f1326e2fdab91892d994d35"><td class="memItemLeft" align="right" valign="top">void * </td><td class="memItemRight" valign="bottom"><a class="el" href="struct_d3_d12_m_a_1_1_a_l_l_o_c_a_t_i_o_n___d_e_s_c.html#ac638dd987f1326e2fdab91892d994d35">pPrivateData</a></td></tr> |
| <tr class="memdesc:ac638dd987f1326e2fdab91892d994d35"><td class="mdescLeft"> </td><td class="mdescRight">Custom general-purpose pointer that will be stored in <a class="el" href="class_d3_d12_m_a_1_1_allocation.html" title="Represents single memory allocation.">D3D12MA::Allocation</a>. <a href="struct_d3_d12_m_a_1_1_a_l_l_o_c_a_t_i_o_n___d_e_s_c.html#ac638dd987f1326e2fdab91892d994d35">More...</a><br /></td></tr> |
| <tr class="separator:ac638dd987f1326e2fdab91892d994d35"><td class="memSeparator" colspan="2"> </td></tr> |
| </table> |
| <a name="details" id="details"></a><h2 class="groupheader">Detailed Description</h2> |
| <div class="textblock"><p >Parameters of created <a class="el" href="class_d3_d12_m_a_1_1_allocation.html" title="Represents single memory allocation.">D3D12MA::Allocation</a> object. To be used with <a class="el" href="class_d3_d12_m_a_1_1_allocator.html#aa37d6b9fe8ea0864f7a35b9d68e8345a" title="Allocates memory and creates a D3D12 resource (buffer or texture). This is the main allocation functi...">Allocator::CreateResource</a>. </p> |
| </div><h2 class="groupheader">Member Data Documentation</h2> |
| <a id="ab06b85f3cf3254f855b29264477e3934" name="ab06b85f3cf3254f855b29264477e3934"></a> |
| <h2 class="memtitle"><span class="permalink"><a href="#ab06b85f3cf3254f855b29264477e3934">◆ </a></span>CustomPool</h2> |
| |
| <div class="memitem"> |
| <div class="memproto"> |
| <table class="memname"> |
| <tr> |
| <td class="memname"><a class="el" href="class_d3_d12_m_a_1_1_pool.html">Pool</a>* D3D12MA::ALLOCATION_DESC::CustomPool</td> |
| </tr> |
| </table> |
| </div><div class="memdoc"> |
| |
| <p>Custom pool to place the new resource in. Optional. </p> |
| <p >When not NULL, the resource will be created inside specified custom pool. It will then never be created as committed. </p> |
| |
| </div> |
| </div> |
| <a id="a97878838f976b2d1e6b1a76881035690" name="a97878838f976b2d1e6b1a76881035690"></a> |
| <h2 class="memtitle"><span class="permalink"><a href="#a97878838f976b2d1e6b1a76881035690">◆ </a></span>ExtraHeapFlags</h2> |
| |
| <div class="memitem"> |
| <div class="memproto"> |
| <table class="memname"> |
| <tr> |
| <td class="memname">D3D12_HEAP_FLAGS D3D12MA::ALLOCATION_DESC::ExtraHeapFlags</td> |
| </tr> |
| </table> |
| </div><div class="memdoc"> |
| |
| <p>Additional heap flags to be used when allocating memory. </p> |
| <p >In most cases it can be 0.</p> |
| <ul> |
| <li>If you use <a class="el" href="class_d3_d12_m_a_1_1_allocator.html#aa37d6b9fe8ea0864f7a35b9d68e8345a" title="Allocates memory and creates a D3D12 resource (buffer or texture). This is the main allocation functi...">D3D12MA::Allocator::CreateResource()</a>, you don't need to care. Necessary flag <code>D3D12_HEAP_FLAG_ALLOW_ONLY_BUFFERS</code>, <code>D3D12_HEAP_FLAG_ALLOW_ONLY_NON_RT_DS_TEXTURES</code>, or <code>D3D12_HEAP_FLAG_ALLOW_ONLY_RT_DS_TEXTURES</code> is added automatically.</li> |
| <li>If you use <a class="el" href="class_d3_d12_m_a_1_1_allocator.html#acb8a10a5ea30171ce60128286aec5ee2" title="Allocates memory without creating any resource placed in it.">D3D12MA::Allocator::AllocateMemory()</a>, you should specify one of those <code>ALLOW_ONLY</code> flags. Except when you validate that <a class="el" href="class_d3_d12_m_a_1_1_allocator.html#ae276d2358a58a36f8c6639f837f29be5" title="Returns cached options retrieved from D3D12 device.">D3D12MA::Allocator::GetD3D12Options()</a><code>.ResourceHeapTier == D3D12_RESOURCE_HEAP_TIER_1</code> - then you can leave it 0.</li> |
| <li>You can specify additional flags if needed. Then the memory will always be allocated as separate block using <code>D3D12Device::CreateCommittedResource</code> or <code>CreateHeap</code>, not as part of an existing larget block.</li> |
| </ul> |
| <p >When <a class="el" href="struct_d3_d12_m_a_1_1_a_l_l_o_c_a_t_i_o_n___d_e_s_c.html#ab06b85f3cf3254f855b29264477e3934" title="Custom pool to place the new resource in. Optional.">D3D12MA::ALLOCATION_DESC::CustomPool</a> != NULL this member is ignored. </p> |
| |
| </div> |
| </div> |
| <a id="a92dec49b788a334fc91c55340dfbace6" name="a92dec49b788a334fc91c55340dfbace6"></a> |
| <h2 class="memtitle"><span class="permalink"><a href="#a92dec49b788a334fc91c55340dfbace6">◆ </a></span>Flags</h2> |
| |
| <div class="memitem"> |
| <div class="memproto"> |
| <table class="memname"> |
| <tr> |
| <td class="memname"><a class="el" href="namespace_d3_d12_m_a.html#abbad31a7e0b3d09d77f3fb704b77645e">ALLOCATION_FLAGS</a> D3D12MA::ALLOCATION_DESC::Flags</td> |
| </tr> |
| </table> |
| </div><div class="memdoc"> |
| |
| <p>Flags. </p> |
| |
| </div> |
| </div> |
| <a id="aa46b3c0456e5a23edef3328607ebf4d7" name="aa46b3c0456e5a23edef3328607ebf4d7"></a> |
| <h2 class="memtitle"><span class="permalink"><a href="#aa46b3c0456e5a23edef3328607ebf4d7">◆ </a></span>HeapType</h2> |
| |
| <div class="memitem"> |
| <div class="memproto"> |
| <table class="memname"> |
| <tr> |
| <td class="memname">D3D12_HEAP_TYPE D3D12MA::ALLOCATION_DESC::HeapType</td> |
| </tr> |
| </table> |
| </div><div class="memdoc"> |
| |
| <p>The type of memory heap where the new allocation should be placed. </p> |
| <p >It must be one of: <code>D3D12_HEAP_TYPE_DEFAULT</code>, <code>D3D12_HEAP_TYPE_UPLOAD</code>, <code>D3D12_HEAP_TYPE_READBACK</code>.</p> |
| <p >When <a class="el" href="struct_d3_d12_m_a_1_1_a_l_l_o_c_a_t_i_o_n___d_e_s_c.html#ab06b85f3cf3254f855b29264477e3934" title="Custom pool to place the new resource in. Optional.">D3D12MA::ALLOCATION_DESC::CustomPool</a> != NULL this member is ignored. </p> |
| |
| </div> |
| </div> |
| <a id="ac638dd987f1326e2fdab91892d994d35" name="ac638dd987f1326e2fdab91892d994d35"></a> |
| <h2 class="memtitle"><span class="permalink"><a href="#ac638dd987f1326e2fdab91892d994d35">◆ </a></span>pPrivateData</h2> |
| |
| <div class="memitem"> |
| <div class="memproto"> |
| <table class="memname"> |
| <tr> |
| <td class="memname">void* D3D12MA::ALLOCATION_DESC::pPrivateData</td> |
| </tr> |
| </table> |
| </div><div class="memdoc"> |
| |
| <p>Custom general-purpose pointer that will be stored in <a class="el" href="class_d3_d12_m_a_1_1_allocation.html" title="Represents single memory allocation.">D3D12MA::Allocation</a>. </p> |
| |
| </div> |
| </div> |
| <hr/>The documentation for this struct was generated from the following file:<ul> |
| <li>D:/PROJECTS/D3D12 Memory Allocator/REPO/include/<a class="el" href="_d3_d12_mem_alloc_8h.html">D3D12MemAlloc.h</a></li> |
| </ul> |
| </div><!-- contents --> |
| <!-- start footer part --> |
| <hr class="footer"/><address class="footer"><small> |
| Generated by <a href="https://www.doxygen.org/index.html"><img class="footer" src="doxygen.svg" width="104" height="31" alt="doxygen"/></a> 1.9.3 |
| </small></address> |
| </body> |
| </html> |