OSDN Git Service

modified: utilsrc/src/Admin/Makefile
[eos/others.git] / utiltools / X86MAC64 / cuda / doc / html / cuda-runtime-api / group__CUDART__D3D9__DEPRECATED.html
1 <!DOCTYPE html
2   PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
3 <html xmlns="http://www.w3.org/1999/xhtml" lang="en-us" xml:lang="en-us">
4    <head>
5       <meta http-equiv="Content-Type" content="text/html; charset=utf-8"></meta>
6       <meta http-equiv="X-UA-Compatible" content="IE=edge"></meta>
7       <meta name="copyright" content="(C) Copyright 2005"></meta>
8       <meta name="DC.rights.owner" content="(C) Copyright 2005"></meta>
9       <meta name="DC.Type" content="cppModule"></meta>
10       <meta name="DC.Title" content="Direct3D 9 Interoperability [DEPRECATED]"></meta>
11       <meta name="abstract" content=""></meta>
12       <meta name="description" content=""></meta>
13       <meta name="DC.Format" content="XHTML"></meta>
14       <meta name="DC.Identifier" content="group__CUDART__D3D9__DEPRECATED"></meta>
15       <link rel="stylesheet" type="text/css" href="../common/formatting/commonltr.css"></link>
16       <link rel="stylesheet" type="text/css" href="../common/formatting/site.css"></link>
17       <title>CUDA Runtime API :: CUDA Toolkit Documentation</title>
18       <!--[if lt IE 9]>
19       <script src="../common/formatting/html5shiv-printshiv.min.js"></script>
20       <![endif]-->
21       <script type="text/javascript" charset="utf-8" src="../common/formatting/jquery.min.js"></script>
22       <script type="text/javascript" charset="utf-8" src="../common/formatting/jquery.ba-hashchange.min.js"></script>
23       <link rel="canonical" href="http://docs.nvidia.com/cuda/cuda-runtime-api/index.html"></link>
24       <link rel="stylesheet" type="text/css" href="../common/formatting/qwcode.highlight.css"></link>
25    </head>
26    <body>
27       
28       <article id="contents">
29          <div id="breadcrumbs"><a href="group__CUDART__D3D9.html" shape="rect">&lt; Previous</a> | <a href="group__CUDART__D3D10.html" shape="rect">Next &gt;</a></div>
30          <div id="release-info">CUDA Runtime API
31             (<a href="../../pdf/CUDA_Runtime_API.pdf">PDF</a>)
32             -
33             CUDA Toolkit v5.5
34             (<a href="https://developer.nvidia.com/cuda-toolkit-archive">older</a>)
35             -
36             Last updated 
37             September 5, 2013
38             -
39             <a href="mailto:cudatools@nvidia.com?subject=CUDA Tools Documentation Feedback: cuda-runtime-api">Send Feedback</a></div>
40          <div class="topic reference apiRef apiPackage cppModule" id="group__CUDART__D3D9__DEPRECATED"><a name="group__CUDART__D3D9__DEPRECATED" shape="rect">
41                <!-- --></a><h2 class="topictitle2 cppModule">2.13.&nbsp;Direct3D 9 Interoperability [DEPRECATED]</h2>
42             <div class="section">
43                <p>This section describes deprecated Direct3D 9 interoperability functions. </p>
44             </div>
45             <h3 class="fake_sectiontitle member_header">Enumerations</h3>
46             <dl class="members">
47                <dt><span class="member_type">enum&nbsp;</span><span class="member_name"><a href="#group__CUDART__D3D9__DEPRECATED_1g77fb48ace0d2da465b6f4bcc00ef750b" shape="rect">cudaD3D9MapFlags</a></span></dt>
48                <dd class="shortdesc"><span></span><span class="desc"></span></dd>
49                <dt><span class="member_type">enum&nbsp;</span><span class="member_name"><a href="#group__CUDART__D3D9__DEPRECATED_1gcdebbc14eb83032da31bd75503cddfea" shape="rect">cudaD3D9RegisterFlags</a></span></dt>
50                <dd class="shortdesc"><span></span><span class="desc"></span></dd>
51             </dl>
52             <h3 class="fake_sectiontitle member_header">Functions</h3>
53             <dl class="members">
54                <dt><span class="member_type"><a href="group__CUDART__TYPES.html#group__CUDART__TYPES_1gf599e5b8b829ce7db0f5216928f6ecb6" title="" shape="rect">cudaError_t</a>&nbsp;</span><span class="member_name"><a href="#group__CUDART__D3D9__DEPRECATED_1g59e2838c98639cdc5acdec99856c5aca" shape="rect">cudaD3D9MapResources</a> (  int <span>&nbsp;</span><span class="keyword keyword apiItemName">count</span>, IDirect3DResource9**<span>&nbsp;</span><span class="keyword keyword apiItemName">ppResources</span> ) </span></dt>
55                <dd class="shortdesc"><span></span><span class="desc">Map Direct3D resources for access by CUDA. </span></dd>
56                <dt><span class="member_type"><a href="group__CUDART__TYPES.html#group__CUDART__TYPES_1gf599e5b8b829ce7db0f5216928f6ecb6" title="" shape="rect">cudaError_t</a>&nbsp;</span><span class="member_name"><a href="#group__CUDART__D3D9__DEPRECATED_1ga8dabfab33631bc9d8a41f30bc26221c" shape="rect">cudaD3D9RegisterResource</a> (  IDirect3DResource9*<span>&nbsp;</span><span class="keyword keyword apiItemName">pResource</span>, unsigned int <span>&nbsp;</span><span class="keyword keyword apiItemName">flags</span> ) </span></dt>
57                <dd class="shortdesc"><span></span><span class="desc">Registers a Direct3D resource for access by CUDA. </span></dd>
58                <dt><span class="member_type"><a href="group__CUDART__TYPES.html#group__CUDART__TYPES_1gf599e5b8b829ce7db0f5216928f6ecb6" title="" shape="rect">cudaError_t</a>&nbsp;</span><span class="member_name"><a href="#group__CUDART__D3D9__DEPRECATED_1g60d2dd299c651866dfd0a0480e752783" shape="rect">cudaD3D9ResourceGetMappedArray</a> (  cudaArray**<span>&nbsp;</span><span class="keyword keyword apiItemName">ppArray</span>, IDirect3DResource9*<span>&nbsp;</span><span class="keyword keyword apiItemName">pResource</span>, unsigned int <span>&nbsp;</span><span class="keyword keyword apiItemName">face</span>, unsigned int <span>&nbsp;</span><span class="keyword keyword apiItemName">level</span> ) </span></dt>
59                <dd class="shortdesc"><span></span><span class="desc">Get an array through which to access a subresource of a Direct3D resource which has been mapped for access by CUDA. </span></dd>
60                <dt><span class="member_type"><a href="group__CUDART__TYPES.html#group__CUDART__TYPES_1gf599e5b8b829ce7db0f5216928f6ecb6" title="" shape="rect">cudaError_t</a>&nbsp;</span><span class="member_name"><a href="#group__CUDART__D3D9__DEPRECATED_1g52d32c6779befee1742e88dc3036bd68" shape="rect">cudaD3D9ResourceGetMappedPitch</a> (  size_t*<span>&nbsp;</span><span class="keyword keyword apiItemName">pPitch</span>, size_t*<span>&nbsp;</span><span class="keyword keyword apiItemName">pPitchSlice</span>, IDirect3DResource9*<span>&nbsp;</span><span class="keyword keyword apiItemName">pResource</span>, unsigned int <span>&nbsp;</span><span class="keyword keyword apiItemName">face</span>, unsigned int <span>&nbsp;</span><span class="keyword keyword apiItemName">level</span> ) </span></dt>
61                <dd class="shortdesc"><span></span><span class="desc">Get the pitch of a subresource of a Direct3D resource which has been mapped for access by CUDA. </span></dd>
62                <dt><span class="member_type"><a href="group__CUDART__TYPES.html#group__CUDART__TYPES_1gf599e5b8b829ce7db0f5216928f6ecb6" title="" shape="rect">cudaError_t</a>&nbsp;</span><span class="member_name"><a href="#group__CUDART__D3D9__DEPRECATED_1g44923b51ce411b519c9a3f5a1674071a" shape="rect">cudaD3D9ResourceGetMappedPointer</a> (  void**<span>&nbsp;</span><span class="keyword keyword apiItemName">pPointer</span>, IDirect3DResource9*<span>&nbsp;</span><span class="keyword keyword apiItemName">pResource</span>, unsigned int <span>&nbsp;</span><span class="keyword keyword apiItemName">face</span>, unsigned int <span>&nbsp;</span><span class="keyword keyword apiItemName">level</span> ) </span></dt>
63                <dd class="shortdesc"><span></span><span class="desc">Get a pointer through which to access a subresource of a Direct3D resource which has been mapped for access by CUDA. </span></dd>
64                <dt><span class="member_type"><a href="group__CUDART__TYPES.html#group__CUDART__TYPES_1gf599e5b8b829ce7db0f5216928f6ecb6" title="" shape="rect">cudaError_t</a>&nbsp;</span><span class="member_name"><a href="#group__CUDART__D3D9__DEPRECATED_1gb592b874549ec1375a570fac7f5e9ab9" shape="rect">cudaD3D9ResourceGetMappedSize</a> (  size_t*<span>&nbsp;</span><span class="keyword keyword apiItemName">pSize</span>, IDirect3DResource9*<span>&nbsp;</span><span class="keyword keyword apiItemName">pResource</span>, unsigned int <span>&nbsp;</span><span class="keyword keyword apiItemName">face</span>, unsigned int <span>&nbsp;</span><span class="keyword keyword apiItemName">level</span> ) </span></dt>
65                <dd class="shortdesc"><span></span><span class="desc">Get the size of a subresource of a Direct3D resource which has been mapped for access by CUDA. </span></dd>
66                <dt><span class="member_type"><a href="group__CUDART__TYPES.html#group__CUDART__TYPES_1gf599e5b8b829ce7db0f5216928f6ecb6" title="" shape="rect">cudaError_t</a>&nbsp;</span><span class="member_name"><a href="#group__CUDART__D3D9__DEPRECATED_1gb280fa315e4728a11f13e4691b19ef61" shape="rect">cudaD3D9ResourceGetSurfaceDimensions</a> (  size_t*<span>&nbsp;</span><span class="keyword keyword apiItemName">pWidth</span>, size_t*<span>&nbsp;</span><span class="keyword keyword apiItemName">pHeight</span>, size_t*<span>&nbsp;</span><span class="keyword keyword apiItemName">pDepth</span>, IDirect3DResource9*<span>&nbsp;</span><span class="keyword keyword apiItemName">pResource</span>, unsigned int <span>&nbsp;</span><span class="keyword keyword apiItemName">face</span>, unsigned int <span>&nbsp;</span><span class="keyword keyword apiItemName">level</span> ) </span></dt>
67                <dd class="shortdesc"><span></span><span class="desc">Get the dimensions of a registered Direct3D surface. </span></dd>
68                <dt><span class="member_type"><a href="group__CUDART__TYPES.html#group__CUDART__TYPES_1gf599e5b8b829ce7db0f5216928f6ecb6" title="" shape="rect">cudaError_t</a>&nbsp;</span><span class="member_name"><a href="#group__CUDART__D3D9__DEPRECATED_1gf0c339fe2a9d07ebc02c0469a6f8c296" shape="rect">cudaD3D9ResourceSetMapFlags</a> (  IDirect3DResource9*<span>&nbsp;</span><span class="keyword keyword apiItemName">pResource</span>, unsigned int <span>&nbsp;</span><span class="keyword keyword apiItemName">flags</span> ) </span></dt>
69                <dd class="shortdesc"><span></span><span class="desc">Set usage flags for mapping a Direct3D resource. </span></dd>
70                <dt><span class="member_type"><a href="group__CUDART__TYPES.html#group__CUDART__TYPES_1gf599e5b8b829ce7db0f5216928f6ecb6" title="" shape="rect">cudaError_t</a>&nbsp;</span><span class="member_name"><a href="#group__CUDART__D3D9__DEPRECATED_1g50f637c33fa9ca33777735f769e7d9a6" shape="rect">cudaD3D9UnmapResources</a> (  int <span>&nbsp;</span><span class="keyword keyword apiItemName">count</span>, IDirect3DResource9**<span>&nbsp;</span><span class="keyword keyword apiItemName">ppResources</span> ) </span></dt>
71                <dd class="shortdesc"><span></span><span class="desc">Unmap Direct3D resources for access by CUDA. </span></dd>
72                <dt><span class="member_type"><a href="group__CUDART__TYPES.html#group__CUDART__TYPES_1gf599e5b8b829ce7db0f5216928f6ecb6" title="" shape="rect">cudaError_t</a>&nbsp;</span><span class="member_name"><a href="#group__CUDART__D3D9__DEPRECATED_1gcca28bc00d63314d2032c36c0ca1fd4d" shape="rect">cudaD3D9UnregisterResource</a> (  IDirect3DResource9*<span>&nbsp;</span><span class="keyword keyword apiItemName">pResource</span> ) </span></dt>
73                <dd class="shortdesc"><span></span><span class="desc">Unregisters a Direct3D resource for access by CUDA. </span></dd>
74             </dl>
75             <div class="description">
76                <h3 class="sectiontitle">Enumerations</h3>
77                <dl class="description">
78                   <dt class="description"><a name="group__CUDART__D3D9__DEPRECATED_1g77fb48ace0d2da465b6f4bcc00ef750b" id="group__CUDART__D3D9__DEPRECATED_1g77fb48ace0d2da465b6f4bcc00ef750b" shape="rect">
79                         <!-- --></a><span>enum cudaD3D9MapFlags</span></dt>
80                   <dd class="description">
81                      <div class="section">
82                         <p>CUDA D3D9 Map Flags </p>
83                      </div>
84                      <div class="enum-members">
85                         <h6 class="enumerator_header">
86                            Values
87                            
88                         </h6>
89                         <dl class="enumerator">
90                            <dt><span class="enum-member-name-def">cudaD3D9MapFlagsNone = <span class="ph ph apiData">0</span></span></dt>
91                            <dd>Default; Assume resource can be read/written </dd>
92                            <dt><span class="enum-member-name-def">cudaD3D9MapFlagsReadOnly = <span class="ph ph apiData">1</span></span></dt>
93                            <dd>CUDA kernels will not write to this resource </dd>
94                            <dt><span class="enum-member-name-def">cudaD3D9MapFlagsWriteDiscard = <span class="ph ph apiData">2</span></span></dt>
95                            <dd>CUDA kernels will only write to and will not read from this resource </dd>
96                         </dl>
97                      </div>
98                   </dd>
99                   <dt class="description"><a name="group__CUDART__D3D9__DEPRECATED_1gcdebbc14eb83032da31bd75503cddfea" id="group__CUDART__D3D9__DEPRECATED_1gcdebbc14eb83032da31bd75503cddfea" shape="rect">
100                         <!-- --></a><span>enum cudaD3D9RegisterFlags</span></dt>
101                   <dd class="description">
102                      <div class="section">
103                         <p>CUDA D3D9 Register Flags </p>
104                      </div>
105                      <div class="enum-members">
106                         <h6 class="enumerator_header">
107                            Values
108                            
109                         </h6>
110                         <dl class="enumerator">
111                            <dt><span class="enum-member-name-def">cudaD3D9RegisterFlagsNone = <span class="ph ph apiData">0</span></span></dt>
112                            <dd>Default; Resource can be accessed througa void* </dd>
113                            <dt><span class="enum-member-name-def">cudaD3D9RegisterFlagsArray = <span class="ph ph apiData">1</span></span></dt>
114                            <dd>Resource can be accessed through a CUarray* </dd>
115                         </dl>
116                      </div>
117                   </dd>
118                </dl>
119             </div>
120             <div class="description">
121                <h3 class="sectiontitle">Functions</h3>
122                <dl class="description">
123                   <dt class="description"><a name="group__CUDART__D3D9__DEPRECATED_1g59e2838c98639cdc5acdec99856c5aca" id="group__CUDART__D3D9__DEPRECATED_1g59e2838c98639cdc5acdec99856c5aca" shape="rect">
124                         <!-- --></a><span><a href="group__CUDART__TYPES.html#group__CUDART__TYPES_1gf599e5b8b829ce7db0f5216928f6ecb6" title="" shape="rect">cudaError_t</a> cudaD3D9MapResources (  int <span>&nbsp;</span><span class="keyword keyword apiItemName">count</span>, IDirect3DResource9**<span>&nbsp;</span><span class="keyword keyword apiItemName">ppResources</span> ) </span></dt>
125                   <dd class="description">
126                      <div class="section">Map Direct3D resources for access by CUDA. </div>
127                      <div class="section">
128                         <h6 class="parameter_header">
129                            Parameters
130                            
131                         </h6>
132                         <dl class="table-display-params">
133                            <dt><tt class="code"><span class="keyword keyword apiItemName">count</span></tt></dt>
134                            <dd>- Number of resources to map for CUDA </dd>
135                            <dt><tt class="code"><span class="keyword keyword apiItemName">ppResources</span></tt></dt>
136                            <dd>- Resources to map for CUDA</dd>
137                         </dl>
138                      </div>
139                      <div class="section">
140                         <h6 class="return_header">Returns</h6>
141                         <p class="return"><a class="xref" href="group__CUDART__TYPES.html#group__CUDART__TYPES_1gg3f51e3575c2178246db0a94a430e0038e355f04607d824883b4a50662830d591" shape="rect">cudaSuccess</a>, <a class="xref" href="group__CUDART__TYPES.html#group__CUDART__TYPES_1gg3f51e3575c2178246db0a94a430e0038c4673247aee4d1ab8d07871f376e0273" shape="rect">cudaErrorInvalidResourceHandle</a>, <a class="xref" href="group__CUDART__TYPES.html#group__CUDART__TYPES_1gg3f51e3575c2178246db0a94a430e00382e491daacef266c7b3e3c1e140a6133c" shape="rect">cudaErrorUnknown</a></p>
142                      </div>
143                      <div class="section">
144                         <h6 class="deprecated_header"><a class="xref xrefsect-title" href="deprecated.html#deprecated__deprecated_1_deprecated000009" shape="rect">Deprecated</a></h6>
145                         <p><span class="ph xrefsect-description">This function is deprecated as of CUDA 3.0.</span></p>
146                         <h6 class="description_header">Description</h6>
147                         <p>Maps the <tt class="ph tt code">count</tt> Direct3D resources in <tt class="ph tt code">ppResources</tt> for access by CUDA.
148                         </p>
149                         <p class="p">The resources in <tt class="ph tt code">ppResources</tt> may be accessed in CUDA kernels until they are unmapped. Direct3D should not access any resources while they are mapped by
150                            CUDA. If an application does so, the results are undefined.
151                         </p>
152                         <p class="p">This function provides the synchronization guarantee that any Direct3D calls issued before <a class="xref" href="group__CUDART__D3D9__DEPRECATED.html#group__CUDART__D3D9__DEPRECATED_1g59e2838c98639cdc5acdec99856c5aca" title="Map Direct3D resources for access by CUDA." shape="rect">cudaD3D9MapResources()</a> will complete before any CUDA kernels issued after <a class="xref" href="group__CUDART__D3D9__DEPRECATED.html#group__CUDART__D3D9__DEPRECATED_1g59e2838c98639cdc5acdec99856c5aca" title="Map Direct3D resources for access by CUDA." shape="rect">cudaD3D9MapResources()</a> begin.
153                         </p>
154                         <p class="p">If any of <tt class="ph tt code">ppResources</tt> have not been registered for use with CUDA or if <tt class="ph tt code">ppResources</tt> contains any duplicate entries then <a class="xref" href="group__CUDART__TYPES.html#group__CUDART__TYPES_1gg3f51e3575c2178246db0a94a430e0038c4673247aee4d1ab8d07871f376e0273" shape="rect">cudaErrorInvalidResourceHandle</a> is returned. If any of <tt class="ph tt code">ppResources</tt> are presently mapped for access by CUDA then <a class="xref" href="group__CUDART__TYPES.html#group__CUDART__TYPES_1gg3f51e3575c2178246db0a94a430e00382e491daacef266c7b3e3c1e140a6133c" shape="rect">cudaErrorUnknown</a> is returned.
155                         </p>
156                         <p class="p"></p>
157                         <p class="p"></p>
158                         <p class="p">
159                            <div class="note note"><span class="notetitle">Note:</span><p class="p">Note that this function may also return error codes from previous, asynchronous launches.</p>
160                            </div>
161                         </p>
162                         <p class="p"></p>
163                         <p class="p apiDesc_subtitle"><strong class="ph b">See also:</strong></p>
164                         <p class="p see_subsection"><a class="xref" href="group__CUDART__INTEROP.html#group__CUDART__INTEROP_1gb7064fb72e54d89d0666e192b45d35cc" title="Map graphics resources for access by CUDA." shape="rect">cudaGraphicsMapResources</a></p>
165                         <p class="p"></p>
166                      </div>
167                   </dd>
168                   <dt class="description"><a name="group__CUDART__D3D9__DEPRECATED_1ga8dabfab33631bc9d8a41f30bc26221c" id="group__CUDART__D3D9__DEPRECATED_1ga8dabfab33631bc9d8a41f30bc26221c" shape="rect">
169                         <!-- --></a><span><a href="group__CUDART__TYPES.html#group__CUDART__TYPES_1gf599e5b8b829ce7db0f5216928f6ecb6" title="" shape="rect">cudaError_t</a> cudaD3D9RegisterResource (  IDirect3DResource9*<span>&nbsp;</span><span class="keyword keyword apiItemName">pResource</span>, unsigned int <span>&nbsp;</span><span class="keyword keyword apiItemName">flags</span> ) </span></dt>
170                   <dd class="description">
171                      <div class="section">Registers a Direct3D resource for access by CUDA. </div>
172                      <div class="section">
173                         <h6 class="parameter_header">
174                            Parameters
175                            
176                         </h6>
177                         <dl class="table-display-params">
178                            <dt><tt class="code"><span class="keyword keyword apiItemName">pResource</span></tt></dt>
179                            <dd>- Resource to register </dd>
180                            <dt><tt class="code"><span class="keyword keyword apiItemName">flags</span></tt></dt>
181                            <dd>- Parameters for resource registration</dd>
182                         </dl>
183                      </div>
184                      <div class="section">
185                         <h6 class="return_header">Returns</h6>
186                         <p class="return"><a class="xref" href="group__CUDART__TYPES.html#group__CUDART__TYPES_1gg3f51e3575c2178246db0a94a430e0038e355f04607d824883b4a50662830d591" shape="rect">cudaSuccess</a>, <a class="xref" href="group__CUDART__TYPES.html#group__CUDART__TYPES_1gg3f51e3575c2178246db0a94a430e00383e8aef5398ee38e28ed41e357b48917c" shape="rect">cudaErrorInvalidValue</a>, <a class="xref" href="group__CUDART__TYPES.html#group__CUDART__TYPES_1gg3f51e3575c2178246db0a94a430e0038c4673247aee4d1ab8d07871f376e0273" shape="rect">cudaErrorInvalidResourceHandle</a>, <a class="xref" href="group__CUDART__TYPES.html#group__CUDART__TYPES_1gg3f51e3575c2178246db0a94a430e00382e491daacef266c7b3e3c1e140a6133c" shape="rect">cudaErrorUnknown</a></p>
187                      </div>
188                      <div class="section">
189                         <h6 class="deprecated_header"><a class="xref xrefsect-title" href="deprecated.html#deprecated__deprecated_1_deprecated000007" shape="rect">Deprecated</a></h6>
190                         <p><span class="ph xrefsect-description">This function is deprecated as of CUDA 3.0.</span></p>
191                         <h6 class="description_header">Description</h6>
192                         <p>Registers the Direct3D resource <tt class="ph tt code">pResource</tt> for access by CUDA.
193                         </p>
194                         <p class="p">If this call is successful, then the application will be able to map and unmap this resource until it is unregistered through
195                            <a class="xref" href="group__CUDART__D3D9__DEPRECATED.html#group__CUDART__D3D9__DEPRECATED_1gcca28bc00d63314d2032c36c0ca1fd4d" title="Unregisters a Direct3D resource for access by CUDA." shape="rect">cudaD3D9UnregisterResource()</a>. Also on success, this call will increase the internal reference count on <tt class="ph tt code">pResource</tt>. This reference count will be decremented when this resource is unregistered through <a class="xref" href="group__CUDART__D3D9__DEPRECATED.html#group__CUDART__D3D9__DEPRECATED_1gcca28bc00d63314d2032c36c0ca1fd4d" title="Unregisters a Direct3D resource for access by CUDA." shape="rect">cudaD3D9UnregisterResource()</a>.
196                         </p>
197                         <p class="p">This call potentially has a high-overhead and should not be called every frame in interactive applications.</p>
198                         <p class="p">The type of <tt class="ph tt code">pResource</tt> must be one of the following.
199                         </p>
200                         <p class="p">
201                            <ul class="ul">
202                               <li class="li">
203                                  <p class="p">IDirect3DVertexBuffer9: No notes.</p>
204                               </li>
205                               <li class="li">
206                                  <p class="p">IDirect3DIndexBuffer9: No notes.</p>
207                               </li>
208                               <li class="li">
209                                  <p class="p">IDirect3DSurface9: Only stand-alone objects of type IDirect3DSurface9 may be explicitly shared. In particular, individual
210                                     mipmap levels and faces of cube maps may not be registered directly. To access individual surfaces associated with a texture,
211                                     one must register the base texture object.
212                                  </p>
213                               </li>
214                               <li class="li">
215                                  <p class="p">IDirect3DBaseTexture9: When a texture is registered, all surfaces associated with all mipmap levels of all faces of the texture
216                                     will be accessible to CUDA.
217                                  </p>
218                               </li>
219                            </ul>
220                         </p>
221                         <p class="p">The <tt class="ph tt code">flags</tt> argument specifies the mechanism through which CUDA will access the Direct3D resource. The following value is allowed:
222                         </p>
223                         <p class="p">
224                            <ul class="ul">
225                               <li class="li">
226                                  <p class="p"><a class="xref" href="group__CUDART__D3D9__DEPRECATED.html#group__CUDART__D3D9__DEPRECATED_1ggcdebbc14eb83032da31bd75503cddfea10cd58f205c593368626b4ec54a54744" shape="rect">cudaD3D9RegisterFlagsNone</a>: Specifies that CUDA will access this resource through a <tt class="ph tt code">void*</tt>. The pointer, size, and pitch for each subresource of this resource may be queried through <a class="xref" href="group__CUDART__D3D9__DEPRECATED.html#group__CUDART__D3D9__DEPRECATED_1g44923b51ce411b519c9a3f5a1674071a" title="Get a pointer through which to access a subresource of a Direct3D resource which has been mapped for access by CUDA." shape="rect">cudaD3D9ResourceGetMappedPointer()</a>, <a class="xref" href="group__CUDART__D3D9__DEPRECATED.html#group__CUDART__D3D9__DEPRECATED_1gb592b874549ec1375a570fac7f5e9ab9" title="Get the size of a subresource of a Direct3D resource which has been mapped for access by CUDA." shape="rect">cudaD3D9ResourceGetMappedSize()</a>, and <a class="xref" href="group__CUDART__D3D9__DEPRECATED.html#group__CUDART__D3D9__DEPRECATED_1g52d32c6779befee1742e88dc3036bd68" title="Get the pitch of a subresource of a Direct3D resource which has been mapped for access by CUDA." shape="rect">cudaD3D9ResourceGetMappedPitch()</a> respectively. This option is valid for all resource types.
227                                  </p>
228                               </li>
229                            </ul>
230                         </p>
231                         <p class="p">Not all Direct3D resources of the above types may be used for interoperability with CUDA. The following are some limitations:</p>
232                         <p class="p">
233                            <ul class="ul">
234                               <li class="li">
235                                  <p class="p">The primary rendertarget may not be registered with CUDA.</p>
236                               </li>
237                               <li class="li">
238                                  <p class="p">Resources allocated as shared may not be registered with CUDA.</p>
239                               </li>
240                               <li class="li">
241                                  <p class="p">Any resources allocated in D3DPOOL_SYSTEMMEM or D3DPOOL_MANAGED may not be registered with CUDA.</p>
242                               </li>
243                               <li class="li">
244                                  <p class="p">Textures which are not of a format which is 1, 2, or 4 channels of 8, 16, or 32-bit integer or floating-point data cannot
245                                     be shared.
246                                  </p>
247                               </li>
248                               <li class="li">
249                                  <p class="p">Surfaces of depth or stencil formats cannot be shared.</p>
250                               </li>
251                            </ul>
252                         </p>
253                         <p class="p">If Direct3D interoperability is not initialized on this context, then <a class="xref" href="group__CUDART__TYPES.html#group__CUDART__TYPES_1gg3f51e3575c2178246db0a94a430e0038938c6e8b96ecde62e3ab5137156f739a" shape="rect">cudaErrorInvalidDevice</a> is returned. If <tt class="ph tt code">pResource</tt> is of incorrect type (e.g, is a non-stand-alone IDirect3DSurface9) or is already registered, then <a class="xref" href="group__CUDART__TYPES.html#group__CUDART__TYPES_1gg3f51e3575c2178246db0a94a430e0038c4673247aee4d1ab8d07871f376e0273" shape="rect">cudaErrorInvalidResourceHandle</a> is returned. If <tt class="ph tt code">pResource</tt> cannot be registered then <a class="xref" href="group__CUDART__TYPES.html#group__CUDART__TYPES_1gg3f51e3575c2178246db0a94a430e00382e491daacef266c7b3e3c1e140a6133c" shape="rect">cudaErrorUnknown</a> is returned.
254                         </p>
255                         <p class="p"></p>
256                         <p class="p"></p>
257                         <p class="p">
258                            <div class="note note"><span class="notetitle">Note:</span><p class="p">Note that this function may also return error codes from previous, asynchronous launches.</p>
259                            </div>
260                         </p>
261                         <p class="p"></p>
262                         <p class="p apiDesc_subtitle"><strong class="ph b">See also:</strong></p>
263                         <p class="p see_subsection"><a class="xref" href="group__CUDART__D3D9.html#group__CUDART__D3D9_1gbe1082b566be4ab414bf69047449ad93" title="Register a Direct3D 9 resource for access by CUDA." shape="rect">cudaGraphicsD3D9RegisterResource</a></p>
264                         <p class="p"></p>
265                      </div>
266                   </dd>
267                   <dt class="description"><a name="group__CUDART__D3D9__DEPRECATED_1g60d2dd299c651866dfd0a0480e752783" id="group__CUDART__D3D9__DEPRECATED_1g60d2dd299c651866dfd0a0480e752783" shape="rect">
268                         <!-- --></a><span><a href="group__CUDART__TYPES.html#group__CUDART__TYPES_1gf599e5b8b829ce7db0f5216928f6ecb6" title="" shape="rect">cudaError_t</a> cudaD3D9ResourceGetMappedArray (  cudaArray**<span>&nbsp;</span><span class="keyword keyword apiItemName">ppArray</span>, IDirect3DResource9*<span>&nbsp;</span><span class="keyword keyword apiItemName">pResource</span>, unsigned int <span>&nbsp;</span><span class="keyword keyword apiItemName">face</span>, unsigned int <span>&nbsp;</span><span class="keyword keyword apiItemName">level</span> ) </span></dt>
269                   <dd class="description">
270                      <div class="section">Get an array through which to access a subresource of a Direct3D resource which has been mapped for access by CUDA. </div>
271                      <div class="section">
272                         <h6 class="parameter_header">
273                            Parameters
274                            
275                         </h6>
276                         <dl class="table-display-params">
277                            <dt><tt class="code"><span class="keyword keyword apiItemName">ppArray</span></tt></dt>
278                            <dd>- Returned array corresponding to subresource </dd>
279                            <dt><tt class="code"><span class="keyword keyword apiItemName">pResource</span></tt></dt>
280                            <dd>- Mapped resource to access </dd>
281                            <dt><tt class="code"><span class="keyword keyword apiItemName">face</span></tt></dt>
282                            <dd>- Face of resource to access </dd>
283                            <dt><tt class="code"><span class="keyword keyword apiItemName">level</span></tt></dt>
284                            <dd>- Level of resource to access</dd>
285                         </dl>
286                      </div>
287                      <div class="section">
288                         <h6 class="return_header">Returns</h6>
289                         <p class="return"><a class="xref" href="group__CUDART__TYPES.html#group__CUDART__TYPES_1gg3f51e3575c2178246db0a94a430e0038e355f04607d824883b4a50662830d591" shape="rect">cudaSuccess</a>, <a class="xref" href="group__CUDART__TYPES.html#group__CUDART__TYPES_1gg3f51e3575c2178246db0a94a430e0038c4673247aee4d1ab8d07871f376e0273" shape="rect">cudaErrorInvalidResourceHandle</a>, <a class="xref" href="group__CUDART__TYPES.html#group__CUDART__TYPES_1gg3f51e3575c2178246db0a94a430e00382e491daacef266c7b3e3c1e140a6133c" shape="rect">cudaErrorUnknown</a></p>
290                      </div>
291                      <div class="section">
292                         <h6 class="deprecated_header"><a class="xref xrefsect-title" href="deprecated.html#deprecated__deprecated_1_deprecated000013" shape="rect">Deprecated</a></h6>
293                         <p><span class="ph xrefsect-description">This function is deprecated as of CUDA 3.0.</span></p>
294                         <h6 class="description_header">Description</h6>
295                         <p>Returns in <tt class="ph tt code">*pArray</tt> an array through which the subresource of the mapped Direct3D resource <tt class="ph tt code">pResource</tt>, which corresponds to <tt class="ph tt code">face</tt> and <tt class="ph tt code">level</tt> may be accessed. The value set in <tt class="ph tt code">pArray</tt> may change every time that <tt class="ph tt code">pResource</tt> is mapped.
296                         </p>
297                         <p class="p">If <tt class="ph tt code">pResource</tt> is not registered then <a class="xref" href="group__CUDART__TYPES.html#group__CUDART__TYPES_1gg3f51e3575c2178246db0a94a430e0038c4673247aee4d1ab8d07871f376e0273" shape="rect">cudaErrorInvalidResourceHandle</a> is returned. If <tt class="ph tt code">pResource</tt> was not registered with usage flags <a class="xref" href="group__CUDART__D3D9__DEPRECATED.html#group__CUDART__D3D9__DEPRECATED_1ggcdebbc14eb83032da31bd75503cddfeaa4c940a582866d5cf40ede9dbfa1f5e5" shape="rect">cudaD3D9RegisterFlagsArray</a>, then <a class="xref" href="group__CUDART__TYPES.html#group__CUDART__TYPES_1gg3f51e3575c2178246db0a94a430e0038c4673247aee4d1ab8d07871f376e0273" shape="rect">cudaErrorInvalidResourceHandle</a> is returned. If <tt class="ph tt code">pResource</tt> is not mapped, then <a class="xref" href="group__CUDART__TYPES.html#group__CUDART__TYPES_1gg3f51e3575c2178246db0a94a430e00382e491daacef266c7b3e3c1e140a6133c" shape="rect">cudaErrorUnknown</a> is returned.
298                         </p>
299                         <p class="p">For usage requirements of <tt class="ph tt code">face</tt> and <tt class="ph tt code">level</tt> parameters, see <a class="xref" href="group__CUDART__D3D9__DEPRECATED.html#group__CUDART__D3D9__DEPRECATED_1g44923b51ce411b519c9a3f5a1674071a" title="Get a pointer through which to access a subresource of a Direct3D resource which has been mapped for access by CUDA." shape="rect">cudaD3D9ResourceGetMappedPointer()</a>.
300                         </p>
301                         <p class="p"></p>
302                         <p class="p"></p>
303                         <p class="p">
304                            <div class="note note"><span class="notetitle">Note:</span><p class="p">Note that this function may also return error codes from previous, asynchronous launches.</p>
305                            </div>
306                         </p>
307                         <p class="p"></p>
308                         <p class="p apiDesc_subtitle"><strong class="ph b">See also:</strong></p>
309                         <p class="p see_subsection"><a class="xref" href="group__CUDART__INTEROP.html#group__CUDART__INTEROP_1gfc796cc80e7a054b13d90afde659546e" title="Get an array through which to access a subresource of a mapped graphics resource." shape="rect">cudaGraphicsSubResourceGetMappedArray</a></p>
310                         <p class="p"></p>
311                      </div>
312                   </dd>
313                   <dt class="description"><a name="group__CUDART__D3D9__DEPRECATED_1g52d32c6779befee1742e88dc3036bd68" id="group__CUDART__D3D9__DEPRECATED_1g52d32c6779befee1742e88dc3036bd68" shape="rect">
314                         <!-- --></a><span><a href="group__CUDART__TYPES.html#group__CUDART__TYPES_1gf599e5b8b829ce7db0f5216928f6ecb6" title="" shape="rect">cudaError_t</a> cudaD3D9ResourceGetMappedPitch (  size_t*<span>&nbsp;</span><span class="keyword keyword apiItemName">pPitch</span>, size_t*<span>&nbsp;</span><span class="keyword keyword apiItemName">pPitchSlice</span>, IDirect3DResource9*<span>&nbsp;</span><span class="keyword keyword apiItemName">pResource</span>, unsigned int <span>&nbsp;</span><span class="keyword keyword apiItemName">face</span>, unsigned int <span>&nbsp;</span><span class="keyword keyword apiItemName">level</span> ) </span></dt>
315                   <dd class="description">
316                      <div class="section">Get the pitch of a subresource of a Direct3D resource which has been mapped for access by CUDA. </div>
317                      <div class="section">
318                         <h6 class="parameter_header">
319                            Parameters
320                            
321                         </h6>
322                         <dl class="table-display-params">
323                            <dt><tt class="code"><span class="keyword keyword apiItemName">pPitch</span></tt></dt>
324                            <dd>- Returned pitch of subresource </dd>
325                            <dt><tt class="code"><span class="keyword keyword apiItemName">pPitchSlice</span></tt></dt>
326                            <dd>- Returned Z-slice pitch of subresource </dd>
327                            <dt><tt class="code"><span class="keyword keyword apiItemName">pResource</span></tt></dt>
328                            <dd>- Mapped resource to access </dd>
329                            <dt><tt class="code"><span class="keyword keyword apiItemName">face</span></tt></dt>
330                            <dd>- Face of resource to access </dd>
331                            <dt><tt class="code"><span class="keyword keyword apiItemName">level</span></tt></dt>
332                            <dd>- Level of resource to access</dd>
333                         </dl>
334                      </div>
335                      <div class="section">
336                         <h6 class="return_header">Returns</h6>
337                         <p class="return"><a class="xref" href="group__CUDART__TYPES.html#group__CUDART__TYPES_1gg3f51e3575c2178246db0a94a430e0038e355f04607d824883b4a50662830d591" shape="rect">cudaSuccess</a>, <a class="xref" href="group__CUDART__TYPES.html#group__CUDART__TYPES_1gg3f51e3575c2178246db0a94a430e00383e8aef5398ee38e28ed41e357b48917c" shape="rect">cudaErrorInvalidValue</a>, <a class="xref" href="group__CUDART__TYPES.html#group__CUDART__TYPES_1gg3f51e3575c2178246db0a94a430e0038c4673247aee4d1ab8d07871f376e0273" shape="rect">cudaErrorInvalidResourceHandle</a>, <a class="xref" href="group__CUDART__TYPES.html#group__CUDART__TYPES_1gg3f51e3575c2178246db0a94a430e00382e491daacef266c7b3e3c1e140a6133c" shape="rect">cudaErrorUnknown</a></p>
338                      </div>
339                      <div class="section">
340                         <h6 class="deprecated_header"><a class="xref xrefsect-title" href="deprecated.html#deprecated__deprecated_1_deprecated000016" shape="rect">Deprecated</a></h6>
341                         <p><span class="ph xrefsect-description">This function is deprecated as of CUDA 3.0.</span></p>
342                         <h6 class="description_header">Description</h6>
343                         <p>Returns in <tt class="ph tt code">*pPitch</tt> and <tt class="ph tt code">*pPitchSlice</tt> the pitch and Z-slice pitch of the subresource of the mapped Direct3D resource <tt class="ph tt code">pResource</tt>, which corresponds to <tt class="ph tt code">face</tt> and <tt class="ph tt code">level</tt>. The values set in <tt class="ph tt code">pPitch</tt> and <tt class="ph tt code">pPitchSlice</tt> may change every time that <tt class="ph tt code">pResource</tt> is mapped.
344                         </p>
345                         <p class="p">The pitch and Z-slice pitch values may be used to compute the location of a sample on a surface as follows.</p>
346                         <p class="p">For a 2D surface, the byte offset of the sample at position <strong class="ph b">x</strong>, <strong class="ph b">y</strong> from the base pointer of the surface is:
347                         </p>
348                         <p class="p"><strong class="ph b">y</strong> * <strong class="ph b">pitch</strong> + (<strong class="ph b">bytes per pixel</strong>) * <strong class="ph b">x</strong></p>
349                         <p class="p">For a 3D surface, the byte offset of the sample at position <strong class="ph b">x</strong>, <strong class="ph b">y</strong>, <strong class="ph b">z</strong> from the base pointer of the surface is:
350                         </p>
351                         <p class="p"><strong class="ph b">z*</strong><strong class="ph b">slicePitch</strong> + <strong class="ph b">y</strong> * <strong class="ph b">pitch</strong> + (<strong class="ph b">bytes per pixel</strong>) * <strong class="ph b">x</strong></p>
352                         <p class="p">Both parameters <tt class="ph tt code">pPitch</tt> and <tt class="ph tt code">pPitchSlice</tt> are optional and may be set to NULL.
353                         </p>
354                         <p class="p">If <tt class="ph tt code">pResource</tt> is not of type IDirect3DBaseTexture9 or one of its sub-types or if <tt class="ph tt code">pResource</tt> has not been registered for use with CUDA, then <a class="xref" href="group__CUDART__TYPES.html#group__CUDART__TYPES_1gg3f51e3575c2178246db0a94a430e0038c4673247aee4d1ab8d07871f376e0273" shape="rect">cudaErrorInvalidResourceHandle</a> is returned. If <tt class="ph tt code">pResource</tt> was not registered with usage flags <a class="xref" href="group__CUDART__D3D9__DEPRECATED.html#group__CUDART__D3D9__DEPRECATED_1ggcdebbc14eb83032da31bd75503cddfea10cd58f205c593368626b4ec54a54744" shape="rect">cudaD3D9RegisterFlagsNone</a>, then <a class="xref" href="group__CUDART__TYPES.html#group__CUDART__TYPES_1gg3f51e3575c2178246db0a94a430e0038c4673247aee4d1ab8d07871f376e0273" shape="rect">cudaErrorInvalidResourceHandle</a> is returned. If <tt class="ph tt code">pResource</tt> is not mapped for access by CUDA then <a class="xref" href="group__CUDART__TYPES.html#group__CUDART__TYPES_1gg3f51e3575c2178246db0a94a430e00382e491daacef266c7b3e3c1e140a6133c" shape="rect">cudaErrorUnknown</a> is returned.
355                         </p>
356                         <p class="p">For usage requirements of <tt class="ph tt code">face</tt> and <tt class="ph tt code">level</tt> parameters, see <a class="xref" href="group__CUDART__D3D9__DEPRECATED.html#group__CUDART__D3D9__DEPRECATED_1g44923b51ce411b519c9a3f5a1674071a" title="Get a pointer through which to access a subresource of a Direct3D resource which has been mapped for access by CUDA." shape="rect">cudaD3D9ResourceGetMappedPointer()</a>.
357                         </p>
358                         <p class="p"></p>
359                         <p class="p"></p>
360                         <p class="p">
361                            <div class="note note"><span class="notetitle">Note:</span><p class="p">Note that this function may also return error codes from previous, asynchronous launches.</p>
362                            </div>
363                         </p>
364                         <p class="p"></p>
365                         <p class="p apiDesc_subtitle"><strong class="ph b">See also:</strong></p>
366                         <p class="p see_subsection"><a class="xref" href="group__CUDART__INTEROP.html#group__CUDART__INTEROP_1ge7f893864a3d38a630e71a99f5a4e17f" title="Get an device pointer through which to access a mapped graphics resource." shape="rect">cudaGraphicsResourceGetMappedPointer</a></p>
367                         <p class="p"></p>
368                      </div>
369                   </dd>
370                   <dt class="description"><a name="group__CUDART__D3D9__DEPRECATED_1g44923b51ce411b519c9a3f5a1674071a" id="group__CUDART__D3D9__DEPRECATED_1g44923b51ce411b519c9a3f5a1674071a" shape="rect">
371                         <!-- --></a><span><a href="group__CUDART__TYPES.html#group__CUDART__TYPES_1gf599e5b8b829ce7db0f5216928f6ecb6" title="" shape="rect">cudaError_t</a> cudaD3D9ResourceGetMappedPointer (  void**<span>&nbsp;</span><span class="keyword keyword apiItemName">pPointer</span>, IDirect3DResource9*<span>&nbsp;</span><span class="keyword keyword apiItemName">pResource</span>, unsigned int <span>&nbsp;</span><span class="keyword keyword apiItemName">face</span>, unsigned int <span>&nbsp;</span><span class="keyword keyword apiItemName">level</span> ) </span></dt>
372                   <dd class="description">
373                      <div class="section">Get a pointer through which to access a subresource of a Direct3D resource which has been mapped for access by CUDA. </div>
374                      <div class="section">
375                         <h6 class="parameter_header">
376                            Parameters
377                            
378                         </h6>
379                         <dl class="table-display-params">
380                            <dt><tt class="code"><span class="keyword keyword apiItemName">pPointer</span></tt></dt>
381                            <dd>- Returned pointer corresponding to subresource </dd>
382                            <dt><tt class="code"><span class="keyword keyword apiItemName">pResource</span></tt></dt>
383                            <dd>- Mapped resource to access </dd>
384                            <dt><tt class="code"><span class="keyword keyword apiItemName">face</span></tt></dt>
385                            <dd>- Face of resource to access </dd>
386                            <dt><tt class="code"><span class="keyword keyword apiItemName">level</span></tt></dt>
387                            <dd>- Level of resource to access</dd>
388                         </dl>
389                      </div>
390                      <div class="section">
391                         <h6 class="return_header">Returns</h6>
392                         <p class="return"><a class="xref" href="group__CUDART__TYPES.html#group__CUDART__TYPES_1gg3f51e3575c2178246db0a94a430e0038e355f04607d824883b4a50662830d591" shape="rect">cudaSuccess</a>, <a class="xref" href="group__CUDART__TYPES.html#group__CUDART__TYPES_1gg3f51e3575c2178246db0a94a430e00383e8aef5398ee38e28ed41e357b48917c" shape="rect">cudaErrorInvalidValue</a>, <a class="xref" href="group__CUDART__TYPES.html#group__CUDART__TYPES_1gg3f51e3575c2178246db0a94a430e0038c4673247aee4d1ab8d07871f376e0273" shape="rect">cudaErrorInvalidResourceHandle</a>, <a class="xref" href="group__CUDART__TYPES.html#group__CUDART__TYPES_1gg3f51e3575c2178246db0a94a430e00382e491daacef266c7b3e3c1e140a6133c" shape="rect">cudaErrorUnknown</a></p>
393                      </div>
394                      <div class="section">
395                         <h6 class="deprecated_header"><a class="xref xrefsect-title" href="deprecated.html#deprecated__deprecated_1_deprecated000014" shape="rect">Deprecated</a></h6>
396                         <p><span class="ph xrefsect-description">This function is deprecated as of CUDA 3.0.</span></p>
397                         <h6 class="description_header">Description</h6>
398                         <p>Returns in <tt class="ph tt code">*pPointer</tt> the base pointer of the subresource of the mapped Direct3D resource <tt class="ph tt code">pResource</tt>, which corresponds to <tt class="ph tt code">face</tt> and <tt class="ph tt code">level</tt>. The value set in <tt class="ph tt code">pPointer</tt> may change every time that <tt class="ph tt code">pResource</tt> is mapped.
399                         </p>
400                         <p class="p">If <tt class="ph tt code">pResource</tt> is not registered, then <a class="xref" href="group__CUDART__TYPES.html#group__CUDART__TYPES_1gg3f51e3575c2178246db0a94a430e0038c4673247aee4d1ab8d07871f376e0273" shape="rect">cudaErrorInvalidResourceHandle</a> is returned. If <tt class="ph tt code">pResource</tt> was not registered with usage flags <a class="xref" href="group__CUDART__D3D9__DEPRECATED.html#group__CUDART__D3D9__DEPRECATED_1ggcdebbc14eb83032da31bd75503cddfea10cd58f205c593368626b4ec54a54744" shape="rect">cudaD3D9RegisterFlagsNone</a>, then <a class="xref" href="group__CUDART__TYPES.html#group__CUDART__TYPES_1gg3f51e3575c2178246db0a94a430e0038c4673247aee4d1ab8d07871f376e0273" shape="rect">cudaErrorInvalidResourceHandle</a> is returned. If <tt class="ph tt code">pResource</tt> is not mapped, then <a class="xref" href="group__CUDART__TYPES.html#group__CUDART__TYPES_1gg3f51e3575c2178246db0a94a430e00382e491daacef266c7b3e3c1e140a6133c" shape="rect">cudaErrorUnknown</a> is returned.
401                         </p>
402                         <p class="p">If <tt class="ph tt code">pResource</tt> is of type IDirect3DCubeTexture9, then <tt class="ph tt code">face</tt> must one of the values enumerated by type D3DCUBEMAP_FACES. For all other types, <tt class="ph tt code">face</tt> must be 0. If <tt class="ph tt code">face</tt> is invalid, then <a class="xref" href="group__CUDART__TYPES.html#group__CUDART__TYPES_1gg3f51e3575c2178246db0a94a430e00383e8aef5398ee38e28ed41e357b48917c" shape="rect">cudaErrorInvalidValue</a> is returned.
403                         </p>
404                         <p class="p">If <tt class="ph tt code">pResource</tt> is of type IDirect3DBaseTexture9, then <tt class="ph tt code">level</tt> must correspond to a valid mipmap level. Only mipmap level 0 is supported for now. For all other types <tt class="ph tt code">level</tt> must be 0. If <tt class="ph tt code">level</tt> is invalid, then <a class="xref" href="group__CUDART__TYPES.html#group__CUDART__TYPES_1gg3f51e3575c2178246db0a94a430e00383e8aef5398ee38e28ed41e357b48917c" shape="rect">cudaErrorInvalidValue</a> is returned.
405                         </p>
406                         <p class="p"></p>
407                         <p class="p"></p>
408                         <p class="p">
409                            <div class="note note"><span class="notetitle">Note:</span><p class="p">Note that this function may also return error codes from previous, asynchronous launches.</p>
410                            </div>
411                         </p>
412                         <p class="p"></p>
413                         <p class="p apiDesc_subtitle"><strong class="ph b">See also:</strong></p>
414                         <p class="p see_subsection"><a class="xref" href="group__CUDART__INTEROP.html#group__CUDART__INTEROP_1ge7f893864a3d38a630e71a99f5a4e17f" title="Get an device pointer through which to access a mapped graphics resource." shape="rect">cudaGraphicsResourceGetMappedPointer</a></p>
415                         <p class="p"></p>
416                      </div>
417                   </dd>
418                   <dt class="description"><a name="group__CUDART__D3D9__DEPRECATED_1gb592b874549ec1375a570fac7f5e9ab9" id="group__CUDART__D3D9__DEPRECATED_1gb592b874549ec1375a570fac7f5e9ab9" shape="rect">
419                         <!-- --></a><span><a href="group__CUDART__TYPES.html#group__CUDART__TYPES_1gf599e5b8b829ce7db0f5216928f6ecb6" title="" shape="rect">cudaError_t</a> cudaD3D9ResourceGetMappedSize (  size_t*<span>&nbsp;</span><span class="keyword keyword apiItemName">pSize</span>, IDirect3DResource9*<span>&nbsp;</span><span class="keyword keyword apiItemName">pResource</span>, unsigned int <span>&nbsp;</span><span class="keyword keyword apiItemName">face</span>, unsigned int <span>&nbsp;</span><span class="keyword keyword apiItemName">level</span> ) </span></dt>
420                   <dd class="description">
421                      <div class="section">Get the size of a subresource of a Direct3D resource which has been mapped for access by CUDA. </div>
422                      <div class="section">
423                         <h6 class="parameter_header">
424                            Parameters
425                            
426                         </h6>
427                         <dl class="table-display-params">
428                            <dt><tt class="code"><span class="keyword keyword apiItemName">pSize</span></tt></dt>
429                            <dd>- Returned size of subresource </dd>
430                            <dt><tt class="code"><span class="keyword keyword apiItemName">pResource</span></tt></dt>
431                            <dd>- Mapped resource to access </dd>
432                            <dt><tt class="code"><span class="keyword keyword apiItemName">face</span></tt></dt>
433                            <dd>- Face of resource to access </dd>
434                            <dt><tt class="code"><span class="keyword keyword apiItemName">level</span></tt></dt>
435                            <dd>- Level of resource to access</dd>
436                         </dl>
437                      </div>
438                      <div class="section">
439                         <h6 class="return_header">Returns</h6>
440                         <p class="return"><a class="xref" href="group__CUDART__TYPES.html#group__CUDART__TYPES_1gg3f51e3575c2178246db0a94a430e0038e355f04607d824883b4a50662830d591" shape="rect">cudaSuccess</a>, <a class="xref" href="group__CUDART__TYPES.html#group__CUDART__TYPES_1gg3f51e3575c2178246db0a94a430e00383e8aef5398ee38e28ed41e357b48917c" shape="rect">cudaErrorInvalidValue</a>, <a class="xref" href="group__CUDART__TYPES.html#group__CUDART__TYPES_1gg3f51e3575c2178246db0a94a430e0038c4673247aee4d1ab8d07871f376e0273" shape="rect">cudaErrorInvalidResourceHandle</a>, <a class="xref" href="group__CUDART__TYPES.html#group__CUDART__TYPES_1gg3f51e3575c2178246db0a94a430e00382e491daacef266c7b3e3c1e140a6133c" shape="rect">cudaErrorUnknown</a></p>
441                      </div>
442                      <div class="section">
443                         <h6 class="deprecated_header"><a class="xref xrefsect-title" href="deprecated.html#deprecated__deprecated_1_deprecated000015" shape="rect">Deprecated</a></h6>
444                         <p><span class="ph xrefsect-description">This function is deprecated as of CUDA 3.0.</span></p>
445                         <h6 class="description_header">Description</h6>
446                         <p>Returns in <tt class="ph tt code">*pSize</tt> the size of the subresource of the mapped Direct3D resource <tt class="ph tt code">pResource</tt>, which corresponds to <tt class="ph tt code">face</tt> and <tt class="ph tt code">level</tt>. The value set in <tt class="ph tt code">pSize</tt> may change every time that <tt class="ph tt code">pResource</tt> is mapped.
447                         </p>
448                         <p class="p">If <tt class="ph tt code">pResource</tt> has not been registered for use with CUDA then <a class="xref" href="group__CUDART__TYPES.html#group__CUDART__TYPES_1gg3f51e3575c2178246db0a94a430e0038c4673247aee4d1ab8d07871f376e0273" shape="rect">cudaErrorInvalidResourceHandle</a> is returned. If <tt class="ph tt code">pResource</tt> was not registered with usage flags <a class="xref" href="group__CUDART__D3D9__DEPRECATED.html#group__CUDART__D3D9__DEPRECATED_1ggcdebbc14eb83032da31bd75503cddfea10cd58f205c593368626b4ec54a54744" shape="rect">cudaD3D9RegisterFlagsNone</a>, then <a class="xref" href="group__CUDART__TYPES.html#group__CUDART__TYPES_1gg3f51e3575c2178246db0a94a430e0038c4673247aee4d1ab8d07871f376e0273" shape="rect">cudaErrorInvalidResourceHandle</a> is returned. If <tt class="ph tt code">pResource</tt> is not mapped for access by CUDA then <a class="xref" href="group__CUDART__TYPES.html#group__CUDART__TYPES_1gg3f51e3575c2178246db0a94a430e00382e491daacef266c7b3e3c1e140a6133c" shape="rect">cudaErrorUnknown</a> is returned.
449                         </p>
450                         <p class="p">For usage requirements of <tt class="ph tt code">face</tt> and <tt class="ph tt code">level</tt> parameters, see <a class="xref" href="group__CUDART__D3D9__DEPRECATED.html#group__CUDART__D3D9__DEPRECATED_1g44923b51ce411b519c9a3f5a1674071a" title="Get a pointer through which to access a subresource of a Direct3D resource which has been mapped for access by CUDA." shape="rect">cudaD3D9ResourceGetMappedPointer()</a>.
451                         </p>
452                         <p class="p"></p>
453                         <p class="p"></p>
454                         <p class="p">
455                            <div class="note note"><span class="notetitle">Note:</span><p class="p">Note that this function may also return error codes from previous, asynchronous launches.</p>
456                            </div>
457                         </p>
458                         <p class="p"></p>
459                         <p class="p apiDesc_subtitle"><strong class="ph b">See also:</strong></p>
460                         <p class="p see_subsection"><a class="xref" href="group__CUDART__INTEROP.html#group__CUDART__INTEROP_1ge7f893864a3d38a630e71a99f5a4e17f" title="Get an device pointer through which to access a mapped graphics resource." shape="rect">cudaGraphicsResourceGetMappedPointer</a></p>
461                         <p class="p"></p>
462                      </div>
463                   </dd>
464                   <dt class="description"><a name="group__CUDART__D3D9__DEPRECATED_1gb280fa315e4728a11f13e4691b19ef61" id="group__CUDART__D3D9__DEPRECATED_1gb280fa315e4728a11f13e4691b19ef61" shape="rect">
465                         <!-- --></a><span><a href="group__CUDART__TYPES.html#group__CUDART__TYPES_1gf599e5b8b829ce7db0f5216928f6ecb6" title="" shape="rect">cudaError_t</a> cudaD3D9ResourceGetSurfaceDimensions (  size_t*<span>&nbsp;</span><span class="keyword keyword apiItemName">pWidth</span>, size_t*<span>&nbsp;</span><span class="keyword keyword apiItemName">pHeight</span>, size_t*<span>&nbsp;</span><span class="keyword keyword apiItemName">pDepth</span>, IDirect3DResource9*<span>&nbsp;</span><span class="keyword keyword apiItemName">pResource</span>, unsigned int <span>&nbsp;</span><span class="keyword keyword apiItemName">face</span>, unsigned int <span>&nbsp;</span><span class="keyword keyword apiItemName">level</span> ) </span></dt>
466                   <dd class="description">
467                      <div class="section">Get the dimensions of a registered Direct3D surface. </div>
468                      <div class="section">
469                         <h6 class="parameter_header">
470                            Parameters
471                            
472                         </h6>
473                         <dl class="table-display-params">
474                            <dt><tt class="code"><span class="keyword keyword apiItemName">pWidth</span></tt></dt>
475                            <dd>- Returned width of surface </dd>
476                            <dt><tt class="code"><span class="keyword keyword apiItemName">pHeight</span></tt></dt>
477                            <dd>- Returned height of surface </dd>
478                            <dt><tt class="code"><span class="keyword keyword apiItemName">pDepth</span></tt></dt>
479                            <dd>- Returned depth of surface </dd>
480                            <dt><tt class="code"><span class="keyword keyword apiItemName">pResource</span></tt></dt>
481                            <dd>- Registered resource to access </dd>
482                            <dt><tt class="code"><span class="keyword keyword apiItemName">face</span></tt></dt>
483                            <dd>- Face of resource to access </dd>
484                            <dt><tt class="code"><span class="keyword keyword apiItemName">level</span></tt></dt>
485                            <dd>- Level of resource to access</dd>
486                         </dl>
487                      </div>
488                      <div class="section">
489                         <h6 class="return_header">Returns</h6>
490                         <p class="return"><a class="xref" href="group__CUDART__TYPES.html#group__CUDART__TYPES_1gg3f51e3575c2178246db0a94a430e0038e355f04607d824883b4a50662830d591" shape="rect">cudaSuccess</a>, <a class="xref" href="group__CUDART__TYPES.html#group__CUDART__TYPES_1gg3f51e3575c2178246db0a94a430e00383e8aef5398ee38e28ed41e357b48917c" shape="rect">cudaErrorInvalidValue</a>, <a class="xref" href="group__CUDART__TYPES.html#group__CUDART__TYPES_1gg3f51e3575c2178246db0a94a430e0038c4673247aee4d1ab8d07871f376e0273" shape="rect">cudaErrorInvalidResourceHandle</a>, 
491                         </p>
492                      </div>
493                      <div class="section">
494                         <h6 class="deprecated_header"><a class="xref xrefsect-title" href="deprecated.html#deprecated__deprecated_1_deprecated000012" shape="rect">Deprecated</a></h6>
495                         <p><span class="ph xrefsect-description">This function is deprecated as of CUDA 3.0.</span></p>
496                         <h6 class="description_header">Description</h6>
497                         <p>Returns in <tt class="ph tt code">*pWidth</tt>, <tt class="ph tt code">*pHeight</tt>, and <tt class="ph tt code">*pDepth</tt> the dimensions of the subresource of the mapped Direct3D resource <tt class="ph tt code">pResource</tt> which corresponds to <tt class="ph tt code">face</tt> and <tt class="ph tt code">level</tt>.
498                         </p>
499                         <p class="p">Since anti-aliased surfaces may have multiple samples per pixel, it is possible that the dimensions of a resource will be
500                            an integer factor larger than the dimensions reported by the Direct3D runtime.
501                         </p>
502                         <p class="p">The parameters <tt class="ph tt code">pWidth</tt>, <tt class="ph tt code">pHeight</tt>, and <tt class="ph tt code">pDepth</tt> are optional. For 2D surfaces, the value returned in <tt class="ph tt code">*pDepth</tt> will be 0.
503                         </p>
504                         <p class="p">If <tt class="ph tt code">pResource</tt> is not of type IDirect3DBaseTexture9 or IDirect3DSurface9 or if <tt class="ph tt code">pResource</tt> has not been registered for use with CUDA, then <a class="xref" href="group__CUDART__TYPES.html#group__CUDART__TYPES_1gg3f51e3575c2178246db0a94a430e0038c4673247aee4d1ab8d07871f376e0273" shape="rect">cudaErrorInvalidResourceHandle</a> is returned.
505                         </p>
506                         <p class="p">For usage requirements of <tt class="ph tt code">face</tt> and <tt class="ph tt code">level</tt> parameters, see <a class="xref" href="group__CUDART__D3D9__DEPRECATED.html#group__CUDART__D3D9__DEPRECATED_1g44923b51ce411b519c9a3f5a1674071a" title="Get a pointer through which to access a subresource of a Direct3D resource which has been mapped for access by CUDA." shape="rect">cudaD3D9ResourceGetMappedPointer</a>.
507                         </p>
508                         <p class="p"></p>
509                         <p class="p"></p>
510                         <p class="p">
511                            <div class="note note"><span class="notetitle">Note:</span><p class="p">Note that this function may also return error codes from previous, asynchronous launches.</p>
512                            </div>
513                         </p>
514                         <p class="p"></p>
515                         <p class="p apiDesc_subtitle"><strong class="ph b">See also:</strong></p>
516                         <p class="p see_subsection"><a class="xref" href="group__CUDART__INTEROP.html#group__CUDART__INTEROP_1gfc796cc80e7a054b13d90afde659546e" title="Get an array through which to access a subresource of a mapped graphics resource." shape="rect">cudaGraphicsSubResourceGetMappedArray</a></p>
517                         <p class="p"></p>
518                      </div>
519                   </dd>
520                   <dt class="description"><a name="group__CUDART__D3D9__DEPRECATED_1gf0c339fe2a9d07ebc02c0469a6f8c296" id="group__CUDART__D3D9__DEPRECATED_1gf0c339fe2a9d07ebc02c0469a6f8c296" shape="rect">
521                         <!-- --></a><span><a href="group__CUDART__TYPES.html#group__CUDART__TYPES_1gf599e5b8b829ce7db0f5216928f6ecb6" title="" shape="rect">cudaError_t</a> cudaD3D9ResourceSetMapFlags (  IDirect3DResource9*<span>&nbsp;</span><span class="keyword keyword apiItemName">pResource</span>, unsigned int <span>&nbsp;</span><span class="keyword keyword apiItemName">flags</span> ) </span></dt>
522                   <dd class="description">
523                      <div class="section">Set usage flags for mapping a Direct3D resource. </div>
524                      <div class="section">
525                         <h6 class="parameter_header">
526                            Parameters
527                            
528                         </h6>
529                         <dl class="table-display-params">
530                            <dt><tt class="code"><span class="keyword keyword apiItemName">pResource</span></tt></dt>
531                            <dd>- Registered resource to set flags for </dd>
532                            <dt><tt class="code"><span class="keyword keyword apiItemName">flags</span></tt></dt>
533                            <dd>- Parameters for resource mapping</dd>
534                         </dl>
535                      </div>
536                      <div class="section">
537                         <h6 class="return_header">Returns</h6>
538                         <p class="return"><a class="xref" href="group__CUDART__TYPES.html#group__CUDART__TYPES_1gg3f51e3575c2178246db0a94a430e0038e355f04607d824883b4a50662830d591" shape="rect">cudaSuccess</a>, <a class="xref" href="group__CUDART__TYPES.html#group__CUDART__TYPES_1gg3f51e3575c2178246db0a94a430e00383e8aef5398ee38e28ed41e357b48917c" shape="rect">cudaErrorInvalidValue</a>, <a class="xref" href="group__CUDART__TYPES.html#group__CUDART__TYPES_1gg3f51e3575c2178246db0a94a430e0038c4673247aee4d1ab8d07871f376e0273" shape="rect">cudaErrorInvalidResourceHandle</a>, <a class="xref" href="group__CUDART__TYPES.html#group__CUDART__TYPES_1gg3f51e3575c2178246db0a94a430e00382e491daacef266c7b3e3c1e140a6133c" shape="rect">cudaErrorUnknown</a></p>
539                      </div>
540                      <div class="section">
541                         <h6 class="deprecated_header"><a class="xref xrefsect-title" href="deprecated.html#deprecated__deprecated_1_deprecated000011" shape="rect">Deprecated</a></h6>
542                         <p><span class="ph xrefsect-description">This function is deprecated as of CUDA 3.0.</span></p>
543                         <h6 class="description_header">Description</h6>
544                         <p>Set flags for mapping the Direct3D resource <tt class="ph tt code">pResource</tt>.
545                         </p>
546                         <p class="p">Changes to flags will take effect the next time <tt class="ph tt code">pResource</tt> is mapped. The <tt class="ph tt code">flags</tt> argument may be any of the following:
547                         </p>
548                         <p class="p">
549                            <ul class="ul">
550                               <li class="li">
551                                  <p class="p"><a class="xref" href="group__CUDART__D3D9__DEPRECATED.html#group__CUDART__D3D9__DEPRECATED_1gg77fb48ace0d2da465b6f4bcc00ef750b231d4d21c0022f27e2bab622cdfce74f" shape="rect">cudaD3D9MapFlagsNone</a>: Specifies no hints about how this resource will be used. It is therefore assumed that this resource will be read from and
552                                     written to by CUDA kernels. This is the default value.
553                                  </p>
554                               </li>
555                               <li class="li">
556                                  <p class="p"><a class="xref" href="group__CUDART__D3D9__DEPRECATED.html#group__CUDART__D3D9__DEPRECATED_1gg77fb48ace0d2da465b6f4bcc00ef750b60d7fc4cd3b30157833587d6703ed6eb" shape="rect">cudaD3D9MapFlagsReadOnly</a>: Specifies that CUDA kernels which access this resource will not write to this resource.
557                                  </p>
558                               </li>
559                               <li class="li">
560                                  <p class="p"><a class="xref" href="group__CUDART__D3D9__DEPRECATED.html#group__CUDART__D3D9__DEPRECATED_1gg77fb48ace0d2da465b6f4bcc00ef750b85d551879a58618fa74b0783b0ff1f73" shape="rect">cudaD3D9MapFlagsWriteDiscard</a>: Specifies that CUDA kernels which access this resource will not read from this resource and will write over the entire contents
561                                     of the resource, so none of the data previously stored in the resource will be preserved.
562                                  </p>
563                               </li>
564                            </ul>
565                         </p>
566                         <p class="p">If <tt class="ph tt code">pResource</tt> has not been registered for use with CUDA, then <a class="xref" href="group__CUDART__TYPES.html#group__CUDART__TYPES_1gg3f51e3575c2178246db0a94a430e0038c4673247aee4d1ab8d07871f376e0273" shape="rect">cudaErrorInvalidResourceHandle</a> is returned. If <tt class="ph tt code">pResource</tt> is presently mapped for access by CUDA, then <a class="xref" href="group__CUDART__TYPES.html#group__CUDART__TYPES_1gg3f51e3575c2178246db0a94a430e00382e491daacef266c7b3e3c1e140a6133c" shape="rect">cudaErrorUnknown</a> is returned.
567                         </p>
568                         <p class="p"></p>
569                         <p class="p"></p>
570                         <p class="p">
571                            <div class="note note"><span class="notetitle">Note:</span><p class="p">Note that this function may also return error codes from previous, asynchronous launches.</p>
572                            </div>
573                         </p>
574                         <p class="p"></p>
575                         <p class="p apiDesc_subtitle"><strong class="ph b">See also:</strong></p>
576                         <p class="p see_subsection">cudaInteropResourceSetMapFlags </p>
577                         <p class="p"></p>
578                      </div>
579                   </dd>
580                   <dt class="description"><a name="group__CUDART__D3D9__DEPRECATED_1g50f637c33fa9ca33777735f769e7d9a6" id="group__CUDART__D3D9__DEPRECATED_1g50f637c33fa9ca33777735f769e7d9a6" shape="rect">
581                         <!-- --></a><span><a href="group__CUDART__TYPES.html#group__CUDART__TYPES_1gf599e5b8b829ce7db0f5216928f6ecb6" title="" shape="rect">cudaError_t</a> cudaD3D9UnmapResources (  int <span>&nbsp;</span><span class="keyword keyword apiItemName">count</span>, IDirect3DResource9**<span>&nbsp;</span><span class="keyword keyword apiItemName">ppResources</span> ) </span></dt>
582                   <dd class="description">
583                      <div class="section">Unmap Direct3D resources for access by CUDA. </div>
584                      <div class="section">
585                         <h6 class="parameter_header">
586                            Parameters
587                            
588                         </h6>
589                         <dl class="table-display-params">
590                            <dt><tt class="code"><span class="keyword keyword apiItemName">count</span></tt></dt>
591                            <dd>- Number of resources to unmap for CUDA </dd>
592                            <dt><tt class="code"><span class="keyword keyword apiItemName">ppResources</span></tt></dt>
593                            <dd>- Resources to unmap for CUDA</dd>
594                         </dl>
595                      </div>
596                      <div class="section">
597                         <h6 class="return_header">Returns</h6>
598                         <p class="return"><a class="xref" href="group__CUDART__TYPES.html#group__CUDART__TYPES_1gg3f51e3575c2178246db0a94a430e0038e355f04607d824883b4a50662830d591" shape="rect">cudaSuccess</a>, <a class="xref" href="group__CUDART__TYPES.html#group__CUDART__TYPES_1gg3f51e3575c2178246db0a94a430e0038c4673247aee4d1ab8d07871f376e0273" shape="rect">cudaErrorInvalidResourceHandle</a>, <a class="xref" href="group__CUDART__TYPES.html#group__CUDART__TYPES_1gg3f51e3575c2178246db0a94a430e00382e491daacef266c7b3e3c1e140a6133c" shape="rect">cudaErrorUnknown</a></p>
599                      </div>
600                      <div class="section">
601                         <h6 class="deprecated_header"><a class="xref xrefsect-title" href="deprecated.html#deprecated__deprecated_1_deprecated000010" shape="rect">Deprecated</a></h6>
602                         <p><span class="ph xrefsect-description">This function is deprecated as of CUDA 3.0.</span></p>
603                         <h6 class="description_header">Description</h6>
604                         <p>Unmaps the <tt class="ph tt code">count</tt> Direct3D resources in <tt class="ph tt code">ppResources</tt>.
605                         </p>
606                         <p class="p">This function provides the synchronization guarantee that any CUDA kernels issued before <a class="xref" href="group__CUDART__D3D9__DEPRECATED.html#group__CUDART__D3D9__DEPRECATED_1g50f637c33fa9ca33777735f769e7d9a6" title="Unmap Direct3D resources for access by CUDA." shape="rect">cudaD3D9UnmapResources()</a> will complete before any Direct3D calls issued after <a class="xref" href="group__CUDART__D3D9__DEPRECATED.html#group__CUDART__D3D9__DEPRECATED_1g50f637c33fa9ca33777735f769e7d9a6" title="Unmap Direct3D resources for access by CUDA." shape="rect">cudaD3D9UnmapResources()</a> begin.
607                         </p>
608                         <p class="p">If any of <tt class="ph tt code">ppResources</tt> have not been registered for use with CUDA or if <tt class="ph tt code">ppResources</tt> contains any duplicate entries, then <a class="xref" href="group__CUDART__TYPES.html#group__CUDART__TYPES_1gg3f51e3575c2178246db0a94a430e0038c4673247aee4d1ab8d07871f376e0273" shape="rect">cudaErrorInvalidResourceHandle</a> is returned. If any of <tt class="ph tt code">ppResources</tt> are not presently mapped for access by CUDA then <a class="xref" href="group__CUDART__TYPES.html#group__CUDART__TYPES_1gg3f51e3575c2178246db0a94a430e00382e491daacef266c7b3e3c1e140a6133c" shape="rect">cudaErrorUnknown</a> is returned.
609                         </p>
610                         <p class="p"></p>
611                         <p class="p"></p>
612                         <p class="p">
613                            <div class="note note"><span class="notetitle">Note:</span><p class="p">Note that this function may also return error codes from previous, asynchronous launches.</p>
614                            </div>
615                         </p>
616                         <p class="p"></p>
617                         <p class="p apiDesc_subtitle"><strong class="ph b">See also:</strong></p>
618                         <p class="p see_subsection"><a class="xref" href="group__CUDART__INTEROP.html#group__CUDART__INTEROP_1gc4dcf300df27f8cf51a89f0287b07861" title="Unmap graphics resources." shape="rect">cudaGraphicsUnmapResources</a></p>
619                         <p class="p"></p>
620                      </div>
621                   </dd>
622                   <dt class="description"><a name="group__CUDART__D3D9__DEPRECATED_1gcca28bc00d63314d2032c36c0ca1fd4d" id="group__CUDART__D3D9__DEPRECATED_1gcca28bc00d63314d2032c36c0ca1fd4d" shape="rect">
623                         <!-- --></a><span><a href="group__CUDART__TYPES.html#group__CUDART__TYPES_1gf599e5b8b829ce7db0f5216928f6ecb6" title="" shape="rect">cudaError_t</a> cudaD3D9UnregisterResource (  IDirect3DResource9*<span>&nbsp;</span><span class="keyword keyword apiItemName">pResource</span> ) </span></dt>
624                   <dd class="description">
625                      <div class="section">Unregisters a Direct3D resource for access by CUDA. </div>
626                      <div class="section">
627                         <h6 class="parameter_header">
628                            Parameters
629                            
630                         </h6>
631                         <dl class="table-display-params">
632                            <dt><tt class="code"><span class="keyword keyword apiItemName">pResource</span></tt></dt>
633                            <dd>- Resource to unregister</dd>
634                         </dl>
635                      </div>
636                      <div class="section">
637                         <h6 class="return_header">Returns</h6>
638                         <p class="return"><a class="xref" href="group__CUDART__TYPES.html#group__CUDART__TYPES_1gg3f51e3575c2178246db0a94a430e0038e355f04607d824883b4a50662830d591" shape="rect">cudaSuccess</a>, <a class="xref" href="group__CUDART__TYPES.html#group__CUDART__TYPES_1gg3f51e3575c2178246db0a94a430e0038c4673247aee4d1ab8d07871f376e0273" shape="rect">cudaErrorInvalidResourceHandle</a>, <a class="xref" href="group__CUDART__TYPES.html#group__CUDART__TYPES_1gg3f51e3575c2178246db0a94a430e00382e491daacef266c7b3e3c1e140a6133c" shape="rect">cudaErrorUnknown</a></p>
639                      </div>
640                      <div class="section">
641                         <h6 class="deprecated_header"><a class="xref xrefsect-title" href="deprecated.html#deprecated__deprecated_1_deprecated000008" shape="rect">Deprecated</a></h6>
642                         <p><span class="ph xrefsect-description">This function is deprecated as of CUDA 3.0.</span></p>
643                         <h6 class="description_header">Description</h6>
644                         <p>Unregisters the Direct3D resource <tt class="ph tt code">pResource</tt> so it is not accessible by CUDA unless registered again.
645                         </p>
646                         <p class="p">If <tt class="ph tt code">pResource</tt> is not registered, then <a class="xref" href="group__CUDART__TYPES.html#group__CUDART__TYPES_1gg3f51e3575c2178246db0a94a430e0038c4673247aee4d1ab8d07871f376e0273" shape="rect">cudaErrorInvalidResourceHandle</a> is returned.
647                         </p>
648                         <p class="p"></p>
649                         <p class="p"></p>
650                         <p class="p">
651                            <div class="note note"><span class="notetitle">Note:</span><p class="p">Note that this function may also return error codes from previous, asynchronous launches.</p>
652                            </div>
653                         </p>
654                         <p class="p"></p>
655                         <p class="p apiDesc_subtitle"><strong class="ph b">See also:</strong></p>
656                         <p class="p see_subsection"><a class="xref" href="group__CUDART__INTEROP.html#group__CUDART__INTEROP_1g1d45ac44d1affe17fb356e0b7a0b0560" title="Unregisters a graphics resource for access by CUDA." shape="rect">cudaGraphicsUnregisterResource</a></p>
657                         <p class="p"></p>
658                      </div>
659                   </dd>
660                </dl>
661             </div>
662          </div>
663          
664          <hr id="contents-end"></hr>
665          <div id="breadcrumbs"><a href="group__CUDART__D3D9.html" shape="rect">&lt; Previous</a> | <a href="group__CUDART__D3D10.html" shape="rect">Next &gt;</a></div>
666          <div id="release-info">CUDA Runtime API
667             (<a href="../../pdf/CUDA_Runtime_API.pdf">PDF</a>)
668             -
669             CUDA Toolkit v5.5
670             (<a href="https://developer.nvidia.com/cuda-toolkit-archive">older</a>)
671             -
672             Last updated 
673             September 5, 2013
674             -
675             <a href="mailto:cudatools@nvidia.com?subject=CUDA Tools Documentation Feedback: cuda-runtime-api">Send Feedback</a></div>
676          
677       </article>
678       
679       <header id="header"><span id="company">NVIDIA</span><span id="site-title">CUDA Toolkit Documentation</span><form id="search" method="get" action="search">
680             <input type="text" name="search-text"></input><fieldset id="search-location">
681                <legend>Search In:</legend>
682                <label><input type="radio" name="search-type" value="site"></input>Entire Site</label>
683                <label><input type="radio" name="search-type" value="document"></input>Just This Document</label></fieldset>
684             <button type="reset">clear search</button>
685             <button id="submit" type="submit">search</button></form>
686       </header>
687       <nav id="site-nav">
688          <div class="category closed"><span class="twiddle">▷</span><a href="../index.html" title="The root of the site.">CUDA Toolkit</a></div>
689          <ul class="closed">
690             <li><a href="../cuda-toolkit-release-notes/index.html" title="The Release Notes for the CUDA Toolkit from v4.0 to today.">Release Notes</a></li>
691             <li><a href="../eula/index.html" title="The End User License Agreements for the NVIDIA CUDA Toolkit, the NVIDIA CUDA Samples, the NVIDIA Display Driver, and NVIDIA NSight (Visual Studio Edition).">EULA</a></li>
692             <li><a href="../cuda-getting-started-guide-for-linux/index.html" title="This guide discusses how to install and check for correct operation of the CUDA Development Tools on GNU/Linux systems.">Getting Started Linux</a></li>
693             <li><a href="../cuda-getting-started-guide-for-mac-os-x/index.html" title="This guide discusses how to install and check for correct operation of the CUDA Development Tools on Mac OS X systems.">Getting Started Mac OS X</a></li>
694             <li><a href="../cuda-getting-started-guide-for-microsoft-windows/index.html" title="This guide discusses how to install and check for correct operation of the CUDA Development Tools on Microsoft Windows systems.">Getting Started Windows</a></li>
695             <li><a href="../cuda-c-programming-guide/index.html" title="This guide provides a detailed discussion of the CUDA programming model and programming interface. It then describes the hardware implementation, and provides guidance on how to achieve maximum performance. The Appendixes include a list of all CUDA-enabled devices, detailed description of all extensions to the C language, listings of supported mathematical functions, C++ features supported in host and device code, details on texture fetching, technical specifications of various devices, and concludes by introducing the low-level driver API.">Programming Guide</a></li>
696             <li><a href="../cuda-c-best-practices-guide/index.html" title="This guide presents established parallelization and optimization techniques and explains coding metaphors and idioms that can greatly simplify programming for CUDA-capable GPU architectures. The intent is to provide guidelines for obtaining the best performance from NVIDIA GPUs using the CUDA Toolkit.">Best Practices Guide</a></li>
697             <li><a href="../kepler-compatibility-guide/index.html" title="This application note is intended to help developers ensure that their NVIDIA CUDA applications will run effectively on GPUs based on the NVIDIA Kepler Architecture. This document provides guidance to ensure that your software applications are compatible with Kepler.">Kepler Compatibility Guide</a></li>
698             <li><a href="../kepler-tuning-guide/index.html" title="Kepler is NVIDIA's next-generation architecture for CUDA compute applications. Applications that follow the best practices for the Fermi architecture should typically see speedups on the Kepler architecture without any code changes. This guide summarizes the ways that an application can be fine-tuned to gain additional speedups by leveraging Kepler architectural features.">Kepler Tuning Guide</a></li>
699             <li><a href="../parallel-thread-execution/index.html" title="This guide provides detailed instructions on the use of PTX, a low-level parallel thread execution virtual machine and instruction set architecture (ISA). PTX exposes the GPU as a data-parallel computing device.">PTX ISA</a></li>
700             <li><a href="../optimus-developer-guide/index.html" title="This document explains how CUDA APIs can be used to query for GPU capabilities in NVIDIA Optimus systems.">Developer Guide for Optimus</a></li>
701             <li><a href="../video-decoder/index.html" title="This document provides the video decoder API specification and the format conversion and display using DirectX or OpenGL following decode.">Video Decoder</a></li>
702             <li><a href="../video-encoder/index.html" title="This document provides the CUDA video encoder specifications, including the C-library API functions and encoder query parameters.">Video Encoder</a></li>
703             <li><a href="../inline-ptx-assembly/index.html" title="This document shows how to inline PTX (parallel thread execution) assembly language statements into CUDA code. It describes available assembler statement parameters and constraints, and the document also provides a list of some pitfalls that you may encounter.">Inline PTX Assembly</a></li>
704             <li><a href="../cuda-runtime-api/index.html" title="The CUDA runtime API.">CUDA Runtime API</a></li>
705             <li><a href="../cuda-driver-api/index.html" title="The CUDA driver API.">CUDA Driver API</a></li>
706             <li><a href="../cuda-math-api/index.html" title="The CUDA math API.">CUDA Math API</a></li>
707             <li><a href="../cublas/index.html" title="The CUBLAS library is an implementation of BLAS (Basic Linear Algebra Subprograms) on top of the NVIDIA CUDA runtime. It allows the user to access the computational resources of NVIDIA Graphical Processing Unit (GPU), but does not auto-parallelize across multiple GPUs.">CUBLAS</a></li>
708             <li><a href="../cufft/index.html" title="The CUFFT library user guide.">CUFFT</a></li>
709             <li><a href="../curand/index.html" title="The CURAND library user guide.">CURAND</a></li>
710             <li><a href="../cusparse/index.html" title="The CUSPARSE library user guide.">CUSPARSE</a></li>
711             <li><a href="../npp/index.html" title="NVIDIA NPP is a library of functions for performing CUDA accelerated processing. The initial set of functionality in the library focuses on imaging and video processing and is widely applicable for developers in these areas. NPP will evolve over time to encompass more of the compute heavy tasks in a variety of problem domains. The NPP library is written to maximize flexibility, while maintaining high performance.">NPP</a></li>
712             <li><a href="../thrust/index.html" title="The Thrust getting started guide.">Thrust</a></li>
713             <li><a href="../cuda-samples/index.html" title="This document contains a complete listing of the code samples that are included with the NVIDIA CUDA Toolkit. It describes each code sample, lists the minimum GPU specification, and provides links to the source code and white papers if available.">CUDA Samples</a></li>
714             <li><a href="../cuda-compiler-driver-nvcc/index.html" title="This document is a reference guide on the use of the CUDA compiler driver nvcc. Instead of being a specific CUDA compilation driver, nvcc mimics the behavior of the GNU compiler gcc, accepting a range of conventional compiler options, such as for defining macros and include/library paths, and for steering the compilation process.">NVCC</a></li>
715             <li><a href="../cuda-gdb/index.html" title="The NVIDIA tool for debugging CUDA applications running on Linux and Mac, providing developers with a mechanism for debugging CUDA applications running on actual hardware. CUDA-GDB is an extension to the x86-64 port of GDB, the GNU Project debugger.">CUDA-GDB</a></li>
716             <li><a href="../cuda-memcheck/index.html" title="CUDA-MEMCHECK is a suite of run time tools capable of precisely detecting out of bounds and misaligned memory access errors, checking device allocation leaks, reporting hardware errors and identifying shared memory data access hazards.">CUDA-MEMCHECK</a></li>
717             <li><a href="../nsight-eclipse-edition-getting-started-guide/index.html" title="Nsight Eclipse Edition getting started guide">Nsight Eclipse Edition</a></li>
718             <li><a href="../profiler-users-guide/index.html" title="This is the guide to the Profiler.">Profiler</a></li>
719             <li><a href="../cuda-binary-utilities/index.html" title="The application notes for cuobjdump and nvdisasm.">CUDA Binary Utilities</a></li>
720             <li><a href="../floating-point/index.html" title="A number of issues related to floating point accuracy and compliance are a frequent source of confusion on both CPUs and GPUs. The purpose of this white paper is to discuss the most common issues related to NVIDIA GPUs and to supplement the documentation in the CUDA C Programming Guide.">Floating Point and IEEE 754</a></li>
721             <li><a href="../incomplete-lu-cholesky/index.html" title="In this white paper we show how to use the CUSPARSE and CUBLAS libraries to achieve a 2x speedup over CPU in the incomplete-LU and Cholesky preconditioned iterative methods. We focus on the Bi-Conjugate Gradient Stabilized and Conjugate Gradient iterative methods, that can be used to solve large sparse nonsymmetric and symmetric positive definite linear systems, respectively. Also, we comment on the parallel sparse triangular solve, which is an essential building block in these algorithms.">Incomplete-LU and Cholesky Preconditioned Iterative Methods</a></li>
722             <li><a href="../libnvvm-api/index.html" title="The libNVVM API.">libNVVM API</a></li>
723             <li><a href="../libdevice-users-guide/index.html" title="The libdevice library is an LLVM bitcode library that implements common functions for GPU kernels.">libdevice User's Guide</a></li>
724             <li><a href="../nvvm-ir-spec/index.html" title="NVVM IR is a compiler IR (internal representation) based on the LLVM IR. The NVVM IR is designed to represent GPU compute kernels (for example, CUDA kernels). High-level language front-ends, like the CUDA C compiler front-end, can generate NVVM IR.">NVVM IR</a></li>
725             <li><a href="../cupti/index.html" title="The CUPTI API.">CUPTI</a></li>
726             <li><a href="../debugger-api/index.html" title="The CUDA debugger API.">Debugger API</a></li>
727             <li><a href="../gpudirect-rdma/index.html" title="A tool for Kepler-class GPUs and CUDA 5.0 enabling a direct path for communication between the GPU and a peer device on the PCI Express bus when the devices share the same upstream root complex using standard features of PCI Express. This document introduces the technology and describes the steps necessary to enable a RDMA for GPUDirect connection to NVIDIA GPUs within the Linux device driver model.">RDMA for GPUDirect</a></li>
728          </ul>
729          <div class="category"><span class="twiddle">▼</span><a href="index.html" title="CUDA Runtime API">CUDA Runtime API</a></div>
730          <ul>
731             <li><a href="api-sync-behavior.html#api-sync-behavior">1.&nbsp;API synchronization behavior </a></li>
732             <li><a href="modules.html#modules">2.&nbsp;Modules</a><ul>
733                   <li><a href="group__CUDART__DEVICE.html#group__CUDART__DEVICE">2.1.&nbsp;Device Management</a></li>
734                   <li><a href="group__CUDART__THREAD__DEPRECATED.html#group__CUDART__THREAD__DEPRECATED">2.2.&nbsp;Thread Management [DEPRECATED]</a></li>
735                   <li><a href="group__CUDART__ERROR.html#group__CUDART__ERROR">2.3.&nbsp;Error Handling</a></li>
736                   <li><a href="group__CUDART__STREAM.html#group__CUDART__STREAM">2.4.&nbsp;Stream Management</a></li>
737                   <li><a href="group__CUDART__EVENT.html#group__CUDART__EVENT">2.5.&nbsp;Event Management</a></li>
738                   <li><a href="group__CUDART__EXECUTION.html#group__CUDART__EXECUTION">2.6.&nbsp;Execution Control</a></li>
739                   <li><a href="group__CUDART__MEMORY.html#group__CUDART__MEMORY">2.7.&nbsp;Memory Management</a></li>
740                   <li><a href="group__CUDART__UNIFIED.html#group__CUDART__UNIFIED">2.8.&nbsp;Unified Addressing</a></li>
741                   <li><a href="group__CUDART__PEER.html#group__CUDART__PEER">2.9.&nbsp;Peer Device Memory Access</a></li>
742                   <li><a href="group__CUDART__OPENGL.html#group__CUDART__OPENGL">2.10.&nbsp;OpenGL Interoperability</a></li>
743                   <li><a href="group__CUDART__OPENGL__DEPRECATED.html#group__CUDART__OPENGL__DEPRECATED">2.11.&nbsp;OpenGL Interoperability [DEPRECATED]</a></li>
744                   <li><a href="group__CUDART__D3D9.html#group__CUDART__D3D9">2.12.&nbsp;Direct3D 9 Interoperability</a></li>
745                   <li><a href="group__CUDART__D3D9__DEPRECATED.html#group__CUDART__D3D9__DEPRECATED">2.13.&nbsp;Direct3D 9 Interoperability [DEPRECATED]</a></li>
746                   <li><a href="group__CUDART__D3D10.html#group__CUDART__D3D10">2.14.&nbsp;Direct3D 10 Interoperability</a></li>
747                   <li><a href="group__CUDART__D3D10__DEPRECATED.html#group__CUDART__D3D10__DEPRECATED">2.15.&nbsp;Direct3D 10 Interoperability [DEPRECATED]</a></li>
748                   <li><a href="group__CUDART__D3D11.html#group__CUDART__D3D11">2.16.&nbsp;Direct3D 11 Interoperability</a></li>
749                   <li><a href="group__CUDART__D3D11__DEPRECATED.html#group__CUDART__D3D11__DEPRECATED">2.17.&nbsp;Direct3D 11 Interoperability [DEPRECATED]</a></li>
750                   <li><a href="group__CUDART__VDPAU.html#group__CUDART__VDPAU">2.18.&nbsp;VDPAU Interoperability</a></li>
751                   <li><a href="group__CUDART__INTEROP.html#group__CUDART__INTEROP">2.19.&nbsp;Graphics Interoperability</a></li>
752                   <li><a href="group__CUDART__TEXTURE.html#group__CUDART__TEXTURE">2.20.&nbsp;Texture Reference Management</a></li>
753                   <li><a href="group__CUDART__SURFACE.html#group__CUDART__SURFACE">2.21.&nbsp;Surface Reference Management</a></li>
754                   <li><a href="group__CUDART__TEXTURE__OBJECT.html#group__CUDART__TEXTURE__OBJECT">2.22.&nbsp;Texture Object Management</a></li>
755                   <li><a href="group__CUDART__SURFACE__OBJECT.html#group__CUDART__SURFACE__OBJECT">2.23.&nbsp;Surface Object Management</a></li>
756                   <li><a href="group__CUDART____VERSION.html#group__CUDART____VERSION">2.24.&nbsp;Version Management</a></li>
757                   <li><a href="group__CUDART__HIGHLEVEL.html#group__CUDART__HIGHLEVEL">2.25.&nbsp;C++ API Routines</a></li>
758                   <li><a href="group__CUDART__DRIVER.html#group__CUDART__DRIVER">2.26.&nbsp;Interactions with the CUDA Driver API</a></li>
759                   <li><a href="group__CUDART__PROFILER.html#group__CUDART__PROFILER">2.27.&nbsp;Profiler Control</a></li>
760                   <li><a href="group__CUDART__TYPES.html#group__CUDART__TYPES">2.28.&nbsp;Data types used by CUDA Runtime</a></li>
761                </ul>
762             </li>
763             <li><a href="annotated.html#annotated">3.&nbsp;Data Structures</a><ul>
764                   <li><a href="structcudaChannelFormatDesc.html#structcudaChannelFormatDesc">3.1.&nbsp;cudaChannelFormatDesc</a></li>
765                   <li><a href="structcudaDeviceProp.html#structcudaDeviceProp">3.2.&nbsp;cudaDeviceProp</a></li>
766                   <li><a href="structcudaExtent.html#structcudaExtent">3.3.&nbsp;cudaExtent</a></li>
767                   <li><a href="structcudaFuncAttributes.html#structcudaFuncAttributes">3.4.&nbsp;cudaFuncAttributes</a></li>
768                   <li><a href="structcudaIpcEventHandle__t.html#structcudaIpcEventHandle__t">3.5.&nbsp;cudaIpcEventHandle_t</a></li>
769                   <li><a href="structcudaIpcMemHandle__t.html#structcudaIpcMemHandle__t">3.6.&nbsp;cudaIpcMemHandle_t</a></li>
770                   <li><a href="structcudaMemcpy3DParms.html#structcudaMemcpy3DParms">3.7.&nbsp;cudaMemcpy3DParms</a></li>
771                   <li><a href="structcudaMemcpy3DPeerParms.html#structcudaMemcpy3DPeerParms">3.8.&nbsp;cudaMemcpy3DPeerParms</a></li>
772                   <li><a href="structcudaPitchedPtr.html#structcudaPitchedPtr">3.9.&nbsp;cudaPitchedPtr</a></li>
773                   <li><a href="structcudaPointerAttributes.html#structcudaPointerAttributes">3.10.&nbsp;cudaPointerAttributes</a></li>
774                   <li><a href="structcudaPos.html#structcudaPos">3.11.&nbsp;cudaPos</a></li>
775                   <li><a href="structcudaResourceDesc.html#structcudaResourceDesc">3.12.&nbsp;cudaResourceDesc</a></li>
776                   <li><a href="structcudaResourceViewDesc.html#structcudaResourceViewDesc">3.13.&nbsp;cudaResourceViewDesc</a></li>
777                   <li><a href="structcudaTextureDesc.html#structcudaTextureDesc">3.14.&nbsp;cudaTextureDesc</a></li>
778                   <li><a href="structsurfaceReference.html#structsurfaceReference">3.15.&nbsp;surfaceReference</a></li>
779                   <li><a href="structtextureReference.html#structtextureReference">3.16.&nbsp;textureReference</a></li>
780                </ul>
781             </li>
782             <li><a href="functions.html#functions">4.&nbsp;Data Fields</a></li>
783             <li><a href="deprecated.html#deprecated">5.&nbsp;Deprecated List</a></li>
784             <li><a href="notices-header.html#notices-header">Notices</a><ul></ul>
785             </li>
786          </ul>
787       </nav>
788       <nav id="search-results">
789          <h2>Search Results</h2>
790          <ol></ol>
791       </nav>
792       <script language="JavaScript" type="text/javascript" charset="utf-8" src="../common/formatting/common.min.js"></script>
793       <script language="JavaScript" type="text/javascript" charset="utf-8" src="../common/scripts/omniture/s_code_us_dev_aut1-nolinktrackin.js"></script>
794       <script language="JavaScript" type="text/javascript" charset="utf-8" src="../common/scripts/omniture/omniture.js"></script>
795       <noscript><a href="http://www.omniture.com" title="Web Analytics"><img src="http://omniture.nvidia.com/b/ss/nvidiacudadocs/1/H.17--NS/0" height="1" width="1" border="0" alt=""></img></a></noscript>
796       <script language="JavaScript" type="text/javascript" charset="utf-8" src="../common/scripts/google-analytics/google-analytics-write.js"></script>
797       <script language="JavaScript" type="text/javascript" charset="utf-8" src="../common/scripts/google-analytics/google-analytics-tracker.js"></script>
798       </body>
799 </html>