1
0

StereoCamera.html 4.1 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495
  1. <!DOCTYPE html>
  2. <html lang="en">
  3. <head>
  4. <meta charset="utf-8">
  5. <title>StereoCamera - 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. <h1 translate="no">StereoCamera</h1>
  13. <section>
  14. <header>
  15. <div class="class-description"><p>A special type of camera that uses two perspective cameras with
  16. stereoscopic projection. Can be used for rendering stereo effects
  17. like <a href="https://en.wikipedia.org/wiki/Anaglyph_3D" target="_blank" rel="noopener">3D Anaglyph</a> or
  18. <a href="https://en.wikipedia.org/wiki/parallax_barrier" target="_blank" rel="noopener">Parallax Barrier</a>.</p></div>
  19. </header>
  20. <article>
  21. <div class="container-overview">
  22. <h2>Constructor</h2>
  23. <h3 class="name name-method" id="StereoCamera" translate="no">new <a href="#StereoCamera">StereoCamera</a><span class="signature">()</span> </h3>
  24. <div class="method">
  25. <div class="description">
  26. <p>Constructs a new stereo camera.</p>
  27. </div>
  28. </div>
  29. </div>
  30. <h2 class="subsection-title">Properties</h2>
  31. <div class="member">
  32. <h3 class="name" id="aspect" translate="no">.<a href="#aspect">aspect</a><span class="type-signature"> : number</span> </h3>
  33. <div class="description">
  34. <p>The aspect.</p>
  35. <p>Default is <code>1</code>.</p>
  36. </div>
  37. </div>
  38. <div class="member">
  39. <h3 class="name" id="cameraL" translate="no">.<a href="#cameraL">cameraL</a><span class="type-signature"> : <a href="PerspectiveCamera.html">PerspectiveCamera</a></span> </h3>
  40. <div class="description">
  41. <p>The camera representing the left eye. This is added to layer <code>1</code> so objects to be
  42. rendered by the left camera must also be added to this layer.</p>
  43. </div>
  44. </div>
  45. <div class="member">
  46. <h3 class="name" id="cameraR" translate="no">.<a href="#cameraR">cameraR</a><span class="type-signature"> : <a href="PerspectiveCamera.html">PerspectiveCamera</a></span> </h3>
  47. <div class="description">
  48. <p>The camera representing the right eye. This is added to layer <code>2</code> so objects to be
  49. rendered by the right camera must also be added to this layer.</p>
  50. </div>
  51. </div>
  52. <div class="member">
  53. <h3 class="name" id="eyeSep" translate="no">.<a href="#eyeSep">eyeSep</a><span class="type-signature"> : number</span> </h3>
  54. <div class="description">
  55. <p>The eye separation which represents the distance
  56. between the left and right camera.</p>
  57. <p>Default is <code>0.064</code>.</p>
  58. </div>
  59. </div>
  60. <div class="member">
  61. <h3 class="name" id="type" translate="no">.<a href="#type">type</a><span class="type-signature"> : string</span> <span class="type-signature">(readonly) </span></h3>
  62. <div class="description">
  63. <p>The type property is used for detecting the object type
  64. in context of serialization/deserialization.</p>
  65. </div>
  66. </div>
  67. <h2 class="subsection-title">Methods</h2>
  68. <h3 class="name name-method" id="update" translate="no">.<a href="#update">update</a><span class="signature">( camera : <span class="param-type"><a href="PerspectiveCamera.html">PerspectiveCamera</a></span> )</span> </h3>
  69. <div class="method">
  70. <div class="description">
  71. <p>Updates the stereo camera based on the given perspective camera.</p>
  72. </div>
  73. <table class="params">
  74. <tbody>
  75. <tr>
  76. <td class="name">
  77. <strong>camera</strong>
  78. </td>
  79. <td class="description last">
  80. <p>The perspective camera.</p>
  81. </td>
  82. </tr>
  83. </tbody>
  84. </table>
  85. </div>
  86. <h2 class="subsection-title">Source</h2>
  87. <p>
  88. <a href="https://github.com/mrdoob/three.js/blob/master/src/cameras/StereoCamera.js" translate="no" target="_blank" rel="noopener">src/cameras/StereoCamera.js</a>
  89. </p>
  90. </article>
  91. </section>
  92. <script src="../scripts/linenumber.js"></script>
  93. <script src="../scripts/page.js"></script>
  94. </body>
  95. </html>
粤ICP备19079148号