PhongLightingModel.html 4.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990
  1. <!DOCTYPE html>
  2. <html lang="en">
  3. <head>
  4. <meta charset="utf-8">
  5. <title>PhongLightingModel - 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="LightingModel.html">LightingModel</a> → <a href="BasicLightingModel.html">BasicLightingModel</a> → </p>
  13. <h1 translate="no">PhongLightingModel</h1>
  14. <section>
  15. <header>
  16. <div class="class-description"><p>Represents the lighting model for a phong material. Used in <a href="MeshPhongNodeMaterial.html">MeshPhongNodeMaterial</a>.</p></div>
  17. </header>
  18. <article>
  19. <div class="container-overview">
  20. <h2>Constructor</h2>
  21. <h3 class="name name-method" id="PhongLightingModel" translate="no">new <a href="#PhongLightingModel">PhongLightingModel</a><span class="signature">( specular : <span class="param-type">boolean</span> )</span> </h3>
  22. <div class="method">
  23. <div class="description">
  24. <p>Constructs a new phong lighting model.</p>
  25. </div>
  26. <table class="params">
  27. <tbody>
  28. <tr>
  29. <td class="name"><code>specular</code></td>
  30. <td class="description last"><p>Whether specular is supported or not.<br/>Default is <code>true</code>.</p></td>
  31. </tr>
  32. </tbody>
  33. </table>
  34. </div>
  35. </div>
  36. <h2 class="subsection-title">Properties</h2>
  37. <div class="member">
  38. <h3 class="name" id="specular" translate="no">.<a href="#specular">specular</a><span class="type-signature"> : boolean</span> </h3>
  39. <div class="description">
  40. <p>Whether specular is supported or not. Set this to <code>false</code> if you are
  41. looking for a Lambert-like material meaning a material for non-shiny
  42. surfaces, without specular highlights.<br/>Default is <code>true</code>.</p>
  43. </div>
  44. </div>
  45. <h2 class="subsection-title">Methods</h2>
  46. <h3 class="name name-method" id="direct" translate="no">.<a href="#direct">direct</a><span class="signature">( lightData : <span class="param-type">Object</span> )</span> </h3>
  47. <div class="method">
  48. <div class="description">
  49. <p>Implements the direct lighting. The specular portion is optional an can be controlled
  50. with the <a href="PhongLightingModel.html#specular">PhongLightingModel#specular</a> flag.</p>
  51. </div>
  52. <table class="params">
  53. <tbody>
  54. <tr>
  55. <td class="name"><code>lightData</code></td>
  56. <td class="description last"><p>The light data.</p></td>
  57. </tr>
  58. </tbody>
  59. </table>
  60. <dl class="details">
  61. <dt class="tag-overrides"><strong>Overrides:</strong> <a href="BasicLightingModel.html#direct">BasicLightingModel#direct</a></dt>
  62. </dl>
  63. </div>
  64. <h3 class="name name-method" id="indirect" translate="no">.<a href="#indirect">indirect</a><span class="signature">( builder : <span class="param-type">NodeBuilder</span> )</span> </h3>
  65. <div class="method">
  66. <div class="description">
  67. <p>Implements the indirect lighting.</p>
  68. </div>
  69. <table class="params">
  70. <tbody>
  71. <tr>
  72. <td class="name"><code>builder</code></td>
  73. <td class="description last"><p>The current node builder.</p></td>
  74. </tr>
  75. </tbody>
  76. </table>
  77. <dl class="details">
  78. <dt class="tag-overrides"><strong>Overrides:</strong> <a href="BasicLightingModel.html#indirect">BasicLightingModel#indirect</a></dt>
  79. </dl>
  80. </div>
  81. <h2 class="subsection-title">Source</h2>
  82. <p>
  83. <a href="https://github.com/mrdoob/three.js/blob/master/src/nodes/functions/PhongLightingModel.js" target="_blank" rel="noopener" translate="no">src/nodes/functions/PhongLightingModel.js</a>
  84. </p>
  85. </article>
  86. </section>
  87. <script src="../scripts/linenumber.js"></script>
  88. <script src="../scripts/page.js"></script>
  89. </body>
  90. </html>
粤ICP备19079148号