Sophie

Sophie

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

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: cuD3D9CtxCreateOnDevice</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__CUDA__D3D9.html">Direct3D 9 Interoperability</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__CUDA__D3D9_gab201a2284d11b00cdb4d6bba492e520.html#gab201a2284d11b00cdb4d6bba492e520">cuD3D9CtxCreate</a></td></tr>
          <tr><td class="navtab"><a class="qindexHL" href="group__CUDA__D3D9_gcaca5329caf0c0253a5a944ecc958742.html#gcaca5329caf0c0253a5a944ecc958742">cuD3D9CtxCreateOnDevice</a></td></tr>
          <tr><td class="navtab"><a class="qindex" href="group__CUDA__D3D9_g8164ac030b6a8c0d95e433201a31ad15.html#g8164ac030b6a8c0d95e433201a31ad15">CUd3d9DeviceList</a></td></tr>
          <tr><td class="navtab"><a class="qindex" href="group__CUDA__D3D9_g9503b73234034811ae9594811fcadb48.html#g9503b73234034811ae9594811fcadb48">CUd3d9DeviceList_enum</a></td></tr>
          <tr><td class="navtab"><a class="qindex" href="group__CUDA__D3D9_ge293c667e76dafaaf47ce64d0bd91c4d.html#ge293c667e76dafaaf47ce64d0bd91c4d">cuD3D9GetDevice</a></td></tr>
          <tr><td class="navtab"><a class="qindex" href="group__CUDA__D3D9_g2c53ac0b20c57738fa497d1f8992f7ad.html#g2c53ac0b20c57738fa497d1f8992f7ad">cuD3D9GetDevices</a></td></tr>
          <tr><td class="navtab"><a class="qindex" href="group__CUDA__D3D9_g439e074e2b46156f859c40ddaaf3d3fb.html#g439e074e2b46156f859c40ddaaf3d3fb">cuD3D9GetDirect3DDevice</a></td></tr>
          <tr><td class="navtab"><a class="qindex" href="group__CUDA__D3D9_g391835e0d3c5a34bdba99840157194bf.html#g391835e0d3c5a34bdba99840157194bf">cuGraphicsD3D9RegisterResource</a></td></tr>
        </table>
      </div>
   </td>
   <td valign="top">
<a class="anchor" name="gcaca5329caf0c0253a5a944ecc958742"></a><!-- doxytag: member="cudaD3D9.h::cuD3D9CtxCreateOnDevice" ref="gcaca5329caf0c0253a5a944ecc958742" args="(CUcontext *pCtx, unsigned int flags, IDirect3DDevice9 *pD3DDevice, CUdevice cudaDevice)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="group__CUDA__TYPES_g09da14df1a751dcbfeccb9cf0073d64c.html#g09da14df1a751dcbfeccb9cf0073d64c">CUresult</a> cuD3D9CtxCreateOnDevice           </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="group__CUDA__TYPES_gf9f5bd81658f866613785b3a0bb7d7d9.html#gf9f5bd81658f866613785b3a0bb7d7d9">CUcontext</a> *&nbsp;</td>
          <td class="paramname"> <em>pCtx</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">unsigned int&nbsp;</td>
          <td class="paramname"> <em>flags</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">IDirect3DDevice9 *&nbsp;</td>
          <td class="paramname"> <em>pD3DDevice</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="group__CUDA__TYPES_gcd81b70eb9968392bb5cdf582af8eab4.html#gcd81b70eb9968392bb5cdf582af8eab4">CUdevice</a>&nbsp;</td>
          <td class="paramname"> <em>cudaDevice</em></td><td>&nbsp;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td><td></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>
Creates a new CUDA context, enables interoperability for that context with the Direct3D device <code>pD3DDevice</code>, and associates the created CUDA context with the calling thread. The created <a class="el" href="group__CUDA__TYPES_gf9f5bd81658f866613785b3a0bb7d7d9.html#gf9f5bd81658f866613785b3a0bb7d7d9">CUcontext</a> will be returned in <code>*pCtx</code>. Direct3D resources from this device may be registered and mapped through the lifetime of this CUDA context.<p>
On success, this call will increase the internal reference count on <code>pD3DDevice</code>. This reference count will be decremented upon destruction of this context through <a class="el" href="group__CUDA__CTX_g27a365aebb0eb548166309f58a1e8b8e.html#g27a365aebb0eb548166309f58a1e8b8e" title="Destroy a CUDA context.">cuCtxDestroy()</a>. This context will cease to function if <code>pD3DDevice</code> is destroyed or encounters an error.<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>pCtx</em>&nbsp;</td><td>- Returned newly created CUDA context </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>flags</em>&nbsp;</td><td>- Context creation flags (see <a class="el" href="group__CUDA__CTX_g65dc0012348bc84810e2103a40d8e2cf.html#g65dc0012348bc84810e2103a40d8e2cf" title="Create a CUDA context.">cuCtxCreate()</a> for details) </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>pD3DDevice</em>&nbsp;</td><td>- Direct3D device to create interoperability context with </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>cudaDevice</em>&nbsp;</td><td>- The CUDA device on which to create the context. This device must be among the devices returned when querying CU_D3D9_DEVICES_ALL from <a class="el" href="group__CUDA__D3D9_g2c53ac0b20c57738fa497d1f8992f7ad.html#g2c53ac0b20c57738fa497d1f8992f7ad" title="Gets the CUDA devices corresponding to a Direct3D 9 device.">cuD3D9GetDevices</a>.</td></tr>
  </table>
</dl>
<dl class="return" compact><dt><b>Returns:</b></dt><dd><a class="el" href="group__CUDA__TYPES_g0cdead942fd5028d157641eef6bdeeaa.html#gg0cdead942fd5028d157641eef6bdeeaaa0eed720f8a87cd1c5fd1c453bc7a03d">CUDA_SUCCESS</a>, <a class="el" href="group__CUDA__TYPES_g0cdead942fd5028d157641eef6bdeeaa.html#gg0cdead942fd5028d157641eef6bdeeaaacf52f132faf29b473cdda6061f0f44a">CUDA_ERROR_DEINITIALIZED</a>, <a class="el" href="group__CUDA__TYPES_g0cdead942fd5028d157641eef6bdeeaa.html#gg0cdead942fd5028d157641eef6bdeeaa8feb999f0af99b4a25ab26b3866f4df8">CUDA_ERROR_NOT_INITIALIZED</a>, <a class="el" href="group__CUDA__TYPES_g0cdead942fd5028d157641eef6bdeeaa.html#gg0cdead942fd5028d157641eef6bdeeaa90696c86fcee1f536a1ec7d25867feeb">CUDA_ERROR_INVALID_VALUE</a>, <a class="el" href="group__CUDA__TYPES_g0cdead942fd5028d157641eef6bdeeaa.html#gg0cdead942fd5028d157641eef6bdeeaa264c50688ed110e8476b591befe60c02">CUDA_ERROR_OUT_OF_MEMORY</a>, <a class="el" href="group__CUDA__TYPES_g0cdead942fd5028d157641eef6bdeeaa.html#gg0cdead942fd5028d157641eef6bdeeaac5a6ab0245179d297f1fa56ed0097183">CUDA_ERROR_UNKNOWN</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__CUDA__D3D9_g2c53ac0b20c57738fa497d1f8992f7ad.html#g2c53ac0b20c57738fa497d1f8992f7ad" title="Gets the CUDA devices corresponding to a Direct3D 9 device.">cuD3D9GetDevices</a>, <a class="el" href="group__CUDA__D3D9_g391835e0d3c5a34bdba99840157194bf.html#g391835e0d3c5a34bdba99840157194bf" title="Register a Direct3D 9 resource for access by CUDA.">cuGraphicsD3D9RegisterResource</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>