ShadowMaterial.html 1.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263
  1. <!DOCTYPE html>
  2. <html lang="en">
  3. <head>
  4. <meta charset="utf-8" />
  5. <base href="../../" />
  6. <script src="list.js"></script>
  7. <script src="page.js"></script>
  8. <link type="text/css" rel="stylesheet" href="page.css" />
  9. </head>
  10. <body>
  11. [page:Material] &rarr; [page:ShaderMaterial] &rarr;
  12. <h1>[name]</h1>
  13. <div class="desc">
  14. This material can recieve shadows, but otherwise is completely transparent.
  15. </div>
  16. <h3>Example</h3>
  17. [example:webgl_geometry_spline_editor gemoetry / spline / editor]
  18. <code>
  19. var planeGeometry = new THREE.PlaneGeometry( 2000, 2000 );
  20. planeGeometry.rotateX( - Math.PI / 2 );
  21. var planeMaterial = new THREE.ShadowMaterial();
  22. planeMaterial.opacity = 0.2;
  23. var plane = new THREE.Mesh( planeGeometry, planeMaterial );
  24. plane.position.y = -200;
  25. plane.receiveShadow = true;
  26. scene.add( plane );
  27. </code>
  28. <h2>Constructor</h2>
  29. <h3>[name]( )</h3>
  30. <h2>Properties</h2>
  31. <div>See the base [page:Material] and [page:ShaderMaterial] classes for common properties.</div>
  32. <h3>[property:Boolean isShadowMaterial]</h3>
  33. <div>
  34. Used to check whether this or derived classes are shadow materials. Default is *true*.<br /><br />
  35. You should not change this, as it used internally for optimisation.
  36. </div>
  37. <h3>[property:Boolean lights]</h3>
  38. <div>Whether the material is affected by lights. Default is *true*.</div>
  39. <h3>[property:Boolean transparent]</h3>
  40. <div>Defines whether this material is transparent. Default is *true*.</div>
  41. <h2>Methods</h2>
  42. <div>See the base [page:Material] and [page:ShaderMaterial] classes for common methods.</div>
  43. <h2>Source</h2>
  44. [link:https://github.com/mrdoob/three.js/blob/master/src/[path].js src/[path].js]
  45. </body>
  46. </html>