Light.html 2.1 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879
  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:Object3D] &rarr;
  12. <h1>[name]</h1>
  13. <p class="desc">
  14. Abstract base class for lights - all other light types inherit the properties and methods
  15. described here.
  16. </p>
  17. <h2>Constructor</h2>
  18. <h3>[name]( [param:Integer color], [param:float intensity] )</h3>
  19. <p>
  20. [page:Integer color] - (optional) hexadecimal color of the light. Default is 0xffffff (white).<br />
  21. [page:Float intensity] - (optional) numeric value of the light's strength/intensity. Default is 1.<br /><br />
  22. Creates a new [name]. Note that this is not intended to be called directly (use one of derived classes instead).
  23. </p>
  24. <h2>Properties</h2>
  25. <p>
  26. See the base [page:Object3D Object3D] class for common properties.
  27. </p>
  28. <h3>[property:Color color]</h3>
  29. <p>
  30. Color of the light. Defaults to a new [page:Color] set to white, if not passed in the constructor.<br />
  31. </p>
  32. <h3>[property:Float intensity]</h3>
  33. <p>
  34. The light's intensity, or strength.<br />
  35. In [page:WebGLRenderer.physicallyCorrectLights physically correct] mode, the product of
  36. [page:.color color] * intensity is interpreted as luminous intensity measured in candela.<br />
  37. Default - *1.0*.
  38. </p>
  39. <h3>[property:Boolean isLight]</h3>
  40. <p>
  41. Used to check whether this or derived classes are lights. Default is *true*.<br /><br />
  42. You should not change this, as it used internally for optimisation.
  43. </p>
  44. <h2>Methods</h2>
  45. <p>
  46. See the base [page:Object3D Object3D] class for common methods.
  47. </p>
  48. <h3>[method:Light copy]( [param:Light source] )</h3>
  49. <p>
  50. Copies the value of [page:.color color] and [page:.intensity intensity] from the
  51. [page:Light source] light into this one.
  52. </p>
  53. <h3>[method:JSON toJSON]( [param:String meta] )</h3>
  54. <p>
  55. Return Light data in JSON format.
  56. </p>
  57. <h2>Source</h2>
  58. [link:https://github.com/mrdoob/three.js/blob/master/src/[path].js src/[path].js]
  59. </body>
  60. </html>