module-RGBShiftShader.html 2.0 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243
  1. <!DOCTYPE html>
  2. <html lang="en">
  3. <head>
  4. <meta charset="utf-8">
  5. <title>RGBShiftShader - 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. <h1 translate="no">RGBShiftShader</h1>
  13. <section>
  14. <header>
  15. </header>
  16. <article>
  17. <h2 class="subsection-title">Import</h2>
  18. <p><span translate="no">RGBShiftShader</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>
  19. <pre><code class="language-js">import { RGBShiftShader } from 'three/addons/shaders/RGBShiftShader.js';</code></pre>
  20. <div class="container-overview">
  21. </div>
  22. <h2 class="subsection-title">Properties</h2>
  23. <div class="member">
  24. <h3 class="name" id="~RGBShiftShader" translate="no">.<a href="#~RGBShiftShader">RGBShiftShader</a><span class="type-signature"> : <a href="ShaderMaterial.html#~Shader">ShaderMaterial~Shader</a></span> <span class="type-signature">(inner, constant) </span></h3>
  25. <div class="description">
  26. <p>RGB Shift Shader
  27. Shifts red and blue channels from center in opposite directions
  28. Ported from https://web.archive.org/web/20090820185047/http://kriss.cx/tom/2009/05/rgb-shift/
  29. by Tom Butterworth / https://web.archive.org/web/20090810054752/http://kriss.cx/tom/</p>
  30. <p>amount: shift distance (1 is width of input)
  31. angle: shift angle in radians</p>
  32. </div>
  33. </div>
  34. <h2 class="subsection-title">Source</h2>
  35. <p>
  36. <a href="https://github.com/mrdoob/three.js/blob/master/examples/jsm/shaders/RGBShiftShader.js" translate="no" target="_blank" rel="noopener">examples/jsm/shaders/RGBShiftShader.js</a>
  37. </p>
  38. </article>
  39. </section>
  40. <script src="../scripts/linenumber.js"></script>
  41. <script src="../scripts/page.js"></script>
  42. </body>
  43. </html>
粤ICP备19079148号