DotScreenNode.html 4.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111
  1. <!DOCTYPE html>
  2. <html lang="en">
  3. <head>
  4. <meta charset="utf-8">
  5. <title>DotScreenNode - 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="Node.html">Node</a> → <a href="TempNode.html">TempNode</a> → </p>
  13. <h1 translate="no">DotScreenNode</h1>
  14. <section>
  15. <header>
  16. <div class="class-description"><p>Post processing node for creating dot-screen effect.</p></div>
  17. </header>
  18. <article>
  19. <h2 class="subsection-title">Import</h2>
  20. <p><span translate="no">DotScreenNode</span> is an addon, and must be imported explicitly, see <a href="https://threejs.org/manual/#en/installation" target="_blank" rel="noopener">Installation#Addons</a>.</p>
  21. <pre><code class="language-js">import { dotScreen } from 'three/addons/tsl/display/DotScreenNode.js';</code></pre>
  22. <div class="container-overview">
  23. <h2>Constructor</h2>
  24. <h3 class="name name-method" id="DotScreenNode" translate="no">new <a href="#DotScreenNode">DotScreenNode</a><span class="signature">( inputNode : <span class="param-type"><a href="Node.html">Node</a></span>, angle : <span class="param-type">number</span>, scale : <span class="param-type">number</span> )</span> </h3>
  25. <div class="method">
  26. <div class="description">
  27. <p>Constructs a new dot screen node.</p>
  28. </div>
  29. <table class="params">
  30. <tbody>
  31. <tr>
  32. <td class="name">
  33. <strong>inputNode</strong>
  34. </td>
  35. <td class="description last">
  36. <p>The node that represents the input of the effect.</p>
  37. </td>
  38. </tr>
  39. <tr>
  40. <td class="name">
  41. <strong>angle</strong>
  42. </td>
  43. <td class="description last">
  44. <p>The rotation of the effect in radians.</p>
  45. <p>Default is <code>1.57</code>.</p>
  46. </td>
  47. </tr>
  48. <tr>
  49. <td class="name">
  50. <strong>scale</strong>
  51. </td>
  52. <td class="description last">
  53. <p>The scale of the effect. A higher value means smaller dots.</p>
  54. <p>Default is <code>1</code>.</p>
  55. </td>
  56. </tr>
  57. </tbody>
  58. </table>
  59. </div>
  60. </div>
  61. <h2 class="subsection-title">Properties</h2>
  62. <div class="member">
  63. <h3 class="name" id="angle" translate="no">.<a href="#angle">angle</a><span class="type-signature"> : <a href="UniformNode.html">UniformNode</a>.&lt;float></span> </h3>
  64. <div class="description">
  65. <p>A uniform node that represents the rotation of the effect in radians.</p>
  66. </div>
  67. </div>
  68. <div class="member">
  69. <h3 class="name" id="inputNode" translate="no">.<a href="#inputNode">inputNode</a><span class="type-signature"> : <a href="Node.html">Node</a></span> </h3>
  70. <div class="description">
  71. <p>The node that represents the input of the effect.</p>
  72. </div>
  73. </div>
  74. <div class="member">
  75. <h3 class="name" id="scale" translate="no">.<a href="#scale">scale</a><span class="type-signature"> : <a href="UniformNode.html">UniformNode</a>.&lt;float></span> </h3>
  76. <div class="description">
  77. <p>A uniform node that represents the scale of the effect. A higher value means smaller dots.</p>
  78. </div>
  79. </div>
  80. <h2 class="subsection-title">Methods</h2>
  81. <h3 class="name name-method" id="setup" translate="no">.<a href="#setup">setup</a><span class="signature">( builder : <span class="param-type"><a href="NodeBuilder.html">NodeBuilder</a></span> )</span><span class="type-signature"> : ShaderCallNodeInternal</span> </h3>
  82. <div class="method">
  83. <div class="description">
  84. <p>This method is used to setup the effect's TSL code.</p>
  85. </div>
  86. <table class="params">
  87. <tbody>
  88. <tr>
  89. <td class="name">
  90. <strong>builder</strong>
  91. </td>
  92. <td class="description last">
  93. <p>The current node builder.</p>
  94. </td>
  95. </tr>
  96. </tbody>
  97. </table>
  98. <dl class="details">
  99. <dt class="tag-overrides"><strong>Overrides:</strong> <a href="TempNode.html#setup">TempNode#setup</a></dt>
  100. </dl>
  101. </div>
  102. <h2 class="subsection-title">Source</h2>
  103. <p>
  104. <a href="https://github.com/mrdoob/three.js/blob/master/examples/jsm/tsl/display/DotScreenNode.js" translate="no" target="_blank" rel="noopener">examples/jsm/tsl/display/DotScreenNode.js</a>
  105. </p>
  106. </article>
  107. </section>
  108. <script src="../scripts/linenumber.js"></script>
  109. <script src="../scripts/page.js"></script>
  110. </body>
  111. </html>
粤ICP备19079148号