MeshPhysicalNodeMaterial.html 19 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306
  1. <!DOCTYPE html>
  2. <html lang="en">
  3. <head>
  4. <meta charset="utf-8">
  5. <title>MeshPhysicalNodeMaterial - 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="Material.html">Material</a> → <a href="NodeMaterial.html">NodeMaterial</a> → <a href="MeshStandardNodeMaterial.html">MeshStandardNodeMaterial</a> → </p>
  13. <h1 translate="no">MeshPhysicalNodeMaterial</h1>
  14. <section>
  15. <header>
  16. <div class="class-description"><p>Node material version of <a href="MeshPhysicalMaterial.html">MeshPhysicalMaterial</a>.</p></div>
  17. </header>
  18. <article>
  19. <div class="container-overview">
  20. <h2>Constructor</h2>
  21. <h3 class="name name-method" id="MeshPhysicalNodeMaterial" translate="no">new <a href="#MeshPhysicalNodeMaterial">MeshPhysicalNodeMaterial</a><span class="signature">( parameters : <span class="param-type">Object</span> )</span> </h3>
  22. <div class="method">
  23. <div class="description">
  24. <p>Constructs a new mesh physical node material.</p>
  25. </div>
  26. <table class="params">
  27. <tbody>
  28. <tr>
  29. <td class="name"><code>parameters</code></td>
  30. <td class="description last"><p>The configuration parameter.</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="anisotropyNode" translate="no">.<a href="#anisotropyNode">anisotropyNode</a><span class="type-signature"> : <a href="Node.html">Node</a>.&lt;float></span> </h3>
  39. <div class="description">
  40. <p>The anisotropy of physical materials is by default inferred from the
  41. <code>anisotropy</code> property. This node property allows to overwrite the default
  42. and define the anisotropy with a node instead.</p>
  43. <p>If you don't want to overwrite the anisotropy but modify the existing
  44. value instead, use <a href="TSL.html#materialAnisotropy">materialAnisotropy</a>.<br/>Default is <code>null</code>.</p>
  45. </div>
  46. </div>
  47. <div class="member">
  48. <h3 class="name" id="attenuationColorNode" translate="no">.<a href="#attenuationColorNode">attenuationColorNode</a><span class="type-signature"> : <a href="Node.html">Node</a>.&lt;vec3></span> </h3>
  49. <div class="description">
  50. <p>The attenuation color of physical materials is by default inferred from the
  51. <code>attenuationColor</code> property. This node property allows to overwrite the default
  52. and define the attenuation color with a node instead.</p>
  53. <p>If you don't want to overwrite the attenuation color but modify the existing
  54. value instead, use <a href="TSL.html#materialAttenuationColor">materialAttenuationColor</a>.<br/>Default is <code>null</code>.</p>
  55. </div>
  56. </div>
  57. <div class="member">
  58. <h3 class="name" id="attenuationDistanceNode" translate="no">.<a href="#attenuationDistanceNode">attenuationDistanceNode</a><span class="type-signature"> : <a href="Node.html">Node</a>.&lt;float></span> </h3>
  59. <div class="description">
  60. <p>The attenuation distance of physical materials is by default inferred from the
  61. <code>attenuationDistance</code> property. This node property allows to overwrite the default
  62. and define the attenuation distance with a node instead.</p>
  63. <p>If you don't want to overwrite the attenuation distance but modify the existing
  64. value instead, use <a href="TSL.html#materialAttenuationDistance">materialAttenuationDistance</a>.<br/>Default is <code>null</code>.</p>
  65. </div>
  66. </div>
  67. <div class="member">
  68. <h3 class="name" id="clearcoatNode" translate="no">.<a href="#clearcoatNode">clearcoatNode</a><span class="type-signature"> : <a href="Node.html">Node</a>.&lt;float></span> </h3>
  69. <div class="description">
  70. <p>The clearcoat of physical materials is by default inferred from the <code>clearcoat</code>
  71. and <code>clearcoatMap</code> properties. This node property allows to overwrite the default
  72. and define the clearcoat with a node instead.</p>
  73. <p>If you don't want to overwrite the clearcoat but modify the existing
  74. value instead, use <a href="TSL.html#materialClearcoat">materialClearcoat</a>.<br/>Default is <code>null</code>.</p>
  75. </div>
  76. </div>
  77. <div class="member">
  78. <h3 class="name" id="clearcoatNormalNode" translate="no">.<a href="#clearcoatNormalNode">clearcoatNormalNode</a><span class="type-signature"> : <a href="Node.html">Node</a>.&lt;vec3></span> </h3>
  79. <div class="description">
  80. <p>The clearcoat normal of physical materials is by default inferred from the <code>clearcoatNormalMap</code>
  81. property. This node property allows to overwrite the default
  82. and define the clearcoat normal with a node instead.</p>
  83. <p>If you don't want to overwrite the clearcoat normal but modify the existing
  84. value instead, use <a href="TSL.html#materialClearcoatNormal">materialClearcoatNormal</a>.<br/>Default is <code>null</code>.</p>
  85. </div>
  86. </div>
  87. <div class="member">
  88. <h3 class="name" id="clearcoatRoughnessNode" translate="no">.<a href="#clearcoatRoughnessNode">clearcoatRoughnessNode</a><span class="type-signature"> : <a href="Node.html">Node</a>.&lt;float></span> </h3>
  89. <div class="description">
  90. <p>The clearcoat roughness of physical materials is by default inferred from the <code>clearcoatRoughness</code>
  91. and <code>clearcoatRoughnessMap</code> properties. This node property allows to overwrite the default
  92. and define the clearcoat roughness with a node instead.</p>
  93. <p>If you don't want to overwrite the clearcoat roughness but modify the existing
  94. value instead, use <a href="TSL.html#materialClearcoatRoughness">materialClearcoatRoughness</a>.<br/>Default is <code>null</code>.</p>
  95. </div>
  96. </div>
  97. <div class="member">
  98. <h3 class="name" id="dispersionNode" translate="no">.<a href="#dispersionNode">dispersionNode</a><span class="type-signature"> : <a href="Node.html">Node</a>.&lt;float></span> </h3>
  99. <div class="description">
  100. <p>The dispersion of physical materials is by default inferred from the
  101. <code>dispersion</code> property. This node property allows to overwrite the default
  102. and define the dispersion with a node instead.</p>
  103. <p>If you don't want to overwrite the dispersion but modify the existing
  104. value instead, use <a href="TSL.html#materialDispersion">materialDispersion</a>.<br/>Default is <code>null</code>.</p>
  105. </div>
  106. </div>
  107. <div class="member">
  108. <h3 class="name" id="iorNode" translate="no">.<a href="#iorNode">iorNode</a><span class="type-signature"> : <a href="Node.html">Node</a>.&lt;float></span> </h3>
  109. <div class="description">
  110. <p>The ior of physical materials is by default inferred from the <code>ior</code>
  111. property. This node property allows to overwrite the default
  112. and define the ior with a node instead.</p>
  113. <p>If you don't want to overwrite the ior but modify the existing
  114. value instead, use <a href="TSL.html#materialIOR">materialIOR</a>.<br/>Default is <code>null</code>.</p>
  115. </div>
  116. </div>
  117. <div class="member">
  118. <h3 class="name" id="iridescenceIORNode" translate="no">.<a href="#iridescenceIORNode">iridescenceIORNode</a><span class="type-signature"> : <a href="Node.html">Node</a>.&lt;float></span> </h3>
  119. <div class="description">
  120. <p>The iridescence IOR of physical materials is by default inferred from the <code>iridescenceIOR</code>
  121. property. This node property allows to overwrite the default
  122. and define the iridescence IOR with a node instead.</p>
  123. <p>If you don't want to overwrite the iridescence IOR but modify the existing
  124. value instead, use <a href="TSL.html#materialIridescenceIOR">materialIridescenceIOR</a>.<br/>Default is <code>null</code>.</p>
  125. </div>
  126. </div>
  127. <div class="member">
  128. <h3 class="name" id="iridescenceNode" translate="no">.<a href="#iridescenceNode">iridescenceNode</a><span class="type-signature"> : <a href="Node.html">Node</a>.&lt;float></span> </h3>
  129. <div class="description">
  130. <p>The iridescence of physical materials is by default inferred from the <code>iridescence</code>
  131. property. This node property allows to overwrite the default
  132. and define the iridescence with a node instead.</p>
  133. <p>If you don't want to overwrite the iridescence but modify the existing
  134. value instead, use <a href="TSL.html#materialIridescence">materialIridescence</a>.<br/>Default is <code>null</code>.</p>
  135. </div>
  136. </div>
  137. <div class="member">
  138. <h3 class="name" id="iridescenceThicknessNode" translate="no">.<a href="#iridescenceThicknessNode">iridescenceThicknessNode</a><span class="type-signature"> : <a href="Node.html">Node</a>.&lt;float></span> </h3>
  139. <div class="description">
  140. <p>The iridescence thickness of physical materials is by default inferred from the <code>iridescenceThicknessRange</code>
  141. and <code>iridescenceThicknessMap</code> properties. This node property allows to overwrite the default
  142. and define the iridescence thickness with a node instead.</p>
  143. <p>If you don't want to overwrite the iridescence thickness but modify the existing
  144. value instead, use <a href="TSL.html#materialIridescenceThickness">materialIridescenceThickness</a>.<br/>Default is <code>null</code>.</p>
  145. </div>
  146. </div>
  147. <div class="member">
  148. <h3 class="name" id="isMeshPhysicalNodeMaterial" translate="no">.<a href="#isMeshPhysicalNodeMaterial">isMeshPhysicalNodeMaterial</a><span class="type-signature"> : boolean</span> <span class="type-signature">(readonly) </span></h3>
  149. <div class="description">
  150. <p>This flag can be used for type testing.<br/>Default is <code>true</code>.</p>
  151. </div>
  152. </div>
  153. <div class="member">
  154. <h3 class="name" id="sheenNode" translate="no">.<a href="#sheenNode">sheenNode</a><span class="type-signature"> : <a href="Node.html">Node</a>.&lt;vec3></span> </h3>
  155. <div class="description">
  156. <p>The sheen of physical materials is by default inferred from the <code>sheen</code>, <code>sheenColor</code>
  157. and <code>sheenColorMap</code> properties. This node property allows to overwrite the default
  158. and define the sheen with a node instead.</p>
  159. <p>If you don't want to overwrite the sheen but modify the existing
  160. value instead, use <a href="TSL.html#materialSheen">materialSheen</a>.<br/>Default is <code>null</code>.</p>
  161. </div>
  162. </div>
  163. <div class="member">
  164. <h3 class="name" id="sheenRoughnessNode" translate="no">.<a href="#sheenRoughnessNode">sheenRoughnessNode</a><span class="type-signature"> : <a href="Node.html">Node</a>.&lt;float></span> </h3>
  165. <div class="description">
  166. <p>The sheen roughness of physical materials is by default inferred from the <code>sheenRoughness</code> and
  167. <code>sheenRoughnessMap</code> properties. This node property allows to overwrite the default
  168. and define the sheen roughness with a node instead.</p>
  169. <p>If you don't want to overwrite the sheen roughness but modify the existing
  170. value instead, use <a href="TSL.html#materialSheenRoughness">materialSheenRoughness</a>.<br/>Default is <code>null</code>.</p>
  171. </div>
  172. </div>
  173. <div class="member">
  174. <h3 class="name" id="specularColorNode" translate="no">.<a href="#specularColorNode">specularColorNode</a><span class="type-signature"> : <a href="Node.html">Node</a>.&lt;vec3></span> </h3>
  175. <div class="description">
  176. <p>The specular color of physical materials is by default inferred from the <code>specularColor</code>
  177. and <code>specularColorMap</code> properties. This node property allows to overwrite the default
  178. and define the specular color with a node instead.</p>
  179. <p>If you don't want to overwrite the specular color but modify the existing
  180. value instead, use <a href="TSL.html#materialSpecularColor">materialSpecularColor</a>.<br/>Default is <code>null</code>.</p>
  181. </div>
  182. </div>
  183. <div class="member">
  184. <h3 class="name" id="specularIntensityNode" translate="no">.<a href="#specularIntensityNode">specularIntensityNode</a><span class="type-signature"> : <a href="Node.html">Node</a>.&lt;float></span> </h3>
  185. <div class="description">
  186. <p>The specular intensity of physical materials is by default inferred from the <code>specularIntensity</code>
  187. and <code>specularIntensityMap</code> properties. This node property allows to overwrite the default
  188. and define the specular intensity with a node instead.</p>
  189. <p>If you don't want to overwrite the specular intensity but modify the existing
  190. value instead, use <a href="TSL.html#materialSpecularIntensity">materialSpecularIntensity</a>.<br/>Default is <code>null</code>.</p>
  191. </div>
  192. </div>
  193. <div class="member">
  194. <h3 class="name" id="thicknessNode" translate="no">.<a href="#thicknessNode">thicknessNode</a><span class="type-signature"> : <a href="Node.html">Node</a>.&lt;float></span> </h3>
  195. <div class="description">
  196. <p>The thickness of physical materials is by default inferred from the <code>thickness</code> and
  197. <code>thicknessMap</code> properties. This node property allows to overwrite the default
  198. and define the thickness with a node instead.</p>
  199. <p>If you don't want to overwrite the thickness but modify the existing
  200. value instead, use <a href="TSL.html#materialThickness">materialThickness</a>.<br/>Default is <code>null</code>.</p>
  201. </div>
  202. </div>
  203. <div class="member">
  204. <h3 class="name" id="transmissionNode" translate="no">.<a href="#transmissionNode">transmissionNode</a><span class="type-signature"> : <a href="Node.html">Node</a>.&lt;float></span> </h3>
  205. <div class="description">
  206. <p>The transmission of physical materials is by default inferred from the <code>transmission</code> and
  207. <code>transmissionMap</code> properties. This node property allows to overwrite the default
  208. and define the transmission with a node instead.</p>
  209. <p>If you don't want to overwrite the transmission but modify the existing
  210. value instead, use <a href="TSL.html#materialTransmission">materialTransmission</a>.<br/>Default is <code>null</code>.</p>
  211. </div>
  212. </div>
  213. <div class="member">
  214. <h3 class="name" id="useAnisotropy" translate="no">.<a href="#useAnisotropy">useAnisotropy</a><span class="type-signature"> : boolean</span> </h3>
  215. <div class="description">
  216. <p>Whether the lighting model should use anisotropy or not.<br/>Default is <code>true</code>.</p>
  217. </div>
  218. </div>
  219. <div class="member">
  220. <h3 class="name" id="useClearcoat" translate="no">.<a href="#useClearcoat">useClearcoat</a><span class="type-signature"> : boolean</span> </h3>
  221. <div class="description">
  222. <p>Whether the lighting model should use clearcoat or not.<br/>Default is <code>true</code>.</p>
  223. </div>
  224. </div>
  225. <div class="member">
  226. <h3 class="name" id="useDispersion" translate="no">.<a href="#useDispersion">useDispersion</a><span class="type-signature"> : boolean</span> </h3>
  227. <div class="description">
  228. <p>Whether the lighting model should use dispersion or not.<br/>Default is <code>true</code>.</p>
  229. </div>
  230. </div>
  231. <div class="member">
  232. <h3 class="name" id="useIridescence" translate="no">.<a href="#useIridescence">useIridescence</a><span class="type-signature"> : boolean</span> </h3>
  233. <div class="description">
  234. <p>Whether the lighting model should use iridescence or not.<br/>Default is <code>true</code>.</p>
  235. </div>
  236. </div>
  237. <div class="member">
  238. <h3 class="name" id="useSheen" translate="no">.<a href="#useSheen">useSheen</a><span class="type-signature"> : boolean</span> </h3>
  239. <div class="description">
  240. <p>Whether the lighting model should use sheen or not.<br/>Default is <code>true</code>.</p>
  241. </div>
  242. </div>
  243. <div class="member">
  244. <h3 class="name" id="useTransmission" translate="no">.<a href="#useTransmission">useTransmission</a><span class="type-signature"> : boolean</span> </h3>
  245. <div class="description">
  246. <p>Whether the lighting model should use transmission or not.<br/>Default is <code>true</code>.</p>
  247. </div>
  248. </div>
  249. <h2 class="subsection-title">Methods</h2>
  250. <h3 class="name name-method" id="setupClearcoatNormal" translate="no">.<a href="#setupClearcoatNormal">setupClearcoatNormal</a><span class="signature">()</span><span class="type-signature"> : <a href="Node.html">Node</a>.&lt;vec3></span> </h3>
  251. <div class="method">
  252. <div class="description">
  253. <p>Setups the clearcoat normal node.</p>
  254. </div>
  255. <dl class="details">
  256. <dt class="tag-returns"><strong>Returns:</strong> The clearcoat normal.</dt>
  257. </dl>
  258. </div>
  259. <h3 class="name name-method" id="setupLightingModel" translate="no">.<a href="#setupLightingModel">setupLightingModel</a><span class="signature">()</span><span class="type-signature"> : <a href="PhysicalLightingModel.html">PhysicalLightingModel</a></span> </h3>
  260. <div class="method">
  261. <div class="description">
  262. <p>Setups the lighting model.</p>
  263. </div>
  264. <dl class="details">
  265. <dt class="tag-overrides"><strong>Overrides:</strong> <a href="MeshStandardNodeMaterial.html#setupLightingModel">MeshStandardNodeMaterial#setupLightingModel</a></dt>
  266. </dl>
  267. <dl class="details">
  268. <dt class="tag-returns"><strong>Returns:</strong> The lighting model.</dt>
  269. </dl>
  270. </div>
  271. <h3 class="name name-method" id="setupSpecular" translate="no">.<a href="#setupSpecular">setupSpecular</a><span class="signature">()</span> </h3>
  272. <div class="method">
  273. <div class="description">
  274. <p>Setups the specular related node variables.</p>
  275. </div>
  276. <dl class="details">
  277. <dt class="tag-overrides"><strong>Overrides:</strong> <a href="MeshStandardNodeMaterial.html#setupSpecular">MeshStandardNodeMaterial#setupSpecular</a></dt>
  278. </dl>
  279. </div>
  280. <h3 class="name name-method" id="setupVariants" translate="no">.<a href="#setupVariants">setupVariants</a><span class="signature">( builder : <span class="param-type">NodeBuilder</span> )</span> </h3>
  281. <div class="method">
  282. <div class="description">
  283. <p>Setups the physical specific node variables.</p>
  284. </div>
  285. <table class="params">
  286. <tbody>
  287. <tr>
  288. <td class="name"><code>builder</code></td>
  289. <td class="description last"><p>The current node builder.</p></td>
  290. </tr>
  291. </tbody>
  292. </table>
  293. <dl class="details">
  294. <dt class="tag-overrides"><strong>Overrides:</strong> <a href="MeshStandardNodeMaterial.html#setupVariants">MeshStandardNodeMaterial#setupVariants</a></dt>
  295. </dl>
  296. </div>
  297. <h2 class="subsection-title">Source</h2>
  298. <p>
  299. <a href="https://github.com/mrdoob/three.js/blob/master/src/materials/nodes/MeshPhysicalNodeMaterial.js" target="_blank" rel="noopener" translate="no">src/materials/nodes/MeshPhysicalNodeMaterial.js</a>
  300. </p>
  301. </article>
  302. </section>
  303. <script src="../scripts/linenumber.js"></script>
  304. <script src="../scripts/page.js"></script>
  305. </body>
  306. </html>
粤ICP备19079148号