WebGLCubeRenderTarget.html 6.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150
  1. <!DOCTYPE html>
  2. <html lang="en">
  3. <head>
  4. <meta charset="utf-8">
  5. <title>WebGLCubeRenderTarget - Three.js Docs</title>
  6. <meta name="viewport" content="width=device-width, user-scalable=no, minimum-scale=1.0, maximum-scale=1.0">
  7. <script src="../scripts/highlight.min.js"></script>
  8. <link type="text/css" rel="stylesheet" href="../styles/highlight-three.css">
  9. <link type="text/css" rel="stylesheet" href="../styles/page.css">
  10. </head>
  11. <body>
  12. <p class="inheritance" translate="no"><a href="EventDispatcher.html">EventDispatcher</a> → <a href="RenderTarget.html">RenderTarget</a> → <a href="WebGLRenderTarget.html">WebGLRenderTarget</a> → </p>
  13. <h1 translate="no">WebGLCubeRenderTarget</h1>
  14. <section>
  15. <header>
  16. <div class="class-description"><p>A cube render target used in context of <a href="WebGLRenderer.html">WebGLRenderer</a>.</p></div>
  17. </header>
  18. <article>
  19. <div class="container-overview">
  20. <h2>Constructor</h2>
  21. <h3 class="name name-method" id="WebGLCubeRenderTarget" translate="no">new <a href="#WebGLCubeRenderTarget">WebGLCubeRenderTarget</a><span class="signature">( size : <span class="param-type">number</span>, options : <span class="param-type"><a href="RenderTarget.html#~Options">RenderTarget~Options</a></span> )</span> </h3>
  22. <div class="method">
  23. <div class="description">
  24. <p>Constructs a new cube render target.</p>
  25. </div>
  26. <table class="params">
  27. <tbody>
  28. <tr>
  29. <td class="name">
  30. <strong>size</strong>
  31. </td>
  32. <td class="description last">
  33. <p>The size of the render target.</p>
  34. <p>Default is <code>1</code>.</p>
  35. </td>
  36. </tr>
  37. <tr>
  38. <td class="name">
  39. <strong>options</strong>
  40. </td>
  41. <td class="description last">
  42. <p>The configuration object.</p>
  43. </td>
  44. </tr>
  45. </tbody>
  46. </table>
  47. </div>
  48. </div>
  49. <h2 class="subsection-title">Properties</h2>
  50. <div class="member">
  51. <h3 class="name" id="isWebGLCubeRenderTarget" translate="no">.<a href="#isWebGLCubeRenderTarget">isWebGLCubeRenderTarget</a><span class="type-signature"> : boolean</span> <span class="type-signature">(readonly) </span></h3>
  52. <div class="description">
  53. <p>This flag can be used for type testing.</p>
  54. <p>Default is <code>true</code>.</p>
  55. </div>
  56. </div>
  57. <div class="member">
  58. <h3 class="name" id="texture" translate="no">.<a href="#texture">texture</a><span class="type-signature"> : <a href="DataArrayTexture.html">DataArrayTexture</a></span> </h3>
  59. <div class="description">
  60. <p>Overwritten with a different texture type.</p>
  61. </div>
  62. <dl class="details">
  63. <dt class="tag-overrides"><strong>Overrides:</strong> <a href="WebGLRenderTarget.html#texture">WebGLRenderTarget#texture</a></dt>
  64. </dl>
  65. </div>
  66. <h2 class="subsection-title">Methods</h2>
  67. <h3 class="name name-method" id="clear" translate="no">.<a href="#clear">clear</a><span class="signature">( renderer : <span class="param-type"><a href="WebGLRenderer.html">WebGLRenderer</a></span>, color : <span class="param-type">boolean</span>, depth : <span class="param-type">boolean</span>, stencil : <span class="param-type">boolean</span> )</span> </h3>
  68. <div class="method">
  69. <div class="description">
  70. <p>Clears this cube render target.</p>
  71. </div>
  72. <table class="params">
  73. <tbody>
  74. <tr>
  75. <td class="name">
  76. <strong>renderer</strong>
  77. </td>
  78. <td class="description last">
  79. <p>The renderer.</p>
  80. </td>
  81. </tr>
  82. <tr>
  83. <td class="name">
  84. <strong>color</strong>
  85. </td>
  86. <td class="description last">
  87. <p>Whether the color buffer should be cleared or not.</p>
  88. <p>Default is <code>true</code>.</p>
  89. </td>
  90. </tr>
  91. <tr>
  92. <td class="name">
  93. <strong>depth</strong>
  94. </td>
  95. <td class="description last">
  96. <p>Whether the depth buffer should be cleared or not.</p>
  97. <p>Default is <code>true</code>.</p>
  98. </td>
  99. </tr>
  100. <tr>
  101. <td class="name">
  102. <strong>stencil</strong>
  103. </td>
  104. <td class="description last">
  105. <p>Whether the stencil buffer should be cleared or not.</p>
  106. <p>Default is <code>true</code>.</p>
  107. </td>
  108. </tr>
  109. </tbody>
  110. </table>
  111. </div>
  112. <h3 class="name name-method" id="fromEquirectangularTexture" translate="no">.<a href="#fromEquirectangularTexture">fromEquirectangularTexture</a><span class="signature">( renderer : <span class="param-type"><a href="WebGLRenderer.html">WebGLRenderer</a></span>, texture : <span class="param-type"><a href="Texture.html">Texture</a></span> )</span><span class="type-signature"> : <a href="WebGLCubeRenderTarget.html">WebGLCubeRenderTarget</a></span> </h3>
  113. <div class="method">
  114. <div class="description">
  115. <p>Converts the given equirectangular texture to a cube map.</p>
  116. </div>
  117. <table class="params">
  118. <tbody>
  119. <tr>
  120. <td class="name">
  121. <strong>renderer</strong>
  122. </td>
  123. <td class="description last">
  124. <p>The renderer.</p>
  125. </td>
  126. </tr>
  127. <tr>
  128. <td class="name">
  129. <strong>texture</strong>
  130. </td>
  131. <td class="description last">
  132. <p>The equirectangular texture.</p>
  133. </td>
  134. </tr>
  135. </tbody>
  136. </table>
  137. <dl class="details">
  138. <dt class="tag-returns"><strong>Returns:</strong> A reference to this cube render target.</dt>
  139. </dl>
  140. </div>
  141. <h2 class="subsection-title">Source</h2>
  142. <p>
  143. <a href="https://github.com/mrdoob/three.js/blob/master/src/renderers/WebGLCubeRenderTarget.js" translate="no" target="_blank" rel="noopener">src/renderers/WebGLCubeRenderTarget.js</a>
  144. </p>
  145. </article>
  146. </section>
  147. <script src="../scripts/linenumber.js"></script>
  148. <script src="../scripts/page.js"></script>
  149. </body>
  150. </html>
粤ICP备19079148号