ShadowMaterial.html 1.6 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364
  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;
  12. <h1>[name]</h1>
  13. <p class="desc">
  14. This material can receive shadows, but otherwise is completely transparent.
  15. </p>
  16. <h2>Code Example</h2>
  17. <code>
  18. var planeGeometry = new THREE.PlaneBufferGeometry( 2000, 2000 );
  19. planeGeometry.rotateX( - Math.PI / 2 );
  20. var planeMaterial = new THREE.ShadowMaterial();
  21. planeMaterial.opacity = 0.2;
  22. var plane = new THREE.Mesh( planeGeometry, planeMaterial );
  23. plane.position.y = -200;
  24. plane.receiveShadow = true;
  25. scene.add( plane );
  26. </code>
  27. <h2>Examples</h2>
  28. <p>
  29. [example:webgl_geometry_spline_editor geometry / spline / editor]
  30. </p>
  31. <h2>Constructor</h2>
  32. <h3>[name]( [param:Object parameters] )</h3>
  33. <p>
  34. [page:Object parameters] - (optional) an object with one or more properties defining the material's appearance.
  35. Any property of the material (including any property inherited from [page:Material]) can be passed in here.<br /><br />
  36. </p>
  37. <h2>Properties</h2>
  38. <p>See the base [page:Material] classes for common properties.</p>
  39. <h3>[property:Boolean transparent]</h3>
  40. <p>Defines whether this material is transparent. Default is *true*.</p>
  41. <h2>Methods</h2>
  42. <p>See the base [page:Material] classes for common methods.</p>
  43. <h2>Source</h2>
  44. <p>
  45. [link:https://github.com/mrdoob/three.js/blob/master/src/[path].js src/[path].js]
  46. </p>
  47. </body>
  48. </html>