Sophie

Sophie

distrib > Mageia > 2 > i586 > media > nonfree-release > by-pkgid > f86555c654b1f4a4c7ccf47789979868 > files > 700

nvidia-cuda-toolkit-devel-4.2.9-2.mga2.nonfree.i586.rpm

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html><head><meta http-equiv="Content-Type" content="text/html;charset=UTF-8">
<title>NVIDIA CUDA Library: cudaD3D10RegisterResource</title>
<link href="customdoxygen.css" rel="stylesheet" type="text/css">
<link href="tabs.css" rel="stylesheet" type="text/css">
</head><body>
<!-- Generated by Doxygen 1.5.8 -->
<div class="navigation" id="top">
  <div class="tabs">
    <ul>
      <li><a href="index.html"><span>Main&nbsp;Page</span></a></li>
      <li><a href="modules.html"><span>Modules</span></a></li>
      <li><a href="annotated.html"><span>Data&nbsp;Structures</span></a></li>
      <li><a href="pages.html"><span>Related&nbsp;Pages</span></a></li>
    </ul>
  </div>
</div>
<div class="contents">
  <div class="navpath"><a class="el" href="group__CUDART__D3D10__DEPRECATED.html">Direct3D 10 Interoperability [DEPRECATED]</a>
  </div>
<table cellspacing="0" cellpadding="0" border="0">
  <tr>
   <td valign="top">
      <div class="navtab">
        <table>
          <tr><td class="navtab"><a class="qindex" href="group__CUDART__D3D10__DEPRECATED_ga4a3d2d5f22faaaa86eba15ecff30d98.html#ga4a3d2d5f22faaaa86eba15ecff30d98">cudaD3D10MapFlags</a></td></tr>
          <tr><td class="navtab"><a class="qindex" href="group__CUDART__D3D10__DEPRECATED_g07bb5ad7c6a8b8417f95f6210dcb2863.html#g07bb5ad7c6a8b8417f95f6210dcb2863">cudaD3D10MapResources</a></td></tr>
          <tr><td class="navtab"><a class="qindex" href="group__CUDART__D3D10__DEPRECATED_g76be8c7eba1b3e3c54c6c9b6b65510de.html#g76be8c7eba1b3e3c54c6c9b6b65510de">cudaD3D10RegisterFlags</a></td></tr>
          <tr><td class="navtab"><a class="qindexHL" href="group__CUDART__D3D10__DEPRECATED_g3e2c5c1e4a3717ef62f04849698e29e0.html#g3e2c5c1e4a3717ef62f04849698e29e0">cudaD3D10RegisterResource</a></td></tr>
          <tr><td class="navtab"><a class="qindex" href="group__CUDART__D3D10__DEPRECATED_g280bd994b759651c2b970271d43707a5.html#g280bd994b759651c2b970271d43707a5">cudaD3D10ResourceGetMappedArray</a></td></tr>
          <tr><td class="navtab"><a class="qindex" href="group__CUDART__D3D10__DEPRECATED_g7facb0cd2235701f25b45c8d6091d2f6.html#g7facb0cd2235701f25b45c8d6091d2f6">cudaD3D10ResourceGetMappedPitch</a></td></tr>
          <tr><td class="navtab"><a class="qindex" href="group__CUDART__D3D10__DEPRECATED_ge4f47fb18bb8489188afdef81959aae3.html#ge4f47fb18bb8489188afdef81959aae3">cudaD3D10ResourceGetMappedPointer</a></td></tr>
          <tr><td class="navtab"><a class="qindex" href="group__CUDART__D3D10__DEPRECATED_g43af14b40baf79e6913cb150d7ee8f3c.html#g43af14b40baf79e6913cb150d7ee8f3c">cudaD3D10ResourceGetMappedSize</a></td></tr>
          <tr><td class="navtab"><a class="qindex" href="group__CUDART__D3D10__DEPRECATED_g8f9aa2ce6edfb4807fc4e41ef79cbadb.html#g8f9aa2ce6edfb4807fc4e41ef79cbadb">cudaD3D10ResourceGetSurfaceDimensions</a></td></tr>
          <tr><td class="navtab"><a class="qindex" href="group__CUDART__D3D10__DEPRECATED_g0633413776593eb44c89962782e27852.html#g0633413776593eb44c89962782e27852">cudaD3D10ResourceSetMapFlags</a></td></tr>
          <tr><td class="navtab"><a class="qindex" href="group__CUDART__D3D10__DEPRECATED_gf5f768abab8b34458d0911e7092f8afb.html#gf5f768abab8b34458d0911e7092f8afb">cudaD3D10UnmapResources</a></td></tr>
          <tr><td class="navtab"><a class="qindex" href="group__CUDART__D3D10__DEPRECATED_g30f187acd639f05de8a2d9c4bc9b9221.html#g30f187acd639f05de8a2d9c4bc9b9221">cudaD3D10UnregisterResource</a></td></tr>
        </table>
      </div>
   </td>
   <td valign="top">
<a class="anchor" name="g3e2c5c1e4a3717ef62f04849698e29e0"></a><!-- doxytag: member="cuda_d3d10_interop.h::cudaD3D10RegisterResource" ref="g3e2c5c1e4a3717ef62f04849698e29e0" args="(ID3D10Resource *pResource, unsigned int flags)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="group__CUDART__TYPES_gf599e5b8b829ce7db0f5216928f6ecb6.html#gf599e5b8b829ce7db0f5216928f6ecb6">cudaError_t</a> cudaD3D10RegisterResource           </td>
          <td>(</td>
          <td class="paramtype">ID3D10Resource *&nbsp;</td>
          <td class="paramname"> <em>pResource</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">unsigned int&nbsp;</td>
          <td class="paramname"> <em>flags</em></td><td>&nbsp;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td><td></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>
<dl compact><dt><b><a class="el" href="deprecated.html#_deprecated000019">Deprecated:</a></b></dt><dd>This function is deprecated as of CUDA 3.0.</dd></dl>
Registers the Direct3D resource <code>pResource</code> for access by CUDA.<p>
If this call is successful, then the application will be able to map and unmap this resource until it is unregistered through <a class="el" href="group__CUDART__D3D10__DEPRECATED_g30f187acd639f05de8a2d9c4bc9b9221.html#g30f187acd639f05de8a2d9c4bc9b9221" title="Unregisters a Direct3D resource.">cudaD3D10UnregisterResource()</a>. Also on success, this call will increase the internal reference count on <code>pResource</code>. This reference count will be decremented when this resource is unregistered through <a class="el" href="group__CUDART__D3D10__DEPRECATED_g30f187acd639f05de8a2d9c4bc9b9221.html#g30f187acd639f05de8a2d9c4bc9b9221" title="Unregisters a Direct3D resource.">cudaD3D10UnregisterResource()</a>.<p>
This call potentially has a high-overhead and should not be called every frame in interactive applications.<p>
The type of <code>pResource</code> must be one of the following:<p>
<ul>
<li>ID3D10Buffer: Cannot be used with <code>flags</code> set to <code>cudaD3D10RegisterFlagsArray</code>.</li><li>ID3D10Texture1D: No restrictions.</li><li>ID3D10Texture2D: No restrictions.</li><li>ID3D10Texture3D: No restrictions.</li></ul>
<p>
The <code>flags</code> argument specifies the mechanism through which CUDA will access the Direct3D resource. The following values are allowed.<p>
<ul>
<li><a class="el" href="group__CUDART__D3D10__DEPRECATED_g76be8c7eba1b3e3c54c6c9b6b65510de.html#gg76be8c7eba1b3e3c54c6c9b6b65510de95fc2f4b886104a90e755c421cef6e89">cudaD3D10RegisterFlagsNone</a>: Specifies that CUDA will access this resource through a <code>void*</code>. The pointer, size, and pitch for each subresource of this resource may be queried through <a class="el" href="group__CUDART__D3D10__DEPRECATED_ge4f47fb18bb8489188afdef81959aae3.html#ge4f47fb18bb8489188afdef81959aae3" title="Gets a pointer through which to access a subresource of a Direct3D resource which...">cudaD3D10ResourceGetMappedPointer()</a>, <a class="el" href="group__CUDART__D3D10__DEPRECATED_g43af14b40baf79e6913cb150d7ee8f3c.html#g43af14b40baf79e6913cb150d7ee8f3c" title="Gets the size of a subresource of a Direct3D resource which has been mapped for access...">cudaD3D10ResourceGetMappedSize()</a>, and <a class="el" href="group__CUDART__D3D10__DEPRECATED_g7facb0cd2235701f25b45c8d6091d2f6.html#g7facb0cd2235701f25b45c8d6091d2f6" title="Gets the pitch of a subresource of a Direct3D resource which has been mapped for...">cudaD3D10ResourceGetMappedPitch()</a> respectively. This option is valid for all resource types.</li><li><a class="el" href="group__CUDART__D3D10__DEPRECATED_g76be8c7eba1b3e3c54c6c9b6b65510de.html#gg76be8c7eba1b3e3c54c6c9b6b65510dea94840c0f64372c6a5c426e527210ff8">cudaD3D10RegisterFlagsArray</a>: Specifies that CUDA will access this resource through a <code>CUarray</code> queried on a sub-resource basis through <a class="el" href="group__CUDART__D3D10__DEPRECATED_g280bd994b759651c2b970271d43707a5.html#g280bd994b759651c2b970271d43707a5" title="Gets an array through which to access a subresource of a Direct3D resource which...">cudaD3D10ResourceGetMappedArray()</a>. This option is only valid for resources of type ID3D10Texture1D, ID3D10Texture2D, and ID3D10Texture3D.</li></ul>
<p>
Not all Direct3D resources of the above types may be used for interoperability with CUDA. The following are some limitations.<p>
<ul>
<li>The primary rendertarget may not be registered with CUDA.</li><li>Resources allocated as shared may not be registered with CUDA.</li><li>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 be shared.</li><li>Surfaces of depth or stencil formats cannot be shared.</li></ul>
<p>
If Direct3D interoperability is not initialized on this context then <a class="el" href="group__CUDART__TYPES_g3f51e3575c2178246db0a94a430e0038.html#gg3f51e3575c2178246db0a94a430e0038938c6e8b96ecde62e3ab5137156f739a">cudaErrorInvalidDevice</a> is returned. If <code>pResource</code> is of incorrect type or is already registered then <a class="el" href="group__CUDART__TYPES_g3f51e3575c2178246db0a94a430e0038.html#gg3f51e3575c2178246db0a94a430e0038c4673247aee4d1ab8d07871f376e0273">cudaErrorInvalidResourceHandle</a> is returned. If <code>pResource</code> cannot be registered then <a class="el" href="group__CUDART__TYPES_g3f51e3575c2178246db0a94a430e0038.html#gg3f51e3575c2178246db0a94a430e00382e491daacef266c7b3e3c1e140a6133c">cudaErrorUnknown</a> is returned.<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"></td><td valign="top"><em>pResource</em>&nbsp;</td><td>- Resource to register </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>flags</em>&nbsp;</td><td>- Parameters for resource registration</td></tr>
  </table>
</dl>
<dl class="return" compact><dt><b>Returns:</b></dt><dd><a class="el" href="group__CUDART__TYPES_g3f51e3575c2178246db0a94a430e0038.html#gg3f51e3575c2178246db0a94a430e0038e355f04607d824883b4a50662830d591">cudaSuccess</a>, <a class="el" href="group__CUDART__TYPES_g3f51e3575c2178246db0a94a430e0038.html#gg3f51e3575c2178246db0a94a430e0038938c6e8b96ecde62e3ab5137156f739a">cudaErrorInvalidDevice</a>, <a class="el" href="group__CUDART__TYPES_g3f51e3575c2178246db0a94a430e0038.html#gg3f51e3575c2178246db0a94a430e00383e8aef5398ee38e28ed41e357b48917c">cudaErrorInvalidValue</a>, <a class="el" href="group__CUDART__TYPES_g3f51e3575c2178246db0a94a430e0038.html#gg3f51e3575c2178246db0a94a430e0038c4673247aee4d1ab8d07871f376e0273">cudaErrorInvalidResourceHandle</a>, <a class="el" href="group__CUDART__TYPES_g3f51e3575c2178246db0a94a430e0038.html#gg3f51e3575c2178246db0a94a430e00382e491daacef266c7b3e3c1e140a6133c">cudaErrorUnknown</a> </dd></dl>
<dl class="note" compact><dt><b>Note:</b></dt><dd>Note that this function may also return error codes from previous, asynchronous launches.</dd></dl>
<dl class="see" compact><dt><b>See also:</b></dt><dd><a class="el" href="group__CUDART__D3D10_g6b09dce4d78b948477dd5c451a2725fa.html#g6b09dce4d78b948477dd5c451a2725fa" title="Registers a Direct3D 10 resource for access by CUDA.">cudaGraphicsD3D10RegisterResource</a> </dd></dl>

</div>
</div><p>
    </td>
  </tr>
</table>
</div>
<hr size="1"><address style="text-align: right;"><small>
Generated by Doxygen for NVIDIA CUDA Library &nbsp;<a
href="http://www.nvidia.com/cuda"><img src="nvidia_logo.jpg" alt="NVIDIA" align="middle" border="0" height="80"></a></small></address>
</body>
</html>