Renderer.html 2.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475
  1. <!DOCTYPE html>
  2. <html lang="en">
  3. <head>
  4. <meta charset="utf-8" />
  5. <base href="../../../" />
  6. <script src="page.js"></script>
  7. <link type="text/css" rel="stylesheet" href="page.css" />
  8. </head>
  9. <body>
  10. <h1>WebGLRenderer Constants</h1>
  11. <h2>Cull Face Modes</h2>
  12. <code>
  13. THREE.CullFaceNone
  14. THREE.CullFaceBack
  15. THREE.CullFaceFront
  16. THREE.CullFaceFrontBack
  17. </code>
  18. <p>
  19. [page:constant CullFaceNone] disables face culling.<br />
  20. [page:constant CullFaceBack] culls back faces (default).<br />
  21. [page:constant CullFaceFront] culls front faces.<br />
  22. [page:constant CullFaceFrontBack] culls both front and back faces.
  23. </p>
  24. <h2>Shadow Types</h2>
  25. <code>
  26. THREE.BasicShadowMap
  27. THREE.PCFShadowMap
  28. THREE.PCFSoftShadowMap
  29. THREE.VSMShadowMap
  30. </code>
  31. <p>
  32. These define the WebGLRenderer's [page:WebGLRenderer.shadowMap.type shadowMap.type] property.<br /><br />
  33. [page:constant BasicShadowMap] gives unfiltered shadow maps - fastest, but
  34. lowest quality.<br />
  35. [page:constant PCFShadowMap] filters shadow maps using the
  36. Percentage-Closer Filtering (PCF) algorithm (default).<br />
  37. [page:constant PCFSoftShadowMap] filters shadow maps using the
  38. Percentage-Closer Filtering (PCF) algorithm with better soft shadows
  39. especially when using low-resolution shadow maps.<br />
  40. [page:constant VSMShadowMap] filters shadow maps using the Variance Shadow
  41. Map (VSM) algorithm. When using VSMShadowMap all shadow receivers will
  42. also cast shadows.
  43. </p>
  44. <h2>Tone Mapping</h2>
  45. <code>
  46. THREE.NoToneMapping
  47. THREE.LinearToneMapping
  48. THREE.ReinhardToneMapping
  49. THREE.CineonToneMapping
  50. THREE.ACESFilmicToneMapping
  51. THREE.CustomToneMapping
  52. </code>
  53. <p>
  54. These define the WebGLRenderer's [page:WebGLRenderer.toneMapping toneMapping] property. This is used to approximate the appearance of high
  55. dynamic range (HDR) on the low dynamic range medium of a standard computer
  56. monitor or mobile device's screen.
  57. </p>
  58. <p>
  59. THREE.LinearToneMapping, THREE.ReinhardToneMapping,
  60. THREE.CineonToneMapping and THREE.ACESFilmicToneMapping are built-in
  61. implementations of tone mapping. THREE.CustomToneMapping expects a custom
  62. implementation by modyfing GLSL code of the material's fragment shader.
  63. See the [example:webgl_tonemapping WebGL / tonemapping] example.
  64. </p>
  65. <h2>Source</h2>
  66. <p>
  67. [link:https://github.com/mrdoob/three.js/blob/master/src/constants.js src/constants.js]
  68. </p>
  69. </body>
  70. </html>